Get payroll costs by cost centers

Deprecated. Use GET /integration/v1/payroll-costs/segments/by-cost-centers, which returns the same response.

🚧

Deprecated

This endpoint is deprecated. Use Get payroll cost segments by cost centers, which returns the same response. This path will keep working, but new integrations should use the new one.

This endpoint allows you to retrieve total payroll cost data for a specific cost center type and one or more values within it.

You specify the cost center to retrieve using two query-string parameters: cost-center-type-key (the cost center type, provided once) and cost-center-value (one or more values within that type, repeated for each value you want). For instance, ?cost-center-type-key=clientId&cost-center-value=c123&cost-center-value=c456 will produce payroll costs coded to the cost center type named clientId with the values c123 or c456.

By default, a cost-center-value that doesn't exist for your company fails the whole request with a 400 error. If you're requesting many values and want results for the ones that do exist, add ignore-unknown-cost-center-values=true. Unknown values are then skipped, and you get an empty page if none of the values exist. An unknown cost-center-type-key is an error either way, so a typo in the type doesn't silently return nothing.

This data includes the full-loaded cost of payroll for the given cost center. It includes wages, employer payroll taxes, additional costs like benefit plan contributions and Workers' Comp insurance premiums, and so on. It also includes amounts that are taken from employee wages as withholdings, including for taxes and various kinds of deductions.

See the Payroll Cost API Guide for all the details about how this API works.

Query Params
string
required

The cost center type to filter by (the type key you specified on your wage data).

cost-center-value
array of strings
required

One or more values within the given cost center type to filter by. Provide multiple cost-center-value parameters to filter by more than one value at the same time.

cost-center-value*
boolean
Defaults to false

By default, a cost-center-value that doesn't exist for your company fails the whole request with a 400 error. Set this to true to skip unknown values and return the results for the values that do exist (or an empty page if none of them exist). An unknown cost-center-type-key is always an error.

number

The page number, starting with 0.

number

The page size. Defaults to 20 and must not exceed 100.

Response

Language
Credentials
Header
LoadingLoading…
Response
Choose an example:
application/json