T
T
TikTak12362018-10-25 11:37:27
Google
TikTak1236, 2018-10-25 11:37:27

How to refresh the token when authorizing through Google?

Hello!!!
I am developing a project for Android, where there is authorization through Google.
After authorization through Google, I am given a token.
How do I track the validity of the token and renew it?
Please give advice, code examples, tutorials.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
kidar2, 2018-10-26
@kidar2

After authorization through Google, you are given a refresh_token and an access_token.
To get a new access_token, you need to make a POST request to https://www.googleapis.com/oauth2/v4/token
with the following fields
client_id = ;
client_secret=;
grant_type="refresh_token";
refresh_token=;

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question