Bank Account Validation Endpoint

Validate bank accounts in real time by using the Bank Account Validation Endpoint

Account Validation Request

POST https://api-stg.directa24.com/v5/account/validate

This endpoint allows you to validate if a bank account is valid, if it exists and if it can receive funds

Headers

Request Body

{
    "description": "Valid account"
}

Description

This endpoint allows you to validate not only if the details of the beneficiary are correct according to the validations performed by the banks, but also to validate if the account exists in the bank and if it can receive funds.

Validations performed:

  1. The bank account, branch and type are valid

  2. The account exists in the bank

  3. The bank account belongs to the beneficiary details indicated (Document, name, etc)

  4. The amount specified is within the minimum and maximum limits (optional, only performed if amount is sent)

  5. The account can receive funds (it's not blocked, closed, etc)

If all this checks pass, we can be sure that the account is valid and that a Withdrawal created with those details will be fulfilled successfully.

In order to start using this API, you need to:

  1. Send the request with POST method.

  2. Use the headers described here.

  3. Specify the details required to validate the account in the body as JSON

This API must be activated on your account. Check with your Account Manager regarding the activation

Example Request

curl --location --request POST 'https://api-stg.directa24.com/v5/account/validate' \
--header 'X-Login: cashouts_api_key' \
--header 'X-Date: 2022-01-01T19:00:06Z' \
--header 'Authorization: D24 520ec3e5e2d8f8c2fc66948bc87984a2ff8dec0fe25d13781272f0ae94665c3c' \
--header 'Content-Type: application/json' \
--data-raw '{
    "country": "BR",
    "document": "84932568207",
    "document_type": "CPF",
    "first_name": "Ricardo",
    "last_name": "Carlos",
    "amount": 100,
    "currency": "BRL",
    "bank_account": {
        "bank_code": 100,
        "account": "123456-7",
        "branch": "6789-X",
        "account_type": "S" 
    }
}'

Request fields description

Example Responses

Success Example

In case the bank account passed all the validations, an HTTP 204 status code will be returned.

Error Responses Example

// The document informed didn't pass our validations
{
    "code": 300,
    "description": "Invalid document number",
    "type": "INVALID_DOCUMENT"
}

// The API Key used is incorrect
{
    "code": 100,
    "description": "Invalid Credentials",
    "type": "INVALID_CREDENTIALS"
}

// The bank account is invalid
{
    "code": 302,
    "description": "Invalid bank account",
    "type": "INVALID_BANK_ACCOUNT"
}

Error Responses Fields

Last updated