收藏
回答

单品优惠退款的时候,有时候可以部分退,有时候又提示“请全额退款”

微信单品优惠退款排查

## 背景

同一个商户,同一个满5000-300的单品活动,同一个商品,有的订单可以部分退款,有的订单无法部分退款,提示请全额退款错误

经过认真检查,没有违反任何单品优惠退款的规则,订单金额=单品总价,退款商品goods_id正确,退款金额<订单总金额

退款均请求单品退款接口:https://api.mch.weixin.qq.com/secapi/pay/refundv2

### 可部分退款订单:4200002014202311119476757956

**支付请求参数**

"request_body": {
  "body": "XX商城小程序",
  "total_fee": 500000,
  "fee_type": "CNY",
  "spbill_create_ip": "172.22.193.194",
  "notify_url": "XXXXXXXXXX",
  "trade_type": "JSAPI",
  "out_trade_no": "3023111148957838433321",
  "sub_appid": "wx69XXXXX494428ce",
  "time_start": "20231111213557",
  "time_expire": "20231111214057",
  "product_id": "3023111148957838433321",
  "device_info": "1212021-XX",
  "detail": "{\"goods_detail\":[{\"goods_id\":\"71936\",\"goods_name\":\"XX心 · 客房餐饮XX\",\"quantity\":50,\"price\":10000}]}",
  "sub_openid": "oy_u45WwvobyFziWCmkj-x4EqFiw",
  "scene_info": "{\"store_info\":{\"id\":\"XXX\",\"name\":\"XXXXXXXu5e97\\u603b\\u90e8\"}}",
  "profit_sharing": "Y",
  "version": "1.0",
  "appid": "wx0b0XXXXXXdef401",
  "mch_id": "122XXXX702",
  "sub_mch_id": "155XXXX491",
  "nonce_str": "siTadfoWbj7Gq93v",
  "sign": "D29416D6AB3AD9762E7C1D75240E0349"
}

"response_body": {
  "return_code": "SUCCESS",
  "return_msg": "OK",
  "result_code": "SUCCESS",
  "mch_id": "122xxxx702",
  "appid": "wx0b0XXXXdef401",
  "openid": "ox-6_wcki8OY-zeRZkwhhcjCTuLY",
  "is_subscribe": "N",
  "sub_mch_id": "155XXXX491",
  "sub_appid": "wx692XXXXX4428ce",
  "sub_openid": "oy_u45WwvobyFziWCmkj-x4EqFiw",
  "sub_is_subscribe": "N",
  "device_info": "1212021-xxxx",
  "trade_type": "JSAPI",
  "trade_state": "SUCCESS",
  "bank_type": "BOC_DEBIT",
  "total_fee": "500000",
  "fee_type": "CNY",
  "cash_fee": "470000",
  "cash_fee_type": "CNY",
  "transaction_id": "4200002014202311119476757956",
  "out_trade_no": "3023111148957838433321",
  "attach": [],
  "time_end": "20231111213603",
  "trade_state_desc": "支付成功",
  "nonce_str": "q4FKsxJkNCtu52GH",
  "sign": "7E130582C72667A31F50BA26CD0889ED",
  "promotion_detail": "{\"promotion_detail\":[{\"promotion_id\":\"53124272468\",\"name\":\"满5000减300\",\"scope\":\"SINGLE\",\"type\":\"DISCOUNT\",\"amount\":30000,\"activity_id\":\"18078318\",\"wxpay_contribute\":0,\"merchant_contribute\":30000,\"other_contribute\":0,\"goods_detail\":[{\"goods_id\":\"71936\",\"quantity\":50,\"price\":10000,\"discount_amount\":30000,\"goods_remark\":\"\"}]}]}",
  "version": "1.0"
}

**退请求参数**

"request_body": {
  "out_refund_no": "2024021562697832923106",
  "out_trade_no": "3023111148957838433321",
  "total_fee": 500000,
  "refund_fee": 230000,
  "op_user_id": "10001",
  "notify_url": "XXXXXX",
  "detail": "{\"goods_detail\":[{\"goods_id\":\"71936\",\"goods_name\":\"XX心 · 客房餐饮XX\",\"price\":10000,\"refund_amount\":230000,\"refund_quantity\":23}]}",
  "sign_type": "HMAC-SHA256",
  "appid": "wx0XXX0cdef401",
  "mch_id": "122XXXX702",
  "sub_mch_id": "155XXXX491",
  "nonce_str": "Q95duFlEUJDcgr6X",
  "sign": "15fa8006b1d099dc754fcc15cbe57589e91b2024d3cebc46c6eeda276b732290"
},

"response_body": {
  "return_code": "SUCCESS",
  "return_msg": "OK",
  "result_code": "SUCCESS",
  "appid": "wx0bXXXXXXef401",
  "mch_id": "122XXXX02",
  "sub_mch_id": "155XXXX491",
  "nonce_str": "ZbvMY8fjFschuRDj",
  "sign": "A8C06222CE4EDA086BA7960CC60F713C8F8EC68DB3739070AC3B32749431B7BF",
  "transaction_id": "4200002014202311119476757956",
  "out_trade_no": "3023111148957838433321",
  "out_refund_no": "2024021562697832923106",
  "refund_id": "50303207872024021521876165951",
  "refund_fee": "230000",
  "total_fee": "500000",
  "cash_fee": "470000",
  "cash_refund_fee": "216200",
  "promotion_detail": "{\"promotion_detail\":[{\"promotion_id\":\"53124272468\",\"scope\":\"SINGLE\",\"type\":\"DISCOUNT\",\"refund_amount\":13800,\"goods_detail\":[{\"goods_id\":\"71936\",\"price\":10000,\"refund_amount\":230000,\"refund_quantity\":23}]}]}"
},

-----------------------

### 不可退款订单:4200002010202311116838410445

**支付请求参数**

"request_body": {
  "body": "XX商城小程序",
  "total_fee": 500000,
  "fee_type": "CNY",
  "spbill_create_ip": "172.22.193.31",
  "notify_url": "XXXXX",
  "trade_type": "JSAPI",
  "out_trade_no": "3023111152203967073128",
  "sub_appid": "wx692XXXXX4428ce",
  "time_start": "20231111223003",
  "time_expire": "20231111223503",
  "product_id": "3023111152203967073128",
  "device_info": "1212021-xxxx",
  "detail": "{\"goods_detail\":[{\"goods_id\":\"71936\",\"goods_name\":\"XX心 · 客房餐饮XX\",\"quantity\":50,\"price\":10000}]}",
  "sub_openid": "oy_u45RFEpxpXlXqvX-EA569YD1U",
  "scene_info": "{\"store_info\":{\"id\":\"xx\",\"name\":\"\xxxxx9152\\u5e97\\u603b\\u90e8\"}}",
  "profit_sharing": "Y",
  "version": "1.0",
  "appid": "wx0b0xxxxx0cdef401",
  "mch_id": "122xxxx702",
  "sub_mch_id": "155xxxx491",
  "nonce_str": "yVnRDQzKfIE9uY0c",
  "sign": "20AFDF50FBB4F3CE2BCF9CA5937186C5"
},

"response_body": {
  "return_code": "SUCCESS",
  "return_msg": "OK",
  "result_code": "SUCCESS",
  "mch_id": "122xxxx702",
  "appid": "wx0b0xxxx0cdef401",
  "openid": "ox-6_wZdP7Sgn80HQCe884JPdLeU",
  "is_subscribe": "N",
  "sub_mch_id": "155xxxx491",
  "sub_appid": "wx6924xxxxx4428ce",
  "sub_openid": "oy_u45RFEpxpXlXqvX-EA569YD1U",
  "sub_is_subscribe": "N",
  "device_info": "1212021-xxxx",
  "trade_type": "JSAPI",
  "trade_state": "SUCCESS",
  "bank_type": "GDB_CREDIT",
  "total_fee": "500000",
  "fee_type": "CNY",
  "cash_fee": "470000",
  "cash_fee_type": "CNY",
  "transaction_id": "4200002010202311116838410445",
  "out_trade_no": "3023111152203967073128",
  "attach": [],
  "time_end": "20231111223054",
  "trade_state_desc": "支付成功",
  "nonce_str": "nE9X7XhhnzcahN6J",
  "sign": "F4C9CDB98CEF2DFC757642F7B4A6E893",
  "promotion_detail": "{\"promotion_detail\":[{\"promotion_id\":\"53154054603\",\"name\":\"满5000减300\",\"scope\":\"SINGLE\",\"type\":\"DISCOUNT\",\"amount\":30000,\"activity_id\":\"18078318\",\"wxpay_contribute\":0,\"merchant_contribute\":30000,\"other_contribute\":0,\"goods_detail\":[{\"goods_id\":\"71936\",\"quantity\":50,\"price\":10000,\"discount_amount\":30000,\"goods_remark\":\"\"}]}]}",
  "version": "1.0"
},

**退款请求参数**

"request_body": {
  "out_refund_no": "2024020245284475031230",
  "out_trade_no": "3023111152203967073128",
  "total_fee": 500000,
  "refund_fee": 330000,
  "op_user_id": "10001",
  "notify_url": "xxxxxx",
  "detail": "{\"goods_detail\":[{\"goods_id\":\"71936\",\"goods_name\":\"凯悦心 · 客房餐饮随心兑\",\"price\":10000,\"refund_amount\":330000,\"refund_quantity\":33}]}",
  "sign_type": "HMAC-SHA256",
  "appid": "wx0bxxxxdef401",
  "mch_id": "122xxxx702",
  "sub_mch_id": "155xxxx491",
  "nonce_str": "kIRzqiy7jQVuUG8g",
  "sign": "ef70bbd28f6eba1e89050795ff001a9b21e2177fb183bcf762f5e4f556918e45"
},

"response_body": {
  "return_code": "SUCCESS",
  "return_msg": "OK",
  "result_code": "FAIL",
  "err_code": "ERROR",
  "err_code_des": "请使用全额退款",
  "appid": "wx0bxxxxxcdef401",
  "mch_id": "122xxxx702",
  "sub_mch_id": "155xxxx491",
  "nonce_str": "ce54FDPJVyt5728F",
  "sign": "341A2EEF78AC62B80D5EE1D39FE68FFF1E27C506F2AC8A3D0C871A0BEF5CEAFB"

},    


敏感信息均使用XXXX脱敏,应该有微信单号即可,如果需要更详细的信息请回复留言,谢谢

回答关注问题邀请回答
收藏

1 个回答

登录 后发表内容