Invalid token when using API requests

Hello
I’m using the WoW API, and I’ve been using it for quite sometime now and everything was going smoothly, but today I authenticated with the servers and received an access_token as usual and was testing some WoW API calls and It kept giving me 401 Unauthorized, I checked the check_token end point and this is what I got

{"error":"invalid_token","error_description":"Invalid access token."}

Can someone please help me? I’ve got a deadline in 5 hours and i need to finis this as soon as possible, Thank you very much in advance.

Hi Sorata, I’d be happy to help you, can you provide more information ?

Do you receive this error using the official API Docs page ?
Are you using the same region for creating the token and consuming the endpoint ?

Hello! I’m using the passport-bnet strategy available on npm so im not sure but I’ve followed the instructions and for the past week or two it has been working completely fine, but today when i was testing it it gave me Invalid Token response

Can you try to fetch the same endpoint using the official API docs here: https://develop.battle.net/documentation/api-reference/world-of-warcraft-game-data-api to make sure your credentials are working properly ?

I tried doing so https://develop.battle.net/documentation/api-reference/world-of-warcraft-community-apiusing the first one (The profile API) with my access_token and before today it was working with the token that i used, but today it weirdly didn’t work at all, kept giving me 401 Unauthorized, but If i do it it using my CLIENT_ID and CLIENT_SECRET, it doesn’t produce any error, but it also returns no characters

The lifetime of a token is only 24 hours. You must generate a new one when they expire either by using the client_credentials flow (which won’t return characters since they are not bound to any specific account) or by re-authenticating using the authorization_code flow.