4 人机协作

4.1 获取人机协作信息

  • 接口地址
/v10/tenants/{tenantId}/recommendation/questions
  • 接口请求示例
curl -X POST \
  http://robot.easemob.com/v10/tenants/9/recommendation/question \
  -H 'content-type: application/json' \
  -H 'token:eyJhbGciOiJIUzI1NiJ9eyJzdWIiOiJjaGl4aWFveXUyMTFAMTYzLmNvbSIsImlzcyI6ImVhc2Vtb2Itcm9ib3QiLCJ0ZW5hbnRJZCI6OSwiZXhwIjoxNTIyMjM3ODk1LCJpYXQiOjE1MjE2MzMwOTUsInVzZXJJZCI6IjFmYmNhNjE5LTZlMWItNDg2Yi1hOTdhLWE4MDc0ZjRlNzIxMSIsImp0aSI6IjJmZDkzOWM1LWFkNDUtNGVjMS04MzFhLTk1NzRhMDYzODg1NSIsInVzZXJuYW1lIjoiY2hpeGlhb3l1MjExQDE2My5jb20ifQ.BXVLRTwe1IzWHrCZVTNQauJFQQMneYiMr5NeCRYHc68' \
  -d '{
    "question":"你好",
    "userId":"8de05700-77e9-478a-a733-dd4e9457b756"
}'
  • 请求参数说明
tenantId:租户id
question:问题
userId:用户id
  • 接口返回的ResponseBody
{
    "entity": {
        "answers": [{
            "answer": "不好",
            "answerId": "faeb66ce-3e5b-4dba-a879-b6e59900d4c2",
            "score": 1
        }],
        "recommendationId": "07911667-c0ef-4913-9f0d-8ac8b73ea1fc",
        "timestamp": 1520394943452
    },
    "errorCode": null,
    "errorDescription": null,
    "first": true,
    "last": true,
    "number": 0,
    "numberOfElements": 0,
    "size": 0,
    "status": "OK",
    "totalElements": 0,
    "totalPages": 0
}
  • 接口返回参数说明
answer:推荐答案
answerId:推荐答案id
score:推荐答案得分
recommendationId:人机协作id