Skip to content

Transfer between accounts​

POST
/v1/account/subaccounts/transfer

Requires TRANSFERS_CREATE, granted by TREASURY_WRITE (bundles)

Moves funds between two of your accounts: your primary account (0) and its sub-accounts. Called on your primary account it can move funds between any of them; called on a sub-account (with X-VALR-SUB-ACCOUNT-ID) it can only move funds out of that sub-account. A key limited to some sub-accounts can only move funds between those sub-accounts. The transfer is processed asynchronously: the 202 response means it was accepted, so check balances or transaction history to confirm it completed. The returned id appears as additionalInfo.transferId on the resulting INTERNAL_TRANSFER transactions.

Request Body​

application/json
JSON
{
"fromId": 0,
"toId": 7340032581337088,
"currencyCode": "USDC",
"amount": "2500",
"allowBorrow": false
}

Responses​

Accepted. The body holds the transfer's ID as a string in id.

application/json

Samples​

Errors

HTTPErrorWhen
400-113INVALID_JSONThe body isn't valid JSON.
400-11INVALID_REQUESTThe body is empty or a field fails validation; validationErrors lists each failing field.
400-109INVALID_CURRENCY_SYMBOLcurrencyCode isn't a currency VALR supports.
400-19213MARGIN_NOT_ENABLED_FOR_ACCOUNTallowBorrow is true, but the source account isn't enabled for margin.
400-6INSUFFICIENT_BALANCEallowBorrow is true, but the source account doesn't have enough collateral to borrow the shortfall.
400-19243BORROW_FOR_WITHDRAWAL_NOT_AVAILABLEBorrowing for transfers is temporarily unavailable. Transfer no more than the available balance, or try again later.
400-19244BORROW_FOR_WITHDRAWAL_NOT_AVAILABLE_FOR_SELECTED_CURRENCYThis currency can't be borrowed for a transfer.
400-11533CURRENCY_BORROW_EXCEEDED_FOR_COLLATERALIZED_LENDINGBorrowing the shortfall would take the source account past its borrow limit for this currency.
400-11534ACCOUNT_BORROW_EXCEEDED_FOR_COLLATERALIZED_LENDINGBorrowing the shortfall would take the source account past its total borrow limit.
403-11133SUB_ACCOUNT_INTERNAL_TRANSFER_NOT_ALLOWEDThe transfer was refused, and the message says why: fromId and toId are the same, one of them isn't an account in your business, the source account doesn't have enough available balance and allowBorrow is false, you called it on a sub-account and fromId isn't that sub-account, or your key is limited to sub-accounts and one of the accounts isn't among them.
500-19202INSUFFICIENT_LIQUIDITY_FOR_BORROWNot enough of this currency is available to borrow right now. Try again later.
500-19502CURRENCY_UNDER_MAINTENANCEThe currency is under maintenance. Try again in a few minutes.
503-11652INTERNAL_TRANSFERS_NOT_AVAILABLETransfers between accounts are temporarily unavailable.

Plus the errors common to all signed endpoints.