Upload a document against a worker
const url = 'https://api2.recruso.co.uk/v1/workers/1/documents';const form = new FormData();form.append('workerId', '4821');form.append('file', 'file');
const options = {method: 'POST', headers: {Authorization: '<Authorization>'}};
options.body = form;
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api2.recruso.co.uk/v1/workers/1/documents \ --header 'Authorization: <Authorization>' \ --header 'Content-Type: multipart/form-data' \ --form workerId=4821 \ --form file=@fileAdds a file to a worker’s documents in your own agency, sent as multipart/form-data with the file in a part named file.
Accepted types are doc, docx, xls, xlsx, pdf, jpg, jpeg, png, gif, tif, tiff, msg, up to 50 MB. Anything else returns 400.
An upload cannot be corrected. The record carries no modified-by audit, so there is nothing to record a correction with: replace a document by uploading the new one and removing the old.
The name you upload is kept as the document name, and the file is stored under a generated identifier instead, so a file whose name another agency has already used is fine. Documents are held in private storage, and the response does not say where.
A worker id belonging to another agency returns 404 rather than 403, so their existence is never disclosed.
Access. Requires a client-credentials access token. Tokens issued through the interactive user login are rejected.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The workerId path parameter
Request Bodyrequired
Section titled “Request Bodyrequired”The file to hold against a worker, sent as multipart/form-data.
object
The worker the document belongs to. Taken from the route.
Example
4821The file itself. Its name is kept as the document name; the name it is stored under is generated, so uploading a file whose name another agency has already used is fine.
Responses
Section titled “Responses”Created
object
The document’s identifier.
The name the file was uploaded as.
The Recruso user id (tblUsers.UserID) that uploaded it, not the ASP.NET Identity id.
When it was uploaded, in UK local time.
Example
{ "workerDocumentId": 7714, "documentName": "New Microsoft Word Document.docx", "createdBy": 100, "createdOn": "2026-09-07T11:04:22"}Bad Request
object
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}Unauthorized
object
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}Forbidden
object
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}Not Found
object
Examplegenerated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}
