收藏
回答

为什么获取草稿 api 返回的 thumb_media_id 与新建草稿 api 设置的有时不一样?

https://developers.weixin.qq.com/doc/offiaccount/Draft_Box/Get_draft.html

调用新建草稿 api,设置的 thumb_media_id,调用成功以后再调用获取草稿 api 返回的 thumb_media_id 和设置的有时不一样。

例如:

获取草稿 api 参数

// request params
{
    "articles": [
        {
            "content_source_url": "",
            "content": "<p>test</p>",
            "show_cover_pic": 0,
            "digest": "test",
            "author": "",
            "thumb_media_id": "wOkYg4CE37hcpWWVdgPtv_0caL7_mhTH4e9L8c1w_1KQxzTzhSz_bqxhTkwbXJdu",
            "title": "test"
        }
    ]
}

// response
{
    "media_id":"wOkYg4CE37hcpWWVdgPtv7JqLSFa82cVEtkebA9edXEne-6yncTH5z55_ydWJCv9"
}


获取草稿 api

// request params
{
    "media_id":"wOkYg4CE37hcpWWVdgPtv7JqLSFa82cVEtkebA9edXEne-6yncTH5z55_ydWJCv9"
}

// response
{
    "update_time": 1654507207,
    "create_time": 1654507207,
    "news_item": [
        {
            "only_fans_can_comment": 0,
            "need_open_comment": 0,
            "thumb_url": "http://mmbiz.qpic.cn/mmbiz_png/Emib00bw3CIycBORJLicibrBnsALfk3njOY7Wh18baGfoJRAQ3OeJhtqJvR1MBNDKPywiajM0jiatgNFBAVbLiaQg7KA/0?wx_fmt=png",
            "url": "http://mp.weixin.qq.com/s?__biz=MjM5OTU0NjEyMg==&tempkey=MTE2OF9teUNNb0RTbjBBUUc4dnIraHJDbXM3dlZmU1ZVNnhGcVljbW83bER3NFZROGxpR3E0RVdwYU9EVktkVC1vN19RQ0ZMVFo0RVJuaUMxTHV3bUhlVmI3cEQ4YkdaYTM0SF9MQ0RlbUxBc3VLbWdXY1pZWXF3YUc1T3ViUWliQU9uZGI0X29wdEVBV2MtS3FPbHpROTNtV0hSRHJGOXNjUkUyYkQzTWRBfn4%3D&chksm=3329fb1b045e720d855497105eff8a82491a15897c96790a95c053722e531393023e406f31c2#rd",
            "show_cover_pic": 0,
            "thumb_media_id": "wOkYg4CE37hcpWWVdgPtv_0caL7_mhTH4e9L8c1w_1IALs2BHWcho2Bqng6jRE_j",
            "content_source_url": "",
            "content": "<p>test</p>",
            "digest": "test",
            "author": "",
            "title": "test"
        }
    ]
}



回答关注问题邀请回答
收藏
登录 后发表内容