Skip to content

Get an employee's validator role and queue counts (user)

Whether this employee holds a validator role, which request types are theirs, how much is queued for them, and whom they validate.

Replaces the validator block of GET /tempus/api/v1/{pbx_id}/user/{employee_id}/profile. The companies, departments and employees lists come from approval chains and v1 rules alike: everybody a chain they sit on targets, whatever the request type. For the work itself use employee/{employee}/validator/queue, narrowed per type with filter[kind][].

The same block is on GET /v2/{pbx}/employee/{employee}/profile, so a screen that already fetches the profile needs no second call. This endpoint exists for the opposite case: deciding whether to offer a validator section is one boolean, and should not require the whole profile payload.

Readable for your own employee record only: asking for another employee returns 403, since how someone else's validator duties are staffed is not theirs to read.

Note the path says employee, not user as v1 did: the subject is a Tempus employee record, and v1 passed an employee id to a segment named user.

HTTP: bearerAuth

User bearer token. Default authentication for customer-facing endpoints. Obtain a token by calling POST /login with your credentials, then send it on every subsequent request as Authorization: Bearer <token>. The token inherits the permissions and PBX scope of the authenticated user.

HTTP Authorization Scheme
bearer
Bearer format
Bearer <token>
pbx path · string · uuid *
UUID of the PBX tenant. Must be the tenant the token belongs to; anything else is refused with 403 rather than answered from another tenant.
employee path · string · uuid *
UUID of the Tempus employee whose queue this is. Must be the caller's own employee record: a queue is built from the approval rows addressed to one person, so another employee's id is refused rather than quietly answered with your own.
accept header · string
example: application/json

Responses

OK. Always this shape, whether or not they are a validator.
Response schema
is_validator*boolean
Whether they hold any validator role at all, which is the signal for whether to offer a validator section. True when any chain that reaches somebody names them, as a step validator or as a supervisor, for at least one request type. A chain that is staffed but scoped to nobody does not count, so a half-built chain cannot light up a section with nothing behind it.
example: 1
permissions*object
Which request types they are asked to decide.
absence_requests*boolean
example: 1
home_office_requests*boolean
example: 1
time_point_corrections*boolean
example:
schedule_assignment_requests*boolean
example:
pending*object
How many requests of each type are waiting on them right now, counted from the approval rows addressed to them, so it matches the queue endpoints exactly. An all-zero map means only that nothing is waiting today: somebody with an empty queue is still a validator, so gate the section on `is_validator` and use these for badges or to skip a part that would open empty. The work itself is at `employee/{employee}/validator/queue`, narrowed per type with `filter[kind][]=absences | home-office | time-point-corrections`. `schedule_assignment_requests` is always 0: schedule assignment is direct management, not a request queue.
absence_requests*integer
example: 3
home_office_requests*integer
example: 1
time_point_corrections*integer
example: 0
schedule_assignment_requests*integer
example: 0
employees*array<object>
Everybody they validate, sorted by name: everyone a chain they sit on targets (named directly, or through the department or company of their active contract, or the whole tenant for a chain that applies to all), plus everyone a v1 rule gives them. They are never listed themselves. Empty for a non-validator.
employee_id*string · uuid
example: 9b2f4c1e-6d3a-4f8e-a1b2-3c4d5e6f7a8b
name*string
example: Sousa Quitéria
departments*array<object>
The departments those employees' active contracts place them in, sorted by name.
id*string · uuid
example: 4e1d2c3b-5a6f-4b7c-8d9e-0f1a2b3c4d5e
name*string
example: Front Office
companies*array<object>
The companies those employees' active contracts place them in, sorted by name.
id*string · uuid
example: 7a8b9c0d-1e2f-4a3b-8c4d-5e6f7a8b9c0d
name*string
example: Voxbi SA
Authorization Token Missing. This error is returned when the authorization token is missing.
Response schema
errorstring
Error message
example: Authorization Token is missing
Forbidden. The caller is outside this PBX, or asked for an employee record that is not their own.
Response schema
messagestring
example: You do not have access to this PBX.
Not found. No such employee in this PBX.
Response schema
messagestring
example: User not found.
get https://cockpit.voxbi.com/api/v1/v2/{pbx}/employee/{employee}/validator
Base URL
Request sample
curl -X GET 'https://cockpit.voxbi.com/api/v1/v2/{pbx}/employee/{employee}/validator' \
  -H 'Authorization: Bearer YOUR_TOKEN'
const response = await fetch('https://cockpit.voxbi.com/api/v1/v2/{pbx}/employee/{employee}/validator', {
  method: 'GET',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': `Bearer ${YOUR_TOKEN}`,
  },
});

const data = await response.json();
console.log(data);
import requests

response = requests.get('https://cockpit.voxbi.com/api/v1/v2/{pbx}/employee/{employee}/validator',
    headers={'Authorization': f'Bearer {YOUR_TOKEN}'}
)
response.raise_for_status()
data = response.json()
print(data)
<?php
$context = stream_context_create([
    'http' => [
        'method'  => 'GET',
        'header'  => "Content-Type: application/json\r\nAuthorization: Bearer YOUR_TOKEN",
    ],
]);

$response = file_get_contents('https://cockpit.voxbi.com/api/v1/v2/{pbx}/employee/{employee}/validator', false, $context);
$data = json_decode($response, true);
print_r($data);
{ … }
"is_validator": true,
"permissions": { … },
"absence_requests": true,
"home_office_requests": true,
"time_point_corrections": false,
"schedule_assignment_requests": false
},
"pending": { … },
"absence_requests": 3,
"home_office_requests": 0,
"time_point_corrections": 0,
"schedule_assignment_requests": 0
},
"companies": [ … ],
{ … }
"id": "7a8b9c0d-1e2f-4a3b-8c4d-5e6f7a8b9c0d",
"name": "Voxbi SA"
}
],
"departments": [ … ],
{ … }
"id": "4e1d2c3b-5a6f-4b7c-8d9e-0f1a2b3c4d5e",
"name": "Front Office"
}
],
"employees": [ … ]
{ … }
"employee_id": "9b2f4c1e-6d3a-4f8e-a1b2-3c4d5e6f7a8b",
"name": "Sousa Quitéria"
}
]
}
{ … }
"error": "Authorization Token is missing"
}
Cache-Control string
example: private, must-revalidate
Connection string
example: keep-alive
Content-Type string
example: application/json
Vary string
example: Origin
X-RateLimit-Limit integer
Max requests allowed in the current rate-limit window.
example: 60
X-RateLimit-Remaining integer
Requests remaining in the current rate-limit window.
example: 57
No example for this status.
No example for this status.