API and graphql and following 2 blog posts
Hi all, beginner here.
I am working on these 2 blog posts to get the graphql from the cloudflare console:
https://developers.cloudflare.com/analytics/graphql-api/tutorials/capture-graphql-queries-from-dashboard/
and using curl as the client
https://developers.cloudflare.com/analytics/graphql-api/getting-started/execute-graphql-query/
I am just trying to get the "Overview" section of a website. I used Chrome and followed the fist blog post to get the query.
Here is the graphql: I removed the type annotations “: String”, replaced
the zone and token, and also put in realistic dates.
Here is the full command (sorry it is long, but it is the main view so seemed like a good place to start!)
thx for any pointers/help!!!
Had to upload the curl as a file...Hope I do this right 🙂
1 Reply
What's the question here? Why your's is wrong? You're missing opening bracket/quotes/etc like shown in the payload structure in the first one you showed.
Personally I like using GraphIQL, and that query can be made to work in it like:
depending on what your end game is, lots of programming languages have their own graphql libs and such to use