报错如下:
{"code":"PARAM_ERROR","message":"需传入转账场景报备信息,请检查"}
但我的请求体中包含transfer_scene_report_infos参数,并且参数的info_type符合文档要求。为什么依然报错了呢?
我的请求头如下:
request_data = {
"appid": settings.WECHAT_APP_ID,
"out_bill_no": out_detail_no,
"transfer_scene_id": "1005",
"openid": openid,
"transfer_amount": int(amount * 100), # 金额转为分
"transfer_remark":"注安做题大师推广佣金",
"transfer_scene_report_infos":[
{
"info_type":"活动名称",
"info_content":"做题大师推广活动"
},
{
"info_type":"奖励说明",
"info_content":f"{date}佣金{amount}元"
}
],
"notify_url":url
}
已解决
参考文档如下:https://pay.weixin.qq.com/doc/v3/merchant/4012711988#2.3-%E5%8F%91%E8%B5%B7%E8%BD%AC%E8%B4%A6
我增加了:user_recv_perception: 劳务报酬
然后把transfer_scene_report_infos修改为:
"transfer_scene_report_infos":[
{
"info_type":"岗位类型",
"info_content":"销售员"
},
{
"info_type":"报酬说明",
"info_content":f"{date}佣金{amount}元"
}
],
user_recv_perception去哪里了?1005也对应不了现金营销啊
但是测试发现报错依旧