来自:https://github.com/r74tech/wikidot-ajax-mock-server
自用
API 接口地址
本服务器仅接受向以下接口发起 POST 请求:
/ajax-module-connector.php:处理模块请求/ajax-action-connector.php:处理操作请求
模块接口使用方式
向 /ajax-module-connector.php 发送表单 URL 编码格式的 POST 请求,携带以下参数:
- moduleName(必填):待加载的模块名称(示例:
edit/PageEditModule) - callbackIndex:Wikidot 异步 AJAX 系统的回调索引
- 其他参数:根据对应模块的实际需求按需传入
请求示例:
curl -X POST http://localhost:8787/ajax-module-connector.php \
-d "moduleName=edit/PageEditModule&callbackIndex=0&pageId=1"
支持的模块列表
edit/PageEditModule:页面编辑界面edit/PagePreviewModule:页面内容预览history/PageHistoryModule:查看页面历史版本history/PageDiffModule:对比页面版本差异history/PageSourceModule:查看指定版本的页面源码history/PageRevisionListModule:列出页面所有修订版本files/PageFilesModule:查看页面附件列表files/FileUploadModule:文件上传界面pagetags/PageTagsModule:页面标签管理界面viewsource/ViewSourceModule:查看页面源码forum/*:各类论坛相关模块account/*:用户账户相关模块search/SearchModule:搜索功能login/*:登录与身份认证相关模块watch/*:页面 / 帖子关注模块
操作接口使用方式
向 /ajax-action-connector.php 发送表单 URL 编码格式的 POST 请求,携带以下参数:
- action(必填):待执行的操作指令
- moduleName:模块类操作专用参数
- eventName:事件类操作专用参数
- 其他参数:根据对应操作的实际需求按需传入

Comments NOTHING