Skip to main content

Link an account

Use this API to let a user register for and authorize linking a bank account.

After the request is created successfully, Tingee sends you a link to a web page where the customer enters the details of the account to link.

POST
URLhttps://open-api.tingee.vn/v1/direct-debit/register

Create a request to link a bank account. Returns a URL where the user completes the verification steps on the Tingee interface.

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
requestIdstring✓Unique identifier for each request, in UUID format.
Reuse this requestId to look up the result with the Query account status API.
phonestring✓Phone number registered with the bank account.
returnUrlstring✓URL to return to your application after completion.
bankBinstring✕Bank BIN. See Supported banks.
accountNamestring✕Account holder name (prefilled as a suggestion for the user).
emailstring✕Customer's email.

Code samples​

curl --location --request POST 'https://open-api.tingee.vn/v1/direct-debit/register' \
--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 '{
"requestId": "550760e0-1cc2-44b9-85ba-eb318e228b4d",
"phone": "0974444479",
"returnUrl": "https://example.com"
}'

Sample Response​

{
"code": "00",
"message": "Success",
"data": "https://direct-debit.tingee.vn/direct-debit?requestId=..."
}
FieldTypeDescription
codestringResponse code (00 means success).
messagestringDetailed message.
datastringURL to redirect the user to for linking the account.
The URL is valid for 30 minutes.

Common error codes​

CodeDescriptionHow to handle
90, 91, 92, 97Request authentication error (timestamp, client-id, signature)See System error codes.
OthersOther errorsSee Error codes.