Unable to access Storefront API with Apollo Client due to CORS

New Member
1 0 1

Hello,

I'm getting a CORS error when trying to make a basic GraphQL query to the Storefront API.

Trying to initialize my client like so:

const client = new ApolloClient({
  uri: "my store",
  headers: {
    "X-Shopify-Storefront-Access-Token": "my access token",
  },
  cache: new InMemoryCache(),
});

 

How do I get around this? I'm using a private app from my normal shopify account NOT from a partner account.

Thanks

Conor 

1 Like
Highlighted
New Member
2 0 0

Exactly my problem as well. Can someone answer this?

0 Likes