pcyan commented on issue #6266: URL: https://github.com/apache/apisix/issues/6266#issuecomment-1033424701
> I could not find the relevant description in the `curl` document. Could you please provide. > > Suggest like this: > > ``` > ### apisix graphql > curl 'https://localhost:9080/v2/c4d7a195/graphql' \ > -H 'authority: api.mocki.io' \ > -H 'accept: */*' \ > -H 'content-type: application/json' \ > -H 'origin: https://api.mocki.io' \ > -X PUT > --data-raw '{"operationName":"getUser","variables":{},"query":"query getUser {\n user(id: \"4dc70521-22bb-4396-b37a-4a927c66d43b\") {\n id\n email\n name\n }\n}\n"}' \ > --compressed > ``` ```bash $ curl --help Usage: curl [options...] <url> -d, --data <data> **HTTP POST data** ... ``` use `-v` to print verbose log ```bash curl -v 'https://api.mocki.io/v2/c4d7a195/graphql' \ -H 'authority: api.mocki.io' \ -H 'accept: */*' \ -H 'content-type: application/json' \ -H 'origin: https://api.mocki.io' \ --data-raw '{"operationName":"getUser","variables":{},"query":"query getUser {\n user(id: \"4dc70521-22bb-4396-b37a-4a927c66d43b\") {\n id\n email\n name\n }\n}\n"}' \ --compressed ``` it will print something like this `> POST /v2/c4d7a195/graphql HTTP/2`, thought i'm not use `-X POST` sorry, i'm try to discuss about how APISIX deal with graphql request. it seems that the mock GraphQL data of APISIX is not a standard GraphQL request. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org