Skip to main content

Pay Out

Transfer API

Pay Out is Cas’s automated money transfer service that allows your system to create payment orders and transfer money to any bank account quickly, securely, and transparently. This service is ideal for businesses that need to process multiple transfers daily—such as salary payouts, refunds, or partner payments.

Benefits:

  • Easy integration with a single API: Connect user accounts, make smarter transaction decisions, manage risks, and transfer funds—all through a single integration with bankHub.
  • Optimized payout operations: Accounting teams no longer need to handle manual tasks, reducing workload.
  • Minimized payment risks: Instead of manual transfers that are error-prone, using the API ensures all transactions are executed exactly as input.
  • Time-saving: With just one click, you can trigger thousands of automated transactions.
  • For enhanced performance, the Pay Out API is commonly used in combination with the Balance API (real-time account balance queries).

Steps to Integrate Pay Out

Below are the steps to integrate Pay Out into your product.

  1. Create a grant /grant/token with scopes set to transfer.

  2. Open the Cas Link interface using the grantToken returned in the previous step. See details

  3. After the user completes authentication, your frontend will receive a publicToken. Use this token to obtain the accessToken for the grant.

  4. You can now call the Pay Out API.

Call API

Grant access for Pay Out

curl --location 'https://sandbox.bankhub.dev/grant/token' \
--header 'X-BankHub-Api-Version: 2023-01-01' \
--header 'x-client-id: <CLIENT_ID_HERE>' \
--header 'x-secret-key: <SECRET_KEY_HERE>' \
--header 'Content-Type: application/json' \
--data '{
"scopes": "transfer",
"language": "vi",
"redirectUri": "https://your-domain.vn/link",
}'
info

For detail API, here

Get accessToken from publicToken

  curl --location 'https://sandbox.bankhub.dev/grant/exchange' \
--header 'X-BankHub-Api-Version: 2023-01-01' \
--header 'x-client-id: <CLIENT_ID_HERE>' \
--header 'x-secret-key: <SECRET_KEY_HERE>' \
--header 'Content-Type: application/json' \
--data '{
"publicToken": "bdbde2bad-7685-4f95-987c-71309a4a3"
}'
info

For detail API, heretại đây

API Pay Out

  curl --location 'https://sandbox.bankhub.dev/transfer' \
--header 'X-BankHub-Api-Version: 2023-01-01' \
--header 'Authorization: <ACCESS_TOKEN_HERE>' \
--header 'x-client-id: <CLIENT_ID_HERE>' \
--header 'x-secret-key: <SECRET_KEY_HERE>'
--header 'x-interaction-id: ebcccee7-b5c6-4990-994b-fccf01320e54' \
--data '{
"amount": 10000,
"fromAccountNumber": "000",
"toBin": "970415",
"toAccountNumber": "113366668888",
"description": "CK"
}'
info

For detail API, here