Blocks
Address
Management surface for viewing and editing a contractor's mailing address after onboarding.
Remarks
Drives the read-view card and edit form via an internal state machine.
Emits events on the supplied onEvent handler when the user requests an
edit, saves changes, or cancels.
AddressProps
Props for Address.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementAddress>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/address/editRequested | Fired when the user clicks Edit on the read-view card | { contractorId: string } |
contractor/management/address/updated | Fired after the address is successfully saved | APIModels.ContractorAddress |
contractor/management/address/editCancelled | Fired when the user cancels editing | — |
Endpoints
| Method | Path |
|---|---|
| GET | /v1/contractors/:contractorUuid |
| GET | /v1/contractors/:contractorUuid/address |
| PUT | /v1/contractors/:contractorUuid/address |
AddressCard
Read-only card showing a contractor's mailing address with an Edit action.
Remarks
Standalone card that fetches its own data. Emits an event when the user clicks Edit so the parent can switch to the edit form. The card does not render success or error alerts itself — alert presentation is the surrounding surface's responsibility.
AddressCardProps
Props for AddressCard.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<EventType, unknown> | Event handler fired when the user requests to edit the address. |
LoaderComponent? | LoaderComponentType | Custom loading indicator rendered while this component's async data is fetching. Overrides the indicator configured on GustoProvider for this instance only. |
Events
| Event | Description | Data |
|---|---|---|
contractor/management/address/editRequested | Fired when the user clicks the Edit button | { contractorId: string } |
AddressEditForm
Standalone edit form for a contractor's mailing address.
Remarks
Renders fields for street address, city, state, and ZIP code — all required — and shows a success alert when the save completes. Save and Cancel both emit events so the parent can return to the read view.
AddressEditFormProps
Props for AddressEditForm.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementAddress>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/address/updated | Fired after the address is successfully saved | The updated ContractorAddress entity |
contractor/management/address/editCancelled | Fired when the user clicks Cancel | — |
Compensation
Management surface for viewing and editing a contractor's compensation after onboarding.
Remarks
Drives the read-view card and edit form via an internal state machine.
Emits events on the supplied onEvent handler when the user requests an
edit, saves changes, or cancels.
CompensationProps
Props for Compensation.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementCompensation>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/compensation/editRequested | Fired when the user clicks Edit on the read-view card | { contractorId: string } |
contractor/management/compensation/updated | Fired after compensation is successfully saved | APIModels.Contractor |
contractor/management/compensation/editCancelled | Fired when the user cancels editing | — |
Endpoints
| Method | Path |
|---|---|
| GET | /v1/contractors/:contractorUuid |
| PUT | /v1/contractors/:contractorUuid |
CompensationCard
Read-only card showing a contractor's compensation type and rate with an Edit action.
Remarks
Standalone card that fetches its own data. Emits an event when the user clicks Edit so the parent can switch to the edit form. The card does not render success or error alerts itself — alert presentation is the surrounding surface's responsibility.
CompensationCardProps
Props for CompensationCard.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<EventType, unknown> | Event handler fired when the user requests to edit compensation. |
LoaderComponent? | LoaderComponentType | Custom loading indicator rendered while this component's async data is fetching. Overrides the indicator configured on GustoProvider for this instance only. |
Events
| Event | Description | Data |
|---|---|---|
contractor/management/compensation/editRequested | Fired when the user clicks the Edit button | { contractorId: string } |
CompensationEditForm
Standalone edit form for a contractor's compensation type and rate.
Remarks
Renders a Fixed/Hourly compensation-type selector and, when Hourly, an hourly-rate field. Save and Cancel both emit events so the parent can return to the read view.
CompensationEditFormProps
Props for CompensationEditForm.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementCompensation>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/compensation/updated | Fired after compensation is successfully saved | The updated Contractor entity |
contractor/management/compensation/editCancelled | Fired when the user clicks Cancel | — |
ContractorList
Renders a tabbed list of a company's contractors split across Active, Onboarding, and Dismissed tabs, with per-row actions tailored to each tab (edit, delete, view details, dismiss, rehire, cancel a scheduled dismissal or rehire).
ManagementContractorListProps
Props for ManagementContractorList.
| Property | Type | Description |
|---|---|---|
companyId | string | The associated company identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementContractorList>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
initialTab? | ContractorTab | Tab to render first: Active, Onboarding, or Dismissed. Defaults to 'active'. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/create | Fired when the user clicks "Add contractor". | — |
contractor/update | Fired when the user selects "Edit"/"Review" on an onboarding-tab row. | { contractorId: string } |
contractor/view | Fired when the user selects "View details" on an active or dismissed row. | { contractorId: string } |
contractor/deleted | Fired after an onboarding-tab row's "Remove" action completes. | { contractorId: string } |
contractor/selfOnboarding/cancelled | Fired after the "Cancel self-onboarding" action updates a contractor's onboarding status. | The updated contractorOnboardingStatus returned by the API. |
contractor/dismiss | Fired when the user selects "Dismiss" on an active row. No mutation is performed by this component. | { contractorId: string } |
contractor/rehire | Fired when the user selects "Rehire" on a dismissed row. No mutation is performed by this component. | { contractorId: string } |
contractor/dismissal/cancelled | Fired after a scheduled dismissal is cancelled via the confirm dialog. | { contractorId: string } |
contractor/rehire/cancelled | Fired after a scheduled rehire is cancelled via the confirm dialog. | { contractorId: string } |
Endpoints
CreatePayment
Form for creating a contractor payment group, including date selection, per-contractor edits, preview, and submission blockers.
Remarks
Active, fully onboarded contractors are listed for the given company. Hours and bonuses apply to hourly contractors; wages apply to fixed contractors; reimbursements apply to both. The form previews the payment group before final submission and surfaces Fast ACH submission blockers when applicable.
Features:
- Payment date selection — choose the payment date; a notice shows the resulting payment speed.
- Per-contractor editing — edit hours and bonus (hourly contractors), wage (fixed contractors), and reimbursement (all) in a modal, with a running total.
- Payment method — choose Check or Direct Deposit per contractor.
- Live totals — wage, bonus, reimbursement, and overall totals update as amounts change.
- Preview before submit — review per-contractor amounts, debit amount, debit account, debit date, contractor pay date, and the submission deadline before finalizing.
- Submission blockers — Fast ACH blockers surface inline with selectable unblock options (wire transfer or slower direct deposit); submission stays disabled until every blocker is resolved.
Example
import { ContractorManagement } from '@gusto/embedded-react-sdk'
function CreateContractorPayment() {
return (
<ContractorManagement.CreatePayment
companyId="a007e1ab-3595-43c2-ab4b-af7a5af2e365"
onEvent={() => {}}
/>
)
}
CreatePaymentProps
Props for CreatePayment.
| Property | Type | Description |
|---|---|---|
companyId | string | UUID of the company for which to create a contractor payment group. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorPaymentsCreatePayment>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/payments/edit | The edit modal was opened for a contractor. | — |
contractor/payments/update | A contractor's payment values were updated locally. | The updated form values (hours, wage, bonus, reimbursement, payment method, etc.). |
contractor/payments/preview | The preview API call succeeded. | The contractor payment group preview response. |
contractor/payments/backToEdit | The user returned from preview to continue editing. | — |
contractor/payments/created | The payment group was successfully created. | The created contractor payment group response. |
contractor/payments/rfi/respond | The user clicked to respond to a payment blocker. | — |
Endpoints
Dashboard
Contractor management dashboard summarizing a single contractor's basic details, pay, and documents.
Remarks
Renders a tabbed overview of the contractor, wrapped in the SDK's standard error and suspense
boundaries. The active tab may be controlled via selectedTab or left uncontrolled, in which
case it defaults to details. Each tab composes the read-only section cards listed below.
DashboardProps
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorDashboard>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
selectedTab? | DashboardTab | The currently active tab. Defaults to 'details' when uncontrolled. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Components
DocumentsCard
Standalone read-only "Documents" card.
Remarks
Fetches its own data via useContractorDocumentsList and renders a table of the contractor's forms with a per-row "View" action that opens the document's PDF in a new tab. Read-only — signing happens during contractor onboarding, not from this surface.
DocumentsCardProps
Props for DocumentsCard.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<EventType, unknown> | Event handler fired when the user views a document. |
LoaderComponent? | LoaderComponentType | Custom loading indicator rendered while this component's async data is fetching. Overrides the indicator configured on GustoProvider for this instance only. |
Events
| Event | Description | Data |
|---|---|---|
contractor/management/documents/card/viewRequested | Fired when a document row's "View" button is clicked, before the PDF is fetched | { contractorId: string, documentUuid: string } |
contractor/management/documents/card/viewed | Fired after the PDF is fetched and opened in a new tab | { contractorId: string, documentUuid: string } |
Endpoints
PaymentHistory
Displays a contractor payment group, including each individual contractor payment, with actions to view details or cancel.
Remarks
Features:
- Payment group overview — debit date and group context in the header.
- Per-contractor table — contractor, wage type, payment method, hours, wage, bonus, reimbursement, and total for each payment.
- Row actions — view an individual contractor payment, or cancel it when the payment is cancelable.
Example
import { ContractorManagement } from '@gusto/embedded-react-sdk'
<ContractorManagement.PaymentHistory
paymentId="payment-group-uuid"
onEvent={() => {}}
/>
PaymentHistoryProps
Props for PaymentHistory.
| Property | Type | Description |
|---|---|---|
onEvent | OnEventType<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. |
paymentId | string | UUID of the contractor payment group to display. |
dictionary? | Record<"en", DeepPartial<ContractorPaymentsPaymentHistory>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/payments/view/details | A row's view-details action was triggered. | { contractor: Contractor | undefined, paymentGroupId: string } — contractor is undefined if the contractor UUID is not found in the loaded list |
contractor/payments/cancel | An individual contractor payment was successfully canceled. | { paymentId: string } — the individual contractor payment UUID, not the payment group UUID passed as paymentId prop |
Endpoints
| Method | Path |
|---|---|
| DELETE | /v1/companies/:companyId/contractor_payments/:contractorPaymentId |
| GET | /v1/companies/:companyUuid/contractors |
| GET | /v1/contractor_payment_groups/:contractorPaymentGroupUuid |
PaymentMethod
Management surface for viewing and editing a contractor's payment method after onboarding.
Remarks
Drives the read-view card and bank-account form via an internal state
machine. Emits events on the supplied onEvent handler when the user
requests to add or edit a bank account, saves changes, or cancels.
PaymentMethodProps
Props for PaymentMethod.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementPaymentMethod>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/paymentMethod/card/addRequested | Fired when the user clicks "Add bank account" on the read-view card | { contractorId: string } |
contractor/management/paymentMethod/card/editRequested | Fired when the user chooses "Edit" from the bank account row menu | { contractorId: string } |
contractor/management/paymentMethod/card/removed | Fired after the bank account is removed and the payment method reverts to Check | APIModels.ContractorPaymentMethod |
contractor/management/paymentMethod/bankForm/submitted | Fired after the bank-account form is successfully saved | APIModels.ContractorBankAccount |
contractor/management/paymentMethod/bankForm/cancelled | Fired when the user cancels the bank-account form | — |
Endpoints
PaymentMethodCard
Standalone "Payment" card showing a contractor's payment method.
Remarks
Fetches its own data and emits the management block's scoped events when the user clicks the card's CTAs or confirms removing the bank account. The card has no alert API — alert rendering is the orchestrator's responsibility.
PaymentMethodCardProps
Props for PaymentMethodCard.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<EventType, unknown> | Event handler fired on card interactions. |
LoaderComponent? | LoaderComponentType | Custom loading indicator rendered while this component's async data is fetching. Overrides the indicator configured on GustoProvider for this instance only. |
Events
| Event | Description | Data |
|---|---|---|
contractor/management/paymentMethod/card/addRequested | Fired when the user clicks "Add bank account" | { contractorId: string } |
contractor/management/paymentMethod/card/editRequested | Fired when the user chooses "Edit" from the bank account row menu | { contractorId: string } |
contractor/management/paymentMethod/card/removed | Fired after the bank account is removed and the payment method reverts to Check | The updated ContractorPaymentMethod entity |
PaymentMethodEditForm
Standalone bank-account form for a contractor's payment method.
Remarks
Renders fields for the account nickname, routing number, account number, and account type. Saving creates the bank account, which updates the contractor's payment method to Direct Deposit as a server-side effect. Save and Cancel both emit events so the parent can return to the read view.
PaymentMethodEditFormProps
Props for PaymentMethodEditForm.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementPaymentMethod>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/paymentMethod/bankForm/submitted | Fired after the bank account is successfully saved | The created ContractorBankAccount entity |
contractor/management/paymentMethod/bankForm/cancelled | Fired when the user clicks Cancel | — |
PaymentsList
Displays a list of contractor payment groups for a company.
Supports viewing payment history, creating new payments, and filtering by date range. Surfaces alerts for pending information requests and wire transfer requirements.
PaymentsListProps
Props for PaymentsList.
| Property | Type | Description |
|---|---|---|
companyId | string | UUID of the company whose contractor payment groups should be listed. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorPaymentsPaymentsList>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/payments/create | User chooses to create a new payment | — |
contractor/payments/view | User selects a payment group to view | { paymentId: string } |
contractor/payments/rfi/respond | User clicks to respond to an information request alert | — |
Endpoints
| Method | Path |
|---|---|
| GET | /v1/companies/:companyId/contractor_payment_groups |
| GET | /v1/companies/:companyUuid/information_requests |
PaymentStatement
Displays a single contractor's payment statement within a payment group, including wage breakdown, bonuses, reimbursements, and a receipt card for funded direct-deposit payments.
PaymentStatementProps
Props for PaymentStatement.
| Property | Type | Description |
|---|---|---|
contractorUuid | string | UUID of the contractor whose payment within the group is being displayed. |
onEvent | OnEventType<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. |
paymentGroupId | string | UUID of the contractor payment group the statement belongs to. |
dictionary? | Record<"en", DeepPartial<ContractorPaymentsPaymentStatement>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Endpoints
| Method | Path |
|---|---|
| GET | /v1/companies/:companyUuid/contractors |
| GET | /v1/contractor_payment_groups/:contractorPaymentGroupUuid |
| GET | /v1/contractor_payments/:contractorPaymentUuid/receipt |
PaymentSummary
Displays a summary of a created contractor payment group, including payment totals, debit information, contractor details, and wire transfer instructions when required.
Remarks
Features:
- Success confirmation — confirms the number of payments scheduled.
- Payment summary — total amount, debit amount, debit account, debit date, and contractor pay date, plus a per-contractor breakdown.
- Debit account — shows the company bank account used for the debit.
- Wire transfer confirmation — when a wire is required, surfaces the wire-details confirmation workflow.
PaymentSummaryProps
Props for PaymentSummary.
| Property | Type | Description |
|---|---|---|
companyId | string | UUID of the company that owns the payment group. |
onEvent | (type: EventType, data?: unknown) => void | Callback invoked when a flow event occurs, e.g. when the user exits. |
paymentGroupId | string | UUID of the contractor payment group to summarize. |
Events
| Event | Description | Data |
|---|---|---|
contractor/payments/exit | User completes the payment flow. | — |
Endpoints
| Method | Path |
|---|---|
| GET | /v1/companies/:companyId/bank_accounts |
| GET | /v1/companies/:companyUuid/contractors |
| GET | /v1/contractor_payment_groups/:contractorPaymentGroupUuid |
Profile
Management surface for viewing and editing a contractor's basic profile details after onboarding.
Remarks
Drives the read-view card and edit form via an internal state machine.
Emits events on the supplied onEvent handler when the user requests an
edit, saves changes, or cancels.
ProfileProps
Props for Profile.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementProfile>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/profile/editRequested | Fired when the user clicks Edit on the read-view card | { contractorId: string } |
contractor/management/profile/updated | Fired after the profile is successfully saved | APIModels.Contractor |
contractor/management/profile/editCancelled | Fired when the user cancels editing | — |
Endpoints
| Method | Path |
|---|---|
| POST | /v1/companies/:companyUuid/contractors |
| GET | /v1/contractors/:contractorUuid |
| PUT | /v1/contractors/:contractorUuid |
ProfileCard
Read-only card showing a contractor's basic profile details with an Edit action.
Remarks
Standalone card that fetches its own data. Emits an event when the user clicks Edit so the parent can switch to the edit form. The card does not render success or error alerts itself — alert presentation is the surrounding surface's responsibility.
ProfileCardProps
Props for ProfileCard.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<EventType, unknown> | Event handler fired when the user requests to edit the profile. |
LoaderComponent? | LoaderComponentType | Custom loading indicator rendered while this component's async data is fetching. Overrides the indicator configured on GustoProvider for this instance only. |
Events
| Event | Description | Data |
|---|---|---|
contractor/management/profile/editRequested | Fired when the user clicks the Edit button | { contractorId: string } |
ProfileEditForm
Standalone edit form for a contractor's basic profile details.
Remarks
Renders fields for the contractor's name (or business name), start date, tax ID (SSN or EIN, depending on the contractor's type), and email — all required on update except tax ID and email — and shows a success alert when the save completes. An SSN/EIN already on file renders as a locked, masked value with a "Change" action rather than a blank editable input. Save and Cancel both emit events so the parent can return to the read view.
ProfileEditFormProps
Props for ProfileEditForm.
| Property | Type | Description |
|---|---|---|
contractorId | string | The associated contractor identifier. |
onEvent | OnEventType<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. |
dictionary? | Record<"en", DeepPartial<ContractorManagementProfile>> | Overrides for the component's i18n strings. Supply a partial object whose keys match the component's resource namespace — any omitted keys fall back to SDK defaults. See the Translation guide for details. |
Inherits children, className, defaultValues, FallbackComponent, LoaderComponent from BaseComponentInterface.
Events
| Event | Description | Data |
|---|---|---|
contractor/management/profile/updated | Fired after the contractor profile is successfully saved | APIModels.Contractor |
contractor/management/profile/editCancelled | Fired when the user clicks Cancel | — |
Utility types
ContractorTab
ContractorTab =
"active"|"onboarding"|"dismissed"
The tab currently selected on ManagementContractorList.
DashboardTab
DashboardTab =
"details"|"pay"|"documents"