开发

获取Feed物料接口

接口功能

批量获取 Feed 物料接口

URL

https://openapi.baidu.com/rest/2.0/smartapp/osa/material/search

调用方式

GET

是否可重入

支持数据格式

JSON

参数说明

参数名 类型 必填 说明
union_sign String 签名,生成方式见签名说明
union_timestamp Long 时间戳,时间标准为 UTC,取当前请求时间
union_nocestr String 随机字符串,每次请求生成一个新的随机字符串,随机 串长度不能超过 64 位,可以有数字,字母,连接符-组成。
access_token String access_token
app_keys String 支持多个小程序 Appkey,使用英文逗号分隔多个建议 只使用一个。app_keys 不使用的时候不用传,最多支持20个
start_date String 创建的开始时间 20190216
end_date String 创建的结束时间 20190217,与start_date必须成对出现,如例子,会获取 createtime 在 2019年02月16日0点0分0秒至2019年02月17日0点0分0秒的数据
page_num Long 分页拉取当前第几页(从 1 开始计数)
page_size Long 每页获取最大数量,不能超过 100

返回字段

Data Object说明

字段 类型 描述
appList Array 物料列表
hasMore Int 是否还有下一页

List_Array_Item 说明

字段 类型 描述
mid int 物料 id
appKey string 小程序、小游戏 product_key
tags string 标签
images string 图片数组
cardStyle int card_style根据类型判断 有视频类1001 直播类1000和图文1002
createTime long 创建时间
feedSubType string feed的物料类型
feedType string feed的物料类型
getFrom string 来源 api提交:openApi 抓取:crawler
imageStyle int 小游戏图片类型 (大图 小图 竖图)
mappSubType int 小程序类型
mappType int 小程序类型
path string 落地路径
feedStatus int 物料流转状态
title string 物料title

返回示例

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{
"errno":0,
"msg":"success",
"timestamp":1572852821,
"data":{
"appList":[
{
"appKey":"flFqXclepWs7RdugAszy9eERL7G5dS0I",
"tags":"",
"images":"[{\"url\":\"https://b.bdstatic.com/miniapp/resource/image/20191019/41620c58-ccd7-4c13-85d7-41e38053c3f0.jpg\",\"width\":1280,\"height\":720}]",
"cardStyle":1001,
"createTime":1571456752115,
"feedSubType":"美食",
"feedType":"生活",
"getFrom":"crawler",
"imageStyle":0,
"mappSubType":1002,
"mappType":1000,
"path":"/pages/pb/pb?tid=6301392316",
"feedStatus":3,
"title":"吃了多年的牛肉,还是这种吃法最过瘾,一口一块好吃得停不下来!",
"mid":"1512118734274080836"
}
],
"hasMore":1
},
"request_id":"be6555b8a8614aa8816a55ebf3ec720e"
}