Register Bank Account
curl --request POST \
--url https://testapi.kravata.co/api/accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"accountHolderName": "ACME MEXICO SA DE CV",
"accountNickname": "Main MXN account",
"accountNumber": "1234567999",
"accountType": "ahorros",
"bankId": 1,
"currencyId": "MXN",
"countryId": 21,
"metadata": [
{
"metadataName": "CABLE",
"metadataValue": "100011010"
},
{
"metadataName": "MEMO",
"metadataValue": "cuenta1234"
}
]
}
'import requests
url = "https://testapi.kravata.co/api/accounts"
payload = {
"accountHolderName": "ACME MEXICO SA DE CV",
"accountNickname": "Main MXN account",
"accountNumber": "1234567999",
"accountType": "ahorros",
"bankId": 1,
"currencyId": "MXN",
"countryId": 21,
"metadata": [
{
"metadataName": "CABLE",
"metadataValue": "100011010"
},
{
"metadataName": "MEMO",
"metadataValue": "cuenta1234"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
accountHolderName: 'ACME MEXICO SA DE CV',
accountNickname: 'Main MXN account',
accountNumber: '1234567999',
accountType: 'ahorros',
bankId: 1,
currencyId: 'MXN',
countryId: 21,
metadata: [
{metadataName: 'CABLE', metadataValue: '100011010'},
{metadataName: 'MEMO', metadataValue: 'cuenta1234'}
]
})
};
fetch('https://testapi.kravata.co/api/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"accountHolderName": "MXN ACCOUUNTS",
"accountNickname": "MXN ACCOUNT",
"accountNumber": "1234567999",
"accountType": "ahorros",
"bankId": 1,
"clientId": "08597c65-c25b-4a7c-8c68-f1180bce65f4",
"id": "181e4661-30bb-4c39-86f3-dd6fe98e4302",
"metadata": [
{
"bankAccountId": "181e4661-30bb-4c39-86f3-dd6fe98e4302",
"metadataName": "CABLE",
"metadataValue": "100011010"
},
{
"bankAccountId": "181e4661-30bb-4c39-86f3-dd6fe98e4302",
"metadataName": "MEMO",
"metadataValue": "cuenta1234"
}
],
"status": "in_review"
}Accounts
Register Bank Account
Registers an external bank account for your company or for one of your users. The account is created with status in_review and can be used once Kravata approves it (accepted).
Request
| Field | Type | Required | Description |
|---|---|---|---|
| Authorization | Header | Yes | Bearer <access> obtained from POST /api/token. |
| clientId | Query | Yes | Your client ID, from GET /api/infoClient. Requests without it are rejected with 401. |
| userId | Query | No | Register the account for one of your users instead of your company. |
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| accountNickname | string | Yes | Alias to identify the account (max 50 characters). |
| accountNumber | string | Yes | Account number (max 50 characters). For breb, the Bre-B key. |
| accountType | string | Yes | ahorros (savings), corriente (checking) or breb (Colombia’s Bre-B instant payment key). |
| accountHolderName | string | No | Name of the account holder. Defaults to accountNickname. |
| bankId | integer | Yes, except for breb | Bank ID from GET /api/parameters/banks. For breb it is resolved automatically from the key. |
| currencyId | string | Only if the currency is not COP | 3-letter currency code, e.g. MXN or USD. Send it together with countryId. |
| countryId | integer | Only if the currency is not COP | Country of the account. Send it together with currencyId. |
| metadata | array | Depends on the currency | List of ('metadataName', 'metadataValue'). MXN accounts require CABLE (CLABE number) and USD accounts require ABBA (ABA routing number). You can add MEMO as a transfer reference. |
Response
The registered account: id, status (in_review), accountNickname, accountHolderName, accountType, accountNumber, bankId, bank, countryFiatId, metadata, isCustodial and registerDate.
Errors
| Status | When |
|---|---|
| 400 | Invalid body, account already registered, or invalid country/currency combination. |
| 401 | Missing token or clientId. |
POST
/
api
/
accounts
Register Bank Account
curl --request POST \
--url https://testapi.kravata.co/api/accounts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"accountHolderName": "ACME MEXICO SA DE CV",
"accountNickname": "Main MXN account",
"accountNumber": "1234567999",
"accountType": "ahorros",
"bankId": 1,
"currencyId": "MXN",
"countryId": 21,
"metadata": [
{
"metadataName": "CABLE",
"metadataValue": "100011010"
},
{
"metadataName": "MEMO",
"metadataValue": "cuenta1234"
}
]
}
'import requests
url = "https://testapi.kravata.co/api/accounts"
payload = {
"accountHolderName": "ACME MEXICO SA DE CV",
"accountNickname": "Main MXN account",
"accountNumber": "1234567999",
"accountType": "ahorros",
"bankId": 1,
"currencyId": "MXN",
"countryId": 21,
"metadata": [
{
"metadataName": "CABLE",
"metadataValue": "100011010"
},
{
"metadataName": "MEMO",
"metadataValue": "cuenta1234"
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
accountHolderName: 'ACME MEXICO SA DE CV',
accountNickname: 'Main MXN account',
accountNumber: '1234567999',
accountType: 'ahorros',
bankId: 1,
currencyId: 'MXN',
countryId: 21,
metadata: [
{metadataName: 'CABLE', metadataValue: '100011010'},
{metadataName: 'MEMO', metadataValue: 'cuenta1234'}
]
})
};
fetch('https://testapi.kravata.co/api/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"accountHolderName": "MXN ACCOUUNTS",
"accountNickname": "MXN ACCOUNT",
"accountNumber": "1234567999",
"accountType": "ahorros",
"bankId": 1,
"clientId": "08597c65-c25b-4a7c-8c68-f1180bce65f4",
"id": "181e4661-30bb-4c39-86f3-dd6fe98e4302",
"metadata": [
{
"bankAccountId": "181e4661-30bb-4c39-86f3-dd6fe98e4302",
"metadataName": "CABLE",
"metadataValue": "100011010"
},
{
"bankAccountId": "181e4661-30bb-4c39-86f3-dd6fe98e4302",
"metadataName": "MEMO",
"metadataValue": "cuenta1234"
}
],
"status": "in_review"
}Authorizations
Access token from POST /api/token (valid 5 minutes).
Body
application/json

