Invalid Api Key error

Hi,

A user tried to install our app and we see these error in our logs:

unable to get discountNodes resource
“errors”: “[API] Invalid API key or access token (unrecognized login or wrong password)”

unable to list resource
GGT_SHOPIFY_AUTHENTICATION_ERROR: Unable to list recurring application charges for shop

Would you know what these mean? Does this mean user doesnt have access to approve payments?

The user is on “Basic Plan” but that should not prevent them from accessing Discount nodes right?

Two things to check:

  1. Is your Shopify API Private Key for your app in production correct? If it’s using your development app’s private key, then this would fail authentication.
  2. Are you certain this merchant’s API key is correct? One potential issue is if the merchant uninstalled and then later reintalled, but your app kept their old token and didn’t overwrite it with their new one.

If all API requests are failing, I suspect #1 is your issue. If it’s only this merchant and all of their Shopify Admin API requests are failing then perhaps you have the wrong access token stored on their account, or perhaps your app is looking up the wrong token.

Actually its a live app and there are other merchants who are able to use the app without any issues. only this merchant faced an issue and they uninstalled the app. So I am not sure if their API key was correct was not.

Figured out the issue. I am using gadget.dev for the app and user uninstalled the app in the middle of a store sync.

Glad you were able to figure it out @Gaurav_Agarwal - I’m not familiar with Gadget. What’s a store sync?

In Gadget, they maintain a database against the webhooks you subscribe to and sync it regularly as per a schedule you set. In the above context, the Store data was getting synced for the 1st time for registered webhooks like product etc