查询退款(单品优惠)
提交退款申请后,通过调用该接口查询退款状态。退款有一定延时,用零钱支付的退款20分钟内到账,银行卡支付的退款3个工作日后重新查询退款状态。 官方文档
js
wxpay.v2.pay.refundqueryv2.post({
appid,
mch_id,
sub_appid,
sub_mch_id,
nonce_str,
sign_type,
transaction_id,
out_trade_no,
out_refund_no,
refund_id,
offset,
})
.then(
({
data: {
return_code,
return_msg,
result_code,
err_code,
err_code_des,
appid,
mch_id,
sub_appid,
sub_mch_id,
nonce_str,
sign,
total_refund_count,
transaction_id,
out_trade_no,
total_fee,
settlement_total_fee,
fee_type,
cash_fee,
refund_count,
out_refund_no_$n,
refund_id_$n,
refund_channel_$n,
refund_fee_$n,
settlement_refund_fee_$n,
coupon_type_$n_$m,
coupon_refund_fee_$n,
coupon_refund_count_$n,
coupon_refund_id_$n_$m,
coupon_refund_fee_$n_$m,
refund_status_$n,
refund_account_$n,
refund_recv_accout_$n,
refund_success_time_$n,
},
}) => return_code === 'SUCCESS' && result_code === 'SUCCESS'
)