Overview
TimeLeaf connects your approved timesheets and leave data to your payroll system. All plans support CSV export. The Professional plan and above add direct integrations with QuickBooks Online (any region) and Xero — Xero payroll sync works for AU, NZ, and UK organizations; Xero has no payroll API for the US or Canada at all.
CSV export
CSV export is the simplest way to get timesheet data into any payroll system, and works regardless of your country.
Running an export
Call GET /api/payroll/export with the dateStart/dateEnd/format parameters described below — see API endpoint.
Only approved timesheets are included in the export. If a timesheet is still pending approval, it is excluded from the results.
Export formats
| Format | Description |
|---|---|
| Standard | A general-purpose CSV with employee name, date, regular hours, overtime hours, and leave hours. Compatible with most payroll systems. |
| QuickBooks | Formatted to match QuickBooks Online's time activity import schema. Includes employee display name, service item, and billable status. |
| Xero | Formatted for Xero's timesheet import. Groups entries by employee and pay period with earnings rate codes. |
Summary export
In addition to the detailed line-by-line export, you can generate a summary export that aggregates hours per employee for the pay period. This is useful for salaried payroll where you only need totals.
QuickBooks Online integration
The QuickBooks integration syncs approved timesheets, overtime, and paid leave as TimeActivity entries. Available on the Professional plan and above.
How it works
- Connect your QuickBooks account under Settings > Integrations.
- Map TimeLeaf employees to QuickBooks employee records.
- Trigger a sync for a pay period — an admin initiates this; it does not run automatically on every timesheet approval.
- TimeLeaf creates a TimeActivity per worked entry, plus separate entries for overtime hours and approved paid leave.
See the QuickBooks integration guide for detailed setup instructions.
Xero integration
The Xero integration syncs approved timesheets, overtime, and paid leave as Xero timesheet entries. Available on the Professional plan and above, for AU, NZ, and UK organizations — Xero has no payroll API for the US or Canada, so this integration cannot push payroll data for organizations in those countries (basic accounting-only Xero connections are unaffected).
How it works
- Connect your Xero account under Settings > Integrations.
- Earnings rate and payroll calendar mappings are configured by your TimeLeaf administrator.
- Trigger a sync for a pay period — an admin initiates this; it does not run automatically on every timesheet approval.
See the Xero integration guide for detailed setup instructions.
API endpoint
You can also retrieve payroll export data programmatically via the REST API.
GET /api/payroll/export
Query parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
dateStart | string (ISO 8601 date) | Yes | Start of the pay period |
dateEnd | string (ISO 8601 date) | Yes | End of the pay period |
format | string | No | standard, quickbooks, or xero. Defaults to standard. |
summary | boolean | No | If true, returns aggregated totals per employee instead of detailed rows. Defaults to false. |
Requires a manager or admin role. Returns CSV.