2 - Authorization
Token creation endpoint Is in OAuth2.0 standard with "grant_type" equal "client_credentials" and the AuthURL is https://auth.easycredito.com.br/client/auth, just declare the token in the bearer token of the following calls.
PS: Remembering that in the next calls the url must be changed, since the AuthURL is different from the others.
Using this endpoint is easy, just declare your clientId and clientSecret credentials provided by our team on our endpoint and after creating the token, use it on the other endpoints on our platform to perform the intended functions.
CURL Request Example
curl --request POST \
--url https://auth.easycredito.com.br/client/auth \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"client_id": "client_id",
"client_secret": "client_secret",
"scopes": [
"api-external"
]
}
'
Response Example
{
"access_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJjbGllbnRfaWQiOjkyLCJ0YWdfbmFtZSI6ImNkZTlhZTRiLTBjOTgtNDY4NC05ZTM2LTViMGNlNDA0NjFiMCIsInNjb3BlIjoiYXBpLWV4dGVybmFsIiwiaWF0IjoxNjY2MTIwOTYzLCJleHAiOjE2NjYyMDczNjN9.dKF2pB7knyHl6lm0O08SQhD2YcoAwoJb88YiQHnZFcYat5DyCGoQKXF2hO6MyZKSrOO0ewdKrVr3o1hV63_sseLD-078UxNboAee1PK7QBZwvlB4BfegPIyyvnZQKbvMSFbmgRoJpWmtuAGp01Lx7WPwL-lwSZax8zaRY-O4D6I954K5-YpZ99CkuY5N3Br-fH42wCbJRvP5TzARpjIkPzR5i0iLPuzuzZuyKDpQlljLB9hi85f07BaTdMNkscYgmDsx8w0f88EGkMW62Voj0KnLC3PDDImbfei5NVRXs6TB1acAfu6VewM0dwZTuucVXtQ3RXs-yQHOTcI4IS23F_kiTnr1rL8ELysAHu7j39vj2zdxmKU-uNHSPCbfFLajdYnHAVsanN4qf9fHQleRhyVViPeyp-_ydEOng-5ut9Oo1QGR9SNWeGd7hMdqU8JxlQ9niPVT-v0YVN3GYBlaK9ybEBzA1LXy45T_5IcqdHS_-S4qHPJHJf08w7UfAnNUD8sGpzGD7vJiWNqnXEEufjZOOexLO5D9YrzH6eQb1yl_0zyu6607Rm2-oLgsek5SbsqI8f2D028ciiINIt5yQYQmsULxep-HVBXzyMPzsBVgdnuveBE5pvk0LQStrmpAXkuiGm2tzwfNk5x9P6j2DvUoJWfA6jG-Si4PKzHgR66",
"expire_at": "2022-10-19T16:22:43.329Z"
}
Updated 2 months ago