Skip to main content

EmployeeListFlow

Hub for viewing and managing all employees, including onboarding new ones.

Remarks

Drop-in entry point for managing all employees in a company. Begins on the management employee list and routes into DashboardFlow, TerminationFlow, or OnboardingExecutionFlow based on the action the admin invokes on a row (or the "Add employee" CTA). A "Back to employees" header is added to each sub-flow so the admin can return to the list at any time.

The flow forwards every event emitted by its blocks to onEvent; see the events table on each block for the full set of events and payloads observable from this flow.

Example

App.tsx
import { EmployeeManagement } from '@gusto/embedded-react-sdk'

function MyApp() {
return (
<EmployeeManagement.EmployeeListFlow
companyId="a007e1ab-3595-43c2-ab4b-af7a5af2e365"
onEvent={() => {}}
/>
)
}

EmployeeListFlowProps

Props for EmployeeListFlow.

PropertyTypeDescription
companyIdstringThe associated company identifier.
onEventOnEventType<EventType, unknown>Callback invoked each time the component emits an event — user interactions, successful API responses, step transitions, or errors. Receives the event type constant and an optional payload whose shape varies by event. See the Event Handling guide and each component's event table for the full list of emitted events.

Inherits children, className, defaultValues, dictionary, FallbackComponent, LoaderComponent from BaseComponentInterface.

Sub-components

ComponentDescription
EmployeeListRenders a tabbed list of a company's employees split across Active, Onboarding, and Dismissed tabs, with per-row actions tailored to each tab (edit, delete, dismiss, rehire).
DashboardFlowHub for viewing and managing a single employee's profile, pay, and documents.
TerminationFlowGuided flow to terminate an employee and arrange their final paycheck.
EmployeeOnboarding.OnboardingExecutionFlowGuided flow to onboard an employee.

Step flow

The flow rests on the management employee list and routes into one of three sub-flows based on the row action invoked (or the "Add employee" CTA):

  • Edit (employee/update) → DashboardFlow
  • Dismiss (employee/dismiss) → TerminationFlow
  • Add employee (employee/create) → OnboardingExecutionFlow

Each sub-flow is given a "Back to employees" header that emits employee/returnToList to come back to the list. The onboarding sub-flow also returns to the list when it completes (company/employees) or is canceled (CANCEL).

The list itself is tabbed into Active, Onboarding, and Dismissed employees, with per-row actions tailored to each tab (edit, delete, dismiss, rehire).

Endpoints

MethodPath
GET/v1/companies/:companyId/employees
POST/v1/companies/:companyId/employees
GET/v1/companies/:companyId/federal_tax_details
GET/v1/companies/:companyId/locations
GET/v1/companies/:companyId/pay_periods
GET/v1/companies/:companyId/pay_periods/unprocessed_termination_pay_periods
GET/v1/companies/:companyId/pay_schedules
GET/v1/companies/:companyId/payrolls
POST/v1/companies/:companyId/payrolls
GET/v1/companies/:companyId/payrolls/:payrollId
GET/v1/companies/:companyUuid/payrolls/blockers
POST/v1/companies/:companyUuid/payrolls/skip
GET/v1/companies/:companyUuid/wire_in_requests
PUT/v1/compensations/:compensationId
DELETE/v1/compensations/:compensationId
GET/v1/employees/:employeeId
PUT/v1/employees/:employeeId
DELETE/v1/employees/:employeeId
GET/v1/employees/:employeeId/garnishments
POST/v1/employees/:employeeId/garnishments
GET/v1/employees/:employeeId/home_addresses
POST/v1/employees/:employeeId/home_addresses
GET/v1/employees/:employeeId/jobs
POST/v1/employees/:employeeId/jobs
PUT/v1/employees/:employeeId/onboarding_documents_config
GET/v1/employees/:employeeId/onboarding_status
PUT/v1/employees/:employeeId/onboarding_status
GET/v1/employees/:employeeId/terminations
POST/v1/employees/:employeeId/terminations
DELETE/v1/employees/:employeeId/terminations
GET/v1/employees/:employeeId/work_addresses
POST/v1/employees/:employeeId/work_addresses
GET/v1/employees/:employeeUuid/federal_taxes
PUT/v1/employees/:employeeUuid/federal_taxes
GET/v1/employees/:employeeUuid/state_taxes
PUT/v1/employees/:employeeUuid/state_taxes
PUT/v1/garnishments/:garnishmentId
GET/v1/garnishments/child_support
GET/v1/home_addresses/:homeAddressUuid
PUT/v1/home_addresses/:homeAddressUuid
PUT/v1/jobs/:jobId
DELETE/v1/jobs/:jobId
POST/v1/jobs/:jobId/compensations
GET/v1/locations/:locationUuid/minimum_wages
PUT/v1/terminations/:employeeId
GET/v1/work_addresses/:workAddressUuid
PUT/v1/work_addresses/:workAddressUuid