Customers GraphQL Problem

Solved
New Member
4 0 0

Hi,

I am having a problem whenever I am querying the customer's data. I am having the errors below on screenshots.

 

I am following this docs https://help.shopify.com/en/api/getting-started/shopify-and-graphql/queries

But if I try another query for example this. Shop Infos. It works just fine.

I hope anyone could help me. Cheers!

query {
  shop {
    id
    name
    email
  }
}


Screen Shot 2019-07-12 at 4.40.10 AM.pngScreen Shot 2019-07-12 at 4.39.57 AM.png

0 Likes

Success.

Shopify Staff
Shopify Staff
1369 56 202

It looks like you're on the free version of NGROK, and that your app has received too many inbound connections within one minute (the limit looks to be 20). You can either wait a little bit and refresh, pay for an NGROK license, or check out alternatives (I'm told this one is pretty decent, and it's free/open source).

1 Like
New Member
4 0 0
Thank you for reply Alex.

One last question, I wonder if its possible to access shopify admins data
outside the shopify url/store? my ngrok works on embededsdk iframe but if I
open it on a normal browser it doesn't fetch any data.

Cheers!
0 Likes
New Member
3 0 0

wrong account.

0 Likes
Shopify Staff
Shopify Staff
1369 56 202

Which calls are you trying to make that are not working? The admin API should work from any external back end without needing to be framed in the admin (I wouldn't recommend making admin API requests from the client anyway for security reasons), but that's assuming you're in fact using the admin API.

 

Cheers.

0 Likes
Highlighted
New Member
4 0 0
Im using graphql to fetch the data. I tried fetching customers and orders
and it didnt work. I created a sample app using the new shopify app cli
that I saw in Unite, it only works inside iframe embededsdk but if i try to
open the ngrok url outside the shopify it doesn't work. cheers!
0 Likes
Shopify Staff
Shopify Staff
1369 56 202

If you're referring to generating a rails app, that uses the shopify_app gem which is documented here. That project has information on how to turn off automatic embedding, assuming that's the root of your problem.

 

When you say that GraphQL calls are not working, can you give me a code example of what you're trying (a whole file is fine), and the response you're getting with as time frame and shop this is occurring on? The more recent the better.

 

Cheers.

0 Likes
New Member
3 0 0
I did it using the node.js option not the rails app. My only concern is
when I open using the ngrok url on a browswer the node.js app from the
generates shopify app cli that I saw on Unite dont fetch any data. but if
Im opening it from the iframe inside shopify admin it fetches the data.
0 Likes
New Member
3 0 0

Hi Alex, this are the pre generated code from the shopify cli. I didn't add anything and somehow I have this error if I'm not inside shopify iframe.

Screen Shot 2019-07-19 at 10.49.39 PM.pngThe error Im getting.Screen Shot 2019-07-19 at 10.49.05 PM.pngThe default.Screen Shot 2019-07-19 at 10.48.55 PM.pngI didnt change anything here.

0 Likes