Atria API
Purpose
The Atria API is a new Rest-based integration point that over time will replace the functionality of the old API, (known as the CortexAPI). If you have developed against The CortexAPI, don’t worry, it’s still working and supported.

Requirements:
- Atria 12.11 or higher
- A valid Atria external API Token
Benefits
The new API will be easier for developers to understand and consume and will be built using standard conventions.
Our initial release is focused on Billing, the API can be used to extract your billing information directly into spreadsheets, PowerBI, or third-party systems.
Using the API
Authentication
Authentication to the API uses a JWT token, the application communicating with Atria, presents the token, this is then validated against a user in Atria, if valid access is permitted and the API call is executed.
Tokens are created within Atria and are attached to a user account.
If the user account in Atria is disabled, then API access via the token attached to that user will also be disabled. Note that the user account must be disabled via Atria in order to disable API access, disabling the associated AD user account will not immediately block access.
At the time of writing, AD Account expiry will not disable API access.
Authorization
In order for a user to have an API token, they must be granted the “Service Provider Developer” permission. Once they have this permission, the change password page allows the tokens to be created and deleted.
In order to grant "Service Provider Developer" permission to a user follow the below steps:
- Click on Users -> select a user -> Edit User -> Account Settings -> Advanced Options -> Enable "Service Provider Developer" check-box
Creating a Token
Login or impersonate a user that has access, click on the “Password” link on the left-hand menu. Half way down the page you should see a “Generate API Access Token” – click on the “Generate” link to create a new token.

Once you leave this page, you will not be able to view the token again, it is encrypted and stored in the database, if you forget the token you will need to create another one and reconfigure your applications.
Store the token securely and protect it in the same way as credentials.
Using the Token
The token should be provided as an Authorization header for every call made to the API. If the token is not present the API call will fail.
Header name
| Value
|
Authorization
| |
Billing API Calls
Billing Parameters
/api/Billing/parameters
This GET command will return
- All of the billing periods that are available within your Atria system
- All of the Customers contained within the system and their customerIDs
Curl Syntax
- curl -X GET "https://{API HOSTNAME}/api/Billing/parameters" -H "accept: text/plain" -H "Authorization: bearer a8cab2d1ae00df4a7edd514af7828d7df672054c89feb753305f17c403127769"
- {
- "data": {
- "endDates": [
- {
- "label": "2019-10-31"
- },
- {
- "label": "2019-11-30"
- },
- {
- "label": "2019-12-31"
- },
- {
- "label": "2020-01-31"
- },
- {
- "label": "2020-02-29"
- },
- ],
- "customers": [
- {
- "id": 30,
- "name": "Aanimals Inc"
- },
- {
- "id": 102,
- "name": "Abacus Computing Group"
- },
- {
- "id": 57,
- "name": "Able Metals Limited"
- },
- {
- "id": 5,
- "name": "Abracard Limited"
- }
- ]
Curl Syntax (Powershell)
- curl -Uri "https://{API HOSTNAME}/api/Billing/parameters" -Method Get -Headers @{
- accept = "text/plain"
- authorization = "bearer a8cab2d1ae00df4a7edd514af7828d7df672054c89feb753305f17c403127769"
- }