Skip to main content

Validate Worker Document

POST/workers/{workerId}/documents/{documentId}/validate
Agency-scoped keys

This endpoint is not available for agency-scoped API keys.

Caller​

This endpoint requires a company-scoped API key with the write:workers scope.

Summary​

Records a manual validated status for a worker attachment or right-to-work document. The validation is owned by the selected company and records the validating user or API-key owner in its history.

Calling the endpoint for an existing manual validation updates it to validated and appends a status-history entry.

URL Parameters​

NameTypeRequiredDescription
workerIdstringYesWorker ObjectId or internal nanoid
documentIdstringYesAttachment or right-to-work document ObjectId

Query Parameters​

NameTypeRequiredDescription
companystringYesCompany ObjectId that owns the validation; it must be linked to key

Request Example​

curl -X POST 'https://api.requidex.com/api/open/v1/workers/{workerId}/documents/{documentId}/validate?company={companyId}' \
-H 'Authorization: Bearer <API_KEY>' \
-H 'Accept: application/json'

Response Fields​

FieldTypeDescription
successbooleanWhether the request succeeded
dataobjectRecorded validation.
Show child attributes
  • id string - Validation ID
  • company object
    Show child attributes
    • id string - Company ID
    • name string - Company name
  • competency object / null - Related competency, when present
    Show child attributes
    • id string - Competency ID
    • name string - Competency name
  • user object / null - User or API-key owner attributed to the action
    Show child attributes
    • id string - User ID
    • name string - User name
  • validationType string - manual
  • status string - validated
  • resolvedAt string - Validation timestamp
  • documentType string - attachment or rightToWork
  • documentRef string - Validated worker document ID
  • statusHistory array[object]
    Show child attributes
    • status string - Status recorded for the history entry
    • changedAt string - Timestamp of the history entry
    • changedBy object - User reference with id and name
  • createdAt string - Validation creation timestamp
  • updatedAt string - Validation update timestamp

Response Example (200)​

{
"success": true,
"data": {
"id": "67bc36db80a1616ec3f48b01",
"company": {
"id": "67bc36db80a1616ec3f47001",
"name": "Requidex Construction Ltd"
},
"competency": {
"id": "67bc36db80a1616ec3f47234",
"name": "CSCS"
},
"user": {
"id": "67bc36db80a1616ec3f49998",
"name": "Alex Carter"
},
"validationType": "manual",
"status": "validated",
"resolvedAt": "2026-08-21T09:00:00.000Z",
"documentType": "attachment",
"documentRef": "67bc36db80a1616ec3f48a10",
"statusHistory": [
{
"status": "validated",
"changedAt": "2026-08-21T09:00:00.000Z",
"changedBy": {
"id": "67bc36db80a1616ec3f49998",
"name": "Alex Carter"
}
}
],
"createdAt": "2026-08-21T09:00:00.000Z",
"updatedAt": "2026-08-21T09:00:00.000Z"
},
"meta": {}
}

MCP Tool​

The MCP server exposes this operation as open_api_validate_worker_document with the inputs workerId, documentId, and company.

Errors​

HTTP StatusDescription
400Missing identifiers or the request does not select exactly one company
401Missing, invalid, revoked, or expired API key
403Missing write:workers scope or agency-scoped access
404Worker or worker document not found
429Rate limit exceeded
500Unexpected internal error