GET [ category-compliance-report ]
Production Endpoint: https://app.complyflow.com.au/app/public/index.php/api/acu/category-compliance-report?plant_category_id={id}
Test Endpoint: https://test.complyflow.com.au/app/public/index.php/api/acu/category-compliance-report?plant_category_id={id}
Overview
This endpoint returns the compliance status of Staff Users against the Operator Competencies required by a Plant Category, so you can report which operators hold current competencies for the plant they use.
Operator Competencies are the Document Categories a Plant Category requires from the Staff Users who operate its plant, for example a Competency Assessment or a High Risk Work Licence. They are configured on the Plant Category rather than a Staff Category, so they are not included when this endpoint is called with category_id. Call it with plant_category_id to report on them.
This is the same endpoint as the Staff Category Compliance Report, called with plant_category_id instead of category_id. The response uses the same structure, so the same reporting logic can be reused. Refer to Staff Category Compliance Report.
If you can't find what you are looking for or need further assistance, please contact support@complyflow.com.au
Authentication instructions
Refer to the Authentication method for Authentication Methods (for Login and Logout).
Permissions Required
API User
User is Staff
Staff > View Employees (previously Staff R), or Add & Edit Internal Employees (previously Staff RW)
Please also review the Permissions Overview guide.
Query parameters
FIELD | TYPE | DESCRIPTION | Example | REQUIRED | DEFAULT | PATTERN |
|
| Plant Category ID (must belong to your organisation). Refer to Get Plant Category List | 12 | Yes |
|
|
|
| Limit the report to one Staff User (must belong to your organisation) | 1024 | No |
|
|
|
| Page number (minimum 1) | 2 | No | 1 |
|
|
| Number of Staff Users per page (1 to 100) | 100 | No | 50 |
|
Note: Send either plant_category_id or category_id, not both. With category_id, the endpoint returns the Staff Category Compliance Report instead. staff_id only applies with plant_category_id.
Request Example
All Staff Users assigned to the Plant Category:
curl --location 'https://test.complyflow.com.au/app/public/index.php/api/acu/category-compliance-report?plant_category_id=12&page=1&per_page=50' \
--header 'Authorization: Bearer {token}'
One Staff User:
curl --location 'https://test.complyflow.com.au/app/public/index.php/api/acu/category-compliance-report?plant_category_id=12&staff_id=1024' \
--header 'Authorization: Bearer {token}'
Response Example
The API request returns the Plant Category, its Operator Competencies, and the status of each Staff User assigned to the Plant Category:
{
"token": "refreshed_jwt_token",
"data": {
"category": { "id": 12, "name": "Elevated Work Platforms", "type": "plant_category" },
"required_documents": [
{ "id": 88, "name": "Competency Assessment - Boom Lift" },
{ "id": 91, "name": "High Risk Work Licence - Boom Lift (WP)" }
],
"required_training": [],
"pagination": {
"current_page": 1,
"per_page": 50,
"total": 2,
"total_pages": 1
},
"members": [
{
"id": 1024,
"name": "Jane Smith",
"email": "jane.smith@example.com",
"overall_status": "non_compliant",
"documents": [
{
"document_category_id": 88,
"document_category_name": "Competency Assessment - Boom Lift",
"status": "compliant",
"expiry_date": "2027-02-11",
"approved_date": "2026-02-11",
"approver": "Chris Lee"
},
{
"document_category_id": 91,
"document_category_name": "High Risk Work Licence - Boom Lift (WP)",
"status": "missing",
"expiry_date": null,
"approved_date": null,
"approver": null
}
],
"training": []
},
{
"id": 1031,
"name": "Sam Patel",
"email": "sam.patel@example.com",
"overall_status": "compliant",
"documents": [
{
"document_category_id": 88,
"document_category_name": "Competency Assessment - Boom Lift",
"status": "expiring_soon",
"expiry_date": "2026-10-05",
"approved_date": "2025-10-06",
"approver": "Chris Lee"
},
{
"document_category_id": 91,
"document_category_name": "High Risk Work Licence - Boom Lift (WP)",
"status": "compliant",
"expiry_date": "2029-05-20",
"approved_date": "2024-05-22",
"approver": "Chris Lee"
}
],
"training": []
}
]
}
}
Response Fields
Report Fields
Field Name | Type | Description |
| object | The Plant Category ( |
| array | The Plant Category's Operator Competencies ( |
| array | Always empty for this report |
| object |
|
| array | One entry per Staff User on this page |
Member Fields
Field Name | Type | Description |
| integer | Staff ID |
| string | Staff User's full name |
| string | Staff User's email address |
| string |
|
| array | One entry per Operator Competency |
| array | Always empty for this report |
Document Fields
Field Name | Type | Description |
| integer | Document Category ID of the Operator Competency |
| string | Operator Competency name |
| string | Compliance status (see Status Values) |
| string or null | Expiry date of the approved or expired document (YYYY-MM-DD). Null if the document has no expiry date |
| string or null | Date the document was approved (YYYY-MM-DD) |
| string or null | Full name of the person who approved the document |
Status Values
Status | Meaning |
| An approved document is held and hasn't expired |
| An approved document is held but expires within 30 days |
| The most recent document has expired, and no approved or pending document is held |
| A document has been uploaded and is awaiting approval |
| No document has been uploaded, or the most recent document was rejected |
overall_status: compliant only if every Operator Competency is compliant or expiring_soon. Otherwise non_compliant.
Note: This report doesn't return a rejected status. A rejected document shows as missing, the same as in the Staff Category Compliance Report.
Error Responses
Errors are returned with HTTP status 200 in the standard response format, with the error details inside data, for example { "token": "...", "data": { "status": false, "error": "Either category_id or plant_category_id is required.", "error_code": 1 } }. If more than one parameter is invalid, only the first error is returned. Token errors are returned before the request reaches ComplyFlow, with the HTTP status shown.
Scenario | Response |
Neither |
|
Both |
|
|
|
Plant Category isn't in your organisation |
|
|
|
Staff User isn't in your organisation |
|
|
|
|
|
No API access, not a Staff User, or no Staff permission |
|
No token supplied | HTTP 400 |
Token has expired | HTTP 401 |
Token is invalid, or has already been replaced by a refreshed token | HTTP 400 or 401 |
Usage Pattern (Power BI)
Call
GET /api/acu/plant-categoriesto get all Plant Category IDs. Refer to Get Plant Category ListFor each Plant Category, call
GET /api/acu/category-compliance-report?plant_category_id={id}Page through the results with
&page=2,&page=3, etc. untilcurrent_pageequalstotal_pagesOptionally add
&staff_id={id}to report on one Staff UserUse the
tokenreturned in each response for your next request
To see every document required of a Staff User, combine this report with the Staff Category Compliance Report for each of their Staff Categories. Refer to Staff Category Compliance Report.
Notes
All results are scoped to your organisation via the JWT token
The report includes the Staff Users assigned to the Plant Category. These are the same Staff Users whose profiles list the Plant Category's Operator Competencies as Required Documents
Deleted and deactivated Staff Users are excluded
A Staff User assigned to more than one Plant Category appears in the report for each of them
With
staff_id,memberscontains only that Staff User. It's empty if they aren't assigned to the Plant CategoryStaff Users are returned in Staff ID order
If the Plant Category has no Operator Competencies, each Staff User's
documentsarray is empty andoverall_statusiscompliantDocuments with no expiry date are never shown as
expiredorexpiring_soonWhen no Staff Users are assigned to the Plant Category,
membersis empty andtotal_pagesis 1Requesting a page after the last page returns an empty
membersarrayTo report on the documents required for the Plant items themselves, refer to Get Plant Compliance Report