GraphQL
Last updated
Last updated
What is GraphQL?
ZEMTU’s GraphQL APIs largely stick to the Relay specifications:
For client-server communication we suggest using JWTAuthentication
with the user’s username and password combination. For machine-to-machine communication TokenAuthentication
is the best fit.
GraphQL mutation tokenAuth
with user credentials to create a long-living token. The token is valid for 14 days. After that a renewed call to tokenAuth
is needed.
Now in order to access protected API you must include the Authorization HTTP header:
POST / HTTP/1.1
Host: domake.io
Authorization: JWT eyJ0eXAiOiJKV1QiLCJh...
Content-Type: application/json;
https://django-graphql-jwt.domake.io/en/stable/index.html
https://jwt.io