PHP 项目对接视频号原来如此简单,小白也能轻松完成【带附件】

首先,商家需要在微信后台申请自定义版交易组件权限,申请成功后,可以将小程序关联至对应视频号,并在视频号带货直播中使用。

申请开通商户号

等商户号审核之后在操作一下步骤接口调用(pro 为例)
实例代码



商品接口调用(https://api.weixin.qq.com/shop/spu/add)
添加完商品等到微信审核,审核过后下单购买
打开微信开发者工具点进个商品详情,

id 是商品 id,场景值选择 1177


正常下单购买流程(https://api.weixin.qq.com/shop/order/add)
同步物流,(https://api.weixin.qq.com/shop/delivery/send)
创建售后(https://api.weixin.qq.com/shop/ecaftersale/add)
同意退款(https://api.weixin.qq.com/shop/ecaftersale/acceptrefund)
小程序公众号平台依次点击完成即可

上传审核小程序,等小程序发布之后,视频号推广审核
十一、场景接入
前往微信公众平台中,进入 “交易组件”>“场景接入” 菜单中,查看并选择需要接入的场景,微信官方默认所有场景均可接入。

视频号对接的讲解就到这里结束了,大家有不懂的地方可以在下方留言
源码附件已经打包好上传到百度云了,大家自行下载即可~
链接: https://pan.baidu.com/s/14G-bpVthImHD4eosZUNSFA?pwd=yu27 提取码: yu27 百度云链接不稳定,随时可能会失效,大家抓紧保存哈。
如果百度云链接失效了的话,请留言告诉我,我看到后会及时更新~
GIT 项目推荐:包含多端免授权可商用
版权声明: 本文为 InfoQ 作者【CRMEB】的原创文章。
原文链接:【http://xie.infoq.cn/article/4a52842212a0fca096000908c】。
本文遵守【CC-BY 4.0】协议,转载请保留原文出处及本版权声明。
评论