timfee / meet

A lightweight Calendly-esque appointment booker, using Next 13
MIT License
51 stars 17 forks source link

Can't get access token #25

Open chriszhang08 opened 6 months ago

chriszhang08 commented 6 months ago

Has anyone gotten an error where they were unable to use the refresh token to retrieve a new access token? I'm getting this error

Error: Couldn't get access token: { "error": "unauthorized_client", "error_description": "Unauthorized" } even though I got the refresh token as instructed in the environment setup.

timfee commented 6 months ago

Invalid client usually means that the client ID and client secret don't match, or there is a typo in one of them.

When you retrieve the refresh token, could you try putting the access token that comes along with it into the tokeinfo endpoint and making sure the values for client ID there match the ones you've configured with: https://www.googleapis.com/oauth2/v1/tokeninfo?access_token=

It might be worth dumping out the request to make sure there isn't a mistake in that (e.g. too short a content-length header or similar).

IndySof commented 3 weeks ago

Hello, I feel like if nobody use the app, the token will expired anyway, can you confirm this ?

trillium commented 3 weeks ago

No, you can set up the token so it doesn't expire