Authentication
Endpoint responsible for authentication and generation of access tokens.
Auth
Authentication is performed using the access keys (Client ID and Secret generated via the WEB console), this information must be made available in the Body of the request.
Body
clientIdstringRequiredExample:
Skedway API Client ID
9f659df8427effe1a8c99c6ee0f636a4.skedway.com
clientSecretstringRequiredExample:
Skedway API Secret ID
97ca9fd9917c9e6bae10c31e70a2729f50e41a4114772bd2344f420160ce20ee
Responses
201
Success, acess token generated
application/json
401
Unauthorized
403
Invalid credential
404
Not Found
post
POST /auth HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 141
{
"clientId": "9f659df8427effe1a8c99c6ee0f636a4.skedway.com",
"clientSecret": "97ca9fd9917c9e6bae10c31e70a2729f50e41a4114772bd2344f420160ce20ee"
}
{
"accessToken": "text",
"accessTokenExpiration": 1,
"refreshToken": "text",
"refreshTokenExpiration": 1
}
Auth expiration
Access tokens have their expiration time, if the access token is expired, it can be renewed via /auth/refresh-token.
Exemple
{
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjb21wYW55SWQiOjEsImNsaWVudElkIjoiN2Y2NTlkZjg0MjdlZmZlMWE4Yzk5YzZlZTBmNjM2YTQuc2tlZHdheS5jb20iLCJ0eXBlIjoxLCJpYXQiOjE2Njk5MjI3NzYsImV4cCI6MTY2OTkyNjM3Nn0.g9Lb32ZKGLaDVh2dvGTS4JFjaX56xh2kvC68Kzx2fg8",
"accessTokenExpiration": 1669926376136,
"refreshToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjb21wYW55SWQiOjEsImNsaWVudElkIjoiN2Y2NTlkZjg0MjdlZmZlMWE4Yzk5YzZlZTBmNjM2YTQuc2tlZHdheS5jb20iLCJ0eXBlIjoxLCJpYXQiOjE2Njk5MjI3NzYsImV4cCI6MTY3MDUyNzU3Nn0.4lm_fDOJOxzNJbhKnnCWSqcXXp7CcGInNP2ImiQ1RuU",
"refreshTokenExpiration": 1670527576136
}
Refresh token
Rquires authentication: Bearer Token (Authorization)
The authentication of this route is performed through the refreshToken generated in the /auth authentication endpoint.
Authorizations
Responses
200
Success, access token refreshed
application/json
401
Unauthorized
404
Not Found
get
GET /auth/refresh-token HTTP/1.1
Host:
Authorization: Bearer Bearer
Accept: */*
{
"accessToken": "text",
"accessTokenExpiration": 1,
"refreshToken": "text",
"refreshTokenExpiration": 1
}
Exemple
{
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjb21wYW55SWQiOjEsImNsaWVudElkIjoiN2Y2NTlkZjg0MjdlZmZlMWE4Yzk5YzZlZTBmNjM2YTQuc2tlZHdheS5jb20iLCJ0eXBlIjoxLCJpYXQiOjE2Njk5MjI3NzYsImV4cCI6MTY2OTkyNjM3Nn0.g9Lb32ZKGLaDVh2dvGTS4JFjaX56xh2kvC68Kzx2fg8",
"accessTokenExpiration": 1669926376136,
"refreshToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjb21wYW55SWQiOjEsImNsaWVudElkIjoiN2Y2NTlkZjg0MjdlZmZlMWE4Yzk5YzZlZTBmNjM2YTQuc2tlZHdheS5jb20iLCJ0eXBlIjoxLCJpYXQiOjE2Njk5MjI3NzYsImV4cCI6MTY3MDUyNzU3Nn0.4lm_fDOJOxzNJbhKnnCWSqcXXp7CcGInNP2ImiQ1RuU",
"refreshTokenExpiration": 1670527576136
}
Last updated