API reference
Payroll API
4 operations for payroll. Each one names the scope your API key needs.
Scopes used here: payroll.run.read , payroll.payslip.read
List payroll runs (all statuses)
GET /payroll-runs
Scope: payroll.run.read
Parameters
| Name | In | Description |
|---|---|---|
period | query | Pay period, YYYY-MM. |
status | query | |
legalEntityId | query | Only runs of this legal entity. |
cursor | query | Opaque cursor from a previous response's nextCursor. |
limit | query | Page size, 1-200. Defaults to 50. |
Response 200
| Field | Type | Notes |
|---|---|---|
data | array of object required | |
data[].id | string (uuid) required | |
data[].legalEntityId | string (uuid) required | |
data[].period | string required | YYYY-MM |
data[].runType | string required | |
data[].sequenceNo | integer required | |
data[].status | string required | |
data[].lockedAt | string or string (date-time) required | ISO-8601 timestamp |
data[].computedAt | string or string (date-time) required | ISO-8601 timestamp |
data[].approvedAt | string or string (date-time) required | ISO-8601 timestamp |
data[].finalizedAt | string or string (date-time) required | ISO-8601 timestamp |
data[].paidAt | string or string (date-time) required | ISO-8601 timestamp |
data[].reversedAt | string or string (date-time) required | ISO-8601 timestamp |
data[].createdAt | string or string (date-time) required | ISO-8601 timestamp |
data[].updatedAt | string or string (date-time) required | ISO-8601 timestamp |
nextCursor | string, nullable required | Opaque. Pass back as ?cursor= for the next page; null on the last page. |
Errors: 400 · 401 · 403 · 404 · 422 · 429
(error format)
curl -s 'https://<your-company>.<app-domain>/api/v1/payroll-runs' \
-H 'Authorization: Bearer YOUR_API_KEY' Fetch one payroll run
GET /payroll-runs/{id}
Scope: payroll.run.read
Parameters
| Name | In | Description |
|---|---|---|
id required | path |
Response 200
| Field | Type | Notes |
|---|---|---|
id | string (uuid) required | |
legalEntityId | string (uuid) required | |
period | string required | YYYY-MM |
runType | string required | |
sequenceNo | integer required | |
status | string required | |
lockedAt | string or string (date-time) required | ISO-8601 timestamp |
computedAt | string or string (date-time) required | ISO-8601 timestamp |
approvedAt | string or string (date-time) required | ISO-8601 timestamp |
finalizedAt | string or string (date-time) required | ISO-8601 timestamp |
paidAt | string or string (date-time) required | ISO-8601 timestamp |
reversedAt | string or string (date-time) required | ISO-8601 timestamp |
createdAt | string or string (date-time) required | ISO-8601 timestamp |
updatedAt | string or string (date-time) required | ISO-8601 timestamp |
Errors: 400 · 401 · 403 · 404 · 422 · 429
(error format)
curl -s 'https://<your-company>.<app-domain>/api/v1/payroll-runs/<id>' \
-H 'Authorization: Bearer YOUR_API_KEY' Every employee's payslip in a finalized or paid run: days, gross, net, employer cost and payout state. A run that is not final yet has no payslips (404)
GET /payroll-runs/{id}/payslips
Scope: payroll.payslip.read
Parameters
| Name | In | Description |
|---|---|---|
id required | path | |
cursor | query | Opaque cursor from a previous response's nextCursor. |
limit | query | Page size, 1-200. Defaults to 50. |
Response 200
| Field | Type | Notes |
|---|---|---|
data | array of object required | |
data[].id | string (uuid) required | The payslip's id (one employee in one run). |
data[].payrollRunId | string (uuid) required | |
data[].period | string required | YYYY-MM |
data[].employeeId | string (uuid) required | |
data[].employeeCode | string required | |
data[].status | string required | included | held | stopped | excluded |
data[].payableDays | string required | Decimal, e.g. "29.50". |
data[].lopDays | string required | |
data[].grossPaise | integer required | Integer paise (₹1 = 100). |
data[].netPaise | integer required | |
data[].employerCostPaise | integer required | |
data[].paymentStatus | string required | |
data[].paidOn | string, nullable required | |
data[].documentAvailable | boolean required | Whether the payslip PDF has been generated. |
nextCursor | string, nullable required | Opaque. Pass back as ?cursor= for the next page; null on the last page. |
Errors: 400 · 401 · 403 · 404 · 422 · 429
(error format)
curl -s 'https://<your-company>.<app-domain>/api/v1/payroll-runs/<id>/payslips' \
-H 'Authorization: Bearer YOUR_API_KEY' One employee's payslip in a finalized or paid run, with its component lines and the TDS it shows
GET /payroll-runs/{id}/payslips/{employeeId}
Scope: payroll.payslip.read
Parameters
| Name | In | Description |
|---|---|---|
id required | path | |
employeeId required | path |
Response 200
| Field | Type | Notes |
|---|---|---|
id | string (uuid) required | The payslip's id (one employee in one run). |
payrollRunId | string (uuid) required | |
period | string required | YYYY-MM |
employeeId | string (uuid) required | |
employeeCode | string required | |
status | string required | included | held | stopped | excluded |
payableDays | string required | Decimal, e.g. "29.50". |
lopDays | string required | |
grossPaise | integer required | Integer paise (₹1 = 100). |
netPaise | integer required | |
employerCostPaise | integer required | |
paymentStatus | string required | |
paidOn | string, nullable required | |
documentAvailable | boolean required | Whether the payslip PDF has been generated. |
lines | array of object required | |
lines[].componentCode | string required | |
lines[].lineType | string required | |
lines[].amountPaise | integer required | |
lines[].sortOrder | integer required | |
tax | object, nullable required | |
tax.fy | string required | |
tax.regime | string required | |
tax.monthlyTdsPaise | integer required |
Errors: 400 · 401 · 403 · 404 · 422 · 429
(error format)
curl -s 'https://<your-company>.<app-domain>/api/v1/payroll-runs/<id>/payslips/<employeeId>' \
-H 'Authorization: Bearer YOUR_API_KEY'