# Payroll Templates

`GET /accounting/payroll-templates`

Group: Accounting › Payroll Templates · Operation ID: `payrollTemplates`

Returns a list of payroll templates. Each item is the header only. For the categories, use GET accounting/payroll-templates/:id or POST accounting/payroll-templates/search.

[Open in the interactive reference](https://docs.api.lensing.ai/?op=payrollTemplates)

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `Api-Version` | header | `"v1"` | yes | The API version this request targets, named by its public identifier. Required on every request; omitting it, or naming a version this company does not have, is answered with 400. This document describes version `v1`. |

## Query surface

- `id` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `name` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `groupBy` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `journalEntryDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `journalEntryGroupBy` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `deductionsType` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `source` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `status` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- `lastModifiedDate` — filter by eq, ne, gt, gte, lt, lte, in, notIn, between, like
- Orderable: id, name, groupBy, journalEntryDate, journalEntryGroupBy, deductionsType, source, status, lastModifiedDate
- Selectable: id, name, description, groupBy, journalEntryDate, journalEntryGroupBy, deductionsType, source, status, lastModifiedDate

## Response

`200` Success

Under `data`, an array of payrollTemplatesRow:

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | string | no | The unique identifier for the payroll template. |
| `name` | string | no | The name of the payroll template. Unique across payroll templates. |
| `description` | string or null | no | A free-form description of the payroll template. |
| `groupBy` | string | no | The level at which payroll amounts are entered. One of 'Employee', 'Department' or 'Multi-level'. |
| `journalEntryDate` | string | no | The date the generated journal entry is posted on. Possible values: 'payrollDate', 'endDate'. |
| `journalEntryGroupBy` | string | no | The default consolidation level for generated journal lines. One of 'account', 'accountAndPayrollCategory', 'payrollCategory' or 'payrollCategoryByEmployee'. |
| `deductionsType` | string | no | Whether deduction amounts in imported data arrive positive or negative. Possible values: 'positive', 'negative'. |
| `source` | string or null | no | The payroll system this template imports from. Possible values: 'datev', 'datevEmployeePayroll', 'datevEmployeePayrollPersonLevel', 'rippling', 'lexware', 'briars', 'gusto', 'adpGLReport', 'adpPayrollHistory', 'sage', 'none'. |
| `status` | string or null | no | The lifecycle status of the payroll template. One of 'create', 'active', 'inactive'. It is computed from the template's categories, not set through the API. |
| `lastModifiedDate` | string (date-time) or null | no | The date and time the payroll template last changed, in UTC. Format YYYY-MM-DDTHH:mm:ss.sssZ. |

## Statuses

- `400` — Invalid request or business failure
- `401` — Missing or invalid access token
- `403` — Not authorized
- `404` — Not found
- `429` — Too many requests
- `500` — Internal server error
