阿里云
发表主题 回复主题
  • 766阅读
  • 1回复

[干货分享]智能对话平台API如何使用?(1)

级别: 论坛粉丝
发帖
1296
云币
2596
|yS  %  
Wz%H?m:g#  
1. 问答服务API LY-,cXm&|  
/g$G G9  
M0yv= g  
​ 问答服务的调用采用Restful API方式,服务内部不保存状态,所以调用和调用之间相互独立。调用API需要校验权限,详细说明见https://help.aliyun.com/document_detail/50410.html ^hNl6)hR  
​ 问答服务的输入为目前与用户对话的内容,输出是与输入最匹配的三个知识点,默认第一位最匹配的。 `J] e.K  
__!LTpp  
注意:调用问答服务前,知识库必须先发布,可以在管控台点击“发布”按钮或调用 single:online 接口发布。 1oe,>\\  
+-C.E  
<2N{oK.  
LTxP@pr  
服务提供方式 djH&)&q!  
'Lq+ONX5  
k4a51[SYBK  
协议URL方法参数
HTTPSnlsapi.aliyun.com/qasPOSTbody中的json字符串
!wN2BCSY@  
}`kiULC'=  
请求示例 tn#cVB3  
`;Ho<26  
<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.     "version": "2.0",
  3.     "app_key": "nui-abcefghi",
  4.     "question": "你是谁?",
  5.     "optional": {"domains":"theme1;theme2;theme3","top":3}
  6. }
R2v9gz;W  
XLC9B3Jt  
请求参数说明 ![;={d0  
EB| iW2'  
:.4O Hp1  
参数类型是否必须说明
versionString协议版本号,必须是2.0
app_keyString创建项目时返回的appId,加上”nui-“前缀
questionString问题
optional/domainsString主题列表,多个主题用分号隔开。如果设置了主题,就从这些主题中匹配答案,否则就从该用户的全部知识库匹配答案
optional/topInteger返回答案数量,默认3个
~Oa$rqu%m  
GF6o  
返回结果示例 XwUa|"X6  
(?m{G Q  
<pre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "id": "921a3c8ac36c4df39dd714dd52344a53",
  3.   "success": true,
  4.   "error_code": "",
  5.   "error_message": "",
  6.   "answers": [
  7.     {
  8.       "question": "",
  9.       "answer": "",
  10.       "score": "",
  11.       "domain": "",
  12.       "optional": {}
  13.     },
  14.     {
  15.       "question": "",
  16.       "answer": "",
  17.       "score": "",
  18.       "domain": "",
  19.       "optional": {}
  20.     },
  21.     {
  22.       "question": "",
  23.       "answer": "",
  24.       "score": "",
  25.       "domain": "",
  26.       "optional": {}
  27.     }
  28.   ]
  29. }
U$mDAi$  
;89kL]  
返回参数说明 ,VS(4  
d\uN  
/ cb`%"Z  
参数类型是否必须说明
idString请求id
successBoolean请求是否处理成功
error_codeString如果失败,对应的错误
error_messageString错误信息
answers[]/questionString知识库中匹配到的问题
answers[]/answerString知识库中匹配到的答案
answers[]/scoreFloat该答案对应的得分(0-1.0之间),分越高,答案越准确
answers[]/domainString该条答案所在的主题
answers[]/optionalObject附加数据,不同的业务定义己的数据格式
"]#Ij6ml  
2HtsSS#0Q  
2. 知识库管理API 9v_s_QkL2  
TKM^  
K fD. J)  
0u1ZU4+EC  
2.1 通用接口 jB(+9?;1${  
M#; ks9  
\?; `_E`j  
服务提供方式 h*%FZ}}`q  
协议URL方法参数
HTTPSnlsapi.aliyun.com/manage/qasPOSTbody中为json字符串,query中需要一个action参数
o>_})WM1[  
请求参数说明 x>}ml\R  
参数名类型示例备注
actionStringprojects:list全小写,在query中,https://nlsapi.aliyun.com/manage/qas?action=projects:list
String{“offset”:0, “pageSize”:10}在body中,action对应的参数组
iP0m1  
返回结果为json格式,所有接口返回结果格式一致,唯一区别为data里面的内容。 b%0p<*:a/  
参数类型是否必须说明
requestIdString唯一请求id
resultCodeInteger错误码
resultMessageString返回信息
dataObject每个业务的返回数据
S7)qq  
错误码为调用返回的resultCode,具体数值如下: `wXK&R<`  
错误码说明
0成功
1登录超时
2输入参数错误
3服务器内部错误
4项目名重复
5项目个数达到最大
6资源不存在
100token错误
}9+;-*m/  
is4}s,]$6  
2.2 具体调用参数说明 !gve]>M  
r|EN5  
g3z/yj  
^FKiVKI:  
2.2.1 创建项目 Z#Mm4(KNh  
Z+&V  >  
iX$G($[l(  
Action: projects:create 1Ng+mT  
请求参数说明 g}NO$?ndg  
参数类型是否必须说明
nameString项目名,最大长度为40
descriptionString项目描述,最大长度为160
O;H6`JQ  
请求示例<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "name":"测试项目",
  3.   "description":"这是一个测试项目"
  4. }
%rylmioW>  
返回结果<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId": "xxxxx-xxx-xxx",
  3.   "resultCode": 0,
  4.   "resultMessage": "OK",
  5.   "data": {
  6.     "id": 1,
  7.     "name": "测试项目",
  8.     "description": "这是一个测试项目",
  9.     "appId": "wdhlqi9a",
  10.     "createTime": "2010-11-10 13:46:00"
  11.   }
  12. }
_ocCt XI9  
返回结果说明 v>_@D@pr  
参数类型是否必须说明
idLong项目id
nameString项目名
descriptionString项目描述
appIdString项目appId,加上”nui-“前缀即app key
createTimeString项目创建时间
(-gomn  
wb0$FZzh  
2.2.2 列出项目 inWLIXC,  
E+aePoU  
& Q3Fgj  
Action: projects:list } ?j5V  
请求参数: =6u@ JpOl  
参数类型是否必须说明
offsetInteger从第几个项目开始列出
pageSizeInteger每页个数
krUtOVI  
请求示例:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "offset":0,
  3.   "pageSize":10
  4. }
<rBW6o7  
返回结果:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId": "xxxxx-xxx-xxx",
  3.   "resultCode": 0,
  4.   "resultMessage": "OK",
  5.   "data": {
  6.     "total": 100,
  7.     "offset": 0,
  8.     "pageSize": 10,
  9.     "items": [
  10.       {
  11.         "id": 1,
  12.         "name": "test1",
  13.         "description": "test1 desc text",
  14.         "appId": "wdhlqi9a",
  15.         "createTime": "2010-11-10 13:46:00"
  16.       },
  17.       {
  18.         "id": 2,
  19.         "name": "test2",
  20.         "description": "test2 desc text",
  21.         "appId": "wdhlqi9a",
  22.         "createTime": "2010-11-10 13:46:00"
  23.       }
  24.     ]
  25.   }
  26. }
aUaeK(x:H  
返回结果说明 (xHmucmwp  
参数类型是否必须说明
idLong项目id
nameString项目名
descriptionString项目描述
appIdString项目appId
createTimeString创建时间
totalInteger项目总数
=rA?,74  
$*ff]>#  
2.2.3 更新项目 +<a\0FsD  
G?s9c0f  
7?*+,Fo#  
Action: projects:update 1&|]8=pG7  
请求参数: F\m^slsu7=  
参数类型是否必须说明
idLong项目id
nameString项目名,最大长度40
descriptionString项目描述,最大长度160
mtmC,jnD  
请求示例:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "id":1,
  3.   "name":"test",
  4.   "description":"test description"
  5. }
<pre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId": "xxxxx-xxx-xxx",
  3.   "resultCode": 0,
  4.   "resultMessage": "OK",
  5.   "data": {
  6.     "id": 1,
  7.     "name": "test1",
  8.     "description": "test1 desc text",
  9.     "appId": "wdhlqi9a",
  10.     "createTime": "2010-11-10 13:46:00"
  11.   }
  12. }
^%r6+ey  
返回结果说明: WXy8<?s  
参数类型是否必须说明
idLong项目id
nameString项目名
descriptionString项目描述
appIdString项目appId
createTimeString创建时间
/eV)5`V  
'Aq^z%|  
2.2.4 删除项目 |Xt.[1  
'H5 30Y\  
?2]fE[SqY  
Action: projects:delete )x6 &Y  
注:该操作会删除项目相关的所有信息,包括主题、知识点等,请谨慎操作。 2lTt  
请求参数: NM{)liP ;8  
参数类型是否必须说明
idLong项目id
6u, g  
请求示例:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "id":1
  3. }
Va8 }JD  
返回结果:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId":"xxxx-xxx-xxx",
  3.   "resultCode":0,
  4.   "resultMessage":"OK",
  5.   "data":""
  6. }
2FMmANH0ev  
GW A T0  
2.2.5 获得项目详细信息 `NIb? /!f  
$gl|^c\  
LKM018H>  
Action: projects:get ~ P\4 N  
请求参数: " .7@  
参数类型是否必须说明
idLong项目id
?w:\0j5 ~  
请求示例:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "id":1
  3. }
2j-l<!s  
返回结果:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId": "xxxxx-xxx-xxx",
  3.   "resultCode": 0,
  4.   "resultMessage": "OK",
  5.   "data": {
  6.     "id": 1,
  7.     "name": "测试项目",
  8.     "description": "这是一个测试项目",
  9.     "appId": "wdhlqi9a",
  10.     "createTime": "2010-11-10 13:46:00"
  11.   }
  12. }
pr<u 5  
返回结果说明: k-~}KlP  
参数类型是否必须说明
idLong项目id
nameString项目名
descriptionString项目描述
appIdString项目appId
createTimeString创建时间
NfoHQU <n  
`y>m >j  
2.2.6 创建主题 [j6]!p]S$  
YuhfPa  
sX"L\v  
Action: theme:create iHv+I~/  
请求参数: -5*OSA:8x  
参数类型是否必须说明
nameString主题名,最大长度30
descriptionString描述,最大长度50
projectIdLong项目id
O~5t[  
请求示例:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "name":"test",
  3.   "description":"desc",
  4.   "projectId":1
  5. }
?8O5%IrJ  
返回结果:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId":"xxxx-xxx-xx",
  3.   "resultCode":"0",
  4.   "resultMessage":"OK",
  5.   "data": {
  6.     "id":1,
  7.       "name":"test",
  8.       "description":"desc",
  9.       "projectId":1
  10.   }
  11. }
(-S^L'v62v  
返回结果说明 02,t  
参数类型是否必须说明
idLong主题id
nameString主题名称
descriptionString主题描述
projectIdLong项目id
ThV>gn5  
/` M#  
2.2.7 列出主题 |sGJum&=  
w[GEm,ZC  
wqG#jC!5  
Action: theme:list G ]h  
请求参数: +(!/(2>~  
参数类型是否必须说明
offsetInteger从第几个主题开始列出
pageSizeInteger每页个数
projectIdLong项目id
OG{*:1EP  
请求示例:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "offset":0,
  3.   "pageSize":10,
  4.   "projectId":1
  5. }
GbLHzw  
返回结果:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId":"xxxx-xxx-xx",
  3.   "resultCode":0,
  4.   "resultMessage":"OK",
  5.   "data":{
  6.     "total":100,
  7.     "offset":0,
  8.     "pageSize":10,
  9.     "items":[
  10.       {
  11.         "id":1,
  12.         "name":"test1",
  13.         "description":"desc1",
  14.         "projectId":1
  15.       },
  16.       {
  17.         "id":2,
  18.         "name":"test2",
  19.         "description":"desc2",
  20.         "projectId":1
  21.       }
  22.     ]
  23.   }
  24. }
,~3rY,y-  
返回结果说明: ;=joQWNDm  
参数类型是否必须说明
idLong主题id
nameString主题名称
descriptionString主题描述
projectIdLong项目id
totalInteger总主题数
%vO(.A+  
O1\4WG%  
2.2.8 更新主题 6D| F1UFU  
\dQc!)&C9  
s/ABT.ZO  
Action: theme:update <<-L,0  
请求参数: U`[viH>K  
参数类型是否必须说明
nameString主题名,最大长度30
descriptionString描述,最大长度50
projectIdLong项目id
idLong主题id
U?dad}7  
请求示例:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "id":1,
  3.   "name":"test",
  4.   "description":"desc1",
  5.   "projectId":1
  6. }
G+fo'ThG  
返回结果:<divre style='background: rgb(246, 246, 246); font: 12px/1.6 "YaHei Consolas Hybrid", Consolas, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace; margin: 0px 0px 16px; padding: 10px; outline: 0px; border-radius: 3px; border: 1px solid rgb(221, 221, 221); color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; overflow: auto; word-spacing: 0px; white-space: pre-wrap; word-wrap: break-word; box-sizing: border-box; orphans: 2; widows: 2; font-size-adjust: none; font-stretch: normal; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial;' prettyprinted?="" linenums="">
  1. {
  2.   "requestId":"xxxx-xxx-xx",
  3.   "resultCode":"0",
  4.   "resultMessage":"OK",
  5.   "data": {
  6.     "id":1,
  7.       "name":"test",
  8.       "description":"desc",
  9.       "projectId":1
  10.   }
  11. }
=oVC*b  
返回结果说明 RR=WD-l  
参数类型是否必须说明
idLong主题id
nameString主题名称
descriptionString主题描述
projectIdLong项目id
v#gXXO[P1  
J#Q>dC7  
级别: 新人
发帖
7
云币
16
只看该作者 沙发  发表于: 2017-11-27
Re智能对话平台API如何使用1
厉害!!!  !!! 楼主加油 !!!
发表主题 回复主题
« 返回列表上一主题下一主题

限100 字节
如果您在写长篇帖子又不马上发表,建议存为草稿
 
验证问题: 19 - 2 = ?
上一个 下一个