Answered

How to get the token via API

  • 22 February 2023
  • 2 replies
  • 114 views

I want to get token from backend but I cannot find any API to get it. I find this API but seem it’s used for integrating in the IU (https://developers.videoask.com/#9d1d98f0-ab59-438e-8b88-6a5e5651d7f9 => Get an access token). Anyone can suggest me a solution?

icon

Best answer by andrew_videoask 22 February 2023, 15:46

View original

2 replies

Userlevel 7
Badge +5

Hi @videoask.uat, that’s the correct endpoint 🙂 I know it might seem a little confusing since you retrieve the access_token via UI rather than through the backend. But you only need to do this the first time you authenticate your account.

Essentially, you call GET https://auth.videoask.com/authorize to get your temporary authorization code.

Then you call POST https://api.videoask.com/oauth/token, using the temporary authorization code, to get your access_token (and optionally a refresh_token).

When your access_token expires, you can use the refresh_token (which doesn’t expire) to generate a new access_token.

I’ll share two Python code snippets that show this process in practice:

I hope this helps!

Userlevel 7
Badge +5

Hey @videoask.uat let us know if Andrew’s message helped or if you have any other questions 😊

Reply