Credit Card

Overview

Orkestra supports processing credit and debit card payments, allowing merchants to offer card transactions with full control over authorization, capture, and installments.

In Brazil, merchants must explicitly ask the customer whether they are using a Credit Card (CREDIT_CARD) or Debit Card (DEBIT_CARD) since the identification via PAN is not automatically possible.

To create a card payment, set the paymentMethod to either CREDIT_CARD or DEBIT_CARD in the order transaction and provide the necessary card details.

📝 Minimum Required Fields for Card Payment

When creating an Order for a card payment, the following fields are mandatory:

FieldTypeDescription
charges[].customer.firstNameStringCustomer’s first name.
charges[].customer.lastNameStringCustomer’s last name.
charges[].customer.documentStringCustomer’s document number.
charges[].customer.documentTypeEnumDocument type — see supported types below.
charges[].transactions[].paymentMethodEnumMust be set to CREDIT_CARD or DEBIT_CARD.
charges[].transactions[].creditCard.card.numberStringCard number (PAN).
charges[].transactions[].creditCard.card.expiresAtStringExpiry date in MM/YYYY format.
charges[].transactions[].creditCard.card.securityCodeStringCard Verification Value (CVV / CVC).

⚙️ Optional Card Fields

FieldTypeDescription
charges[].transactions[].creditCard.card.holder.firstNameStringCardholder’s first name (if different from customer).
charges[].transactions[].creditCard.card.holder.lastNameStringCardholder’s last name.
charges[].transactions[].creditCard.card.holder.documentTypeEnumCardholder’s document type.
charges[].transactions[].creditCard.card.holder.documentStringCardholder’s document number.
charges[].transactions[].creditCard.card.billingAddressObjectBilling address (same structure as livingAddress).
charges[].transactions[].creditCard.card.issuingCountryEnum (ISO Alpha-3)Country code of card issuing country (e.g., BRA, USA, ARG).

📦 options Object

You can control the behavior of the card processing via the options object:

FieldTypeDefaultDescription
installmentsInteger1Number of installments for the payment.
autoCaptureBooleantrueWhether to capture automatically after authorization.
anticipateIntegernullDays to anticipate the receivables.
threeDSecureBooleantrueWhether to enforce 3D Secure authentication.
retryOnFailureBooleanfalseWhether to automatically retry failed transactions on retryable decline reasons.
captureDelayInteger0Delay in minutes before capture happens after authorization.
noCaptureBehaviorEnumVOIDWhat to do if a capture is not performed: VOID or CAPTURE.

🆔 DocumentTypeEnum

The following document types are supported depending on the country:

EnumCountry
CPFBrazil
CNPJBrazil
CUITArgentina
RFCMexico
CURPMexico
CCColombia
NITColombia
TIColombia
RUTChile
DNIPeru
CIEcuador
CEColombia, Peru
RUCEcuador, Peru
PASSPORTAll countries

📦 Example: Card Payment Request

{
    "merchantOrderId": "order-12345",
    "softDescriptor": "Orkestra Store",
    "amount": 5000,
    "currency": "BRL",
    "allowsThirdPartyPayments": false,
    "charges": [
        {
            "customer": {
                "firstName": "Camila",
                "lastName": "Silva",
                "document": "12345678900",
                "documentType": "CPF"
            },
            "transactions": [
                {
                    "paymentMethod": "CREDIT_CARD",
                    "creditCard": {
                        "card": {
                            "number": "4111111111111111",
                            "expiresAt": "12/2026",
                            "securityCode": "123",
                            "holder": {
                                "firstName": "Camila",
                                "lastName": "Silva",
                                "document": "12345678900",
                                "documentType": "CPF"
                            },
                            "billingAddress": {
                                "street": "Av. Paulista",
                                "number": "1000",
                                "complement": "Ap 12",
                                "neighborhood": "Bela Vista",
                                "zipCode": "01310000",
                                "city": "São Paulo",
                                "state": "SP",
                                "country": "BRA",
                                "mainInformation": "Av. Paulista, 1000",
                                "secondaryInformation": "Ap 12",
                                "latitude": -23.561684,
                                "longitude": -46.656139
                            },
                            "issuingCountry": "BRA"
                        },
                        "options": {
                            "installments": 3,
                            "autoCapture": true,
                            "anticipate": 30,
                            "threeDSecure": true,
                            "retryOnFailure": true,
                            "captureDelay": 5,
                            "noCaptureBehavior": "VOID",
                            "antifraud": {
                                "provider": "ClearSale",
                                "scoreThreshold": 70,
                                "metadata": {
                                    "ipAddress": "1.2.3.4",
                                    "deviceFingerprint": "abc123xyz",
                                    "customerSince": "2020-01-01",
                                    "previousOrders": 2
                                }
                            }
                        }
                    }
                }
            ]
        }
    ]
}

🔁 Payment Flow Overview

  • You create an order with paymentMethod set to CREDIT_CARD or DEBIT_CARD.
  • Orkestra processes the card authorization.
  • If autoCapture is enabled, the transaction will be captured immediately.
  • If 3DS is enabled, authentication will be performed automatically.
  • Payment confirmation is sent via webhook.

📦 Example: Card Payment Response

{
    "id": 987654,
    "merchantOrderId": "order-12345",
    "softDescriptor": "Orkestra Store",
    "amount": 5000,
    "currency": "BRL",
    "status": "PAID",
    "allowsThirdPartyPayments": false,
    "charges": [
        {
            "id": 123456,
            "amount": 5000,
            "status": "PAID",
            "customer": {
                "firstName": "Camila",
                "lastName": "Silva",
                "document": "12345678900",
                "documentType": "CPF"
            },
            "transactions": [
                {
                    "id": 789123,
                    "amount": 5000,
                    "paymentMethod": "CREDIT_CARD",
                    "creditCard": {
                        "card": {
                            "brand": "VISA",
                            "firstSixDigits": "411111",
                            "lastFourDigits": "1111",
                            "expiresAt": "12/2026",
                            "holder": {
                                "firstName": "Camila",
                                "lastName": "Silva",
                                "document": "12345678900",
                                "documentType": "CPF"
                            },
                            "billingAddress": {
                                "street": "Av. Paulista",
                                "number": "1000",
                                "complement": "Ap 12",
                                "neighborhood": "Bela Vista",
                                "zipCode": "01310000",
                                "city": "São Paulo",
                                "state": "SP",
                                "country": "BRA",
                                "mainInformation": "Av. Paulista, 1000",
                                "secondaryInformation": "Ap 12",
                                "latitude": -23.561684,
                                "longitude": -46.656139
                            },
                            "issuingCountry": "BRA"
                        },
                        "options": {
                            "installments": 3,
                            "autoCapture": true,
                            "captureDelay": 5,
                            "anticipate": 30,
                            "threeDSecure": true,
                            "retryOnFailure": true,
                            "noCaptureBehavior": "VOID",
                            "antifraud": {
                                "provider": "ClearSale",
                                "status": "APPROVED",
                                "scoreThreshold": 70,
                                "score": 85,
                                "riskLevel": "LOW",
                                "metadata": {
                                    "ipAddress": "1.2.3.4",
                                    "deviceFingerprint": "abc123xyz",
                                    "customerSince": "2020-01-01",
                                    "previousOrders": 2
                                }
                            }
                        },
                        "authorizedAt": "2025-05-31T16:30:00.000Z",
                        "capturedAt": "2025-05-31T16:30:00.000Z",
                        "authorizationCode": "A12345",
                        "nsu": "987654321",
                        "acquirer": "CIELO",
                        "threeDSecure": {
                            "enrolled": true,
                            "authenticated": false,
                            "threeDSUrl": "https://3ds.challenge.provider.com/abc123"
                        }
                    },
                    "status": "APPROVED"
                }
            ]
        }
    ]
}

🚨 Important Notes

  • It is highly recommended to validate the document field for local compliance.
  • 3DS authentication enhances security and helps in dispute management.
  • Be sure to collect explicit customer consent for installment payments when applicable.
  • Billing address can help improve authorization rates and lower fraud risks, especially internationally.
  • Retry on failure can help recover transactions in case of transient declines.

✅ Summary

To process card payments with Orkestra:

  • Collect card number, expiry date, and security code (CVV/CVC).
  • Collect customer information (name and document).
  • Use the options object to configure installments, 3DS, capture strategy, and receivables anticipation.

Orkestra handles authorization, capture, and secure transaction processing behind the scenes.