Can't query anything with GraphQL

Topic summary

A developer is unable to query Shopify data using GraphQL despite successful REST API queries and verified syntax in GraphiQL on a demo store. The issue persists with a 404 Not Found error when sending POST requests to /admin/api/2025-04/graphql.json.

Key Details:

  • REST API queries work correctly for Customers and MetaFields
  • GraphQL queries fail with 404, even though syntax is validated
  • Using proper authentication (X-Shopify-Access-Token header)
  • Motivation: GraphQL is more efficient and needed for MetaField updates

Troubleshooting Attempted:

  • Shopify Support unable to resolve
  • Shared scopes between REST and GraphQL make the discrepancy puzzling

Current Discussion:
Another user requested screenshots and suggested verifying API scopes are properly configured for the POST request. An image showing scope configuration was shared as a potential solution area to investigate.

Summarized with AI on October 28. AI used: claude-sonnet-4-5-20250929.

I’m trying to query and update data in our Shopify store via GraphQL. I can query the required objects such as Customers with the REST API, but I can’t do this with GraphQL. I’ve executed my basic query in GraphiQL on a demo store successfully, so I know the syntax I’m sending through is correct, but I always get a 404 Not Found response.

I’m led to believe that there could be a problem with the store itself, but Shopify Support can’t seem to help me in regard. I only want to use GraphQL because it is more efficient to achieve what I’m after and because I don’t seem to be able to update MetaFields via REST, although I can query them in REST (not in GraphQL). Since REST and GraphQL share scopes for Developed Apps, I’m lost as to why I can’t query any data using GraphQL.

If anyone has any ideas, I’d appreciate it.

Hi @russellbird

can you screenshot your Graphql query by any tools like Postman or Insomnia?

Hi,

I’m sending:

{
“query”: “query getCustomer($id: ID!) { customer(id: $id) { id email firstName lastName createdAt updatedAt } }”,
“variables”: {
“id”: “gid://shopify/Customer/XXXXXXXXXXXXXXX”
}
}

I’ve removed the Customer Record ID from the above.

I’m sending a POST request to /admin/api/2025-04/graphql.json with the X-Shopify-Access-Token header set to my key. My understanding is that this should behave the same as a GET request to admin/api/2024-10/customers/XXXXXXXXXXXX.json, which works. On the POST request to graphql I get 404 returned.

for Post request, did you accept the scope for your API?