Card Validation

The Card Validation endpoint allows merchants to verify the validity of cards across various acquirers in Latin America, using either Zero Auth operations or simulated minimal-amount purchases followed by automatic refunds.

Request URL

Send a POST request to the following URLs according to your needs:

  • Production: https://secure-api.bamboopayment.com/v3/api/card/validate
  • Testing: https://secure-api.stage.bamboopayment.com/v3/api/card/validate

Remember to include your merchant’s Private Key in the request headers.
For more details, check our Authentication Guide.

Request Parameters

The request consists of two main objects: CardData containing the card information and Customer with the cardholder’s details.

CardData Object

ParameterTypeMandatoryDescription
CardHolderNamestringYesFull name as it appears on the card
PanstringYesCard number without spaces or separators
CVVstringYesCard security code (3-4 digits)
ExpirationstringYesCard expiration date in format MM/YY
EmailstringYesCardholder’s email address
DocumentstringYes*Cardholder’s document number (*Required for some countries)
TargetCountryISOstringYesTwo-letter ISO country code where the card will be processed. Send the country using ISO-3166-1 format.

Customer Object

ParameterTypeRequiredDescription
FirstNamestringNo¹Customer’s first name
LastNamestringNo¹Customer’s last name
EmailstringNo¹Customer’s email address
DocumentNumberstringNo¹Customer’s identification number. Use CPF for Brazil or DNI for Argentina
DocumentTypestringNo¹Type of document. Use “CPF.BR” for Brazil or “DNI.AR” for Argentina
AddressobjectNo¹Customer’s address information

¹ It should be required for Argentina and Brazil.

Address Object

ParameterTypeRequiredDescription
CountrystringNo¹Two-letter ISO country code (BR or AR)
StatestringNo¹State or province code (e.g., “SP” for São Paulo, “BA” for Buenos Aires)
CitystringNo¹City name
PostalCodestringNoPostal or ZIP code
AddressDetailstringYes¹Street address with number

¹ It should be required for Argentina and Brazil.

Request example

{
    "CardData": {
        "CardHolderName": "João Silva",
        "Pan": "4507990000004905",
        "CVV": "123",
        "Expiration": "08/30",
        "Email": "joao.silva@example.com",
        "Document": "41158995814",
        "TargetCountryISO": "BR"
    },
    "Customer":{
        "FirstName": "João",
        "LastName": "Silva",
        "Email": "joao.silva@example.com",
        "DocumentNumber": "41158995814",
        "DocumentType": "CPF.BR",
        "Address":{
            "Country": "BR",
            "City": "São Paulo",
            "State": "SP",
            "PostalCode": "01234-567",
            "AddressDetail": "Rua da Consolação, 1234"
        }
    }
}

Response Parameters

The response includes information about the validation result and details about the payment method.

ParameterTypeDescription
StatusstringResult of the validation. Possible values are APPROVED, REJECTED
ErrorCodestringError code if the validation was rejected. null if approved
ErrorDescriptionstringDetailed description of the error if the validation was rejected. null if approved
PaymentMethodobjectInformation about the validated card

PaymentMethod Object

ParameterTypeDescription
BrandstringCard brand (e.g., “MasterCard”, “Visa”)
IssuerBankstringName of the bank that issued the card
TypestringType of card (e.g., “CreditCard”, “DebitCard”)

Response Example

{
    "Status": "APPROVED",
    "ErrorCode": null,
    "ErrorDescription": null,
    "PaymentMethod": {
        "Brand": "MasterCard",
        "IssuerBank": "SANTANDER BRASIL",
        "Type": "CreditCard"
    }
}

Status Values

The validation can return the following status values:

StatusDescription
APPROVEDCard successfully validated
REJECTEDCard validation failed. Check ErrorCode and ErrorDescription for details

When the status is REJECTED, the ErrorCode and ErrorDescription fields will provide specific information about why the validation failed. For more information about error codes, check our Error Guide.

footer
Last modified December 20, 2024

© Bamboo | All rights reserved 2024