Skip to main content

Refresh access token

POST /auth/refresh-token
devhttps://api.sandbox.ovok.com

By making a POST request to this endpoint you can refresh the access token, ensuring uninterrupted access to protected resources.

Example cURL request

curl -X POST \
--url 'https://api.dev.ovok.com/auth/refresh-token' \
-H 'Content-Type: application/json' \
-d '{
"refresh_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE3MzEzMzY0NDIsImV4cCI6MTczMTM0MDA0Mn0.MQbovtK2tKu8Zj6_7vaqSVXWunIG8-iuwa6JEXCqXAQ"
}'

Request body

Content-Type: application/json

  • refresh_token: string (required) — Refresh token.

Responses

CodeDescription
200Access token, refresh token and expiration time.
400The request could not be operated by the server.
401The resource owner or authorization server denied the request.
404The requested resource could not be found.
422The request could not be validated by the server.
500The server encountered an unexpected condition. Please try again later.

200ResponseTokenDto (application/json)

  • access_token: string (required) — Bearer access token. Expires in 1 hour.
  • refresh_token: string — Refresh token.
  • expires_in: integer (required) — Token expiration.

Example

{
"access_token": "example.jwt.eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE3NzkzNTA5NzEsImV4cCI6MTc3OTM1NDU3MX0.PO6ZkOtyOEugGyNuZUyg_YxUt3ozpJ_QOdJuriC14uY",
"refresh_token": "example.jwt.eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpYXQiOjE3NzkzNTA5NzEsImV4cCI6MTc3OTM1NDU3MX0.PO6ZkOtyOEugGyNuZUyg_YxUt3ozpJ_QOdJuriC14uY",
"expires_in": 3600
}