Hello
I’m creating an app with the remix framework.
When in run npm run dev everything works. I can make request to the GraphQL admin API. But in production, after running rpm run build and npm run start I have this error
[API] Invalid API key or access token (unrecognized login or wrong password)
If you report this error, please include this id: a31d8298-71a7-4889-9370-0323611be086
at NewHttpClient.throwFailedRequest (/srv/shopify-app-prp/node_modules/@shopify/shopify-api/lib/clients/http_client/http_client.ts:260:15)
at NewHttpClient.<anonymous> (/srv/shopify-app-prp/node_modules/@shopify/shopify-api/lib/clients/http_client/http_client.ts:294:12)
at Generator.next (<anonymous>)
at fulfilled (/srv/shopify-app-prp/node_modules/tslib/tslib.js:166:62)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
after this request
{
method: 'POST',
path: '/admin/api/2023-07/graphql.json',
type: 'application/graphql',
data: 'query {\n shop {\n id\n }\n }',
extraHeaders: {
'X-Shopify-Access-Token': 'shpua_*************'
}
}
The only difference when I test the app locally is that the access token starts with shpca instead of shpua in production.
I checked everything I could think about.
In the env config the SHOPIFY_API_KEY and SHOPIFY_API_SECRET are the same as Client ID and the Client secret in the App config “Overview” tab. The SHOPIFY_APP_URL is the same as all the urls sets in the “App Setup”->“URLs” section. The SCOPES variable of the env file contains the same values than the .toml I’m using in local.
I have no idea where it could come from.
Thanks for your heal
