cURL
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>" }
This endpoint can be used for login. The response contains an access token and a refresh token which need to be used in the Authorization header in the future API calls.
The request body includes user email and password as compulsory fields.
The email of the user is required to login.
The password of the user is a compulsory requirement for login.
Successful Response
On successful login an access token is returned, which needs to be saved and used as auth token in the future api calls.
This endpoint also returns a refresh token for the user.