Invalid API Token

I am using an Admin API to externally manage orders but the the response from API is that i am giving Invalid API Token.

Hi Alihusayn,

This issue usually occurs due to incorrect or expired API keys. Here are a few steps to troubleshoot this issue:

1. Check API Key: Make sure that you’re using the correct API key. It should be the same as the one you received when you created your application in your Shopify admin panel.

2. Check API Secret: Along with the API key, you should also have an API secret. When making requests, you should be using the correct combination of both.

3. Check Access Token: If you’re using a token for authentication, ensure it’s still valid and not expired. Tokens can expire and when they do, you’ll need to generate a new one.

4. Check Permissions: Make sure your app has the necessary permissions to access the Order APIs. You can manage these permissions in the Shopify admin panel under the “Apps” section.

Hope this helps!

1 Like

API name please i dont understand

Which API endpoint are you getting this error for?

I checked the code and I had a hardcoded API token from a different app in a function in debug session. Later encountered this and changed it to a global variable.

Thanks for help tho.