This is the new Pix integration you should follow from 09/01.
Learn more about this feature in the documentation.
To generate a Pix QR code through Gateway de Pagamento, integrate according to the specification below.
The required field Payment.Type must be sent as "Pix". The response will return the base64 code of the Pix QR Code image, which the store must provide to the buyer.
The maximum expiration time for the Pix QR Code by Cielo is 24 hours. This expiration time can be changed in the
Payment.QrCodeExpirationfield.
Alphanumeric CNPJs will be implemented by the Brazilian Federal Revenue Service in July 2026This change applies only to new registrations. There will be no changes to existing CNPJs.
The alphanumeric CNPJ is already supported by Cielo, with no changes required to your integration.
We recommend checking whether adjustments are needed in your merchant’s own checkout systems.
Request
| Environment | Method | Endpoint |
|---|---|---|
| Production | post | https://api.braspag.com.br/v2/sales/ |
The new Pix integration does not yet have a sandbox environment available.
{
"MerchantOrderId": "1234567890",
"Customer": {
"Name": "Aline de Souza",
"Identity": "077...",
"IdentityType": "CPF"
},
"Payment": {
"Type": "Pix",
"Amount": 100,
"Provider": "Cielo2"
}
}Header parameters
| Property | Description | Type | Size | Required |
|---|---|---|---|---|
MerchantId | Merchant identifier in Gateway de Pagamento. | Text | 36 | Yes |
MerchantKey | Public key for dual authentication in Gateway de Pagamento. | Text | 40 | Yes |
RequestId | Request identifier, used when the merchant uses different servers for each GET/POST/PUT. | Text | 36 | No |
Body parameters
| Field | Type | Description |
|---|---|---|
MerchantOrderId | text | Order identification number. Special characters are not allowed. Size: 25 |
Customer.Name | text | Shopper's name. Size: 255. |
Customer.Identity | text | Shopper's CPF or CNPJ number. Size: 18. Allows submission of alphanumeric CNPJs. |
Payment.Type | text | Payment method type. In this case, enter “Pix”. Size: 15. |
Payment.Provider | text | Payment provider name. In this case, "Cielo2" |
Payment.Amount | number | Order amount, in cents. |
Payment.QrCodeExpiration | number | QR Code expiration time, in seconds. (E.g.: 30 minutes = 1800). This field is optional; if not informed, the default value is 86400 (24h). |
Response
{
"MerchantOrderId": "7a8...",
"Customer": {
"Name": "Aline de Souza",
"Identity": "211...",
"IdentityType": "CPF"
},
"Payment": {
"QrCodeBase64Image": "iVB...",
"QrCodeString": "00020...",
"SentOrderId": "f72...",
"PaymentId": "f72...",
"Type": "Pix",
"Amount": 100,
"ReceivedDate": "2024-11-25 11:30:33",
"Currency": "BRL",
"Country": "BRA",
"Provider": "Cielo2",
"ReasonCode": 0,
"ReasonMessage": "Successful",
"Status": 12,
"ProviderReturnCode": "0",
"ProviderReturnMessage": "QRCode gerado com sucesso",
"Links": [
{
"Method": "GET",
"Rel": "self",
"Href": "https://apiquerysandbox.braspag.com.br/v2/sales/f72965cb-e5d3-42fd-8fc3-4eaa51c9427e"
}
]
}
}Response parameters
The table below presents the main parameters that can be returned by Gateway de Pagamento when generating a QR code for Pix payment:
| Field | Type | Description |
|---|---|---|
Payment.QrCodeBase64Image | text | Base64 of the QRCode image generated for Pix payment. |
Payment.QrCodeString | text | Pix code (Copy and paste) that can be used for payment. |
Payment.SentOrderId | text | Pix transaction identifier, represents the txid. |
Payment.ReturnCode | number | Return code. |
Payment.ReturnMessage | text | Return message. |
Payment.PaymentId | text | Transaction identifier used for query. |
Payment.ProviderReturnCode | text | Provider return code. |
Payment.ProviderReturnMessage | text | Provider return message. |
Field Changes
See the changes in the fields returned when updating the provider from Cielo30 to Cielo2:
| Fields | Previous integration | New integration (Cielo2) |
|---|---|---|
AcquirerOrderId | Represented the QR Code ID. | No longer exists. |
ProofOfSale | Represented the Pix NSU. | No longer exists. |
SentOrderId | Represented the MerchantOrderId. | Now represents the txid. |
All other fields remain the same.