Getting an Access Token
Rikke Søndergaard avatar
Written by Rikke Søndergaard
Updated over a week ago

Before You Begin

Make sure that you have already set up a OAuth 2.0 authorisation module in your app or integration. You'll need these credentials to get an access token to authorise all REST API calls to APSIS One API.

We suggest that you create a sandbox Section in your APSIS One account to test your implementations during the development process.

Since the APSIS One API is in an early development stage, we might make changes that will require you to replace your API key. In which case, we'll give you a 30 days notice before your current API key stops working.

Per region host names

APSIS One API is provided under different hostnames depending on your region. For EU use https://api.apsis.one/ and for APAC call https://api-apac.apsis.one/.


How to Get an Access Token

Did you create an API Key yet?

The first step to add an app in APSIS One is to get an API Key. You'll need this before you get an access token.

The Client ID and Secret will be used to request authorisation to the REST API service. To request an access token, you must pass the OAuth 2.0 credentials:

curl --request POST \
  --url https://api.apsis.one/oauth/token \
  --header 'accept: application/json' \
  --header 'content-type: application/json' \
  --data '{ 
  "grant_type": "client_credentials",
  "client_id": "752cdd05-75e0-4f8a-bd08-62e3df753ff3",
  "client_secret": "78313-25456etc-q12e-1325-62w62a7q"
  }'

A successful request will return the JSON object with the following:

{
  "access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSO...",
  "expires_in": 86400,
  "token_type": "Bearer"
}

Once you have gained an access token, you can begin making API calls to APSIS One APIs.


What's Next?

Did this answer your question?