module 字段)。POST /api/v1/supports/module_grant.json
Authorization: Basic <encoded-value>
Content-Type: application/json{
"support": {
"sId": 5,
"module": [5, 6]
}
}| 字段 | 类型 | 必填 | 说明 |
|---|---|---|---|
| sId | int | 是 | 坐席 ID(须属于当前服务商) |
| module | int[] | 是 | 模块 mId 数组(1/4/5/6/7/8),见模块映射表 |
| 场景 | 结果 |
|---|---|
| 模块不存在 / 服务商未购买 / 已过期 | errors:XX 功能已过期或未购买 / 功能不存在 |
| 坐席已授权该模块 | already_granted(幂等,不重复写入) |
| 已授权数量达上限(number) | errors:XX 客服授权数量已达上限(N) |
| 授权成功 | granted:写入 servicers_set(type = mId+1);在线客服 (mId=5) 连带开通即时聊天 (type=4);刷新坐席模块 / IM 客服列表缓存;微信网页授权租户同步 add 坐席;写 operateLog (type=8) + 审计日志 ServicerModuleGrant |
{
"support": {
"sId": "5",
"granted_modules": [
{"mId": "5", "module": "在线客服", "result": "granted"},
{"mId": "6", "module": "工单客服", "result": "already_granted"}
],
"errors": [
{"mId": "9", "module": "不存在的模块", "error": "功能不存在"}
]
}
}