Authentication
The Pix Indiretos’ APIs are based on the OAuth 2 protocol, and they specifically use the client_credentials flow.
Please go to First Steps and enter the Pix Indiretos APIs you wish to use.
Generating access key to APIs
To make any request in the Pix Indiretos’ APIs, you will need an access_token. You can get it through a request on the token generation endpoint Gerando Access Tokens.
The validity of the access token is obtained from the expires_in object, in a few seconds.
Environment | Validity (seconds) |
---|---|
Production | 300 |
Approval | 420 |
The partner will need to manage the access token to ensure that all requests within the Pix Indiretos’ APIs will be made using a valid token.
Generate tokens
If you want to generate a token, please follow these instructions:
- With the API Key, API Secret and Scope make an HTTP request - POST type - to the endpoint Gerando Access Tokens;
- In Body, use the values retrieved from the application to fill in the parameters below:
client_id
with the client_id value;client_secret
with the client_secret value;scope
whose value is equal to the scope from credentials;grant_type
whose value is equal to the client_credentials value;
- Make the request and get the access_token.
Nota:
The access_token obtained when generating the token must be used in all requests to the Pix Indiretos’ APIs.
Updated 8 days ago