素材列表接口
收藏我的收藏
使用限制
无
接口说明
获取素材列表。
基本信息
名称 | 描述 |
HTTP URL | https://open.douyin.com/enterprise/media/list/ |
HTTP Method | GET |
Scope | im |
权限要求 | 当前暂不支持新增申请 |
请求头
参数名称 | 类型 | 参数描述 | 参数示例 | 是否必填 |
Content-Type | string | 固定值:application/json | application/json | 是 |
请求参数
Query
参数名称 | 参数类型 | 参数描述 | 参数示例 | 是否必填 |
open_id | string | ba253642-0590-40bc-9bdf-9a1334b94059 | 是 | |
access_token | string | act.1d1021d2aee3d41fee2d2add43456badMFZnrhFhfWotu3Ecuiuka27L56lr | 是 | |
cursor | int64 | 分页游标, 第一页请求cursor是0, response中会返回下一页请求用到的cursor, 同时response还会返回has_more来表明是否有更多的数据。 | 0 | 否 |
count | int64 | 每页数量 | 10 | 是 |
请求示例
curl -X GET "https://open.douyin.comhttps://open.douyin.com/enterprise/media/list/?open_id=ba253642-0590-40bc-9bdf-9af334b94059&access_token=act.1d1021d2aee3d41fee2d2add43456badMFZnrhFhfWotu3Eoi&cursor=0&count=10" \ -H "Content-Type: application/json"
响应参数
参数名称 | 参数类型 | 参数描述 | 参数示例 |
extra | struct | | <nil> |
- sub_description | string | 子错误码描述 | |
- sub_error_code | int64 | 子错误码 | 0 |
- description | string | 错误码描述 | |
- error_code | int64 | 错误码 | 0 |
- logid | string | 标识请求的唯一 id | 202008121419360101980821035705926A |
- now | int64 | 毫秒级时间戳 | 1597213176393 |
data | struct | | <nil> |
- cursor | int64 | 用于下一页请求的cursor | <nil> |
- description | string | 错误码描述 | |
- error_code | int64 | 错误码 | 0 |
- has_more | bool | | <nil> |
- medias | []struct | | <nil> |
-- media_id | string | 素材id | <nil> |
-- status | string | 审核状态(avaliable可使用,review审核中,reject审核不通过) | <nil> |
-- url_list | []string | 素材链接数组 | <nil> |
响应示例
正常示例
{ "data": { "cursor": "<nil>", "description": "", "error_code": "0", "has_more": "<nil>", "medias": [ { "media_id": "<nil>", "status": "<nil>", "url_list": [ "<nil>" ] } ] }, "extra": { "description": "", "error_code": "0", "logid": "202008121419360101980821035705926A", "now": "1597213176393", "sub_description": "", "sub_error_code": "0" } }
异常示例
{ "data": { "description": "Parameter error", "error_code": 2100005 }, "extra": { "logid": "2020070614111601022506808001045D59", "now": 1594015876138 } }
错误码
HTTP 状态码 | 错误码 | 错误码描述 |
200 | 2100005 | Parameter error |