POST
/
users
/
login
Login
curl --request POST \
  --url https://api.gan.ai/users/login \
  --header 'Content-Type: application/json' \
  --data '{
  "email": "<string>",
  "password": "<string>"
}'
{
  "access_token": "<string>",
  "refresh_token": "<string>"
}

Body

application/json

The request body includes user email and password as compulsory fields.

email
string
required

The email of the user is required to login.

password
string
required

The password of the user is a compulsory requirement for login.

Response

Successful Response

access_token
string
required

On successful login an access token is returned, which needs to be saved and used as auth token in the future api calls.

refresh_token
string
required

This endpoint also returns a refresh token for the user.