Cancel Agreement
Cancel an automatic-debit agreement when the shopper withdraws consent. Where the channel supports it, the API revokes the provider
authorization before the local agreement is changed to CANCELED.
POST /mch-api/v1/pa/auto_debit/agreements/cancel
{
"agreement_id": "ADG5f4f5c8e5b6d4f3fbd9d3e8ca4f1b2a3",
"merchant_customer_id": "customer_001"
}
{
"code": 0,
"data": {
"agreement_id": "ADG5f4f5c8e5b6d4f3fbd9d3e8ca4f1b2a3",
"status": "CANCELED"
},
"message": "ok"
}
For Alipay Plus, cancellation is valid only for an active agreement. Treat a cancellation notification as the final record of the agreement state.