Approve a payroll

Approves a payroll.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

The payroll must have a completed preview (indicated by a preview.status of succeeded) before it can be approved.

{
  ...,
  "preview": {
    "status": "succeeded",
    "started_at": "2019-06-29T18:26:56.848920Z"
  },
  ...
}

Approving a preview approves the most recent preview of the payroll and moves the payroll status to pending, and the payroll must be reopened before it can be further modified.


Optionally, pass preview_started_at to guard against approving a stale preview. If provided, it's compared against the payroll's current preview.started_at; if they don't match, the request fails with a 409 preview_superseded error instead of approving. This lets a client detect that someone else (or another tab) re-previewed the payroll after it last fetched it. Omitting the parameter preserves the current behavior.

Path Params
string
required
Body Params
string

OPTIONAL. The preview.started_at timestamp the client last saw. If provided and it no longer matches the payroll's current preview, the request fails with a 409 preview_superseded error instead of approving.

Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json