获取素材详情
优质
小牛编辑
129浏览
2023-12-01
接口说明
查询素材的详细信息
如需调用,请访问 开发者文档 来查看详细的接口使用说明
该接口仅开放给已获取SDK的开发者
API地址
POST
/api/server/1.0.0/details
是否需要登录
是
请求字段说明
参数 | 类型 | 请求类型 | 是否必须 | 说明 |
---|---|---|---|---|
guid | string | form | 是 | 素材id |
响应字段说明
无
响应成功示例
{ "code": 200, "data": { "data": [ { "isdelserver": 0, "dataType": "obj", "dataSize": 243433, "jsonPath": "", "updateTime": "1534398792000", "beforeWaitingTotal": 0, "serverstate": 1, "title": "obj", "userGuid": "1", "isdelzip": 0, "serverType": 2, "guid": "88987909-9f11-434e-b464-58916a71c147", "handleStatus": 6, "from": "", "position": "120,30,0", "viewTimes": 1, "powers": "", "isDel": 0, "handleStartTime": "0", "username": "admin" }, { "coverImg": "", "isdelserver": 0, "dataType": "osgb", "dataSize": 87139125, "jsonPath": "", "updateTime": "1532829524000", "beforeWaitingTotal": 0, "serverstate": 2, "title": "fuzhou", "userGuid": "1", "isdelzip": 0, "password": "", "serverType": 1, "guid": "5f2fd0a1-b335-4355-850f-9beed313c8aa", "viewPointGuid": "", "handleStatus": -3, "from": "0", "position": "120);30);0", "viewTimes": 0, "powers": "", "isDel": 0, "username": "admin" } ], "count": "54" }, "message": "OK" }
响应失败示例
{ "code": 500, "message": "未知错误,请及时联系管理人员进行处理" }
响应接受类型
application/json:charset=utf-8
响应状态码
HTTP状态码 | 原因 |
---|---|
204 | No Content |
401 | Unauthorized |
403 | Forbidden |
40001 | 查询结果为空 |
40001 | 查询结果不是JSON数据 |
40001 | 查询结果JSON不符合要求 |
40002 | 请求接口失败 |
40003 | 参数无效 |
40004 | 令牌无效 |
40004 | 令牌为空 |
示例代码
$.ajax({ url:'/api/server/1.0.0/details', type:'POST', data:'guid=', dataType:'text', cache:false, contentType: "application/x-www-form-urlencoded", xhrFields: { withCredentials: true }, crossDomain: true, success:function(data){ // 成功返回值 }, error:function(XMLHttpRequest, textStatus, errorThrown){ } })