Authentication
Rollee User API is protected with JWT authentication. When making a request to the API, ensure that your API key is included. The initial token is provided by Rollee with a specific validity time period. It's important to treat your API keys confidentially, as they grant permission to initiate requests and access completed results on your behalf. If you suspect a key has been compromised, promptly revoke it and ask for a new one.
Please contact us to get your JWT.
You can create a new valid token when the previous one is closed to expire using the API.
Examples using curl:
- Refresh Token:
curl -X GET -H "Authorization: Bearer <YOUR_TOKEN>" https://api.getrollee.com/api/v0.5/token/refresh
curl -X GET -H "Authorization: Bearer <YOUR_TOKEN>" https://api.sand.getrollee.com/api/v0.3/token/refresh
- Response Format:
{
"token": "YOUR_NEW_TOKEN"
}
In case of wrong usage of the token, API's call will return a 401 Unauthorized
response. If you got a 200 OK
you can start making requests as the following example:
- Get list of users
curl -X GET -H "Authorization: Bearer <YOUR_TOKEN>" https://api.getrollee.com/api/v0.5/users
curl -X GET -H "Authorization: Bearer <YOUR_TOKEN>" https://api.sand.getrollee.com/api/v0.4/users
Updated 7 months ago