Everything an AI agent can do with the Gusto API.

A reference guide for building AI agents: every method, how to authenticate, and the permissions each one needs.

Endpoints24
API version2026-06-15
Last updated23 June 2026
Orientation

How the Gusto Embedded API works.

The Gusto API is how an app or AI agent works with a company's payroll: reading employees, calculating and running payroll, paying contractors, and tracking time off. Access is granted through an OAuth token whose scopes, named by resource and action like payrolls:read, decide what each call can read or write, and a token is tied to a single company so it cannot reach another. Versions are dated, and Gusto can push events to a subscribed webhook URL when something happens in a company.

24Endpoints
9Capability groups
13Read
11Write
18Permissions
Authentication
Gusto authenticates with an OAuth 2.0 bearer token sent as 'Authorization: Bearer '. An admin authorizes one company through the authorization-code flow, and the app exchanges the code for an access token and a refresh token. The access token expires after two hours and is renewed with the refresh token, which itself rotates on each refresh. A separate system-level token handles application-wide actions like creating a company.
Permissions
Access is governed by OAuth scopes named resource and action, such as employees:read, employees:write, payrolls:read, payrolls:run, and time_off_requests:approve. An application is granted its scopes in the Developer Portal based on its use case, and a call outside those scopes returns 403 missing_oauth_scopes. On top of scopes, Gusto's strict access model ties each company token to a single company, so it can never reach another company's data.
Versioning
The API is versioned by date through the X-Gusto-API-Version header, with the newest version 2026-06-15. Backward-incompatible versions ship on a roughly quarterly cadence, each supported for twelve months after it is superseded, with six months of full support followed by six months of critical fixes only. When no header is sent, a request falls back to the application's configured default version.
Data model
Gusto is resource-oriented JSON over HTTPS at https://api.gusto.com/v1, with a demo host at https://api.gusto-demo.com/v1. Most resources nest under a company at /v1/companies/{company_id}, covering employees, payrolls, contractors, pay schedules, bank accounts, time off, and departments, while some, like /v1/employees/{employee_id} and /v1/compensations/{compensation_id}, are addressed directly. A state change emits an event delivered by webhook, and an update carries a resource version to prevent overwriting newer data.
Connect & authenticate

Connection & authentication methods.

How an app or AI agent connects to Gusto determines what it can reach. There is a route for making calls, a route for receiving events, and a hosted server that helps an agent build against the API, and each is governed by the token behind it and the scopes that token carries.

Ways to connect

REST API

The REST API answers at https://api.gusto.com/v1, with a separate demo host at https://api.gusto-demo.com/v1 for testing. A call authenticates with an OAuth bearer token and pins behavior with the X-Gusto-API-Version header.

Best forConnecting an app or AI agent to Gusto.
Governed byThe OAuth token and the scopes it carries.
Docs ↗

Webhooks

Gusto POSTs events to a subscribed HTTPS URL. A subscription names the resource types to watch and is verified once with a token, after which each delivery carries an X-Gusto-Signature header that is an HMAC of the payload, keyed by the verification token, so a receiver can confirm the event came from Gusto.

Best forReceiving Gusto events at an app or AI agent.
Governed byThe verification token on the subscription.
Docs ↗

Dev Assistant MCP server

A hosted Model Context Protocol server at https://embedded-payroll.readme.io/mcp lets an AI coding tool search and fetch the API reference and documentation while building against Gusto. It is in open beta, and it exposes reference and docs search rather than live payroll operations, so it helps write integration code, not run payroll.

Best forHelping an AI tool build against the Gusto Embedded API.
Governed byRead-only access to Gusto's public reference and docs.
Docs ↗
Authentication

OAuth 2.0 (company access token)

An app sends an admin through the OAuth 2.0 authorization-code flow at api.gusto.com to authorize one company, then exchanges the code for an access token and a refresh token. The access token is a bearer token sent as Authorization: Bearer, and it is scoped to that single company under Gusto's strict access model.

TokenOAuth bearer access token (one company)
Best forActing on a company an admin has authorized
Docs ↗

System access token

A system-level token authenticates application-wide actions that are not tied to one company, such as creating a new company. It uses the same bearer scheme and is distinct from the per-company token issued through OAuth.

TokenSystem bearer access token
Best forApplication-wide actions like provisioning a company
Docs ↗
Capability map

What an AI agent can do in Gusto.

The Gusto Embedded API is split into areas an agent can act on, like employees, companies, payrolls, contractors, and time off. Each area has its own methods and its own scopes, and writes in some areas pay people or move money.

Endpoint reference

Every Gusto Embedded API method.

Filter by method, access, or permission, or search any path. Select a row for version detail, rate limits, the related webhook event, and the source.

MethodEndpointWhat it doesAccessPermissionVersion

Employees

List a company's employees, read and update a single employee, and create a new one.4

Returns every employee for the company the token is scoped to. Read-only.

Acts onemployee
Permission (capability)employees:read
VersionAvailable since the API’s base version
Webhook eventemployee.created
Rate limitStandard limits apply

Read-only.

Acts onemployee
Permission (capability)employees:read
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Creating an employee needs the employees:manage scope, which is broader than employees:write.

Acts onemployee
Permission (capability)employees:manage
VersionAvailable since the API’s base version
Webhook eventemployee.created
Rate limitStandard limits apply

An update sends the resource version to guard against overwriting newer data; a stale version returns 409.

Acts onemployee
Permission (capability)employees:write
VersionAvailable since the API’s base version
Webhook eventemployee.updated
Rate limitStandard limits apply

Companies

Read a company's details and update its settings.2

Some extra fields, like home address, payroll admin, and signatory, need the employees:read, company_admin:read, or signatories:read scopes too. Read-only.

Acts oncompany
Permission (capability)companies:read
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

A company token is scoped to a single company and cannot reach another.

Acts oncompany
Permission (capability)companies:write
VersionAvailable since the API’s base version
Webhook eventcompany.updated
Rate limitStandard limits apply

Payrolls

List and read payrolls, calculate, prepare, and submit a payroll for processing.5

Filterable by processing status and payroll type. Read-only.

Acts onpayroll
Permission (capability)payrolls:read
VersionAvailable since the API’s base version
Webhook eventpayroll.processed
Rate limitStandard limits apply

Read-only.

Acts onpayroll
Permission (capability)payrolls:read
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Preparing a calculated payroll cancels its calculations so it can be edited again.

Acts onpayroll
Permission (capability)payrolls:write
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Asynchronous; a successful request returns 202 and the result arrives by webhook.

Acts onpayroll
Permission (capability)payrolls:write
VersionAvailable since the API’s base version
Webhook eventpayroll.calculated
Rate limitStandard limits apply

This is the call that actually pays people. Asynchronous; a successful request returns 202.

Acts onpayroll
Permission (capability)payrolls:run
VersionAvailable since the API’s base version
Webhook eventpayroll.submitted
Rate limitStandard limits apply

Contractors

List a company's contractors and read a single contractor.2

Read-only.

Acts oncontractor
Permission (capability)contractors:read
VersionAvailable since the API’s base version
Webhook eventcontractor.created
Rate limitStandard limits apply

Read-only.

Acts oncontractor
Permission (capability)contractors:read
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Pay schedules

List a company's pay schedules, read one, and create a new schedule.3

Read-only.

Acts onpay_schedule
Permission (capability)pay_schedules:read
VersionAvailable since the API’s base version
Webhook eventpay_schedule.created
Rate limitStandard limits apply

Read-only.

Acts onpay_schedule
Permission (capability)pay_schedules:read
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

A company can have multiple pay schedules.

Acts onpay_schedule
Permission (capability)pay_schedules:write
VersionAvailable since the API’s base version
Webhook eventpay_schedule.created
Rate limitStandard limits apply

Compensations

Read how much a job is paid through its compensation records.1

A compensation belongs to a job on an employee. Read-only.

Acts oncompensation
Permission (capability)compensations:read
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Company bank accounts

List a company's bank accounts, create one, and verify a new account.3

Read-only.

Acts oncompany_bank_account
Permission (capability)company_bank_accounts:read
VersionAvailable since the API’s base version
Webhook eventbank_account.created
Rate limitStandard limits apply

A new account starts with verification_status awaiting_deposits until it is verified.

Acts oncompany_bank_account
Permission (capability)company_bank_accounts:write
VersionAvailable since the API’s base version
Webhook eventbank_account.created
Rate limitStandard limits apply

Verifying moves the account to verified so it can fund payroll.

Acts oncompany_bank_account
Permission (capability)company_bank_accounts:write
VersionAvailable since the API’s base version
Webhook eventbank_account.updated
Rate limitStandard limits apply

Time off

List a company's time off requests and approve a request.2

Narrowable with start_date and end_date. Read-only.

Acts ontime_off_request
Permission (capability)time_off_requests:read
VersionAvailable since the API’s base version
Webhook eventtime_off_request.created
Rate limitStandard limits apply

Approval is a separate scope from time_off_requests:write, so an agent can read and edit requests without being able to approve them.

Acts ontime_off_request
Permission (capability)time_off_requests:approve
VersionAvailable since the API’s base version
Webhook eventtime_off_request.updated
Rate limitStandard limits apply

Departments

List a company's departments and create a new department.2

Read-only.

Acts ondepartment
Permission (capability)departments:read
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply

Employees and contractors are assigned to a department after it is created.

Acts ondepartment
Permission (capability)departments:write
VersionAvailable since the API’s base version
Webhook eventNone
Rate limitStandard limits apply
No endpoints match those filters.
Webhooks

Webhook events.

Gusto can notify an app or AI agent when something happens in a company, like a payroll being paid or an employee being onboarded. It posts an event to a subscribed URL, so an integration learns about activity without polling.

EventWhat it signalsTriggered by
Company.updatedFires when a company's details change. The Company subscription type also covers provisioned, onboarded, approved, suspended, and other lifecycle events./v1/companies/{company_id}
Employee.createdFires when an employee is created. The Employee subscription type also covers updated, onboarded, terminated, rehired, and deleted./v1/companies/{company_id}/employees
/v1/companies/{company_id}/employees
Employee.updatedFires when an employee's details are updated./v1/employees/{employee_id}
Contractor.createdFires when a contractor is created. The Contractor subscription type also covers updated, onboarded, deactivated, reactivated, and deleted./v1/companies/{company_id}/contractors
Payroll.calculatedFires when a payroll finishes calculating, delivering the asynchronous result of a calculate call./v1/companies/{company_id}/payrolls/{payroll_id}/calculate
Payroll.submittedFires when a payroll is submitted to be run./v1/companies/{company_id}/payrolls/{payroll_id}/submit
Payroll.processedFires when a payroll is processed. The Payroll subscription type also covers paid, reversed, cancelled, and processing_failed./v1/companies/{company_id}/payrolls
/v1/companies/{company_id}/payrolls/{payroll_id}/submit
PaySchedule.createdFires when a pay schedule is created. The PaySchedule subscription type also covers updated./v1/companies/{company_id}/pay_schedules
/v1/companies/{company_id}/pay_schedules
BankAccount.createdFires when a company bank account is created. The BankAccount subscription type also covers updated and deleted./v1/companies/{company_id}/bank_accounts
/v1/companies/{company_id}/bank_accounts
BankAccount.updatedFires when a company bank account changes, such as moving to verified./v1/companies/{company_id}/bank_accounts/{bank_account_uuid}/verify
TimeOffRequest.createdFires when a time off request is created. The TimeOffRequest subscription type also covers updated and deleted./v1/companies/{company_id}/time_off_requests
TimeOffRequest.updatedFires when a time off request changes, such as being approved./v1/time_off/requests/{time_off_request_uuid}/approve
No events match that search.
Rate limits & pagination

Rate limits, pagination & request size.

Gusto limits how fast an app or AI agent can call, through a per-token request quota measured over a rolling minute, returning a throttling response once the quota is spent.

Request rate

Gusto meters requests per token over a rolling sixty-second window, allowing 200 requests per minute for each application-user pairing. The window starts at the first call and resets sixty seconds later. Going over returns HTTP 429 with the rate_limit_exceeded category, and only on a 429 does Gusto send a Retry-After header saying how many seconds to wait. Gusto recommends webhooks over polling to stay within the quota.

Pagination

List endpoints page through the page parameter, which is 1-based, and the per parameter for page size. Page sizes vary by endpoint, for example payrolls default to 25 and cap at 100 per page. Responses carry pagination details in the X-Pagination headers, including the total count and the total number of pages.

Request size

Requests and responses are JSON. Page size is capped per endpoint, commonly at 100 records. There is no single documented payload size limit across the whole API.

Errors

Status codes & error handling.

The status codes an agent should handle, and what to do about each.

StatusCodeMeaningWhat to do
401invalid_tokenThe token is missing, invalid, or expired. A Gusto access token expires after two hours.Refresh the access token with the refresh token and client credentials, then retry.
403missing_oauth_scopesThe token is valid but lacks a scope the request needs, such as payrolls:read or employees:write.Grant the missing scope to the application in the Developer Portal, then retry.
404not_foundThe resource or endpoint does not exist in the requested API version, or the token cannot see it.Confirm the path, the company the token is scoped to, and the X-Gusto-API-Version header.
406invalid_api_versionThe X-Gusto-API-Version header is malformed. It must be a date in YYYY-MM-DD form.Send a valid dated version, such as 2026-06-15.
409invalid_resource_versionAn update used an out-of-date resource version, so the resource changed since it was last read.Refetch the resource to get its current version, then resend the update.
422invalid_attribute_valueValidation failed: a field is missing, malformed, or breaks a business rule. Related codes include missing_parameter, invalid_operation, and payroll_blocker.Read the errors in the response body, correct the named field, and resend.
429rate_limit_exceededThe request quota for the token was exceeded over the rolling minute.Wait for the Retry-After header's seconds, then retry with exponential backoff.
500internal_errorAn unexpected error on Gusto's side. Gusto's engineering team is notified automatically.Retry after a short delay, and contact Gusto support if it persists.
Versioning & freshness

Version history.

Gusto versions its API by date through the X-Gusto-API-Version header. The newest version is 2026-06-15, and an application has a default version it falls back to when no version header is sent.

Version history

What changed, and when

Latest version2026-06-15
2026-06-15Current version
Current version

The 2026-06-15 version is the newest dated release and carries backward-incompatible changes from the prior version. It is selected with the X-Gusto-API-Version header. Gusto ships backward-incompatible versions on a roughly quarterly cadence, and on this release the 2026-02-01 version entered its twelve-month deprecation, while 2024-04-01 reached end of support.

What changed
  • New current version with backward-incompatible changes from 2026-02-01
  • 2026-02-01 entered its twelve-month deprecation window
  • 2024-04-01 reached end of support, effective 15 June 2026
2026-02-01Requires migration
February 2026 release

A dated release that became the prior version when 2026-06-15 shipped, entering its twelve-month deprecation window at that point. Recent additions across these releases include the Payroll Digests API for multi-company monitoring, payroll.deleted webhooks, time off requests with admin approval, and contractor management flows.

What changed
  • Dev Assistant MCP server entered open beta
  • Payroll Digests API for multi-company monitoring
  • payroll.deleted webhook event added
2025-11-15Requires migration
November 2025 release

A dated release that entered its deprecation window when a newer version superseded it, following Gusto's twelve-month support policy of six months of full support and six months of critical fixes.

What changed
  • Backward-incompatible changes from the prior dated version
2025-06-15Requires migration
June 2025 release

A dated release in Gusto's quarterly cadence, also the version pinned by Gusto's official API clients. Each dated version is supported for twelve months after a newer one launches.

What changed
  • Backward-incompatible changes from the prior dated version
  • Version targeted by Gusto's official API client libraries
2024-04-01Requires migration
April 2024 release (end of support)

An earlier dated release that reached end of support effective 15 June 2026, when 2026-06-15 launched. After end of support a version no longer receives fixes.

What changed
  • Reached end of support on 15 June 2026

An integration can pin a version and move up on a schedule that suits it.

Gusto Embedded changelog ↗
Questions

Gusto Embedded API, answered.

Does the Gusto Embedded API use OAuth scopes?+
Yes. Each scope is named by resource and action, like employees:read or payrolls:write, and a token only reaches what its scopes allow. Scopes are granted to an application in the Developer Portal based on its embedded payroll use case, and a request outside them returns a 403 with the missing_oauth_scopes category. To change scopes after launch, a partner contacts their Gusto technical contact.
How long do access tokens last, and how do I refresh them?+
An access token expires two hours after it is issued, and a call with an expired token returns a 401 with the invalid_token category. The app exchanges its refresh token, with the client id and secret, for a new access token. Each refresh issues a new refresh token and revokes the previous one, so the latest refresh token must be stored each time.
Why can't one token see more than one company?+
Gusto uses a strict access model: each company a partner manages has its own access token that cannot reach any other company. An admin who manages several companies goes through the OAuth flow once per company, producing a separate token for each. This keeps one company's payroll data isolated from another's.
What are the rate limits?+
Each application is allowed 200 requests per minute for a given user, measured over a rolling sixty-second window that starts at the first call. Going over returns HTTP 429 with the rate_limit_exceeded category, and the 429 carries a Retry-After header with the seconds to wait. Gusto recommends subscribing to webhooks instead of polling to stay within the quota.
How does API versioning work?+
Versions are dated and selected with the X-Gusto-API-Version header, like 2026-06-15. Backward-incompatible versions are released about quarterly, and each is supported for twelve months after a newer one launches, with six months of full support and then six months of critical fixes. If no header is sent, the request uses the default version set for the application in the Developer Portal.
How do I receive events instead of polling?+
Gusto delivers webhooks. A subscription names the resource types to watch, such as Company, Employee, Payroll, or TimeOffRequest, and points at an HTTPS URL. The subscription is verified once with a token Gusto posts to the URL, and after that each delivery carries an X-Gusto-Signature header that is an HMAC of the payload keyed by that token, so the receiver can confirm it came from Gusto.
How do I run a payroll through the API?+
Running a payroll is a sequence: prepare the payroll to make it editable, calculate it to get the taxes and net pay, then submit it to actually run and pay. Calculate and submit are asynchronous and return a 202, with the result delivered by the Payroll.calculated and Payroll.processed webhooks. The submit call needs the payrolls:run scope, which is the step that moves money.
Related

More hr API guides for agents

What is Bollard AI?

Control what every AI agent can do in Gusto.

Bollard AI sits between a team's AI agents and Gusto. Grant each agent exactly the access it needs, read or write, resource by resource, and every call is checked and logged.

  • Set read, write, or full access per agent, never a shared Gusto token.
  • Denied by default, so an agent reaches only what has been explicitly allowed.
  • Every call recorded in plain English: who, what, where, and the decision.
Gusto
Payroll Agent
Read employees ResourceOffReadFull use
Run payroll ActionOffReadFull use
Time off requests ResourceOffReadFull use
Per-agent access, set in Bollard AI, not in Gusto