Payments

Banco Inter Pix API: how to integrate it

How to create a Banco Inter API integration, download its certificate and key, authenticate, issue a first Pix charge and reuse the same credential for boletos.

By Intopays team

6 min read

An integration created in Banco Inter's online banking becomes a certificate and key bundle, and your system starts generating Pix QR codes.crt + .keyBanco Inter Pix API

Banco Inter is a Brazilian digital bank with a large base of small-business accounts, and it is a common request for developers building checkouts, invoicing tools or ERPs for Brazilian clients. Its Pix API has one practical advantage over most Brazilian banks: you don't need to buy a digital certificate. Inter generates the client certificate and key itself when the account holder creates an integration in online banking.

This guide explains how that integration is created, what the API calls look like, and what to watch for in production. At the end it shows how to connect the same Inter account to Intopays and issue Pix charges and boletos through one English-language API.

What you need

ItemNote
A business (PJ) account at Intereach account gets its own integration
Online banking access with admin rightsthe person who creates the integration and accepts its permissions
A Pix key on the accounttax ID, email, phone or random key, on the same account
A public HTTPS endpointto receive payment webhooks

Unlike Sicoob, Banco do Brasil, Bradesco and Santander, Inter does not use the company's own ICP-Brasil A1 certificate for its API. The certificate used for mutual TLS is issued by the bank.

Creating the integration in online banking

Four steps at Banco Inter: sign in to business online banking, create the integration with its permissions, download the certificate and key, call the APIPUT /cob2011Business bankingsign in withthe QR code2New integrationpick the permissions3Download filescertificate and key4Call the APItoken + Pix charge
From online banking to the first charge: the certificate and key come from the bank itself.

According to Inter's developer documentation (developers.inter.co, in Portuguese), the account holder:

  1. Signs in to online banking on a computer, scanning a QR code with the Inter app.
  2. Opens Soluções para sua empresa (Business solutions) and clicks Nova Integração (New integration).
  3. Fills in the details and picks the permissions the application gets: create and read Pix charges (cob), read received Pix, manage the webhook and, if needed, issue boletos. A permission not granted here makes the matching API call fail later.
  4. In the list of integrations, downloads the key and certificate (a zip file) and activates the integration.

The zip holds the certificate (.crt) and private key (.key). The integration screen also shows the client ID and client secret. If your client is doing this for you, ask them to share the files and secret through a password manager, never by email or chat.

The certificate expires (integrators report one year, and Inter warns the account holder before it does). When it does, the holder generates a new one in online banking and you swap the files.

Authentication and the first charge

Inter's business APIs live at cdpj.partners.bancointer.com.br, and every call goes over a TLS connection that presents the downloaded certificate and key.

1. Token. Request a token at POST /oauth/v2/token, form-encoded, with client_id, client_secret, grant_type=client_credentials and space-separated scopes (cob.write cob.read webhook.write…). Only scopes granted to the integration are accepted. Cache the token and refresh it before it expires instead of requesting one per call.

2. Charge. With Authorization: Bearer <token>, an immediate charge follows the central bank's schema (Portuguese field names, amounts as strings in reais). At Inter you pick the txid and create the charge with PUT /pix/v2/cob/{txid}:

{
  "calendario": { "expiracao": 900 },
  "valor": { "original": "42.90" },
  "chave": "[email protected]",
  "solicitacaoPagador": "Order #1042"
}

The txid must be 26 to 35 alphanumeric characters and unique on the account — your order ID with a prefix works. The response carries pixCopiaECola, the payload you render as a QR code.

3. Account header. When an integration serves more than one account, Inter expects the account number in an x-conta-corrente header on each call. Sending it always saves a surprise when the client opens a second account.

4. Webhook. Register the notification URL for the Pix key with PUT /pix/v2/webhook/{key} and { "webhookUrl": "https://…" }. Inter calls it when a Pix lands. Treat the notice as a signal and confirm the charge at the bank before you ship — see handling Pix webhooks.

How it compares to what you know

If you've integrated Stripe or Square, three things will feel different:

Stripe / SquareBanco Inter Pix API
Authenticationa secret API keyOAuth token plus a client certificate on every call
Who holds the fundsthe processor, paid out laternobody: the Pix settles in the business account in seconds
Feesa percentage per transactionwhatever the account's plan charges per Pix received
Payment confirmationa signed webhook from the processora bank notice you should confirm by reading the charge

Pix and boletos on one credential

Inter's integration is not Pix-only. With the boleto permissions granted, the same client ID, secret and files issue boletos — Brazil's bank payment slips, common for B2B invoices with payment terms.

One Banco Inter credential, with its certificate and key, issues both Pix charges with QR codes and boletosInter credentialclient_id, client_secret, accountPix chargeQR code + copy and pasteBoletoissued on the same accountOne credential
One Inter integration, with the same certificate and key, issues both Pix charges and boletos.

In Intopays, an Inter boleto uses a 10-character referenceCode and, with the current integration, comes back without a Pix QR code. See create a boleto.

Connecting Inter to Intopays

If you'd rather not maintain token refresh, mutual TLS, webhook registration and Portuguese payloads in your own code, connect the Inter integration to Intopays. In the dashboard (currently in Portuguese), go to Banking → Credenciais → Nova credencial (Credentials → New credential), choose Inter and fill in:

FieldWhere it comes from
clientIdthe integration's client ID
clientSecretthe integration's client secret
pixKeythe account's Pix key
bankingNumberthe checking account number (sent as x-conta-corrente)
CRT and KEY certificate filesthe two files from the zip

The client secret is write-only: the API never returns it. The certificate's expiry is read from the .crt file and shown in the list. A connection test checks access to Inter and registers the payment webhook on the Pix key. Then a charge is a single call, with no txid to generate and no token to refresh:

curl -X POST https://api.intopays.com/v1/pixs \
  -H "Authorization: Bearer $INTOPAYS_TOKEN" \
  -H "X-Credential-Key: $INTOPAYS_CREDENTIAL_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "amountOriginal": 42.90,
    "calendarExpiration": 900,
    "payerRequest": "Order #1042"
  }'

The response includes the qrcode payload, the transactionId (Inter's txid) and a hosted payment page url. When the customer pays, your endpoint gets a pix.update event with status COMPLETED. See create a Pix charge and bank credentials.

The same call works for Sicoob, Sicredi, Banco do Brasil and Santander accounts — only the credential changes. Compare them in Pix API by bank, or read the Sicoob guide.

Frequently asked questions

Do I need an A1 certificate for Inter's API?

No. The certificate and key used for the API are generated by Inter when the integration is created. The company may still need an A1 for other things, such as signing electronic invoices.

Where are the client ID and client secret?

On the integration's screen under Soluções para sua empresa in Inter's online banking, next to the download of the certificate and key.

Can a non-Brazilian company open an Inter business account?

Not without a Brazilian entity. A business account needs a CNPJ. Without one, receiving Pix means using a cross-border payment provider that collects in Brazil on your behalf.

What happens when Inter's certificate expires?

Calls are refused at the TLS handshake. The account holder generates a new certificate in online banking before the expiry date, and you replace the files in your application or in the Intopays credential.

Does the same integration work for boletos?

Yes, if the boleto permissions were granted when the integration was created. If they weren't, create a new integration with them.

All articles

Keep reading

A checkout page with a Pix QR code and a copy button, a customer paying from her phone and the green mark of a confirmed orderR$89.90expires in 14:32Copy codePix on your website's checkout

Payments

How to accept Pix payments on your website: a developer guide

Build a Pix checkout end to end: create the charge on your backend, show the QR and copy-and-paste code, confirm by webhook, handle expiry. With curl and Node.

7 min readRead the article
Your system sends the boleto request, the bank registers it, and the boleto comes out with a barcode and a Pix QR codePOST /v1/boletosBarcode + Pix QRRegistered

Payments

Boleto bancário explained, and how to issue boletos via API

What a boleto is, how Brazilians pay it, why it survives next to Pix, and what a business needs to issue registered boletos through its own bank's API.

6 min readRead the article
An NFC-e receipt comes out of the checkout printer with its lookup QR code, after SEFAZ authorized itNFC-e · model 65SEFAZ

Payments

Brazil e-invoicing: NFC-e vs NF-e explained

How Brazil's electronic invoices work: NFC-e (model 65) vs NF-e (model 55), SEFAZ authorization, what a company needs to issue them and the usual pitfalls.

7 min readRead the article