3.1 接口说明(重要必读)
由对接方主动发起调用HAI平台API接口,HAI平台被动返回数据
HTTP请求说明
以下http请求需要以json格式传送和接收,固定参数header需标注
- Accept:application/json,
- Content-Type:application/json,
- Authorization:Bearer xxxxxxxxxxxxxxx(登录时获取的access_token)
HTTP响应说明
- api接口严格区分get 或 post方法。
- 文档中出现的 1为true,0为false。
- api接口返回均为JSON个格式字符串。
- token 采用oauth2授权方式,支持refresh token,每个api 都有token鉴权,如果鉴权失败会返回http code 500, message 消息为
{
"error":"error: wrong",
"code":401,
"message":"error: wrong",
"details":[]
}
URL说明
- 地址: http:// + 服务器IP
- base_url: http:// + 服务器IP (例:http://192.168.5.180)