This article explains how to retrieve active and deleted paychecks; add or delete paycheck export logs; create a candidate's payroll record; and attach a payslip, such as a PDF, via the API.
Get Paycheck
GET
https://api.recman.io/v2/get/?key={{api_key}}&
scope=paycheck&page=1Retrieve paychecks through the GET method. page is required. If exported is not specified, all paychecks are returned. The paycheck list is sorted in descending order.
Note
If a paycheck has an attached object, it can be downloaded separately using the workAttachment scope.
| URL | https://api.recman.io/v2/get/ |
| scope | paycheck |
| page | Page number, 1000 paychecks per page |
| parameters | minPaycheckId, payCheckIds, paycheckId, exported, paycheckSystemId |
Parameters explained
| Parameter | Description |
|---|---|
| payCheckIds | Enter several paycheck IDs to list specific ones. Comma-separated, no spaces. |
| paycheckId | Select only one paycheck to export. |
| exported | Request only paychecks that have been exported or not. "0" = Not exported, "1" = Exported. |
| paycheckSystemId | Gives an ID based on what kind of export the paycheck has been exported to. exported must be set to "1" for this parameter to work. |
| minPaycheckId | Lists all paychecks over a specified paycheck ID, and none below. |
PARAMS
| key | {{api_key}} |
| scope | paycheck |
| page | 1 |
Get Paycheck – Deleted
GET
https://api.recman.io/v2/get/?key={{api_key}}&
scope=deletedPaycheck&page=1Gives you a list of all paychecks that have been deleted. The same pagination and parameters as the standard paycheck scope apply.
| URL | https://api.recman.io/v2/get/ |
| Scope | deletedPaycheck |
| Page | Page number, 1000 paychecks per page |
| Parameters | minPaycheckId, payCheckIds, paycheckId, exported, paycheckSystemId |
PARAMS
| key | {{api_key}} |
| scope | deletedPaycheck |
| page | 1 |
Insert / Delete Paycheck Export Log
POST
https://api.recman.io/v2/post/The POST method is used for inserting and deleting paycheck export logs.
| URL POST | https://api.recman.io/v2/post/ |
| Scope | paycheckExportLog |
| Operation | insert / delete |
Fields
| Field | Description |
|---|---|
| paycheckId integer | Paycheck ID. Required on operation: insert |
| userId integer | User ID. Required on operation: insert |
| paycheckSystemId integer | Paycheck system ID. Required on operation: insert |
| paycheckExportLogId integer | Paycheck export log ID. Required on operation: delete |
Request Body – Insert
| key | {{api_key}} |
| scope | paycheckExportLog |
| operation | insert |
| data.paycheckId | 423562 |
| data.userId | 13236 |
| data.paycheckSystemId | 755682 |
Request Body – Delete
| key | {{api_key}} |
| scope | paycheckExportLog |
| operation | delete |
| data.paycheckExportLogId | 321312 |
Insert / Delete Deleted-Paycheck Export Log
POST
https://api.recman.io/v2/post/The POST method is used for inserting and deleting export logs specifically for deleted paychecks.
Fields and behavior are identical to the standard paycheck export log, but apply to thedeletedPaycheckExportLog scope.
| URL POST | https://api.recman.io/v2/post/ |
| Scope | deletedPaycheckExportLog |
| Operation | insert / delete |
Fields
| Field | Description |
|---|---|
| paycheckId integer | Paycheck ID. Required on operation: insert |
| userId integer | User ID. Required on operation: insert |
| paycheckSystemId integer | Paycheck system ID. Required on operation: insert |
| paycheckExportLogId integer | Paycheck export log ID. Required on operation: delete |
Request Body – Insert
| key | {{api_key}} |
| scope | deletedPaycheckExportLog |
| operation | insert |
| data.paycheckId | 423562 |
| data.userId | 13236 |
| data.paycheckSystemId | 755682 |
Insert Payroll
POST
https://api.recman.io/v2/post/Here you can find an overview of how to request payrolls and what you can do with them.
| URL POST | https://api.recman.io/v2/post/ |
| Scope | payroll |
| Operation | insert |
Payroll fields
| Field | Description |
|---|---|
| candidateId integer | ID of the candidate for whom to insert the payroll |
| grossAmount integer | The amount before deduction |
| netAmount integer | The amount after deduction |
| year integer | Which year the payroll was created. Format: yyyy |
| month integer | Which month the payroll was created. Format: m |
| date date | Which date the payroll was uploaded. Format: y-m-d |
| attachments object | See "Attaching a File to a Payroll Record" below |
Request Body
| key | {{api_key}} |
| scope | payroll |
| operation | insert |
| data.candidateId | 3772436 |
| data.grossAmount | 1000 |
| data.netAmount | 1000 |
| data.year | 2022 |
| data.month | 1 |
| data.date | 2022-05-25 21:05:16 |
Attaching a File to a Payroll Record
POST
https://api.recman.io/v2/post/A file (e.g., a payslip PDF) can be attached to a payroll record at the same time it is inserted, by including an attachments object in the request.
Attachments — sub-fields
| Field | Description |
|---|---|
| name string | Name of the file to be uploaded |
| ext string | File extension type. Valid values: pdf, docx, etc. |
| base64 string | Base64-encoded string of the file |
Request Body
| key | {{api_key}} |
| scope | payroll |
| operation | insert |
| data.candidateId | 3772436 |
| data.grossAmount | 1000 |
| data.netAmount | 1000 |
| data.year | 2022 |
| data.month | 1 |
| data.date | 2022-05-25 21:05:16 |
| data.attachments.name | attachmentsName.pdf |
| data.attachments.ext | |
| data.attachments.base64 | (base64-encoded file content) |