> ## Documentation Index
> Fetch the complete documentation index at: https://lava.so/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Gusto

> Gusto REST API access for reading payroll, employees, companies, departments, and pay schedules for a connected Gusto company.

Gusto REST API access for reading payroll, employees, companies, departments, and pay schedules for a connected Gusto company. Use when an agent needs employee records, payroll history, or pay schedules from Gusto. Routes through Pipedream Connect, so the user sees one Gusto consent screen that says "Pipedream wants access" and Lava holds no Gusto token.

5 example endpoints available through Lava's AI Gateway. See the [Gusto API docs](https://docs.gusto.com/app-integrations/reference/) for full documentation.

<Warning>This provider requires your own credentials — connect your API key or OAuth account before use.</Warning>

<Info>This is a **catch-all provider** — any valid URL under `https://api.gusto.com` is supported. Gusto REST API v1. Base [https://api.gusto.com](https://api.gusto.com), paths under /v1. The connected company UUID is NOT in the token, so resolve it first via GET /v1/me, then most reads are company-scoped: /v1/companies/\{company\_id}/employees, /v1/employees/\{employee\_id}, /v1/companies/\{company\_id}/payrolls, /v1/companies/\{company\_id}/pay\_schedules, /v1/companies/\{company\_id}/departments. Pagination is offset-based with page and per (per max 100). Pin the API version with an X-Gusto-API-Version header (e.g. 2024-04-01); omitting it uses the connection default. Money is returned as decimal strings. Auth is brokered by Pipedream, do not send an Authorization header. This provider is read-only: only GET requests are supported. The endpoints below are curated examples.</Info>

## Endpoints

### Get the authenticated user and associated company info. Use as a cheap auth probe and to resolve the company UUID (not present in the token) needed for company-scoped reads.

**GET** `https://api.gusto.com/v1/me` — Free

<Tabs>
  <Tab title="SDK">
    ```typescript theme={null}
    const data = await lava.gateway('https://api.gusto.com/v1/me', { method: 'GET' });
    ```
  </Tab>

  <Tab title="cURL">
    ```bash theme={null}
    curl "https://api.lava.so/v1/forward?u=https%3A%2F%2Fapi.gusto.com%2Fv1%2Fme" \
      -H "Authorization: Bearer $LAVA_SECRET_KEY"
    ```
  </Tab>
</Tabs>

### List employees (onboarding, active, terminated) for a company. Paginate with page and per (max 100).

**GET** `https://api.gusto.com/v1/companies/{company_id}/employees?page=1&per=50` — Free

<Tabs>
  <Tab title="SDK">
    ```typescript theme={null}
    const data = await lava.gateway('https://api.gusto.com/v1/companies/{company_id}/employees?page=1&per=50', { method: 'GET' });
    ```
  </Tab>

  <Tab title="cURL">
    ```bash theme={null}
    curl "https://api.lava.so/v1/forward?u=https%3A%2F%2Fapi.gusto.com%2Fv1%2Fcompanies%2F%7Bcompany_id%7D%2Femployees%3Fpage%3D1%26per%3D50" \
      -H "Authorization: Bearer $LAVA_SECRET_KEY"
    ```
  </Tab>
</Tabs>

### Get a single employee by UUID. Compensation fields require the compensations:read scope on the connection.

**GET** `https://api.gusto.com/v1/employees/{employee_id}` — Free

<Tabs>
  <Tab title="SDK">
    ```typescript theme={null}
    const data = await lava.gateway('https://api.gusto.com/v1/employees/{employee_id}', { method: 'GET' });
    ```
  </Tab>

  <Tab title="cURL">
    ```bash theme={null}
    curl "https://api.lava.so/v1/forward?u=https%3A%2F%2Fapi.gusto.com%2Fv1%2Femployees%2F%7Bemployee_id%7D" \
      -H "Authorization: Bearer $LAVA_SECRET_KEY"
    ```
  </Tab>
</Tabs>

### List payrolls for a company (defaults to processed regular payrolls for the past 6 months).

**GET** `https://api.gusto.com/v1/companies/{company_id}/payrolls` — Free

<Tabs>
  <Tab title="SDK">
    ```typescript theme={null}
    const data = await lava.gateway('https://api.gusto.com/v1/companies/{company_id}/payrolls', { method: 'GET' });
    ```
  </Tab>

  <Tab title="cURL">
    ```bash theme={null}
    curl "https://api.lava.so/v1/forward?u=https%3A%2F%2Fapi.gusto.com%2Fv1%2Fcompanies%2F%7Bcompany_id%7D%2Fpayrolls" \
      -H "Authorization: Bearer $LAVA_SECRET_KEY"
    ```
  </Tab>
</Tabs>

### List the pay schedules for a company (pay frequency and period dates).

**GET** `https://api.gusto.com/v1/companies/{company_id}/pay_schedules` — Free

<Tabs>
  <Tab title="SDK">
    ```typescript theme={null}
    const data = await lava.gateway('https://api.gusto.com/v1/companies/{company_id}/pay_schedules', { method: 'GET' });
    ```
  </Tab>

  <Tab title="cURL">
    ```bash theme={null}
    curl "https://api.lava.so/v1/forward?u=https%3A%2F%2Fapi.gusto.com%2Fv1%2Fcompanies%2F%7Bcompany_id%7D%2Fpay_schedules" \
      -H "Authorization: Bearer $LAVA_SECRET_KEY"
    ```
  </Tab>
</Tabs>

## Next Steps

<CardGroup cols={2}>
  <Card title="All Providers" icon="grid" href="/gateway/supported-providers">
    Browse all supported AI providers
  </Card>

  <Card title="Forward Proxy" icon="route" href="/gateway/forward-proxy">
    Learn how to construct proxy URLs and authenticate requests
  </Card>
</CardGroup>
