How to refresh Trans.eu API access_token using refresh_token.
Refresh token request
Example
- Method: POST
- URL: /ext/auth-api/accounts/token
- Host: api.platform.trans.eu
- Content-Type: application/x‑www-form-urlencoded
Request parameters
Description of query parameters required during token refresh.
Name | Required | Type | Description |
grant_type | yes | string | Must be set to refresh_token. |
refresh_token | yes | string | The refresh token issued during authorization. |
client_id | yes | string | Application client_id obtained during registration. Only required if Authorization header is not sent. |
client_secret | yes | string | Application client_secret obtained during registration. Only required if Authorization header is not sent. |
Header parameters
Name | Required | Value |
Content-Type | yes | application/x‑www-form-urlencoded |
Api-key | yes | Api-key obtained during registrationAccess token response |
Example response
HTTP/1.1 200 OK
Content-Type: application/json
{
"access_token": "59d9aa9b15cd59a61fc52014792efb6caa82373b",
"expires_in": 21599,
"token_type": "Bearer",
"refresh_token": "d52d1d998d6533a3be8e7f26f904be513287938b"
}
Response parameters
Name | Description |
access_token | Access token to use by application for authorization. |
expires_in | Time in seconds until token expires. |
token_type | Type Bearer is returned as defined in rfc6749. |
refresh_token | Single serving token that can be used to extend lifetime of access token. |