curlやHTTPieでGraphQLを送る
curlでも使える
code:bash
-H 'Content-Type: application/json' \
--data '{"query":"{ allLifts { name }}"}'
見て分かる通り、こんなqueryをおくってる
code:graphql
{
allLifts {
name
}
}
mutation
code:bash
-H 'Content-Type: application/json' \
--data '{"query":"mutation {setLiftStatus(id: \"panorama\" status: OPEN) {name status}}"}'
code:bash