| Version | Update Time | Status | Author | Description |
|---|---|---|---|---|
0.0.1 | 2022-07-27 09:50:00 | 创建文档 | binguo | 初始化接口文档 |
1. 推送项目设置
1.1. 查询推送项目
Type: GET
Content-Type: application/x-www-form-urlencoded;charset=utf-8
Description: 查询推送项目
Request-example:
curl -X GET -i http://192.168.161.34:8099/wx/push/queryPushProjectResponse-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "45229",
"data": {
"waring": "You may have used non-display generics."
}
}1.2. 添加推送项目
Type: POST
Content-Type: application/x-www-form-urlencoded;charset=utf-8
Description: 添加推送项目
Query-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
url | string | 推送服务接口:post请求 json参数 | false | - |
project | string | 服务名称 | false | - |
Request-example:
curl -X POST -i http://192.168.161.34:8099/wx/push/addPushProject --data 'url=www.xn---xn--nw5a-9h6sj467a.org&project=ppuqpx'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "45229",
"data": {
"waring": "You may have used non-display generics."
}
}1.3. 修改推送项目
Type: PUT
Content-Type: application/json; charset=utf-8
Description: 修改推送项目
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
id | int64 | 主键 | false | - |
url | string | 推送地址 | false | - |
project | string | 推送项目 | false | - |
statu | int32 | 状态 0(有效) 1(无效) | false | - |
Request-example:
curl -X PUT -H 'Content-Type: application/json; charset=utf-8' -i http://192.168.161.34:8099/wx/push/updatePushProject --data '{
"id": 281,
"url": "www.xn---xn--nw5a-9h6sj467a.org",
"project": "36hifl",
"statu": 907
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "45229",
"data": {
"waring": "You may have used non-display generics."
}
}1.4. 删除推送项目
Type: DELETE
Content-Type: application/x-www-form-urlencoded;charset=utf-8
Description: 删除推送项目
Query-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
id | int64 | No comments found. | false | - |
Request-example:
curl -X DELETE -i http://192.168.161.34:8099/wx/push/deletePushProject?id=435Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
success | boolean | 接口调用结果标识 | - |
message | string | 接口调用结果信息 | - |
code | string | 接口调用业务码 | - |
data | object | 接口调用返回数据 | - |
Response-example:
{
"success": true,
"message": "success",
"code": "45229",
"data": {
"waring": "You may have used non-display generics."
}
}2. 微校推送服务
2.1. 微校数据变更推送接口
Type: POST
Content-Type: application/json; charset=utf-8
Description: 微校数据变更推送接口
Body-parameters:
| Parameter | Type | Description | Required | Since |
|---|---|---|---|---|
app_key | string | 应用appKey | false | - |
school_code | string | 学校主体代码 | false | - |
event | string | 推送事件类型 | false | - |
raw_data | string | 推送加密后数据 | false | - |
Request-example:
curl -X POST -H 'Content-Type: application/json; charset=utf-8' -i http://192.168.161.34:8099/wx/wxc/receive --data '{
"app_key": "3zx9s9",
"school_code": "45229",
"event": "ebytou",
"raw_data": "82izkc"
}'Response-fields:
| Field | Type | Description | Since |
|---|---|---|---|
code | int32 | 响应代码 | - |
message | string | 响应消息 | - |
Response-example:
{
"code": 741,
"message": "success"
}3. 错误码列表
| Error code | Description |
|---|---|
10000 | 系统未知异常 |
10001 | 请求方法不支持 |
10002 | 缺少必要的请求头 |
10003 | 无效的token |
10004 | token为空 |
10005 | 管理员登录失败 |
10006 | 权限不足 |
11001 | 参数格式校验失败 |
11002 | body为空 |
11003 | 参数异常 |
11004 | 重复提交表单 |
11005 | 订单提交失败 |
11006 | 消费者消费异常 |
16000 | 数据已存在 |
16000 | 数据不存在 |
16006 | 临时文件不存在 |
16007 | 文件上传失败 |
16008 | 文件太大 |
16009 | 微校信息推送异常 |