1. Who this guide is for
This guide explains how to use the API to get user and team rankings for your organization, so you can display them on an internal portal, dashboard, or in your reports.
Your IT team or integration partner is responsible for automating the calls (scheduling, processing, and storing the data): LibraCyber provides the data and supports you in understanding it.
Before you start, read Start here: API authentication: there you'll find how to get your credentials and token.
2. The API call
GET <api_base_url>/report/rankings
with the header Authorization: Bearer <access_token>.
| Parameter | Required | What it's for |
|---|---|---|
type |
Yes | Ranking type: 0 = users, 1 = teams, 2 = users of a specific team |
team |
Only with type=2
|
Name of the team you want the ranking for |
level_uuid |
No | Path identifier: limits the ranking to that path |
limit |
No | Results per page (from 1 to 1000) |
page |
No | Page to read, used with limit
|
3. What you get
User ranking (type=0 or type=2):
{
"accounts": [
{ "position": "1", "firstname": "Mario", "lastname": "Rossi", "team": "Sales EMEA", "points": "36" },
{ "position": "2", "firstname": "Alessandro", "lastname": "Bianchi", "team": "IT Operations", "points": "32" }
]
}
Team ranking (type=1):
{
"teams": [
{ "position": "1", "team": "Sales EMEA", "members": "23", "points": "31" },
{ "position": "2", "team": "IT Operations", "members": "34", "points": "26" }
]
}
If you use limit and page, the response will also include a pagination block with the current page, total items and pages, and references to the previous and next pages.
4. If something doesn't work
| Code | What it means | What to do |
|---|---|---|
EXT_1000 |
An invalid parameter (for example, missing type or missing team with type=2) |
Fix the parameter mentioned in the message |
EXT_1006 |
The specified path doesn't belong to your organization | Check level_uuid
|
EXT_1007 |
The specified path doesn't exist | Check level_uuid
|
EXT_1008 |
The specified team doesn't exist | Check the team name in the platform |
EXT_1003 |
Temporary error retrieving data | Try again later; if it keeps happening, contact support |
EXT_1001 |
Token expired or invalid | Request a new token |
If the problem continues, contact support and include the API call you made, the date and time, and the full error message. We can help you with testing, first in the test environment and then in production.