Authentication
Request access and refresh token with your credentials
API Endpoint
/auth/email/sign-in
Methods
POST
Data Params
| Field | Type | Description | Required |
|---|---|---|---|
| string | Email address of the sales partner user. | Yes | |
| password | string | Password of the sales partner user. | Yes |
Success Response
Code: 200
| Field | Type | Description |
|---|---|---|
| accessToken | string | Authentication token that has to be included in all further requests. |
| refreshToken | string | Used to retrieve new tokens when they expire (more informations below). |
Sample Call
Body
{
"email": "youremail@gmail.com",
"password": "supersecret"
}
Response
{
"accessToken": "cewbdqijcw@&#hbub4bi8hbb",
"refreshToken": "kjfesnkhd83oqijdcnkdow"
}
Refresh expired tokens
API Endpoint
/auth/refresh
Methods
POST
Data Params
| Field | Type | Description | Required |
|---|---|---|---|
| token | string | Refresh token obtained during authentication. | Yes |
Success Response
Code: 200
| Field | Type | Description |
|---|---|---|
| accessToken | string | Authentication token that has to be included in all further requests. |
| refreshToken | string | Used to retrieve new tokens when they expire. |
Sample Call
Body
{
"token": "kjfesnkhd83oqijdcnkdow"
}
Response
{
"accessToken": "#hbub4bi8hbbcewbdb4bi8hbb",
"refreshToken": "oqijdcnkdowkjfesnkhd83"
}
