Skip to content

Instantly share code, notes, and snippets.

@ecthiender
Created April 5, 2019 11:44
Show Gist options
  • Save ecthiender/0436b2124c5647d5f8f0498388a919b4 to your computer and use it in GitHub Desktop.
Save ecthiender/0436b2124c5647d5f8f0498388a919b4 to your computer and use it in GitHub Desktop.
graphql introspection as curl
curl 'http://localhost:8080/v1alpha1/graphql' -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:66.0) Gecko/20100101 Firefox/66.0' -H 'Accept: */*' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: http://localhost:8080/console/api-explorer' -H 'content-type: application/json' -H 'x-hasura-role: admin' -H 'Origin: http://localhost:8080' -H 'DNT: 1' -H 'Connection: keep-alive' --data '{"query":"\n query IntrospectionQuery {\n __schema {\n queryType { name }\n mutationType { name }\n subscriptionType { name }\n types {\n ...FullType\n }\n directives {\n name\n description\n locations\n args {\n ...InputValue\n }\n }\n }\n }\n\n fragment FullType on __Type {\n kind\n name\n description\n fields(includeDeprecated: true) {\n name\n description\n args {\n ...InputValue\n }\n type {\n ...TypeRef\n }\n isDeprecated\n deprecationReason\n }\n inputFields {\n ...InputValue\n }\n interfaces {\n ...TypeRef\n }\n enumValues(includeDeprecated: true) {\n name\n description\n isDeprecated\n deprecationReason\n }\n possibleTypes {\n ...TypeRef\n }\n }\n\n fragment InputValue on __InputValue {\n name\n description\n type { ...TypeRef }\n defaultValue\n }\n\n fragment TypeRef on __Type {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n ofType {\n kind\n name\n }\n }\n }\n }\n }\n }\n }\n }\n "}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment