TimeLeafTimeLeaf
Back to site

Core Features

Payroll Integration

Export approved timesheets to payroll via CSV, QuickBooks Online, or Xero.

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

FormatDescription
StandardA general-purpose CSV with employee name, date, regular hours, overtime hours, and leave hours. Compatible with most payroll systems.
QuickBooksFormatted to match QuickBooks Online's time activity import schema. Includes employee display name, service item, and billable status.
XeroFormatted 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

  1. Connect your QuickBooks account under Settings > Integrations.
  2. Map TimeLeaf employees to QuickBooks employee records.
  3. Trigger a sync for a pay period — an admin initiates this; it does not run automatically on every timesheet approval.
  4. 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

  1. Connect your Xero account under Settings > Integrations.
  2. Earnings rate and payroll calendar mappings are configured by your TimeLeaf administrator.
  3. 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:

ParameterTypeRequiredDescription
dateStartstring (ISO 8601 date)YesStart of the pay period
dateEndstring (ISO 8601 date)YesEnd of the pay period
formatstringNostandard, quickbooks, or xero. Defaults to standard.
summarybooleanNoIf true, returns aggregated totals per employee instead of detailed rows. Defaults to false.

Requires a manager or admin role. Returns CSV.