Quick Start

Your API requests are authenticated using a Decide login token. You will attach this as an authorization header in each request. Any request that doesn’t include a valid login token will return an error.

Generate a login token#

You can generate a login token via the /login endpoint. Simply pass in your Decide username and password as parameters. Since all communication to Decide Dashboard API uses HTTPS, your credentials are safe. Generating a new token does not invalidate older tokens. If a user’s password or username is changed in your Decide user settings, all tokens generated prior to the change are revoked and a new token must be generated.

POST https://dashboard.decide.co/v1/login

Retrieve Decide login token.

Request body

NameTypeDescription
username* string Your Decide dashboard username or email address.
password* string Your Decide dashboard password.

* Required.

Responses

  • 200Success — the token is returned in result.
  • 400Invalid request args, or the username and password did not match.
  • 429Maximum request limit reached — see Rate Limits.
  • 500Unspecified internal error.

Example request#

Take a look at how you might call this method:

curl https://dashboard.decide.co/v1/login \
    -H 'content-type: application/json' \
    -d '{"username":"kyle","password":"123"}'

Here is an example login token:

"1234567891234567|1234567891234:1234:|all|uYxUcpO2XABC4aABCOPQS123/ji+CbK6AvABC/EabLOa0kbTclJ/Om1QaD/5abcNmBnrV95lRsdJhLhV91oq+Z=="

Important

Login tokens are only valid for 30 days. If you are running into an invalid token error it may be because your token has expired.

Make an authenticated request#

Pass the token you just generated in the Authorization header of every subsequent request, prefixed with Bearer. Requests that omit the header, or send it without the Bearer prefix, are rejected with a 401.

curl https://dashboard.decide.co/v1/ad_units \
    -H 'content-type: application/json' \
    -H 'authorization: Bearer <your_login_token>' \
    -d '{"start_time":"2025-05-15","end_time":"2025-05-22"}'

Every endpoint reads its arguments from a JSON request body, so every endpoint — including /login — is a POST.

Next steps#

Once you have successfully generated a Decide login token you are ready to make requests. Please continue to our API Reference page for more information.