Magento 2 – How to get customer token using graphQL?

magento_base_url/graphql

GraphQl Body

mutation {
  generateCustomerToken(
    email: String!
    password: String!
  ) {
    token
  }
}

Example:

mutation {
  generateCustomerToken(
    email: "test@test.com"
    password: "testtest"
  ) {
    token
  }
}

Responce

{
  "data": {
    "generateCustomerToken": {
      "token": "lkh2c42342599f8d09sh23k5ne"
    }
  }
}