Lien à copier

BETA

How do I get an API access authorization token?

The Sage Active Public API V0 is secured by Oauth 2.0 authentication.

The example of obtaining a token is explained:

Http 400 error - Invalid scopes when get new access token

If the error invalid_scopes occurs when requesting a new access token:

img

Check this point :

Check that the Permissions mentioned in your application are enough for the defined scopes :

Example

  • On the application side, you have only defined Read Sage Active Data
  • but on the scopes side, you ask more permissions like RDSA WDSA

Like below, scopes must be equal to or less than the permissions img

img

Http 400 error - Invalid request when get new access token

If the error invalid_request occurs when requesting a new access token:

img

Check the following points :
  1. Check that the CallBack URL mentioned in the Postman environment variable CallBackUrl is the same as the one of your application :
    img

  2. Check that the value filled in the Postman environment variable ClientId is the correct Client ID in your application. img
  3. Check that the scopes are not empty but filled in with RDSA and / or WDSA depending of the permissions defined in your application. img

Authentication failed

If this error occurs when requesting a new access token:

img

Check the following points :
  1. Check that the AuthUrl is the correct Auth URL.
  2. Check that the ClientSecret is the correct Client Secret in your application. img