Skip to Content
CollectionsDirect DebitAuthorizations

Cancel a Direct Debit Authorization

When a Singapore (eGIRO) cancellation fails, for example because the authorization is not SUCCEEDED, the answer is a 400 with an empty body.

HSBC Hong Kong authorizations cannot be cancelled through Acme: the answer is a 422 with INVALID_OPERATION. Your payer cancels with their bank, and Acme sends direct-debit-authorizations.canceled once HSBC's daily report shows it.

Which cancellations send direct-debit-authorizations.canceled, bank by bank: When Acme sends a cancel event.

POST
/v1/direct-debit-authorizations/{id}/cancel

Authorization

authorization
headerAuthorizationBearer <SECRET_API_KEY>

Set Your Secret API Key

Path Parameters

id*string

Header Parameters

Idempotency-Key?string

A unique value, eg. a UUID.

Request Body

application/json
cancelReturnUrl*string

Payer will be redirected to this URL after they have cancelled the Direct Debit Authorisation at their bank's website. Conditionally required: not applicable for HK direct debit authorizations.

Match ^[A-Za-z][A-Za-z0-9+\-\.]+:\/\/[^:\?\/]+(:[0-9]+)?((\/[^\/\?]*)*\/?(\?[^\?\/]*)?)?$
Length 0 <= length <= 2048
country?string

Value in

  • "SG"
  • "MY"
  • "HK"
  • "KR"
  • "AU"
  • "US"
  • "ID"
  • "TW"
  • "BR"
  • "DK"
  • "PH"
  • "VN"
  • "AE"
  • "GB"
  • "IN"
  • "MX"
  • "CN"

Response Body

OK

*/*
authorizeUrl?string

Redirect payer to this URL for logging into their bank to perform authorization. This is only present when the DDA status is REQUIRES_AUTHORIZATION. Not applicable for HK DDA.

billReferenceNumber?string

Bill reference number for your payer.

cancelReturnUrl?string

Payer will be redirected to this URL after they have cancelled the Direct Debit Authorisation at their bank's website. This is only present when you request for cancellation. Not applicable for HK DDA.

cancelUrl?string

Redirect payer to this URL for logging into their bank to perform cancellation. This is only present when you request for cancellation. Not applicable for HK DDA.

createdAt?string

Time at which the object was created. In ISO 8601 format.

endDate?string

The DDA expiry date. For HK DDA, if not specified, the value will be defaulted as "2099-12-31".

failureReason?string

If status is FAILED, this provides additional information about the failure.

  • PAYER_AUTHORIZATION_FAILED: Payer has failed to authorize the Direct Debit Authorization.
  • PAYER_AUTHORIZATION_TIMEOUT: Acme did not receive an authorization response in time. Acme will wait up to 20 minutes for RETAIL payer segment Direct Debit Authorizations, and up to 48 hours for CORPORATE payer segment Direct Debit Authorizations. For a payer at DBS, the time limit ends once the payer has approved. If the bank confirms a Singapore authorization after its time limit, it becomes SUCCEEDED.
  • PAYER_SPECIFIED_LOWER_MAX_AMOUNT: Payer has authorized the Direct Debit Authorization with a lower maximum amount than what is required.
  • PAYER_SPECIFIED_EARLIER_END_DATE: Payer has authorized the Direct Debit Authorization with an earlier end date than what is required.

For HK DDA, Acme's internal failure code according to the bank's returned error:

  • PAYER_ID_TYPE_INVALID: Invalid payer's proxy type provided.
  • PAYER_ID_NUMBER_INVALID: Invalid payer's proxy value provided.
  • PAYER_ACCOUNT_CLOSED: Payer's account is closed.
  • PAYER_ACCOUNT_TYPE_NOT_SUPPORTED: Payer's account is not supported for direct debit authorization.
  • PAYER_ACCOUNT_TYPE_INVALID: Invalid payer's account number.
  • PAYER_ACCOUNT_NAME_NOT_MATCHED: Payer's account name not matched.
  • PAYER_ACCOUNT_NOT_FOUND: Payer's account does not exist.
  • PAYER_ACCOUNT_NAME_AND_ID_NOT_MATCHED: Payer's proxy value and account name not matched.
  • PAYER_MOBILE_NUMBER_INVALID: Invalid payer's mobile number.
  • DUPLICATE_BILL_REFERENCE_NUMBER: Duplicated bill reference number.
  • OTHERS: Unrecognized error message will be defaulted as OTHERS.
id?string

Unique identifier for the object. For HK DDA, Acme sends the id to the bank as referenceId (e.g. dda_0KAQCK2Y8FNTB, formatted as dda-0KAQCK2Y8FNTB), which is used for tracking the DDA request and may appear in bank notifications/portals. Note: this is different from the billReferenceNumber you provide and is what typically appears on your payer's bank statement.

maxAmount?integer

Deprecated: use precheckMaxAmount instead.

Format int64
maxAmountCurrency?string

Deprecated: use precheckCurrency instead. Not applicable for HK DDA.

metadata?object

Metadata of the direct debit authorization, when present.

otp?DirectDebitAuthorizationOtpResponse

The SMS one-time password the bank sent your payer. Present while an HSBC Hong Kong direct debit authorization for an HSBC account is REQUIRES_AUTHORIZATION, unless the bank's answer to the create was lost: call /otp-regeneration to get one.

payerAuthorizedMaxAmount?integer

Maximum payment amount authorized by the payer with their bank, in SGD minor units. Only populated for SG eGIRO Direct Debit Authorizations, and only after the payer has approved. For other DDA types (e.g. HK, Malaysia FPX), this always returns 0 regardless of any cap set via precheckMaxAmount — check that field instead.

Format int64
payerBankAccountNumber?string

Payer's bank account number. This field is only set after the payer has approved the Direct Debit Authorization.

payerBankCode?string

3-digit local clearing code of the payer's bank. Hong Kong direct debit authorizations only.

payerIdHash?string

Hash value of the payer's identification number stored in the payer's bank system. Not applicable for HK DDA.

payerIdType?string

Payer's identification type stored in the payer's bank system (e.g. NRIC, FIN, PASSPORT, UEN). Not returned for HK DDA.

payerName?string

Payer's name.

payerSegment?string

Your payer's segment: RETAIL or CORPORATE. Not applicable for HK DDA.

payerSwiftBic?string

Payer's bank SWIFT/BIC code. Not applicable for HK DDA.

precheckCurrency?string

Three-letter ISO 4217 currency code in full uppercase.

precheckMaxAmount?integer

Direct Debit Payments above this amount (in the currency's smallest unit) are rejected by Acme without being sent to the bank. For HK DDA, this can be used to set a maximum transaction amount for this DDA.

Format int64
precheckMinAmount?integer

Direct Debit Payments below this amount (in the currency's smallest unit) are rejected by Acme without being sent to the bank.

Format int64
returnUrl?string

Payer will be redirected to this URL after they have authorized the Direct Debit Authorisation at their bank's website. Not applicable for HK DDA.

startDate?string

Effective date of the direct debit authorization.

status?string

Status of the Direct Debit Authorization:

  • REQUIRES_AUTHORIZATION: Requires the payer to perform authorization with their bank.
  • PROCESSING: A creation callback was received from the payer's bank. Normally, a DDA will transition very quickly from PROCESSING to SUBMITTED.
  • SUBMITTED: The DDA was sent on and awaits the final answer: from the Industry Aggregator for Singapore, or from the payer's bank for Hong Kong.
  • SUCCEEDED: The DDA has been created successfully with the bank and is ready to be used for creating Direct Debit Payments.
  • FAILED: The DDA creation failed. You should create a new DDA if you wish to try again. A Singapore DDA failed with PAYER_AUTHORIZATION_TIMEOUT becomes SUCCEEDED if the bank confirms it later.
  • CANCELED: The DDA has been canceled by the payer. For HSBC Hong Kong, also when HSBC's daily report shows the mandate cancelled, expired or deleted after it was active.
transactionReference?string

Transaction reference from the bank, when available.

underlyingErrorMessage?string

A descriptive error message constructed from the bank's response, normally by concatenating the bank-provided error code and error message. This field is intended to aid troubleshooting and may vary depending on the bank.

updatedAt?string

Time at which the object was last updated. In ISO 8601 format.

Example Request
curl -X POST 'https://api.tryacme.com/v1/direct-debit-authorizations/string/cancel' \
  -H 'Content-Type: application/json' \
  -d '{
  "cancelReturnUrl": "string"
}'
Example Response

Cancellation needs the payer to approve it. Redirect them to cancelUrl, and the status moves to CANCELED once their bank confirms.

{
  "id": "dda_0J7Q6A3M8V5X1",
  "billReferenceNumber": "A0012334455",
  "payerSwiftBic": "DBSSSGSGXXX",
  "payerBankCode": null,
  "payerSegment": "RETAIL",
  "payerName": "Richard Hendricks",
  "payerBankAccountNumber": "0052312891",
  "payerIdHash": "a3f0d8331c9d860aa685df22501d",
  "payerIdType": "NRIC",
  "status": "SUCCEEDED",
  "failureReason": null,
  "underlyingErrorMessage": null,
  "startDate": "2026-09-09",
  "precheckMinAmount": null,
  "precheckMaxAmount": 100000,
  "precheckCurrency": "SGD",
  "maxAmount": 100000,
  "maxAmountCurrency": "SGD",
  "payerAuthorizedMaxAmount": 100000,
  "endDate": "2042-04-24",
  "authorizeUrl": null,
  "cancelUrl": "https://api.tryacme.com/redirection/direct-debit-authorizations/dda_0J7Q6A3M8V5X1/cancel?key=0J7Q6B7QTZ4Y1N",
  "returnUrl": "https://example.com/return",
  "cancelReturnUrl": "https://example.com/cancel-return",
  "transactionReference": "EG2026090900012345",
  "createdAt": "2026-09-09T02:10:11.204118Z",
  "updatedAt": "2026-09-12T08:30:19.284415Z"
}