Billing » API » Authentication

This endpoint is responsible for handling authetication.

Get the token

Request headers

Content-Type application/json
POST

/graphql

Example request with curl
curl "https://api.canyan.io/graphql" \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{ "query": "{ Auth(email: \"alex@canyan.io\", password: \"test\") { token } }" }'

Response body

token JWT JSON Web Token
Example response body
HTTP/1.1 200 OK
Content-Type: application/json

{
    "data": {
      "Auth": {
          "token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJiaWxsaW5nLmNhbnlhbi5pbyIsImV4cCI6MTU2NTM1NzYwOSwiaWF0IjoxNTY1MzU0MDA5LCJuYmYiOjE1NjUzNTQwMDksImp0aSI6MTQ4OTkyNzA5NTM5Njg4MjQ3ODYsInVzZXIiOnsiaWQiOiIzMGE3Y2I2Mi0xNzZjLTRhNWMtODVkMi1iMTU0YjI4MTU3MmMifX0.CwROALogWCVIEiGL11jHeFb3_Xyar_1faUj2Ha9wMYU"
      }
    }
}