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.
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>
application/jsonResponses
1permissions*object
11pending*object
3100employees*array<object>
9b2f4c1e-6d3a-4f8e-a1b2-3c4d5e6f7a8bSousa Quitériadepartments*array<object>
4e1d2c3b-5a6f-4b7c-8d9e-0f1a2b3c4d5eFront Officecompanies*array<object>
7a8b9c0d-1e2f-4a3b-8c4d-5e6f7a8b9c0dVoxbi SAAuthorization Token is missingYou do not have access to this PBX.User not found.https://cockpit.voxbi.com/api/v1/v2/{pbx}/employee/{employee}/validator
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);
{ … }
"permissions": { … },
"pending": { … },
"companies": [ … ],
{ … }
"departments": [ … ],
{ … }
"employees": [ … ]
{ … }
{ … }
private, must-revalidatekeep-aliveapplication/jsonOrigin6057