Skip to content

Transfer

Create a transfer

POSThttps://connect.cabital.com/api/v1/accounts/{account_id}/transfers

Transfer between same name accounts from Cabital to partner.

User Account Status

  • Linked
  • KYC Pass

Request Path Parameters

Parameter Required Description
account_id Yes Customer account ID provided by Cabital.

Request Body Parameters

Content Type: application/json

Parameter Required Type Description
symbol Yes string Transfer currency code
amount Yes string Transfer amount
direction Yes string Indicates the direction of funds:
  • CREDIT: Partner → Cabital
  • DEBIT: Cabital → Partner
otp Conditional string A 6-digit code that the customer set up the Google Authenticator at Cabital.
When direction is DEBIT, this parameter is required.
conversion_id No string Conversion ID for associated conversion and transfer transactions, and it is used for reconciliation.
external_id No string Partner's transaction ID. If the ID is duplicated, the transaction will be rejected.

Response Parameters

Precautions:

The transfer transaction status should not stay PROCESSING too long. If a transfer transaction is in the PROCESSING state for a long time, it will need to check manually.

  • If the transaction partner already accounted, Cabital will change the status to SUCCESS manually.
  • If the transaction partner not yet accounted, Cabital will change the status to CANCEL manually.
Parameter Type Description
transfer_id string Transfer transaction ID
instruction_id string Instruction ID for reconciliation
external_id string Partner's transaction ID
instructed_amount string Transfer amount
customer_fee string The transfer fee charged to the user.
actual_amount string The amount that the customer receive actually.
status string Transfer transaction status.
  • PROCESSING: The transaction is processing.
  • SUCCESS: The transaction is successful.
  • FAILED: The transaction is failed.
  • CANCEL: The transaction is canceled.

Example

Request Data

curl -X POST "http://connect.cabital.com/api/v1/accounts/6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c/transfers"
-d '{
    "amount": "1002.865",
    "symbol": "USDT",
    "direction": "DEBIT",
    "conversion_id": "d81adf6d-0322-41d7-8c32-669203e35f11",
    "external_id": "adb8f31d-7a71-4003-85d7-3ac58158461f"
}'

Response Data

1
2
3
4
5
6
7
8
9
{
  "transfer_id": "4c416854-8970-4838-99ad-febc437ac81d",
  "status": "SUCCESS",
  "instructed_amount": "0.010001",
  "customer_fee": "0.01",
  "actual_amount": "0.000001",
  "external_id": "bbda2651-0ae3-447f-acaf-c23b5449bfb5",
  "instruction_id": "3a344f80-f057-4841-b186-7a1daa0b8390"
}

Confirm a transfer

PUThttps://connect.cabital.com/api/v1/accounts/{account_id}/transfers/{transfer_id}

When the customer initiates a transfer in Cabital, Cabital will notify partner via Webhook. After partner complete the transfer should update the result via this API.

Notice

If you create a transfer by Create a transfer API, you don't need to confirm the transfer by this API.

User Account Status

  • Linked
  • KYC Pass

Request Path Parameters

Parameter Required Description
account_id Yes Customer account ID provided by Cabital.
transfer_id Yes Transfer transaction ID

Request Body Parameters

Content Type: application/json

Parameter Required Type Description
status Yes string Transfer transaction status.
  • PROCESSING: The transaction is processing
  • SUCCESS: The transaction is successful
  • FAILED: The transaction is failed
  • CANCEL: The transaction is canceled
external_id Yes string Partner's transaction ID. If the ID is duplicated, the transaction will be rejected.
handle_time Yes integer Time of processing the transaction.
code No string Please provide the error code when status is FAILED or CANCEL.
message No string Please provide the error message when status is FAILED or CANCEL.

Response Parameters

If the HTTP status code of the response is 200 OK, means the content is accepted, no need to retry.

Example

Request Data

curl -X PUT "http://connect.cabital.com/api/v1/accounts/transfers/30643636-3162-6564-3563-373064383332"
-d '{
    "status": "SUCCESS",
    "external_id": "12345",
    "handle_time": 1658485881
}'

Response Data

{}

List all transfers by account ID

GEThttps://connect.cabital.com/api/v1/accounts/{account_id}/transfers

User Account Status

  • Linked
  • KYC Pass

Request Path Parameters

Parameter Required Description
account_id Yes Customer account ID provided by Cabital.

Request Query Parameter

Parameter Required Type Description
direction No string Indicates the direction of funds:
  • CREDIT: Partner → Cabital
  • DEBIT: Cabital → Partner
symbol No string Transfer currency
has_conversion No boolean Transfer transaction is associated with the conversion transaction.
cursor No string Pagination cursor value, default value is -1.
page_size No integer Number of transfer transactions returned.
Default value is 10, the range of number is between 1 and 30.
created_from No timestamp The timestamp when transfer transaction is created.
created_to No timestamp The timestamp when transfer transaction is ended.

Response Parameters

Parameter Type Description
account_id string Customer account ID provided by Cabital.
user_ext_ref string Customer account ID provided by Partner.
transfer_id string Transfer transaction ID
instruction_id string Instruction ID for reconciliation
symbol string Transfer currency
direction string Indicates the direction of funds:
  • CREDIT: Partner → Cabital
  • DEBIT: Cabital → Partner
external_id string Partner's transaction ID
conversion_id string Conversion ID for associated conversion and transfer transactions, and it is used for reconciliation.
instructed_amount string Transfer amount
customer_fee string The transfer fee charged to the user.
actual_amount string The amount that the customer receive actually.
status string Transfer transaction status.
  • PROCESSING: The transaction is processing.
  • SUCCESS: The transaction is successful.
  • FAILED: The transaction is failed.
  • CANCEL: The transaction is canceled.
created_at timestamp The timestamp when transfer transaction is created.
transfer_by string Initiator of transfer transaction.
  • PARTNER: Partner
  • CUSTOMER: Customer

Example

Request Data

curl "https://connect.cabital.com/api/v1/accounts/6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c/transfers"

Response Data

{
  "pagination_response": {
    "cursor": "-1"
  },
  "transfers":[
    {
      "transfer_id": "4c416854-8970-4838-99ad-febc437ac81d",
      "account_id": "6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c",
      "instructed_amount": "1002.865",
      "customer_fee": "2.5",
      "actual_amount": "1000.365",
      "symbol": "USDT",
      "direction": "DEBIT",
      "conversion_id": "d81adf6d-0322-41d7-8c32-669203e35f11",
      "external_id": "adb8f31d-7a71-4003-85d7-3ac58158461f",
      "user_ext_ref": "bc6b32a7-414e-46e4-a8c4-901568ad51e2",
      "created_at": 1633445162,
      "status": "SUCCESS",
      "transfer_by": "PARTNER"
    },
    {
      "transfer_id": "4c416854-8971-4838-99ad-febc437ac81d",
      "account_id": "6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c",
      "instructed_amount": "2.865",
      "customer_fee": "2.5",
      "actual_amount": "0.365",
      "symbol": "BTC",
      "direction": "CREDIT",
      "external_id": "adb8f31d-7a71-4003-85d7-3ac58158461f",
      "user_ext_ref": "c66768c2-9d1a-4cd9-a255-16de265624ae",
      "created_at": 1633445160,
      "status": "SUCCESS",
      "transfer_by": "CUSTOMER"
    }
  ]
}

List all transfers by partner's account ID

GEThttps://connect.cabital.com/api/v1/userextref/{user_ext_ref}/transfers

User Account Status

  • Linked
  • KYC Pass

Request Path Parameters

Parameter Required Description
user_ext_ref Yes Customer account ID provided by Partner.

Request Query Parameter

Parameter Required Type Description
direction No string Indicates the direction of funds:
  • CREDIT: Partner → Cabital
  • DEBIT: Cabital → Partner
symbol No string Transfer currency
has_conversion No boolean Transfer transaction is associated with the conversion transaction.
cursor No string Pagination cursor value, default value is -1.
page_size No integer Number of transfer transactions returned.
Default value is 10, the range of number is between 1 and 30.
created_from No timestamp The timestamp when transfer transaction is created.
created_to No timestamp The timestamp when transfer transaction is ended.

Response Parameters

Parameter Type Description
account_id string Customer account ID provided by Cabital.
user_ext_ref string Customer account ID provided by Partner.
transfer_id string Transfer transaction ID
instruction_id string Instruction ID for reconciliation
symbol string Transfer currency
direction string Indicates the direction of funds:
  • CREDIT: Partner → Cabital
  • DEBIT: Cabital → Partner
external_id string Partner's transaction ID
conversion_id string Conversion ID for associated conversion and transfer transactions, and it is used for reconciliation.
instructed_amount string Transfer amount
customer_fee string The transfer fee charged to the user.
actual_amount string The amount that the customer receive actually.
status string Transfer transaction status.
  • PROCESSING: The transaction is processing.
  • SUCCESS: The transaction is successful.
  • FAILED: The transaction is failed.
  • CANCEL: The transaction is canceled.
created_at integer Transfer transaction timestamp.
transfer_by string Initiator of transfer transaction.
  • PARTNER: Partner
  • CUSTOMER: Customer

Example

Request Data

curl "https://connect.cabital.com/api/v1/userextref/6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c/transfers"

Response Data

{
  "pagination_response": {
    "cursor": "-1"
  },
  "transfers":[
    {
      "transfer_id": "4c416854-8970-4838-99ad-febc437ac81d",
      "account_id": "1f30d577-982a-4091-96e0-af3819fcd412",
      "instructed_amount": "1002.865",
      "customer_fee": "2.5",
      "actual_amount": "1000.365",
      "symbol": "USDT",
      "direction": "DEBIT",
      "conversion_id": "d81adf6d-0322-41d7-8c32-669203e35f11",
      "external_id": "adb8f31d-7a71-4003-85d7-3ac58158461f",
      "user_ext_ref": "6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c",
      "created_at": 1633445162,
      "status": "SUCCESS",
      "transfer_by": "PARTNER"
    },
    {
      "transfer_id": "4c416854-8971-4838-99ad-febc437ac81d",
      "account_id": "bbdde6e2-25e0-4eab-a31d-37142e34c2ee",
      "instructed_amount": "2.865",
      "customer_fee": "2.5",
      "actual_amount": "0.365",
      "symbol": "BTC",
      "direction": "CREDIT",
      "external_id": "adb8f31d-7a71-4003-85d7-3ac58158461f",
      "user_ext_ref": "6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c",
      "created_at": 1633445160,
      "status": "SUCCESS",
      "transfer_by": "CUSTOMER"
    }
  ]
}

Retrieve a transfer by transfer ID

GEThttps://connect.cabital.com/api/v1/transfers/{transfer_id}

Request Path Parameters

Parameter Required Description
transfer_id Yes Transfer transaction ID.

Response Parameters

Parameter Type Description
account_id string Customer account ID provided by Cabital.
user_ext_ref string Customer account ID provided by Partner.
transfer_id string Transfer transaction ID
instruction_id string Instruction ID for reconciliation
symbol string Transfer currency
direction string Indicates the direction of funds:
  • CREDIT: Partner → Cabital
  • DEBIT: Cabital → Partner
external_id string Partner's transaction ID
conversion_id string Conversion ID for associated conversion and transfer transactions, and it is used for reconciliation.
instructed_amount string Transfer amount
customer_fee string The transfer fee charged to the user.
actual_amount string The amount that the customer receive actually.
status string Transfer transaction status.
  • PROCESSING: The transaction is processing.
  • SUCCESS: The transaction is successful.
  • FAILED: The transaction is failed.
  • CANCEL: The transaction is canceled.
created_at integer The timestamp when transfer transaction is created.
transfer_by string Initiator of transfer transaction.
  • PARTNER: Partner
  • CUSTOMER: Customer

Example

Request Data

curl "https://connect.cabital.com/api/v1/transfers/4c416854-8970-4838-99ad-febc437ac81d"

Response Data

{
  "transfer_id": "4c416854-8970-4838-99ad-febc437ac81d",
  "account_id": "6d92e7b4-715c-4ce3-a028-19f1c8c9fa6c",
  "instructed_amount": "1002.865",
  "customer_fee": "2.5",
  "actual_amount": "1000.365",
  "symbol": "USDT",
  "direction": "DEBIT",
  "conversion_id": "d81adf6d-0322-41d7-8c32-669203e35f11",
  "external_id": "adb8f31d-7a71-4003-85d7-3ac58158461f",
  "user_ext_ref": "6d3654ac-5f8b-4202-af20-6ab3a7f44d78",
  "created_at": 1633445162,
  "status": "SUCCESS",
  "transfer_by": "PARTNER"
}

Retrieve a transfer by partner's transaction ID

GEThttps://connect.cabital.com/api/v1/recon/transfers/{external_id}

Request Path Parameters

Parameter Required Type Description
external_id Yes string Partner's transaction ID

Response Parameters

Parameter Type Description
account_id string Customer account ID provided by Cabital.
user_ext_ref string Customer account ID provided by Partner.
transfer_id string Transfer transaction ID
instruction_id string Instruction ID for reconciliation
symbol string Transfer currency
direction string Indicates the direction of funds:
  • CREDIT: Partner → Cabital
  • DEBIT: Cabital → Partner
external_id string Partner's transaction ID
conversion_id string Conversion ID for associated conversion and transfer transactions, and it is used for reconciliation.
instructed_amount string Transfer amount
customer_fee string The transfer fee charged to the user.
actual_amount string The amount that the customer receive actually.
status string Transfer transaction status.
  • PROCESSING: The transaction is processing.
  • SUCCESS: The transaction is successful.
  • FAILED: The transaction is failed.
  • CANCEL: The transaction is canceled.
created_at timestamp The timestamp when transfer transaction is created.

Example

Request Data

curl "https://connect.cabital.com/api/v1/recon/transfers/adb8f31d-7a71-4003-85d7-3ac58158461f"

Response Data

{
    "transfer_id": "eca83642-0e70-41f2-beee-ebdafe332a2d",
    "external_id": "adb8f31d-7a71-4003-85d7-3ac58158461f",
    "status": "SUCCESS",
    "direction": "CREDIT",
    "symbol": "USDT",
    "instructed_amount": "200",
    "customer_fee": "0",
    "actual_amount": "200",
    "created_at": 1661307719,
    "instruction_id": "21ef34f2-fd3e-4d42-9143-15f48b1a00ad",
    "account_id": "614bebe5-b9a5-433a-99c5-59d637617cbb",
    "user_ext_ref": "latibac_user_1656053354",
    "transfer_by": "PARTNER"
}