# Create charge (/en/docs/cartao/endpoints/charges/post_charges)

## POST /charges

`POST https://api.payzu.io/v1/charges`

Creates a new credit card charge. - For 3DS authentication, see [Using 3DS](https://docs.payzu.com.br/docs/cartao/three-d-secure). - For the antifraud engine, see [Using Antifraud](https://docs.payzu.com.br/docs/cartao/antifraud). - For foreign currency charges, see [International charges](https://docs.payzu.com.br/docs/cartao/international). - For recurring payments, send the `recurrence` node. See [Recurring Payments](https://docs.payzu.com.br/docs/cartao/recurrence).

### Body params

| Field | Type | Required | Details |
| --- | --- | --- | --- |
| `amount` | number | yes | Charge amount in cents |
| `customer` | object | yes | Buyer data |
| `customer.name` | string | yes | Buyer's full name |
| `customer.identity` | string | no | Buyer's identification document number |
| `customer.identityType` | string | no | Buyer's identification document type |
| `customer.email` | string | no | Buyer's email |
| `customer.birthdate` | string | no | Buyer's birthdate |
| `customer.phone` | string | no | Buyer's phone number |
| `customer.address` | object | no | Billing address |
| `customer.address.street` | string | yes | Billing address street |
| `customer.address.number` | string | yes | Billing address number |
| `customer.address.complement` | string | no | Billing address complement |
| `customer.address.zipCode` | string | yes | Billing address postal code |
| `customer.address.city` | string | yes | Billing address city |
| `customer.address.state` | string | yes | Billing address state |
| `customer.address.country` | string | yes | Billing address country |
| `customer.address.district` | string | yes | Billing address district |
| `postbackUrl` | string | no | Url for notifications about the charge status. See [Webhooks](https://docs.payzu.com.br/docs/cartao/webhooks) |
| `paymentType` | string | yes | Charge payment type. See [Payment types](https://docs.payzu.com.br/docs/cartao/reference-codes) — `creditcard` |
| `cart` | object[] | yes | Buyer's cart |
| `cart.name` | string | yes | Product name |
| `cart.quantity` | number | yes | Product quantity |
| `cart.sku` | string | yes | Product SKU (Stock Keeping Unit) |
| `cart.unitPrice` | number | yes | Product unit price in cents |
| `creditCardPayment` | object | yes | Settings for the payment type: credit card |
| `creditCardPayment.installments` | number | yes | Number of installments. Must be 1 on international charges and recurrences |
| `creditCardPayment.card` | object | yes | Card details |
| `creditCardPayment.card.number` | string | yes | Credit card number |
| `creditCardPayment.card.holder` | string | yes | Cardholder name as printed on the credit card |
| `creditCardPayment.card.expiration` | string | yes | Credit card expiration date |
| `creditCardPayment.card.cvv` | string | yes | Security code on the back of the credit card |
| `creditCardPayment.currency` | string | no | Charge currency. In a foreign currency, `amount` is expressed in that currency's smallest unit. See [Currencies](https://docs.payzu.com.br/docs/cartao/reference-codes) and [International charges](https://docs.payzu.com.br/docs/cartao/international) — default: BRL |
| `creditCardPayment.authenticate` | boolean | yes | Defines whether the buyer will be redirected to the issuer for card authentication (3DS) |
| `creditCardPayment.externalAuthentication` | object | no | 3DS authentication data performed outside PayZu (external authentication) |
| `creditCardPayment.externalAuthentication.cavv` | string | yes | Signature returned on successful authentication scenarios |
| `creditCardPayment.externalAuthentication.xid` | string | no | XID returned in the authentication process |
| `creditCardPayment.externalAuthentication.eci` | string | yes | Electronic Commerce Indicator returned in the authentication process. See [ECI table](https://docs.payzu.com.br/docs/cartao/reference-codes) |
| `creditCardPayment.externalAuthentication.version` | string | yes | 3DS version applied in the authentication process |
| `creditCardPayment.externalAuthentication.referenceId` | string | yes | RequestID returned in the authentication process |
| `creditCardPayment.fraudAnalysis` | object | no | Data for the antifraud engine. Required on international charges. See [Using Antifraud](https://docs.payzu.com.br/docs/cartao/antifraud) |
| `creditCardPayment.fraudAnalysis.fingerPrintId` | string | yes | Identifier used to correlate information collected from the buyer's device |
| `creditCardPayment.fraudAnalysis.browser` | object | yes | Information about the buyer's browser |
| `creditCardPayment.fraudAnalysis.definedFields` | object[] | yes | Merchant Defined Data (MDD). See [MDD table](https://docs.payzu.com.br/docs/cartao/mdds) |
| `recurrence` | object | no | Recurring payment configuration. The first charge is created immediately; the following cycles are generated automatically. Requires `installments` equal to 1. See [Recurring Payments](https://docs.payzu.com.br/docs/cartao/recurrence) |
| `recurrence.interval` | string | yes | Interval between charges: `Monthly` or `Annual` — `Monthly`, `Annual` |
| `recurrence.endDate` | string | no | Recurrence end date in `YYYY-MM-DD` format. Without it, the recurrence runs indefinitely |
| `externalId` | string | yes | Unique identifier generated externally |

### Responses

**200** Successful request

| Field | Type | Required | Details |
| --- | --- | --- | --- |
| `id` | string | no | Charge identifier |
| `externalId` | string | no | Unique identifier generated externally |
| `postbackUrl` | string | no | Url for notifications about the charge status |
| `amount` | number | no | Charge amount in cents |
| `paymentType` | string | no | Charge payment type. See [Payment types](https://docs.payzu.com.br/docs/cartao/reference-codes) |
| `createdAt` | string | no | Charge creation date |
| `updatedAt` | string | no | Date the charge was last updated |
| `customer` | object | no | Buyer data |
| `customer.id` | number | no | Buyer identifier. |
| `customer.name` | string | no | Buyer's full name |
| `customer.identity` | string | no | Buyer's identification document number |
| `customer.identityType` | string | no | Buyer's identification document type |
| `customer.email` | string | no | Buyer's email |
| `customer.birthdate` | string | no | Buyer's birthdate |
| `customer.phone` | string | no | Buyer's phone number |
| `customer.address` | object | no | Billing address |
| `customer.address.street` | string | yes | Billing address street |
| `customer.address.number` | string | yes | Billing address number |
| `customer.address.complement` | string | no | Billing address complement |
| `customer.address.zipCode` | string | yes | Billing address postal code |
| `customer.address.city` | string | yes | Billing address city |
| `customer.address.state` | string | yes | Billing address state |
| `customer.address.country` | string | yes | Billing address country |
| `customer.address.district` | string | yes | Billing address district |
| `cart` | object[] | no | Buyer's cart |
| `cart.name` | string | yes | Product name |
| `cart.quantity` | number | yes | Product quantity |
| `cart.sku` | string | yes | Product SKU (Stock Keeping Unit) |
| `cart.unitPrice` | number | yes | Product unit price in cents |
| `creditCardPayment` | object | no | Credit card payment details |
| `creditCardPayment.installments` | number | no | Number of installments |
| `creditCardPayment.authenticate` | boolean | no | Indicates whether the buyer was redirected to the issuer for 3DS authentication |
| `creditCardPayment.currency` | string | no | Charge currency. See [Currencies](https://docs.payzu.com.br/docs/cartao/reference-codes) |
| `creditCardPayment.acquirerTransactionId` | string | no | Transaction identifier at the acquirer |
| `creditCardPayment.authorizationCode` | string | no | Authorization code returned by the acquirer |
| `creditCardPayment.reasonCode` | number | no | Reason code of the result. See [ReasonCode/ReasonMessage list](https://docs.payzu.com.br/docs/cartao/reason-codes) |
| `creditCardPayment.reasonMessage` | string | no | Reason message of the result. See [ReasonCode/ReasonMessage list](https://docs.payzu.com.br/docs/cartao/reason-codes) |
| `creditCardPayment.status` | integer | no | Transaction status. See [Transaction status list](https://docs.payzu.com.br/docs/cartao/transaction-status) |
| `creditCardPayment.returnCode` | string | no | Return code from the acquirer. See [Error Codes](https://docs.payzu.com.br/docs/cartao/error-codes) and [ABECS return codes](https://docs.payzu.com.br/docs/cartao/abecs-codes) |
| `creditCardPayment.returnMessage` | string | no | Return message from the acquirer |
| `creditCardPayment.externalAuthentication` | object | no | External 3DS authentication data, when sent at creation |
| `creditCardPayment.reversedAmount` | number | no | Reversed amount in cents, when a reversal exists |
| `creditCardPayment.reversedDate` | string | no | Reversal date, when present |
| `creditCardPayment.chargeId` | string | no | Charge identifier |
| `creditCardPayment.card` | object | no | Details of the card used in the charge |
| `creditCardPayment.card.id` | number | no | Card identifier. |
| `creditCardPayment.card.number` | string | no | Credit card number |
| `creditCardPayment.card.holder` | string | no | Cardholder name as printed on the credit card |
| `creditCardPayment.card.expiration` | string | no | Credit card expiration date |
| `creditCardPayment.card.brand` | string | no | Card brand. See [Brand](https://docs.payzu.com.br/docs/cartao/reference-codes) — `Visa`, `Master`, `Elo`, `Diners`, `Hipercard` |
| `creditCardPayment.chargebacks` | object[] | no | Chargebacks linked to the charge |
| `creditCardPayment.chargebacks.id` | number | no | Chargeback identifier |
| `creditCardPayment.chargebacks.number` | string | no | Chargeback number at the acquirer |
| `creditCardPayment.chargebacks.amount` | number | no | Chargeback amount in cents |
| `creditCardPayment.chargebacks.status` | string | no | Chargeback status. See [Chargeback status list](https://docs.payzu.com.br/docs/cartao/transaction-status) — `RECEIVED`, `ACCEPTED`, `DEFENDED` |
| `creditCardPayment.chargebacks.reasonCode` | string | no | Reason code provided by the card brand |
| `creditCardPayment.chargebacks.reasonDescription` | string | no | Reason description provided by the card brand |
| `creditCardPayment.chargebacks.issuedAt` | string | no | Chargeback issue date |
| `creditCardPayment.chargebacks.createdAt` | string | no | Record creation date |
| `creditCardPayment.chargebacks.updatedAt` | string | no | Date the record was last updated |
| `recurrence` | object | no | State of a recurrence |
| `recurrence.recurrentPaymentId` | string | no | Recurrence identifier. Use it on the recurrence query and management endpoints |
| `recurrence.interval` | string | no | Configured interval — `MONTHLY`, `ANNUAL` |
| `recurrence.status` | string | no | Recurrence status. See [Recurring Payments](https://docs.payzu.com.br/docs/cartao/recurrence) — `ACTIVE`, `INACTIVE`, `ENDED` |
| `recurrence.amount` | number | no | Amount of each cycle, in cents |
| `recurrence.nextRecurrency` | string | no | Date of the next automatic charge |
| `recurrence.endDate` | string | no | End date, if provided at creation |
| `recurrenceCycle` | integer | no | Cycle number of the recurrence this charge belongs to: 0 is the initial charge, 1..n are the automatically generated cycles. Present only on recurrence charges |