Skip to main content

Register for debit notifications

Use this API to register for notifications of debit transactions (money out) on an ACB original account number. Once registration succeeds, every time money is deducted from the account, TINGEE sends a webhook to the partner's system.

Scope
  • Only ACB (bankBin = "970416") is supported, for personal, household business and business accounts.
  • The API registers on the original account number; it does not create a virtual account (VA).
  • If the account number is already registered for credit notifications (created with Create/Link account number with isNotifyAccountNumber = true), the system switches the registration to receive both credit and debit notifications.

Process​

  1. Call this API to send the registration request. ACB sends an OTP to the account holder's mobile phone number, and the result returns a confirmId.
  2. Call the Confirm account number API with the confirmId and otpNumber to complete it. The confirmId is valid for 4 minutes.
POST
URLhttps://open-api.tingee.vn/v1/create-debit

Start a request to register for debit notifications on an ACB account. The result returns a confirmId used for the OTP confirmation step.

Header Request​

HeaderRequiredDescription
Content-Type✓application/json
x-client-id✓Partner identifier issued by TINGEE.
x-signature✓HMAC SHA512 authentication signature. See How to generate the signature.
x-request-timestamp✓Time the request is sent (format: yyyyMMddHHmmssSSS, UTC+7)

Body Parameter​

FieldTypeRequiredDescription
bankBinstring✓Always 970416 (ACB).
accountTypestring✓Account type: personal-account, business-account, business-household-account.
accountNumberstring✓ACB account number to register.
accountNamestring✓Account holder name (uppercase, without diacritics).
mobilestring✓Phone number registered with ACB, used to receive the OTP. Format: 10 digits, starting with 0.
acbUserIdstring~ACB Online / Biz login user ID.
Required for business and household business accounts.
merchantIdnumber~Merchant ID
(required if you connect with a Master Merchant account).
shopIdnumber✕ID of the shop to assign the account to. If left empty, the system creates a new shop on confirmation.
namestring✕Account nickname. Default: ACB - {accountNumber} - Ghi nợ.
merchantNamestring✕Shop name (used when the system creates a new shop).
merchantAddressstring✕Shop address (used when the system creates a new shop).

Code samples​

curl --location --request POST 'https://open-api.tingee.vn/v1/create-debit' \
--header 'accept: application/json' \
--header 'x-client-id: YOUR_CLIENT_ID' \
--header 'x-request-timestamp: 20240509154004003' \
--header 'x-signature: YOUR_SIGNATURE' \
--header 'Content-Type: application/json' \
--data '{
"bankBin": "970416",
"accountType": "personal-account",
"accountNumber": "12345678",
"accountName": "NGUYEN VAN A",
"mobile": "0935926988"
}'

Sample Response​

{
"code": "00",
"message": "Success",
"data": {
"confirmId": "c2a8f3e0-4b1d-4e0a-9a51-7d2f0e6b9c11"
}
}
FieldTypeDescription
codestringResult code (00 = success).
messagestringResponse message.
data.confirmIdstringConfirmation ID, used to call the Confirm account number API within 4 minutes.

Common error codes​

CodeDescriptionHow to handle
1059The bank does not support this operationThis API only applies to ACB.
1048Account number already registeredThe account is already registered for debit notifications.
1022Account already existsThe account is already registered for both credit and debit notifications.
1031, 1085Shop does not exist or is inactiveCheck shopId, or leave it empty so the system creates a shop.
1037, 1103The shop's TingeeBox device does not support this bankChoose another shop that matches the device configuration.
1095, 1096Master Merchant merchantId errorPass a merchantId that belongs to the Master Merchant calling the API.
400Invalid data or error from ACBmessage describes the details (e.g. the phone number does not match the information at ACB).
90, 91, 92, 97Request authentication error (timestamp, client-id, signature)See System error codes.
OthersOther errorsSee Error codes.