Get Api Token

Exchange your deepmirror account credentials for a temporary API token.

Use the returned token as the X-API-Key header on subsequent requests. The lifetime defaults to 12 hours and can be set to at most 30 days.

curl https://api.app.deepmirror.ai/api/v3/public/authenticate       --request POST       --header 'Content-Type: application/x-www-form-urlencoded'       --data-urlencode 'username=you@example.com'       --data-urlencode 'password=your-password'
Query Parameters
  • token_lifetime_minutes
    Type: integer · Token Lifetime Minutes
    min:  
    1
    max:  
    43200

    Token lifetime in minutes (12 hours by default).

Body
required
application/json
Responses
  • application/json
  • 400

    Incorrect email or password

  • application/json
Request Example for post/api/v3/public/authenticate
curl /api/v3/public/authenticate \
  --request POST \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data-urlencode 'username=' \
  --data-urlencode 'password='
{
  "api_token": "string"
}