diff --git a/example/src/ReviewOnboardingStep.tsx b/example/src/ReviewOnboardingStep.tsx index 3a803a18d..b07fc1836 100644 --- a/example/src/ReviewOnboardingStep.tsx +++ b/example/src/ReviewOnboardingStep.tsx @@ -230,6 +230,7 @@ export const ReviewOnboardingStep = ({ OnboardingInvite, BackButton, ReviewStep: ReviewStepCreditRisk, + PreOnboardingRequirements, } = components; return ( @@ -279,6 +280,138 @@ export const ReviewOnboardingStep = ({ > Edit Benefits + +

Pre-Onboarding Requirements

+ {PreOnboardingRequirements && ( + + | undefined; + isLoadingRequirements: boolean; + documentPreview: + | { + id: string; + employment_id: string; + document_type: string; + status: string; + pdf_url?: string; + created_at: string; + } + | undefined; + onCreateDocument: () => Promise; + onSignDocument: (signature: string) => Promise; + isCreatingDocument: boolean; + isSigning: boolean; + }) => ( +
+ {isLoadingRequirements ? ( +

Loading requirements...

+ ) : ( + <> +

Requirements List

+ {requirements?.map( + (req: { + id: string; + title: string; + description: string; + status: string; + }) => ( +
+ {req.title} +

{req.description}

+ + Status: {req.status} + +
+ ), + )} + + {!documentPreview && ( + + )} + + {documentPreview && ( +
+

Document Preview

+

Document ID: {documentPreview.id}

+

Status: {documentPreview.status}

+ {documentPreview.pdf_url && ( +

+ PDF URL:{' '} + + {documentPreview.pdf_url} + +

+ )} + +
+ )} + + )} +
+ )} + /> + )} +

Review

0) { + console.log( + `\n✓ Successfully removed /api/eor prefix from ${totalReplacements} URLs`, + ); + } else { + console.log('\n✓ No /api/eor prefixes found'); + } +} + +cleanupApiEorPrefix(); diff --git a/src/client/client.gen.ts b/src/client/client.gen.ts index 5f44e28fd..0e7e8e27a 100644 --- a/src/client/client.gen.ts +++ b/src/client/client.gen.ts @@ -20,6 +20,4 @@ export type CreateClientConfig = ( override?: Config, ) => Config & T>; -export const client = createClient( - createConfig({ baseUrl: 'https://gateway.remote.com/' }), -); +export const client = createClient(createConfig()); diff --git a/src/client/index.ts b/src/client/index.ts index d63701e37..3b067e362 100644 --- a/src/client/index.ts +++ b/src/client/index.ts @@ -96,6 +96,8 @@ export { getV1LeavePoliciesSummaryEmploymentId, getV1Offboardings, getV1OffboardingsId, + getV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsId, + getV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirements, getV1PayItems, getV1PayrollCalendars, getV1PayrollCalendarsCycle, @@ -125,6 +127,12 @@ export { getV1TimesheetsId, getV1TravelLetterRequests, getV1TravelLetterRequestsId, + getV1WdGphPayDetail, + getV1WdGphPayDetailData, + getV1WdGphPayProcessingFeature, + getV1WdGphPayProgress, + getV1WdGphPaySummary, + getV1WdGphPayVariance, getV1WebhookEvents, getV1WorkAuthorizationRequests, getV1WorkAuthorizationRequestsId, @@ -156,6 +164,7 @@ export { patchV2EmploymentsEmploymentId, patchV2EmploymentsEmploymentId2, postAuthOauth2Token, + postAuthOauth2Token2, postV1BenefitRenewalRequestsBenefitRenewalRequestId, postV1BulkEmploymentJobs, postV1CancelOnboardingEmploymentId, @@ -198,6 +207,8 @@ export { postV1IncentivesRecurring, postV1MagicLink, postV1Offboardings, + postV1OnboardingEmploymentsEmploymentIdPreOnboardingDocuments, + postV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSign, postV1PayItemsBulk, postV1ProbationCompletionLetter, postV1ProbationExtensions, @@ -217,6 +228,7 @@ export { postV1TimeoffTimeoffIdCancelRequestApprove, postV1TimeoffTimeoffIdCancelRequestDecline, postV1TimeoffTimeoffIdDecline, + postV1Timesheets, postV1TimesheetsTimesheetIdApprove, postV1TimesheetsTimesheetIdSendBack, postV1WebhookCallbacks, @@ -407,6 +419,7 @@ export type { CreateGeneralCustomFieldDefinitionParams, CreateOffboardingParams, CreateOneTimeIncentiveParams, + CreatePreOnboardingDocumentResponse, CreatePricingPlanParams, CreatePricingPlanResponse, CreatePricingPlanWithoutPartnerTemplateParams, @@ -531,6 +544,7 @@ export type { ExpenseResponse, File, FileParams, + FindOrCreatePreOnboardingDocumentParams, ForbiddenResponse, GenericFile, GetV1BenefitOffersCountrySummariesData, @@ -981,6 +995,16 @@ export type { GetV1OffboardingsIdResponses, GetV1OffboardingsResponse, GetV1OffboardingsResponses, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdData, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdError, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdErrors, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponse, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponses, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsData, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsError, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsErrors, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponse, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponses, GetV1PayItemsData, GetV1PayItemsError, GetV1PayItemsErrors, @@ -1124,6 +1148,36 @@ export type { GetV1TravelLetterRequestsIdResponses, GetV1TravelLetterRequestsResponse, GetV1TravelLetterRequestsResponses, + GetV1WdGphPayDetailData, + GetV1WdGphPayDetailDataData, + GetV1WdGphPayDetailDataError, + GetV1WdGphPayDetailDataErrors, + GetV1WdGphPayDetailDataResponse, + GetV1WdGphPayDetailDataResponses, + GetV1WdGphPayDetailError, + GetV1WdGphPayDetailErrors, + GetV1WdGphPayDetailResponse, + GetV1WdGphPayDetailResponses, + GetV1WdGphPayProcessingFeatureData, + GetV1WdGphPayProcessingFeatureError, + GetV1WdGphPayProcessingFeatureErrors, + GetV1WdGphPayProcessingFeatureResponse, + GetV1WdGphPayProcessingFeatureResponses, + GetV1WdGphPayProgressData, + GetV1WdGphPayProgressError, + GetV1WdGphPayProgressErrors, + GetV1WdGphPayProgressResponse, + GetV1WdGphPayProgressResponses, + GetV1WdGphPaySummaryData, + GetV1WdGphPaySummaryError, + GetV1WdGphPaySummaryErrors, + GetV1WdGphPaySummaryResponse, + GetV1WdGphPaySummaryResponses, + GetV1WdGphPayVarianceData, + GetV1WdGphPayVarianceError, + GetV1WdGphPayVarianceErrors, + GetV1WdGphPayVarianceResponse, + GetV1WdGphPayVarianceResponses, GetV1WebhookEventsData, GetV1WebhookEventsError, GetV1WebhookEventsErrors, @@ -1171,6 +1225,7 @@ export type { IncentiveResponse, IndexContractDocuments, IndexContractDocumentsResponse, + IndexPreOnboardingDocumentRequirementsResponse, IntegrationsScimErrorResponse, IntegrationsScimGroup, IntegrationsScimGroupListResponse, @@ -1419,6 +1474,11 @@ export type { PayVarianceResponse, PeriodProperties, PersonalDetails, + PostAuthOauth2Token2Data, + PostAuthOauth2Token2Error, + PostAuthOauth2Token2Errors, + PostAuthOauth2Token2Response, + PostAuthOauth2Token2Responses, PostAuthOauth2TokenData, PostAuthOauth2TokenError, PostAuthOauth2TokenErrors, @@ -1633,6 +1693,16 @@ export type { PostV1OffboardingsErrors, PostV1OffboardingsResponse, PostV1OffboardingsResponses, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsData, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsError, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsErrors, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignData, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignError, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignErrors, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponse, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponses, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponse, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponses, PostV1PayItemsBulkData, PostV1PayItemsBulkError, PostV1PayItemsBulkErrors, @@ -1727,6 +1797,11 @@ export type { PostV1TimeoffTimeoffIdDeclineErrors, PostV1TimeoffTimeoffIdDeclineResponse, PostV1TimeoffTimeoffIdDeclineResponses, + PostV1TimesheetsData, + PostV1TimesheetsError, + PostV1TimesheetsErrors, + PostV1TimesheetsResponse, + PostV1TimesheetsResponses, PostV1TimesheetsTimesheetIdApproveData, PostV1TimesheetsTimesheetIdApproveError, PostV1TimesheetsTimesheetIdApproveErrors, @@ -1752,6 +1827,7 @@ export type { PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors, PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponse, PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses, + PreOnboardingDocumentRequirement, Price, PricingPlan, PricingPlanDetails, @@ -1891,6 +1967,7 @@ export type { SentBackTimesheetResponse, ShortId, ShowLegalEntityAdministrativeDetailsResponse, + ShowPreOnboardingDocumentResponse, Signatory, SignatoryStatus, SignatoryType, diff --git a/src/client/sdk.gen.ts b/src/client/sdk.gen.ts index 1599ea06d..548175df6 100644 --- a/src/client/sdk.gen.ts +++ b/src/client/sdk.gen.ts @@ -292,6 +292,12 @@ import type { GetV1OffboardingsIdErrors, GetV1OffboardingsIdResponses, GetV1OffboardingsResponses, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdData, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdErrors, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponses, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsData, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsErrors, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponses, GetV1PayItemsData, GetV1PayItemsErrors, GetV1PayItemsResponses, @@ -378,6 +384,24 @@ import type { GetV1TravelLetterRequestsIdErrors, GetV1TravelLetterRequestsIdResponses, GetV1TravelLetterRequestsResponses, + GetV1WdGphPayDetailData, + GetV1WdGphPayDetailDataData, + GetV1WdGphPayDetailDataErrors, + GetV1WdGphPayDetailDataResponses, + GetV1WdGphPayDetailErrors, + GetV1WdGphPayDetailResponses, + GetV1WdGphPayProcessingFeatureData, + GetV1WdGphPayProcessingFeatureErrors, + GetV1WdGphPayProcessingFeatureResponses, + GetV1WdGphPayProgressData, + GetV1WdGphPayProgressErrors, + GetV1WdGphPayProgressResponses, + GetV1WdGphPaySummaryData, + GetV1WdGphPaySummaryErrors, + GetV1WdGphPaySummaryResponses, + GetV1WdGphPayVarianceData, + GetV1WdGphPayVarianceErrors, + GetV1WdGphPayVarianceResponses, GetV1WebhookEventsData, GetV1WebhookEventsErrors, GetV1WebhookEventsResponses, @@ -465,6 +489,9 @@ import type { PatchV2EmploymentsEmploymentIdData, PatchV2EmploymentsEmploymentIdErrors, PatchV2EmploymentsEmploymentIdResponses, + PostAuthOauth2Token2Data, + PostAuthOauth2Token2Errors, + PostAuthOauth2Token2Responses, PostAuthOauth2TokenData, PostAuthOauth2TokenErrors, PostAuthOauth2TokenResponses, @@ -594,6 +621,12 @@ import type { PostV1OffboardingsData, PostV1OffboardingsErrors, PostV1OffboardingsResponses, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsData, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsErrors, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignData, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignErrors, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponses, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponses, PostV1PayItemsBulkData, PostV1PayItemsBulkErrors, PostV1PayItemsBulkResponses, @@ -651,6 +684,9 @@ import type { PostV1TimeoffTimeoffIdDeclineData, PostV1TimeoffTimeoffIdDeclineErrors, PostV1TimeoffTimeoffIdDeclineResponses, + PostV1TimesheetsData, + PostV1TimesheetsErrors, + PostV1TimesheetsResponses, PostV1TimesheetsTimesheetIdApproveData, PostV1TimesheetsTimesheetIdApproveErrors, PostV1TimesheetsTimesheetIdApproveResponses, @@ -744,241 +780,212 @@ export type Options< }; /** - * List Offboarding + * Update administrative details * - * Lists Offboarding requests. + * Updates employment's administrative details. * - * ## Scopes + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employments (`employments`) | View offboarding requests (`offboarding:read`) | Manage offboarding (`offboarding:write`) | + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. * - */ -export const getV1Offboardings = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1OffboardingsResponses, - GetV1OffboardingsErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/offboardings', - ...options, - }); - -/** - * Create Offboarding + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. * - * Creates an Offboarding request. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage offboarding (`offboarding:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1Offboardings = ( - options?: Options, +export const putV2EmploymentsEmploymentIdAdministrativeDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + PutV2EmploymentsEmploymentIdAdministrativeDetailsData, + ThrowOnError + >, ) => - (options?.client ?? client).post< - PostV1OffboardingsResponses, - PostV1OffboardingsErrors, + (options.client ?? client).put< + PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses, + PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/offboardings', + url: '/v2/employments/{employment_id}/administrative_details', ...options, headers: { 'Content-Type': 'application/json', - ...options?.headers, + ...options.headers, }, }); /** - * Show timesheet + * Get engagement agreement details * - * Shows a timesheet by its ID. + * Returns the engagement agreement details for an employment. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timesheets (`timesheet:read`) | Manage timesheets (`timesheet:write`) | + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const getV1TimesheetsId = ( - options: Options, +export const getV1EmploymentsEmploymentIdEngagementAgreementDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + GetV1EmploymentsEmploymentIdEngagementAgreementDetailsData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1TimesheetsIdResponses, - GetV1TimesheetsIdErrors, + GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses, + GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timesheets/{id}', + url: '/v1/employments/{employment_id}/engagement-agreement-details', ...options, }); /** - * Cancel onboarding + * Upsert engagement agreement details * - * Cancel onboarding. + * Creates or updates the engagement agreement details for an employment. * - * Requirements for the cancellation to succeed: + * This endpoint requires country-specific data. The exact required fields will vary depending on + * which country the employment is in. To see the list of parameters for each country, see the + * **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that compliance requirements for each country are subject to change according to local laws. + * Using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) is recommended + * to avoid compliance issues and to have the latest version of a country's requirements. * - * * Employment has to be in `invited`, `created`, `created_awaiting_reserve`, `created_reserve_paid`, `pre_hire` status - * * Employee must not have signed the employment contract * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage onboarding (`onboarding:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1CancelOnboardingEmploymentId = < +export const postV1EmploymentsEmploymentIdEngagementAgreementDetails = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PostV1EmploymentsEmploymentIdEngagementAgreementDetailsData, + ThrowOnError + >, ) => (options.client ?? client).post< - PostV1CancelOnboardingEmploymentIdResponses, - PostV1CancelOnboardingEmploymentIdErrors, + PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses, + PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/cancel-onboarding/{employment_id}', + url: '/v1/employments/{employment_id}/engagement-agreement-details', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Show form schema - * - * Returns the json schema of the `contract_amendment` form for a specific employment. - * This endpoint requires a company access token, as forms are dependent on certain - * properties of companies and their current employments. + * Convert currency using dynamic rates * + * Convert currency using the rates Remote applies during employment creation and invoicing. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View contract amendments (`contract_amendment:read`) | Manage contract amendments (`contract_amendment:write`) | + * | Manage company resources (`company_admin`) | Convert currencies (`convert_currency:read`) | - | * */ -export const getV1ContractAmendmentsSchema = < +export const postV1CurrencyConverterEffective2 = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).get< - GetV1ContractAmendmentsSchemaResponses, - GetV1ContractAmendmentsSchemaErrors, + (options.client ?? client).post< + PostV1CurrencyConverterEffective2Responses, + PostV1CurrencyConverterEffective2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contract-amendments/schema', + url: '/v1/currency-converter', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Bulk Create Pay Items + * List contractor subscriptions * - * Bulk creates pay items for employments. Supports up to 500 items per request. - * Integration-specific fields (shift code, currency, pay amount, etc.) go in the `meta` object. - * Only Global Payroll employments are supported. Non-GP employments are returned as `employment_not_global_payroll`. + * Endpoint that can be used to list contractor subscriptions. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage payroll runs (`payroll`) | - | Manage pay items (`pay_item:write`) | + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const postV1PayItemsBulk = ( - options: Options, -) => - (options.client ?? client).post< - PostV1PayItemsBulkResponses, - PostV1PayItemsBulkErrors, +export const getV1ContractorsEmploymentsEmploymentIdContractorSubscriptions = < + ThrowOnError extends boolean = false, +>( + options: Options< + GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsData, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/pay-items/bulk', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); - -/** - * Get latest data sync events - * - * Get the latest data sync events for each data type that have passed - * - * - * @deprecated - */ -export const getV1DataSync = ( - options?: Options, + >, ) => - (options?.client ?? client).get< - GetV1DataSyncResponses, - GetV1DataSyncErrors, + (options.client ?? client).get< + GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses, + GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/data-sync', + url: '/v1/contractors/employments/{employment_id}/contractor-subscriptions', ...options, }); /** - * Create test data sync job + * Convert currency using flat rates * - * Create Test Data Synchronization job that will sync test data to the database from production - * The job will be handled asynchronously and the response will be a 202 status code. + * Convert currency using FX rates used in Remote’s estimation tools. + * These rates are not guaranteed to match final onboarding or contract rates. * - * **Heads up:** This endpoint is only available for specific usecases and should not be used for general data sync needs, - * if you need to request access to this endpoint, please contact the api-support@remote.com. + * ## Scopes * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage company resources (`company_admin`) | Convert currencies (`convert_currency:read`) | - | * - * @deprecated */ -export const postV1DataSync = ( - options: Options, +export const postV1CurrencyConverterRaw = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => (options.client ?? client).post< - PostV1DataSyncResponses, - PostV1DataSyncErrors, + PostV1CurrencyConverterRawResponses, + PostV1CurrencyConverterRawErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/data-sync', + url: '/v1/currency-converter/raw', ...options, headers: { 'Content-Type': 'application/json', @@ -987,67 +994,50 @@ export const postV1DataSync = ( }); /** - * List pricing plans - * - * List all pricing plans for a company. - * Currently the endpoint only returns the pricing plans for the EOR monthly product and the contractor products (Standard, Plus and COR). + * List Incentives * + * Lists all Incentives of a company * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage companies (`company_management`) | View pricing plans (`pricing_plan:read`) | Manage pricing plans (`pricing_plan:write`) | + * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | * */ -export const getV1CompaniesCompanyIdPricingPlans = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1Incentives = ( + options: Options, ) => (options.client ?? client).get< - GetV1CompaniesCompanyIdPricingPlansResponses, - GetV1CompaniesCompanyIdPricingPlansErrors, + GetV1IncentivesResponses, + GetV1IncentivesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/pricing-plans', - ...options, - }); + >({ url: '/v1/incentives', ...options }); /** - * Create a pricing plan for a company - * - * Create a pricing plan for a company, in order to do that we have 2 ways: + * Create Incentive * - * 1. Create a pricing plan from a partner template - * 2. Create a pricing plan from a product price + * Creates an Incentive. * - * The pricing plan is always created in the company's desired currency. + * Incentives use the currency of the employment specified provided in the `employment_id` field. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage companies (`company_management`) | - | Manage pricing plans (`pricing_plan:write`) | + * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | * */ -export const postV1CompaniesCompanyIdPricingPlans = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1Incentives = ( + options: Options, ) => (options.client ?? client).post< - PostV1CompaniesCompanyIdPricingPlansResponses, - PostV1CompaniesCompanyIdPricingPlansErrors, + PostV1IncentivesResponses, + PostV1IncentivesErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies/{company_id}/pricing-plans', + url: '/v1/incentives', ...options, headers: { 'Content-Type': 'application/json', @@ -1056,92 +1046,118 @@ export const postV1CompaniesCompanyIdPricingPlans = < }); /** - * Show probation completion letter + * List Benefit Offers By Employment + * + * List benefit offers by employment. * - * Show a single probation completion letter. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View probation documents (`probation_document:read`) | Manage probation documents (`probation_document:write`) | + * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | * */ -export const getV1ProbationCompletionLetterId = < +export const getV1BenefitOffers = ( + options: Options, +) => + (options.client ?? client).get< + GetV1BenefitOffersResponses, + GetV1BenefitOffersErrors, + ThrowOnError + >({ url: '/v1/benefit-offers', ...options }); + +/** + * Complete onboarding + * + * Completes the employee onboarding. When all tasks are completed, the employee is marked as in `review` status + * + * @deprecated + */ +export const postV1Ready = ( + options: Options, +) => + (options.client ?? client).post< + PostV1ReadyResponses, + PostV1ReadyErrors, + ThrowOnError + >({ + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/ready', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); + +/** + * Creates a cost estimation of employments + */ +export const postV1CostCalculatorEstimation = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).get< - GetV1ProbationCompletionLetterIdResponses, - GetV1ProbationCompletionLetterIdErrors, + (options.client ?? client).post< + PostV1CostCalculatorEstimationResponses, + PostV1CostCalculatorEstimationErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/probation-completion-letter/{id}', + url: '/v1/cost-calculator/estimation', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Show Contractor Invoice + * List Recurring Incentive + * + * List all Recurring Incentives of a company. * - * Shows a single Contractor Invoice record. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | + * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | * */ -export const getV1ContractorInvoicesId = ( - options: Options, +export const getV1IncentivesRecurring = ( + options: Options, ) => (options.client ?? client).get< - GetV1ContractorInvoicesIdResponses, - GetV1ContractorInvoicesIdErrors, + GetV1IncentivesRecurringResponses, + GetV1IncentivesRecurringErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractor-invoices/{id}', - ...options, - }); + >({ url: '/v1/incentives/recurring', ...options }); /** - * Convert currency using flat rates + * Create Recurring Incentive + * + * Create a Recurring Incentive, that is, a monthly paid incentive. + * + * Incentives use the currency of the employment specified provided in the `employment_id` field. * - * Convert currency using FX rates used in Remote’s estimation tools. - * These rates are not guaranteed to match final onboarding or contract rates. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | Convert currencies (`convert_currency:read`) | - | + * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | * */ -export const postV1CurrencyConverterRaw = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1IncentivesRecurring = ( + options: Options, ) => (options.client ?? client).post< - PostV1CurrencyConverterRawResponses, - PostV1CurrencyConverterRawErrors, + PostV1IncentivesRecurringResponses, + PostV1IncentivesRecurringErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/currency-converter/raw', + url: '/v1/incentives/recurring', ...options, headers: { 'Content-Type': 'application/json', @@ -1150,151 +1166,120 @@ export const postV1CurrencyConverterRaw = < }); /** - * Show contractor contract details + * List timesheets * - * Returns the contract details JSON Schema for contractors given a country + * Lists all timesheets. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | + * | Manage timeoffs (`time_and_attendance`) | View timesheets (`timesheet:read`) | Manage timesheets (`timesheet:write`) | * */ -export const getV1CountriesCountryCodeContractorContractDetails = < - ThrowOnError extends boolean = false, ->( - options: Options< - GetV1CountriesCountryCodeContractorContractDetailsData, - ThrowOnError - >, +export const getV1Timesheets = ( + options?: Options, ) => - (options.client ?? client).get< - GetV1CountriesCountryCodeContractorContractDetailsResponses, - GetV1CountriesCountryCodeContractorContractDetailsErrors, + (options?.client ?? client).get< + GetV1TimesheetsResponses, + GetV1TimesheetsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/countries/{country_code}/contractor-contract-details', - ...options, - }); + >({ url: '/v1/timesheets', ...options }); /** - * List incentives for the authenticated employee + * Create timesheet * - * Returns all incentives for the authenticated employee. + * Creates a new timesheet. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timesheets (`timesheet:write`) | * */ -export const getV1EmployeeIncentives = ( - options?: Options, +export const postV1Timesheets = ( + options?: Options, ) => - (options?.client ?? client).get< - GetV1EmployeeIncentivesResponses, - GetV1EmployeeIncentivesErrors, + (options?.client ?? client).post< + PostV1TimesheetsResponses, + PostV1TimesheetsErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/incentives', + url: '/v1/timesheets', ...options, + headers: { + 'Content-Type': 'application/json', + ...options?.headers, + }, }); /** - * List employments - * - * Lists all employments, except for the deleted ones. + * Approve timesheet * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * Approves the given timesheet. * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. + * ## Scopes * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage timeoffs (`time_and_attendance`) | - | Manage timesheets (`timesheet:write`) | * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + */ +export const postV1TimesheetsTimesheetIdApprove = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).post< + PostV1TimesheetsTimesheetIdApproveResponses, + PostV1TimesheetsTimesheetIdApproveErrors, + ThrowOnError + >({ url: '/v1/timesheets/{timesheet_id}/approve', ...options }); + +/** + * Get latest data sync events * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * Get the latest data sync events for each data type that have passed * * + * @deprecated */ -export const getV1Employments = ( - options: Options, +export const getV1DataSync = ( + options?: Options, ) => - (options.client ?? client).get< - GetV1EmploymentsResponses, - GetV1EmploymentsErrors, + (options?.client ?? client).get< + GetV1DataSyncResponses, + GetV1DataSyncErrors, ThrowOnError >({ security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employments', + url: '/v1/data-sync', ...options, }); /** - * Create employment - * - * Creates an employment. We support creating employees and contractors. - * - * ## Global Payroll Employees - * - * To create a Global Payroll employee, pass `global_payroll_employee` as the `type` parameter, - * and provide the slug of the specific legal entity that the employee will be engaged by and billed to as the `engaged_by_entity_slug` parameter. - * - * ## HRIS Employees - * - * To create a HRIS employee, pass `hris` as the `type` parameter. - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. - * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. - * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. - * + * Create test data sync job * + * Create Test Data Synchronization job that will sync test data to the database from production + * The job will be handled asynchronously and the response will be a 202 status code. * - * ## Scopes + * **Heads up:** This endpoint is only available for specific usecases and should not be used for general data sync needs, + * if you need to request access to this endpoint, please contact the api-support@remote.com. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * + * @deprecated */ -export const postV1Employments = ( - options: Options, +export const postV1DataSync = ( + options: Options, ) => (options.client ?? client).post< - PostV1EmploymentsResponses, - PostV1EmploymentsErrors, + PostV1DataSyncResponses, + PostV1DataSyncErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/data-sync', ...options, headers: { 'Content-Type': 'application/json', @@ -1303,237 +1288,207 @@ export const postV1Employments = ( }); /** - * Get Onboarding Reserves Status for Employment - * - * Returns the onboarding reserves status for a specific employment. - * - * The status is the same as the credit risk status but takes the onboarding reserves policies into account. + * Show probation completion letter * + * Show a single probation completion letter. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | Manage employment documents (`employment_documents`) | View probation documents (`probation_document:read`) | Manage probation documents (`probation_document:write`) | * */ -export const getV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatus = - ( - options: Options< - GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusData, - ThrowOnError - >, - ) => - (options.client ?? client).get< - GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses, - GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/employments/{employment_id}/onboarding-reserves-status', - ...options, - }); +export const getV1ProbationCompletionLetterId = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).get< + GetV1ProbationCompletionLetterIdResponses, + GetV1ProbationCompletionLetterIdErrors, + ThrowOnError + >({ url: '/v1/probation-completion-letter/{id}', ...options }); /** - * Get Help Center Article + * Show the current SSO Configuration * - * Get a help center article by its ID + * Shows the current SSO Configuration for the company. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View help articles (`help_center_article:read`) | - | + * | Manage company resources (`company_admin`) | View SSO configuration (`sso_configuration:read`) | Manage SSO (`sso_configuration:write`) | * */ -export const getV1HelpCenterArticlesId = ( - options: Options, +export const getV1SsoConfiguration = ( + options?: Options, ) => - (options.client ?? client).get< - GetV1HelpCenterArticlesIdResponses, - GetV1HelpCenterArticlesIdErrors, + (options?.client ?? client).get< + GetV1SsoConfigurationResponses, + GetV1SsoConfigurationErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/help-center-articles/{id}', - ...options, - }); + >({ url: '/v1/sso-configuration', ...options }); /** - * Get user by ID via SCIM v2.0 + * Create the SSO Configuration + * + * Creates the SSO Configuration for the company. + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage company resources (`company_admin`) | - | Manage SSO (`sso_configuration:write`) | * - * Retrieves a single user for the authenticated company by user ID */ -export const getV1ScimV2UsersId = ( - options: Options, +export const postV1SsoConfiguration = ( + options: Options, ) => - (options.client ?? client).get< - GetV1ScimV2UsersIdResponses, - GetV1ScimV2UsersIdErrors, + (options.client ?? client).post< + PostV1SsoConfigurationResponses, + PostV1SsoConfigurationErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/scim/v2/Users/{id}', + url: '/v1/sso-configuration', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Get engagement agreement details + * List Offboarding * - * Returns the engagement agreement details for an employment. + * Lists Offboarding requests. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | View offboarding requests (`offboarding:read`) | Manage offboarding (`offboarding:write`) | * */ -export const getV2EmploymentsEmploymentIdEngagementAgreementDetails = < - ThrowOnError extends boolean = false, ->( - options: Options< - GetV2EmploymentsEmploymentIdEngagementAgreementDetailsData, - ThrowOnError - >, +export const getV1Offboardings = ( + options?: Options, ) => - (options.client ?? client).get< - GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses, - GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors, + (options?.client ?? client).get< + GetV1OffboardingsResponses, + GetV1OffboardingsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/engagement-agreement-details', - ...options, - }); + >({ url: '/v1/offboardings', ...options }); /** - * Upsert engagement agreement details - * - * Creates or updates the engagement agreement details for an employment. - * - * This endpoint requires country-specific data. The exact required fields will vary depending on - * which country the employment is in. To see the list of parameters for each country, see the - * **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that compliance requirements for each country are subject to change according to local laws. - * Using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) is recommended - * to avoid compliance issues and to have the latest version of a country's requirements. + * Create Offboarding * + * Creates an Offboarding request. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | - | Manage offboarding (`offboarding:write`) | * */ -export const postV2EmploymentsEmploymentIdEngagementAgreementDetails = < - ThrowOnError extends boolean = false, ->( - options: Options< - PostV2EmploymentsEmploymentIdEngagementAgreementDetailsData, - ThrowOnError - >, +export const postV1Offboardings = ( + options?: Options, ) => - (options.client ?? client).post< - PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses, - PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors, + (options?.client ?? client).post< + PostV1OffboardingsResponses, + PostV1OffboardingsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/engagement-agreement-details', + url: '/v1/offboardings', ...options, headers: { 'Content-Type': 'application/json', - ...options.headers, + ...options?.headers, }, }); /** - * Download a document for the employee + * Create a contract document for a contractor + * + * Create a contract document for a contractor. + * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | + * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | * */ -export const getV1EmployeeDocumentsId = ( - options: Options, +export const postV1ContractorsEmploymentsEmploymentIdContractDocuments = < + ThrowOnError extends boolean = false, +>( + options: Options< + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsData, + ThrowOnError + >, ) => - (options.client ?? client).get< - GetV1EmployeeDocumentsIdResponses, - GetV1EmployeeDocumentsIdErrors, + (options.client ?? client).post< + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses, + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/documents/{id}', + url: '/v1/contractors/employments/{employment_id}/contract-documents', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List Contractor Invoices + * Update federal taxes + * + * Updates employment's federal taxes. + * + * Requirements to update federal taxes successfully: + * * Employment should be Global Payroll + * * Employment should be in the post-enrollment state + * * Employment should belong to USA + * + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * * - * Lists Contractor Invoice records. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | - * - */ -export const getV1ContractorInvoices = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1ContractorInvoicesResponses, - GetV1ContractorInvoicesErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractor-invoices', - ...options, - }); - -/** - * Report SDK errors - * - * Receives error telemetry from the frontend SDK. - * Errors are logged to observability backend for monitoring and debugging. + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1SdkTelemetryErrors = ( - options: Options, +export const putV1EmploymentsEmploymentIdFederalTaxes = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).post< - PostV1SdkTelemetryErrorsResponses, - PostV1SdkTelemetryErrorsErrors, + (options.client ?? client).put< + PutV1EmploymentsEmploymentIdFederalTaxesResponses, + PutV1EmploymentsEmploymentIdFederalTaxesErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sdk/telemetry-errors', + url: '/v1/employments/{employment_id}/federal-taxes', ...options, headers: { 'Content-Type': 'application/json', @@ -1542,55 +1497,59 @@ export const postV1SdkTelemetryErrors = ( }); /** - * Show the SSO Configuration Details + * List pricing plans + * + * List all pricing plans for a company. + * Currently the endpoint only returns the pricing plans for the EOR monthly product and the contractor products (Standard, Plus and COR). * - * Shows the SSO Configuration details for the company. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage SSO (`sso_configuration:write`) | + * | Manage companies (`company_management`) | View pricing plans (`pricing_plan:read`) | Manage pricing plans (`pricing_plan:write`) | * */ -export const getV1SsoConfigurationDetails = < +export const getV1CompaniesCompanyIdPricingPlans = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options, ) => - (options?.client ?? client).get< - GetV1SsoConfigurationDetailsResponses, - GetV1SsoConfigurationDetailsErrors, + (options.client ?? client).get< + GetV1CompaniesCompanyIdPricingPlansResponses, + GetV1CompaniesCompanyIdPricingPlansErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sso-configuration/details', - ...options, - }); + >({ url: '/v1/companies/{company_id}/pricing-plans', ...options }); /** - * Creates a cost estimation of employments + * Create a pricing plan for a company + * + * Create a pricing plan for a company, in order to do that we have 2 ways: + * + * 1. Create a pricing plan from a partner template + * 2. Create a pricing plan from a product price + * + * The pricing plan is always created in the company's desired currency. + * + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage companies (`company_management`) | - | Manage pricing plans (`pricing_plan:write`) | + * */ -export const postV1CostCalculatorEstimation = < +export const postV1CompaniesCompanyIdPricingPlans = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).post< - PostV1CostCalculatorEstimationResponses, - PostV1CostCalculatorEstimationErrors, + PostV1CompaniesCompanyIdPricingPlansResponses, + PostV1CompaniesCompanyIdPricingPlansErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/cost-calculator/estimation', + url: '/v1/companies/{company_id}/pricing-plans', ...options, headers: { 'Content-Type': 'application/json', @@ -1599,75 +1558,51 @@ export const postV1CostCalculatorEstimation = < }); /** - * Show form schema + * Update federal taxes * - * Returns the json schema of the requested company form. - * Currently only supports the `address_details` form. + * Updates employment's federal taxes. * + * Requirements to update federal taxes successfully: + * * Employment should be Global Payroll + * * Employment should be in the post-enrollment state + * * Employment should belong to USA * - * ## Scopes + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * - */ -export const getV1CompaniesSchema = ( - options: Options, -) => - (options.client ?? client).get< - GetV1CompaniesSchemaResponses, - GetV1CompaniesSchemaErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies/schema', - ...options, - }); - -/** - * Get employment benefit offers * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const getV1EmploymentsEmploymentIdBenefitOffers = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => - (options.client ?? client).get< - GetV1EmploymentsEmploymentIdBenefitOffersResponses, - GetV1EmploymentsEmploymentIdBenefitOffersErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/benefit-offers', - ...options, - }); - -/** - * Upserts employment benefit offers - */ -export const putV1EmploymentsEmploymentIdBenefitOffers = < +export const putV2EmploymentsEmploymentIdFederalTaxes = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).put< - PutV1EmploymentsEmploymentIdBenefitOffersResponses, - PutV1EmploymentsEmploymentIdBenefitOffersErrors, + PutV2EmploymentsEmploymentIdFederalTaxesResponses, + PutV2EmploymentsEmploymentIdFederalTaxesErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employments/{employment_id}/benefit-offers', + url: '/v2/employments/{employment_id}/federal-taxes', ...options, headers: { 'Content-Type': 'application/json', @@ -1676,41 +1611,30 @@ export const putV1EmploymentsEmploymentIdBenefitOffers = < }); /** - * Get Employment Profile - * - * Gets necessary information to perform the identity verification of an employee. + * List travel letter requests * + * List travel letter requests. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View identity verification (`identity_verification:read`) | Manage identity verification (`identity_verification:write`) | + * | - | View travel letters (`travel_letter:read`) | - | * */ -export const getV1IdentityVerificationEmploymentId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1TravelLetterRequests = ( + options?: Options, ) => - (options.client ?? client).get< - GetV1IdentityVerificationEmploymentIdResponses, - GetV1IdentityVerificationEmploymentIdErrors, + (options?.client ?? client).get< + GetV1TravelLetterRequestsResponses, + GetV1TravelLetterRequestsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/identity-verification/{employment_id}', - ...options, - }); + >({ url: '/v1/travel-letter-requests', ...options }); /** - * List contractor subscriptions - * - * Endpoint that can be used to list contractor subscriptions. + * Get engagement agreement details * + * Returns the engagement agreement details for an employment. * * ## Scopes * @@ -1719,325 +1643,196 @@ export const getV1IdentityVerificationEmploymentId = < * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const getV1ContractorsEmploymentsEmploymentIdContractorSubscriptions = < +export const getV2EmploymentsEmploymentIdEngagementAgreementDetails = < ThrowOnError extends boolean = false, >( options: Options< - GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsData, + GetV2EmploymentsEmploymentIdEngagementAgreementDetailsData, ThrowOnError >, ) => (options.client ?? client).get< - GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses, - GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors, + GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses, + GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contractor-subscriptions', + url: '/v2/employments/{employment_id}/engagement-agreement-details', ...options, }); /** - * List approved payslip files for the authenticated employee + * Upsert engagement agreement details * - * Returns a paginated list of payslip files belonging to the current employee. + * Creates or updates the engagement agreement details for an employment. * - * ## Scopes + * This endpoint requires country-specific data. The exact required fields will vary depending on + * which country the employment is in. To see the list of parameters for each country, see the + * **Show form schema** endpoint under the [Countries](#tag/Countries) category. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employment documents (`employment_documents`) | View payslips (`payslip:read`) | - | + * Please note that compliance requirements for each country are subject to change according to local laws. + * Using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) is recommended + * to avoid compliance issues and to have the latest version of a country's requirements. * - */ -export const getV1EmployeePayslips = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1EmployeePayslipsResponses, - GetV1EmployeePayslipsErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/payslips', - ...options, - }); - -/** - * List Webhook Events * - * List all webhook events * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View webhooks (`webhook:read`) | Manage webhooks (`webhook:write`) | - * - */ -export const getV1WebhookEvents = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1WebhookEventsResponses, - GetV1WebhookEventsErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/webhook-events', - ...options, - }); - -/** - * Pass KYB - * - * Pass KYB and credit risk for a company without the intervention of a Remote admin. - * - * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1SandboxCompaniesCompanyIdBypassEligibilityChecks = < +export const postV2EmploymentsEmploymentIdEngagementAgreementDetails = < ThrowOnError extends boolean = false, >( options: Options< - PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksData, + PostV2EmploymentsEmploymentIdEngagementAgreementDetailsData, ThrowOnError >, ) => (options.client ?? client).post< - PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses, - PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors, + PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses, + PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/companies/{company_id}/bypass-eligibility-checks', + url: '/v2/employments/{employment_id}/engagement-agreement-details', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Approve risk reserve proof of payment - * - * Approves a risk reserve proof of payment without the intervention of a Remote admin. - * - * Triggers an `employment.cor_hiring.proof_of_payment_accepted` webhook event. - * - * This endpoint is only available in Sandbox, otherwise it will respond with a 404. - * - */ -export const postV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApprove = - ( - options: Options< - PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveData, - ThrowOnError - >, - ) => - (options.client ?? client).post< - PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses, - PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/employments/{employment_id}/risk-reserve-proof-of-payments/approve', - ...options, - }); - -/** - * Get a mock JSON Schema + * Payroll processing summary API resource * - * Get a mock JSON Schema for testing purposes + * API to retrieve summary data for processing pay groups */ -export const getV1TestSchema = ( - options?: Options, +export const getV1WdGphPaySummary = ( + options?: Options, ) => (options?.client ?? client).get< - GetV1TestSchemaResponses, - unknown, + GetV1WdGphPaySummaryResponses, + GetV1WdGphPaySummaryErrors, ThrowOnError >({ security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/test-schema', + url: '/v1/wd/gph/paySummary', ...options, }); /** - * List all holidays of a country + * Show employment job + * + * Shows an employment job details. * - * List all holidays of a country for a specific year. Optionally, it can be filtered by country subdivision. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View countries (`country:read`) | - | + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const getV1CountriesCountryCodeHolidaysYear = < +export const getV1EmploymentsEmploymentIdJob = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).get< - GetV1CountriesCountryCodeHolidaysYearResponses, - GetV1CountriesCountryCodeHolidaysYearErrors, + GetV1EmploymentsEmploymentIdJobResponses, + GetV1EmploymentsEmploymentIdJobErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/countries/{country_code}/holidays/{year}', - ...options, - }); + >({ url: '/v1/employments/{employment_id}/job', ...options }); /** - * Cancel Time Off + * Create bulk employment job * - * Cancel a time off request that was already approved. + * Creates a job to bulk-create employments for multiple employees at once. Each employee payload must match the employment schema for the selected country. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1TimeoffTimeoffIdCancel = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1BulkEmploymentJobs = ( + options?: Options, ) => - (options.client ?? client).post< - PostV1TimeoffTimeoffIdCancelResponses, - PostV1TimeoffTimeoffIdCancelErrors, + (options?.client ?? client).post< + PostV1BulkEmploymentJobsResponses, + PostV1BulkEmploymentJobsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{timeoff_id}/cancel', + url: '/v1/bulk-employment-jobs', ...options, headers: { 'Content-Type': 'application/json', - ...options.headers, + ...options?.headers, }, }); /** - * Show employment job - * - * Shows an employment job details. + * List Contract Amendment * + * List Contract Amendment requests. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | View contract amendments (`contract_amendment:read`) | Manage contract amendments (`contract_amendment:write`) | * */ -export const getV1EmploymentsEmploymentIdJob = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => +export const getV1ContractAmendments = ( + options: Options, +) => (options.client ?? client).get< - GetV1EmploymentsEmploymentIdJobResponses, - GetV1EmploymentsEmploymentIdJobErrors, + GetV1ContractAmendmentsResponses, + GetV1ContractAmendmentsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/job', - ...options, - }); + >({ url: '/v1/contract-amendments', ...options }); /** - * List pricing plan partner templates - * - * List all pricing plan partner templates. - * + * Create Contract Amendment * - * ## Scopes + * Creates a Contract Amendment request. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage companies (`company_management`) | View pricing plans (`pricing_plan:read`) | Manage pricing plans (`pricing_plan:write`) | + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Contract Amendments](#tag/Contract-Amendments) category. * - */ -export const getV1PricingPlanPartnerTemplates = < - ThrowOnError extends boolean = false, ->( - options?: Options, -) => - (options?.client ?? client).get< - GetV1PricingPlanPartnerTemplatesResponses, - GetV1PricingPlanPartnerTemplatesErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/pricing-plan-partner-templates', - ...options, - }); - -/** - * List EOR Payroll Calendar + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. * - * List all active payroll calendars for EOR. + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. * - * ## Scopes + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage payroll runs (`payroll`) | View payroll calendars (`payroll_calendar:read`) | - | + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. * - */ -export const getV1PayrollCalendars = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1PayrollCalendarsResponses, - GetV1PayrollCalendarsErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/payroll-calendars', - ...options, - }); - -/** - * Update Time Off as Employee * - * Updates a Time Off record as Employee * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | - | Manage contract amendments (`contract_amendment:write`) | * */ -export const patchV1EmployeeTimeoffId2 = ( - options: Options, +export const postV1ContractAmendments = ( + options: Options, ) => - (options.client ?? client).patch< - PatchV1EmployeeTimeoffId2Responses, - PatchV1EmployeeTimeoffId2Errors, + (options.client ?? client).post< + PostV1ContractAmendmentsResponses, + PostV1ContractAmendmentsErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/timeoff/{id}', + url: '/v1/contract-amendments', ...options, headers: { 'Content-Type': 'application/json', @@ -2046,120 +1841,91 @@ export const patchV1EmployeeTimeoffId2 = ( }); /** - * Update Time Off as Employee + * Delete a Recurring Incentive + * + * Delete a Recurring Incentive, that is, a monthly paid incentive. + * + * Internally, Remote schedules upcoming incentives. As such, when you attempt to + * delete a recurring incentive, Remote will **ONLY** delete scheduled incentives + * with the `pending` status. + * + * Incentives payments that are already scheduled and cannot be deleted will be + * included in the response, in case you need to reference them. * - * Updates a Time Off record as Employee * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | * */ -export const patchV1EmployeeTimeoffId = ( - options: Options, +export const deleteV1IncentivesRecurringId = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).put< - PatchV1EmployeeTimeoffIdResponses, - PatchV1EmployeeTimeoffIdErrors, + (options.client ?? client).delete< + DeleteV1IncentivesRecurringIdResponses, + DeleteV1IncentivesRecurringIdErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/timeoff/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/incentives/recurring/{id}', ...options }); /** - * List Recurring Incentive - * - * List all Recurring Incentives of a company. + * Show Benefit Renewal Request * + * Show Benefit Renewal Request details. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | + * | Manage company resources (`company_admin`) | View benefit renewals (`benefit_renewal:read`) | Manage benefit renewals (`benefit_renewal:write`) | * */ -export const getV1IncentivesRecurring = ( - options: Options, +export const getV1BenefitRenewalRequestsBenefitRenewalRequestId = < + ThrowOnError extends boolean = false, +>( + options: Options< + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1IncentivesRecurringResponses, - GetV1IncentivesRecurringErrors, + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses, + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives/recurring', + url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}', ...options, }); /** - * Create Recurring Incentive - * - * Create a Recurring Incentive, that is, a monthly paid incentive. - * - * Incentives use the currency of the employment specified provided in the `employment_id` field. + * Updates a Benefit Renewal Request Response * + * Updates a Benefit Renewal Request with the given response. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | - * - */ -export const postV1IncentivesRecurring = ( - options: Options, -) => - (options.client ?? client).post< - PostV1IncentivesRecurringResponses, - PostV1IncentivesRecurringErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives/recurring', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); - -/** - * Creates a Benefit Renewal Request - * - * Creates a Benefit Renewal Request for a specific Benefit Group. - * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * | Manage company resources (`company_admin`) | - | Manage benefit renewals (`benefit_renewal:write`) | * */ -export const postV1SandboxBenefitRenewalRequests = < +export const postV1BenefitRenewalRequestsBenefitRenewalRequestId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PostV1BenefitRenewalRequestsBenefitRenewalRequestIdData, + ThrowOnError + >, ) => (options.client ?? client).post< - PostV1SandboxBenefitRenewalRequestsResponses, - PostV1SandboxBenefitRenewalRequestsErrors, + PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses, + PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/benefit-renewal-requests', + url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}', ...options, headers: { 'Content-Type': 'application/json', @@ -2168,182 +1934,147 @@ export const postV1SandboxBenefitRenewalRequests = < }); /** - * Return a base64 encoded version of the contract document + * List all holidays of a country + * + * List all holidays of a country for a specific year. Optionally, it can be filtered by country subdivision. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | + * | Manage company resources (`company_admin`) | View countries (`country:read`) | - | * */ -export const getV1ContractorsEmploymentsEmploymentIdContractDocumentsId = < +export const getV1CountriesCountryCodeHolidaysYear = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses, - GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors, + GetV1CountriesCountryCodeHolidaysYearResponses, + GetV1CountriesCountryCodeHolidaysYearErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contract-documents/{id}', - ...options, - }); + >({ url: '/v1/countries/{country_code}/holidays/{year}', ...options }); /** - * List contract documents for an employment + * List custom field value for an employment * - * Only contractor employment types are supported. Lists contract documents for a specific employment with pagination, filtering by status, and sorted by updated_at descending (latest first). + * Returns a list of custom field values for a given employment * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | + * | Manage employments (`employments`) | View custom field values (`custom_field_value:read`) | Manage custom field values (`custom_field_value:write`) | * */ -export const getV1EmploymentsEmploymentIdContractDocuments = < +export const getV1EmploymentsEmploymentIdCustomFields = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1EmploymentsEmploymentIdContractDocumentsData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1EmploymentsEmploymentIdContractDocumentsResponses, - GetV1EmploymentsEmploymentIdContractDocumentsErrors, + GetV1EmploymentsEmploymentIdCustomFieldsResponses, + GetV1EmploymentsEmploymentIdCustomFieldsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/contract-documents', - ...options, - }); + >({ url: '/v1/employments/{employment_id}/custom-fields', ...options }); /** - * List expenses + * Show timesheet * - * Lists all expenses records + * Shows a timesheet by its ID. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | + * | Manage timeoffs (`time_and_attendance`) | View timesheets (`timesheet:read`) | Manage timesheets (`timesheet:write`) | * */ -export const getV1Expenses = ( - options: Options, +export const getV1TimesheetsId = ( + options: Options, ) => (options.client ?? client).get< - GetV1ExpensesResponses, - GetV1ExpensesErrors, + GetV1TimesheetsIdResponses, + GetV1TimesheetsIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses', - ...options, - }); + >({ url: '/v1/timesheets/{id}', ...options }); /** - * Create expense + * List Company Managers + * + * List all company managers of an integration. If filtered by the company_id param, + * it lists only company managers belonging to the specified company. * - * Creates an **approved** expense * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | + * | Manage company resources (`company_admin`) | View managers (`company_manager:read`) | Manage managers (`company_manager:write`) | * */ -export const postV1Expenses = ( - options: Options, -) => - (options.client ?? client).post< - PostV1ExpensesResponses, - PostV1ExpensesErrors, +export const getV1CompanyManagers = ( + options: Options, +) => + (options.client ?? client).get< + GetV1CompanyManagersResponses, + GetV1CompanyManagersErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/company-managers', ...options }); /** - * Show the current SSO Configuration + * Create and invite a Company Manager * - * Shows the current SSO Configuration for the company. + * Create a Company Manager and sends the invitation email for signing in to the Remote Platform. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View SSO configuration (`sso_configuration:read`) | Manage SSO (`sso_configuration:write`) | + * | Manage company resources (`company_admin`) | - | Manage managers (`company_manager:write`) | * */ -export const getV1SsoConfiguration = ( - options?: Options, +export const postV1CompanyManagers = ( + options: Options, ) => - (options?.client ?? client).get< - GetV1SsoConfigurationResponses, - GetV1SsoConfigurationErrors, + (options.client ?? client).post< + PostV1CompanyManagersResponses, + PostV1CompanyManagersErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sso-configuration', + url: '/v1/company-managers', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Create the SSO Configuration + * Bulk Create Pay Items + * + * Bulk creates pay items for employments. Supports up to 500 items per request. + * Integration-specific fields (shift code, currency, pay amount, etc.) go in the `meta` object. + * Only Global Payroll employments are supported. Non-GP employments are returned as `employment_not_global_payroll`. * - * Creates the SSO Configuration for the company. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage SSO (`sso_configuration:write`) | + * | Manage payroll runs (`payroll`) | - | Manage pay items (`pay_item:write`) | * */ -export const postV1SsoConfiguration = ( - options: Options, +export const postV1PayItemsBulk = ( + options: Options, ) => (options.client ?? client).post< - PostV1SsoConfigurationResponses, - PostV1SsoConfigurationErrors, + PostV1PayItemsBulkResponses, + PostV1PayItemsBulkErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sso-configuration', + url: '/v1/pay-items/bulk', ...options, headers: { 'Content-Type': 'application/json', @@ -2352,314 +2083,226 @@ export const postV1SsoConfiguration = ( }); /** - * Approve Contract Amendment + * Show travel letter request * - * Approves a contract amendment request without the intervention of a Remote admin. - * Approvals done via this endpoint are effective immediately, - * regardless of the effective date entered on the contract amendment creation. + * Show a single travel letter request. * - * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | - | View travel letters (`travel_letter:read`) | - | * */ -export const putV1SandboxContractAmendmentsContractAmendmentRequestIdApprove = < +export const getV1TravelLetterRequestsId = < ThrowOnError extends boolean = false, >( - options: Options< - PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).put< - PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses, - PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors, + (options.client ?? client).get< + GetV1TravelLetterRequestsIdResponses, + GetV1TravelLetterRequestsIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/approve', - ...options, - }); + >({ url: '/v1/travel-letter-requests/{id}', ...options }); /** - * List Employee Leave Policies + * Updates a travel letter request * - * List the leave policies for the current employee + * Updates a travel letter request * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * | - | - | Manage travel letters (`travel_letter:write`) | * */ -export const getV1EmployeeLeavePolicies = < +export const patchV1TravelLetterRequestsId2 = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options, ) => - (options?.client ?? client).get< - GetV1EmployeeLeavePoliciesResponses, - GetV1EmployeeLeavePoliciesErrors, + (options.client ?? client).patch< + PatchV1TravelLetterRequestsId2Responses, + PatchV1TravelLetterRequestsId2Errors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/leave-policies', + url: '/v1/travel-letter-requests/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List all currencies for the contractor - * - * The currencies are listed in the following order: - * 1. billing currency of the company - * 2. currencies of contractor’s existing withdrawal methods - * 3. currency of the contractor’s country - * 4. the rest, alphabetical. + * Updates a travel letter request * + * Updates a travel letter request * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | - | - | Manage travel letters (`travel_letter:write`) | * */ -export const getV1ContractorsEmploymentsEmploymentIdContractorCurrencies = < +export const patchV1TravelLetterRequestsId = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).get< - GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses, - GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors, + (options.client ?? client).put< + PatchV1TravelLetterRequestsIdResponses, + PatchV1TravelLetterRequestsIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contractor-currencies', + url: '/v1/travel-letter-requests/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Replay Webhook Events - * - * Replay webhook events + * Pass KYB * - * ## Scopes + * Pass KYB and credit risk for a company without the intervention of a Remote admin. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | + * This endpoint is only available in Sandbox, otherwise it will respond with a 404. * */ -export const postV1WebhookEventsReplay = ( - options: Options, +export const postV1SandboxCompaniesCompanyIdBypassEligibilityChecks = < + ThrowOnError extends boolean = false, +>( + options: Options< + PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksData, + ThrowOnError + >, ) => (options.client ?? client).post< - PostV1WebhookEventsReplayResponses, - PostV1WebhookEventsReplayErrors, + PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses, + PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/webhook-events/replay', + url: '/v1/sandbox/companies/{company_id}/bypass-eligibility-checks', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Create a contractor of record (COR) termination request - * - * Initiates a termination request for a Contractor of Record employment. - * When a termination request is sent, a stop work order is issued and the contractor remains active until a final invoice is paid or waived. - * Currently, only Contractor of Record employments can be terminated. + * List Employee Leave Policies * + * List the leave policies for the current employee * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | * */ -export const postV1ContractorsEmploymentsEmploymentIdCorTerminationRequests = < +export const getV1EmployeeLeavePolicies = < ThrowOnError extends boolean = false, >( - options: Options< - PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsData, - ThrowOnError - >, + options?: Options, ) => - (options.client ?? client).post< - PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses, - PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors, + (options?.client ?? client).get< + GetV1EmployeeLeavePoliciesResponses, + GetV1EmployeeLeavePoliciesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/cor-termination-requests', - ...options, - }); + >({ url: '/v1/employee/leave-policies', ...options }); /** - * Show Background Check + * List Webhook Callbacks * - * Show Background Check details for a given employment and background check request. + * List callbacks for a given company * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View background checks (`background_check:read`) | - | + * | Manage company resources (`company_admin`) | View webhooks (`webhook:read`) | Manage webhooks (`webhook:write`) | * */ -export const getV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckId = < +export const getV1CompaniesCompanyIdWebhookCallbacks = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses, - GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors, + GetV1CompaniesCompanyIdWebhookCallbacksResponses, + GetV1CompaniesCompanyIdWebhookCallbacksErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employments/{employment_id}/background-checks/{background_check_id}', - ...options, - }); + >({ url: '/v1/companies/{company_id}/webhook-callbacks', ...options }); /** - * Show benefit renewal request schema - * - * Returns the json schema of the `benefit_renewal_request` form for a specific request. - * This endpoint requires a company access token, as forms are dependent on certain - * properties of companies and their current employments. + * Download a billing document PDF * + * Downloads a billing document PDF * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View benefit renewals (`benefit_renewal:read`) | Manage benefit renewals (`benefit_renewal:write`) | + * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | * */ -export const getV1BenefitRenewalRequestsBenefitRenewalRequestIdSchema = < +export const getV1BillingDocumentsBillingDocumentIdPdf = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses, - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors, + GetV1BillingDocumentsBillingDocumentIdPdfResponses, + GetV1BillingDocumentsBillingDocumentIdPdfErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}/schema', - ...options, - }); + >({ url: '/v1/billing-documents/{billing_document_id}/pdf', ...options }); /** - * Magic links generator - * - * Generates a magic link for a passwordless authentication. - * To create a magic link for a company admin, you need to provide the `user_id` parameter. - * To create a magic link for an employee, you need to provide the `employment_id` parameter. + * Delete a Webhook Callback * + * Delete a callback previously registered for webhooks * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Create magic links (`magic_link:write`) | + * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | * */ -export const postV1MagicLink = ( - options: Options, +export const deleteV1WebhookCallbacksId = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).post< - PostV1MagicLinkResponses, - PostV1MagicLinkErrors, + (options.client ?? client).delete< + DeleteV1WebhookCallbacksIdResponses, + DeleteV1WebhookCallbacksIdErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/magic-link', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/webhook-callbacks/{id}', ...options }); /** - * Update basic information - * - * Updates employment's basic information. - * - * Supported employment statuses: `created`, `job_title_review`, `created_reserve_paid`, `created_awaiting_reserve`. - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. - * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. - * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. - * + * Update a Webhook Callback * + * Update a callback previously registered for webhooks * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | * */ -export const putV2EmploymentsEmploymentIdBasicInformation = < - ThrowOnError extends boolean = false, ->( - options: Options< - PutV2EmploymentsEmploymentIdBasicInformationData, - ThrowOnError - >, +export const patchV1WebhookCallbacksId = ( + options: Options, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdBasicInformationResponses, - PutV2EmploymentsEmploymentIdBasicInformationErrors, + (options.client ?? client).patch< + PatchV1WebhookCallbacksIdResponses, + PatchV1WebhookCallbacksIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/basic_information', + url: '/v1/webhook-callbacks/{id}', ...options, headers: { 'Content-Type': 'application/json', @@ -2668,99 +2311,84 @@ export const putV2EmploymentsEmploymentIdBasicInformation = < }); /** - * Delete a Recurring Incentive - * - * Delete a Recurring Incentive, that is, a monthly paid incentive. - * - * Internally, Remote schedules upcoming incentives. As such, when you attempt to - * delete a recurring incentive, Remote will **ONLY** delete scheduled incentives - * with the `pending` status. + * List countries * - * Incentives payments that are already scheduled and cannot be deleted will be - * included in the response, in case you need to reference them. + * Returns a list of all countries that are supported by Remote API alphabetically ordered. + * The supported list accounts for creating employment with basic information and it does not imply fully onboarding employment via JSON Schema. + * The countries present in the list are the ones where creating a company is allowed. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | + * | Manage company resources (`company_admin`) | View countries (`country:read`) | - | * */ -export const deleteV1IncentivesRecurringId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1Countries = ( + options: Options, ) => - (options.client ?? client).delete< - DeleteV1IncentivesRecurringIdResponses, - DeleteV1IncentivesRecurringIdErrors, + (options.client ?? client).get< + GetV1CountriesResponses, + GetV1CountriesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives/recurring/{id}', - ...options, - }); + >({ url: '/v1/countries', ...options }); /** - * List Incentives + * Show contractor eligibility and COR-supported countries for legal entity + * + * Returns which contractor products (standard, plus, cor) the legal entity is eligible to use, + * and the list of country codes where COR is supported for this legal entity. + * COR-supported countries exclude sanctioned and signup-prevented countries and apply entity rules (same-country, local-to-local). + * When the legal entity is not COR-eligible, `cor_supported_country_codes` is an empty list. * - * Lists all Incentives of a company * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | + * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * */ -export const getV1Incentives = ( - options: Options, -) => - (options.client ?? client).get< - GetV1IncentivesResponses, - GetV1IncentivesErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives', - ...options, - }); +export const getV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibility = + ( + options: Options< + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityData, + ThrowOnError + >, + ) => + (options.client ?? client).get< + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses, + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors, + ThrowOnError + >({ + url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/contractor-eligibility', + ...options, + }); /** - * Create Incentive - * - * Creates an Incentive. - * - * Incentives use the currency of the employment specified provided in the `employment_id` field. + * Convert currency using dynamic rates * + * Convert currency using the rates Remote applies during employment creation and invoicing. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | + * | Manage company resources (`company_admin`) | Convert currencies (`convert_currency:read`) | - | * */ -export const postV1Incentives = ( - options: Options, +export const postV1CurrencyConverterEffective = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => (options.client ?? client).post< - PostV1IncentivesResponses, - PostV1IncentivesErrors, + PostV1CurrencyConverterEffectiveResponses, + PostV1CurrencyConverterEffectiveErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives', + url: '/v1/currency-converter/effective', ...options, headers: { 'Content-Type': 'application/json', @@ -2769,130 +2397,124 @@ export const postV1Incentives = ( }); /** - * Create probation completion letter + * Show personal information for the authenticated employee * - * Create a new probation completion letter request. + * Returns personal information for the authenticated employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage probation documents (`probation_document:write`) | + * | Manage employments (`employments`) | View personal details (`personal_detail:read`) | - | * */ -export const postV1ProbationCompletionLetter = < +export const getV1EmployeePersonalInformation = < ThrowOnError extends boolean = false, >( - options: Options, + options?: Options, ) => - (options.client ?? client).post< - PostV1ProbationCompletionLetterResponses, - PostV1ProbationCompletionLetterErrors, + (options?.client ?? client).get< + GetV1EmployeePersonalInformationResponses, + GetV1EmployeePersonalInformationErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/probation-completion-letter', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/employee/personal-information', ...options }); /** - * Show Contractor Invoice Schedule + * Show form schema + * + * Returns the json schema of a supported form. Possible form names are: + * ``` + * - address_details + * - administrative_details + * - bank_account_details + * - employment_basic_information + * - contractor_basic_information + * - contractor_contract_details + * - billing_address_details + * - contract_details + * - emergency_contact + * - emergency_contact_details + * - employment_document_details + * - personal_details + * - pricing_plan_details + * - company_basic_information + * - global_payroll_administrative_details + * - global_payroll_basic_information + * - global_payroll_contract_details + * - global_payroll_federal_taxes + * - global_payroll_personal_details + * - benefit_renewal_request + * - hris_personal_details + * + * ``` + * + * Most forms require a company access token, as they are dependent on certain + * properties of companies and their current employments. However, the `address_details` + * and `company_basic_information` forms can be accessed using client_credentials + * authentication (without a company). + * * - * Shows a single Contractor Invoice Schedule record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | + * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | * */ -export const getV1ContractorInvoiceSchedulesId = < +export const getV1CountriesCountryCodeForm = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).get< - GetV1ContractorInvoiceSchedulesIdResponses, - GetV1ContractorInvoiceSchedulesIdErrors, + GetV1CountriesCountryCodeFormResponses, + GetV1CountriesCountryCodeFormErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractor-invoice-schedules/{id}', - ...options, - }); + >({ url: '/v1/countries/{country_code}/{form}', ...options }); /** - * Updates Contractor Invoice Schedule + * List Time Off * - * Updates a contractor invoice schedule record + * Lists all Time Off records. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | - | Manage invoices (`invoices:write`) | + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | * */ -export const patchV1ContractorInvoiceSchedulesId2 = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1Timeoff = ( + options: Options, ) => - (options.client ?? client).patch< - PatchV1ContractorInvoiceSchedulesId2Responses, - PatchV1ContractorInvoiceSchedulesId2Errors, + (options.client ?? client).get< + GetV1TimeoffResponses, + GetV1TimeoffErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractor-invoice-schedules/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/timeoff', ...options }); /** - * Updates Contractor Invoice Schedule + * Create Time Off * - * Updates a contractor invoice schedule record + * Creates a Time Off record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | - | Manage invoices (`invoices:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const patchV1ContractorInvoiceSchedulesId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1Timeoff = ( + options: Options, ) => - (options.client ?? client).put< - PatchV1ContractorInvoiceSchedulesIdResponses, - PatchV1ContractorInvoiceSchedulesIdErrors, + (options.client ?? client).post< + PostV1TimeoffResponses, + PostV1TimeoffErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractor-invoice-schedules/{id}', + url: '/v1/timeoff', ...options, headers: { 'Content-Type': 'application/json', @@ -2901,317 +2523,275 @@ export const patchV1ContractorInvoiceSchedulesId = < }); /** - * Show Billing Document + * List countries for Cost Calculator * - * Shows a billing document details. + * Lists active and processing countries + */ +export const getV1CostCalculatorCountries = < + ThrowOnError extends boolean = false, +>( + options?: Options, +) => + (options?.client ?? client).get< + GetV1CostCalculatorCountriesResponses, + unknown, + ThrowOnError + >({ url: '/v1/cost-calculator/countries', ...options }); + +/** + * Submit risk reserve proof of payment * - * Please contact api-support@remote.com to request access to this endpoint. + * Submits a proof of payment document for a risk reserve associated with an employment. + * + * Triggers an `employment.cor_hiring.proof_of_payment_submitted` webhook event. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | + * | Manage company resources (`company_admin`) | - | Manage risk reserves (`risk_reserve:write`) | * */ -export const getV1BillingDocumentsBillingDocumentId = < +export const postV1EmploymentsEmploymentIdRiskReserveProofOfPayments = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsData, + ThrowOnError + >, ) => - (options.client ?? client).get< - GetV1BillingDocumentsBillingDocumentIdResponses, - GetV1BillingDocumentsBillingDocumentIdErrors, + (options.client ?? client).post< + PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses, + PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/billing-documents/{billing_document_id}', + ...formDataBodySerializer, + url: '/v1/employments/{employment_id}/risk-reserve-proof-of-payments', ...options, + headers: { + 'Content-Type': null, + ...options.headers, + }, }); /** - * Creates PDF cost estimation of employments + * Show Background Check + * + * Show Background Check details for a given employment and background check request. + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employments (`employments`) | View background checks (`background_check:read`) | - | * - * Creates a PDF cost estimation of employments based on the provided parameters. */ -export const postV1CostCalculatorEstimationPdf = < +export const getV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckId = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options< + GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdData, + ThrowOnError + >, ) => - (options?.client ?? client).post< - PostV1CostCalculatorEstimationPdfResponses, - PostV1CostCalculatorEstimationPdfErrors, + (options.client ?? client).get< + GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses, + GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/cost-calculator/estimation-pdf', + url: '/v1/employments/{employment_id}/background-checks/{background_check_id}', ...options, - headers: { - 'Content-Type': 'application/json', - ...options?.headers, - }, }); /** - * Show work authorization request + * Show Time Off Balance + * + * Shows the time off balance for the given employment_id. + * + * Deprecated since February 2025 in favour of **[List Leave Policies Summary](#tag/Leave-Policies/operation/get_index_leave_policies_summary)** endpoint. * - * Show a single work authorization request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View work authorizations (`work_authorization:read`) | Manage work authorizations (`work_authorization:write`) | + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * * + * @deprecated */ -export const getV1WorkAuthorizationRequestsId = < +export const getV1TimeoffBalancesEmploymentId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).get< - GetV1WorkAuthorizationRequestsIdResponses, - GetV1WorkAuthorizationRequestsIdErrors, + GetV1TimeoffBalancesEmploymentIdResponses, + GetV1TimeoffBalancesEmploymentIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/work-authorization-requests/{id}', - ...options, - }); + >({ url: '/v1/timeoff-balances/{employment_id}', ...options }); /** - * Update work authorization request + * List expenses for the authenticated employee * - * Updates a work authorization request. + * Returns a paginated list of expenses belonging to the current employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage work authorizations (`work_authorization:write`) | + * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | * */ -export const patchV1WorkAuthorizationRequestsId2 = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1EmployeeExpenses = ( + options?: Options, ) => - (options.client ?? client).patch< - PatchV1WorkAuthorizationRequestsId2Responses, - PatchV1WorkAuthorizationRequestsId2Errors, + (options?.client ?? client).get< + GetV1EmployeeExpensesResponses, + GetV1EmployeeExpensesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/work-authorization-requests/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/employee/expenses', ...options }); /** - * Update work authorization request + * Create an expense for the authenticated employee * - * Updates a work authorization request. + * Creates a new expense record for the current employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage work authorizations (`work_authorization:write`) | + * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | * */ -export const patchV1WorkAuthorizationRequestsId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1EmployeeExpenses = ( + options?: Options, ) => - (options.client ?? client).put< - PatchV1WorkAuthorizationRequestsIdResponses, - PatchV1WorkAuthorizationRequestsIdErrors, + (options?.client ?? client).post< + PostV1EmployeeExpensesResponses, + PostV1EmployeeExpensesErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/work-authorization-requests/{id}', + url: '/v1/employee/expenses', ...options, headers: { 'Content-Type': 'application/json', - ...options.headers, + ...options?.headers, }, }); /** - * Update federal taxes - * - * Updates employment's federal taxes. - * - * Requirements to update federal taxes successfully: - * * Employment should be Global Payroll - * * Employment should be in the post-enrollment state - * * Employment should belong to USA - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. - * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. - * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. - * + * Download a resignation letter * + * Downloads a resignation letter from an employment request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage employment documents (`employment_documents`) | View resignation letters (`resignation_letter:read`) | - | * */ -export const putV2EmploymentsEmploymentIdFederalTaxes = < +export const getV1ResignationsOffboardingRequestIdResignationLetter = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1ResignationsOffboardingRequestIdResignationLetterData, + ThrowOnError + >, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdFederalTaxesResponses, - PutV2EmploymentsEmploymentIdFederalTaxesErrors, + (options.client ?? client).get< + GetV1ResignationsOffboardingRequestIdResignationLetterResponses, + GetV1ResignationsOffboardingRequestIdResignationLetterErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/federal-taxes', + url: '/v1/resignations/{offboarding_request_id}/resignation-letter', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Create Probation Extension + * Deletes a Company Manager user * - * Create a probation extension request. + * Deletes a Company Manager user * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage probation documents (`probation_document:write`) | + * | Manage company resources (`company_admin`) | - | Manage managers (`company_manager:write`) | * */ -export const postV1ProbationExtensions = ( - options: Options, +export const deleteV1CompanyManagersUserId = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).post< - PostV1ProbationExtensionsResponses, - PostV1ProbationExtensionsErrors, + (options.client ?? client).delete< + DeleteV1CompanyManagersUserIdResponses, + DeleteV1CompanyManagersUserIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/probation-extensions', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/company-managers/{user_id}', ...options }); /** - * Update billing address details - * - * Updates employment's billing address details. - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. - * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. - * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. - * + * Show company manager user * + * Shows a single company manager user * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage company resources (`company_admin`) | View managers (`company_manager:read`) | Manage managers (`company_manager:write`) | * */ -export const putV2EmploymentsEmploymentIdBillingAddressDetails = < +export const getV1CompanyManagersUserId = < ThrowOnError extends boolean = false, >( - options: Options< - PutV2EmploymentsEmploymentIdBillingAddressDetailsData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses, - PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors, + (options.client ?? client).get< + GetV1CompanyManagersUserIdResponses, + GetV1CompanyManagersUserIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/billing_address_details', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/company-managers/{user_id}', ...options }); /** - * Update address details + * Show onboarding steps for an employment * - * Updates employment's address details. + * Returns onboarding steps and substeps in a hierarchical, ordered structure. + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * + */ +export const getV1EmploymentsEmploymentIdOnboardingSteps = < + ThrowOnError extends boolean = false, +>( + options: Options< + GetV1EmploymentsEmploymentIdOnboardingStepsData, + ThrowOnError + >, +) => + (options.client ?? client).get< + GetV1EmploymentsEmploymentIdOnboardingStepsResponses, + GetV1EmploymentsEmploymentIdOnboardingStepsErrors, + ThrowOnError + >({ url: '/v1/employments/{employment_id}/onboarding-steps', ...options }); + +/** + * Automatable Contract Amendment + * + * Check if a contract amendment request is automatable. + * If the contract amendment request is automatable, then after submission, it will instantly amend the employee's contract + * and send them an updated document. * * This endpoint requires and returns country-specific data. The exact required and returned fields will * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * see the **Show form schema** endpoint under the [Contract Amendments](#tag/Contract-Amendments) category. * * Please note that the compliance requirements for each country are subject to change according to local * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid @@ -3223,7 +2803,7 @@ export const putV2EmploymentsEmploymentIdBillingAddressDetails = < * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. * * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. * * * @@ -3231,27 +2811,20 @@ export const putV2EmploymentsEmploymentIdBillingAddressDetails = < * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | - | Manage contract amendments (`contract_amendment:write`) | * */ -export const putV2EmploymentsEmploymentIdAddressDetails = < +export const postV1ContractAmendmentsAutomatable = < ThrowOnError extends boolean = false, >( - options: Options< - PutV2EmploymentsEmploymentIdAddressDetailsData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdAddressDetailsResponses, - PutV2EmploymentsEmploymentIdAddressDetailsErrors, + (options.client ?? client).post< + PostV1ContractAmendmentsAutomatableResponses, + PostV1ContractAmendmentsAutomatableErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/address_details', + url: '/v1/contract-amendments/automatable', ...options, headers: { 'Content-Type': 'application/json', @@ -3260,348 +2833,296 @@ export const putV2EmploymentsEmploymentIdAddressDetails = < }); /** - * Create risk reserve + * List Company Payroll Runs * - * Create a new risk reserve + * Lists all payroll runs for a company * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage risk reserves (`risk_reserve:write`) | + * | Manage payroll runs (`payroll`) | View payroll runs (`payroll_run:read`) | - | * */ -export const postV1RiskReserve = ( - options: Options, +export const getV1PayrollRuns = ( + options?: Options, ) => - (options.client ?? client).post< - PostV1RiskReserveResponses, - PostV1RiskReserveErrors, + (options?.client ?? client).get< + GetV1PayrollRunsResponses, + GetV1PayrollRunsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/risk-reserve', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/payroll-runs', ...options }); /** - * Submit risk reserve proof of payment - * - * Submits a proof of payment document for a risk reserve associated with an employment. - * - * Triggers an `employment.cor_hiring.proof_of_payment_submitted` webhook event. + * List incentives for the authenticated employee * + * Returns all incentives for the authenticated employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage risk reserves (`risk_reserve:write`) | + * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | * */ -export const postV1EmploymentsEmploymentIdRiskReserveProofOfPayments = < +export const getV1EmployeeIncentives = ( + options?: Options, +) => + (options?.client ?? client).get< + GetV1EmployeeIncentivesResponses, + GetV1EmployeeIncentivesErrors, + ThrowOnError + >({ url: '/v1/employee/incentives', ...options }); + +/** + * Update employment + * + * Updates an employment. Use this endpoint to: + * - modify employment states for testing + * - Backdate employment start dates + * + * This endpoint will respond with a 404 outside of the Sandbox environment. + * + * For updating an employment's parameters outside of testing purposes, use [this Employment update endpoint](#operation/patch_update_employment). + * + */ +export const patchV1SandboxEmploymentsEmploymentId2 = < ThrowOnError extends boolean = false, >( - options: Options< - PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).post< - PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses, - PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors, + (options.client ?? client).patch< + PatchV1SandboxEmploymentsEmploymentId2Responses, + PatchV1SandboxEmploymentsEmploymentId2Errors, ThrowOnError >({ - ...formDataBodySerializer, - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/risk-reserve-proof-of-payments', + url: '/v1/sandbox/employments/{employment_id}', ...options, headers: { - 'Content-Type': null, + 'Content-Type': 'application/json', ...options.headers, }, }); /** - * Get Company Compliance Profile - * - * Returns the KYB and credit risk status for the company's default legal entity. + * Update employment * + * Updates an employment. Use this endpoint to: + * - modify employment states for testing + * - Backdate employment start dates * - * ## Scopes + * This endpoint will respond with a 404 outside of the Sandbox environment. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | + * For updating an employment's parameters outside of testing purposes, use [this Employment update endpoint](#operation/patch_update_employment). * */ -export const getV1CompaniesCompanyIdComplianceProfile = < +export const patchV1SandboxEmploymentsEmploymentId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).get< - GetV1CompaniesCompanyIdComplianceProfileResponses, - GetV1CompaniesCompanyIdComplianceProfileErrors, + (options.client ?? client).put< + PatchV1SandboxEmploymentsEmploymentIdResponses, + PatchV1SandboxEmploymentsEmploymentIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/compliance-profile', + url: '/v1/sandbox/employments/{employment_id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Show product prices in the company's desired currency + * Show benefit renewal request schema * - * list product prices in the company's desired currency. - * the endpoint currently only returns the product prices for the EOR monthly product and the contractor products (Standard, Plus and COR). - * the product prices are then used to create a pricing plan for the company. + * Returns the json schema of the `benefit_renewal_request` form for a specific request. + * This endpoint requires a company access token, as forms are dependent on certain + * properties of companies and their current employments. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage companies (`company_management`) | View pricing plans (`pricing_plan:read`) | Manage pricing plans (`pricing_plan:write`) | + * | Manage company resources (`company_admin`) | View benefit renewals (`benefit_renewal:read`) | Manage benefit renewals (`benefit_renewal:write`) | * */ -export const getV1CompaniesCompanyIdProductPrices = < +export const getV1BenefitRenewalRequestsBenefitRenewalRequestIdSchema = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1CompaniesCompanyIdProductPricesResponses, - GetV1CompaniesCompanyIdProductPricesErrors, + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses, + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies/{company_id}/product-prices', + url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}/schema', ...options, }); /** - * Show a company + * Update billing address details * - * Given an ID, shows a company. + * Updates employment's billing address details. + * + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. * - * If the used access token was issued by the OAuth 2.0 Authorization Code flow, - * then only the associated company can be accessed through the endpoint. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const getV1CompaniesCompanyId = ( - options: Options, +export const putV2EmploymentsEmploymentIdBillingAddressDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + PutV2EmploymentsEmploymentIdBillingAddressDetailsData, + ThrowOnError + >, ) => - (options.client ?? client).get< - GetV1CompaniesCompanyIdResponses, - GetV1CompaniesCompanyIdErrors, + (options.client ?? client).put< + PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses, + PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}', + url: '/v2/employments/{employment_id}/billing_address_details', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Update a company - * - * Given an ID and a request object with new information, updates a company. + * Delete an Incentive * - * ### Getting a company and its owner to `active` status - * If you created a company using the - * [create a company endpoint](#tag/Companies/operation/post_create_company) without all the required - * request body parameters, you can use this endpoint to provide the missing data. Once the company - * and its owner have all the necessary data, both their statuses will be set to `active` and the company - * onboarding will be marked as "completed". + * Delete an incentive. * - * The following constitutes a company with "all the necessary data": - * * Complete `address`, with valid `address`, `postal_code`, `country` and `state` parameters (Varies by country. Use the - * [show form schema endpoint](#tag/Countries/operation/get_show_form_country) to see which address parameters - * are required). - * * Company `tax_number` or `registration_number` is not nil - * * Company `name` is not nil (already required when creating the company) - * * Company has a `desired_currency` in their bank account (already required when creating the company) - * * Company has accepted terms of service (already required when creating the company) + * `one_time` incentives that have the following status **CANNOT** be deleted: + * * `processing` + * * `paid` * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | + * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | * */ -export const patchV1CompaniesCompanyId2 = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const deleteV1IncentivesId = ( + options: Options, ) => - (options.client ?? client).patch< - PatchV1CompaniesCompanyId2Responses, - PatchV1CompaniesCompanyId2Errors, + (options.client ?? client).delete< + DeleteV1IncentivesIdResponses, + DeleteV1IncentivesIdErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies/{company_id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/incentives/{id}', ...options }); /** - * Update a company - * - * Given an ID and a request object with new information, updates a company. - * - * ### Getting a company and its owner to `active` status - * If you created a company using the - * [create a company endpoint](#tag/Companies/operation/post_create_company) without all the required - * request body parameters, you can use this endpoint to provide the missing data. Once the company - * and its owner have all the necessary data, both their statuses will be set to `active` and the company - * onboarding will be marked as "completed". - * - * The following constitutes a company with "all the necessary data": - * * Complete `address`, with valid `address`, `postal_code`, `country` and `state` parameters (Varies by country. Use the - * [show form schema endpoint](#tag/Countries/operation/get_show_form_country) to see which address parameters - * are required). - * * Company `tax_number` or `registration_number` is not nil - * * Company `name` is not nil (already required when creating the company) - * * Company has a `desired_currency` in their bank account (already required when creating the company) - * * Company has accepted terms of service (already required when creating the company) + * Show Incentive * + * Show an Incentive's details * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | + * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | * */ -export const patchV1CompaniesCompanyId = ( - options: Options, +export const getV1IncentivesId = ( + options: Options, ) => - (options.client ?? client).put< - PatchV1CompaniesCompanyIdResponses, - PatchV1CompaniesCompanyIdErrors, + (options.client ?? client).get< + GetV1IncentivesIdResponses, + GetV1IncentivesIdErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies/{company_id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/incentives/{id}', ...options }); /** - * Download a resignation letter + * Update Incentive + * + * Updates an Incentive. + * + * Incentives use the currency of the employment specified provided in the `employment_id` field. + * + * The API doesn't support updating paid incentives. * - * Downloads a resignation letter from an employment request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View resignation letters (`resignation_letter:read`) | - | + * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | * */ -export const getV1ResignationsOffboardingRequestIdResignationLetter = < - ThrowOnError extends boolean = false, ->( - options: Options< - GetV1ResignationsOffboardingRequestIdResignationLetterData, - ThrowOnError - >, +export const patchV1IncentivesId2 = ( + options: Options, ) => - (options.client ?? client).get< - GetV1ResignationsOffboardingRequestIdResignationLetterResponses, - GetV1ResignationsOffboardingRequestIdResignationLetterErrors, + (options.client ?? client).patch< + PatchV1IncentivesId2Responses, + PatchV1IncentivesId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/resignations/{offboarding_request_id}/resignation-letter', + url: '/v1/incentives/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Update federal taxes - * - * Updates employment's federal taxes. - * - * Requirements to update federal taxes successfully: - * * Employment should be Global Payroll - * * Employment should be in the post-enrollment state - * * Employment should belong to USA - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * Update Incentive * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * Updates an Incentive. * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * Incentives use the currency of the employment specified provided in the `employment_id` field. * + * The API doesn't support updating paid incentives. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | * */ -export const putV1EmploymentsEmploymentIdFederalTaxes = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const patchV1IncentivesId = ( + options: Options, ) => (options.client ?? client).put< - PutV1EmploymentsEmploymentIdFederalTaxesResponses, - PutV1EmploymentsEmploymentIdFederalTaxesErrors, + PatchV1IncentivesIdResponses, + PatchV1IncentivesIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/federal-taxes', + url: '/v1/incentives/{id}', ...options, headers: { 'Content-Type': 'application/json', @@ -3610,41 +3131,75 @@ export const putV1EmploymentsEmploymentIdFederalTaxes = < }); /** - * List Contract Amendment + * Show Legal Entity Administrative details + * + * Show administrative details of legal entity for the authorized company specified in the request. * - * List Contract Amendment requests. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View contract amendments (`contract_amendment:read`) | Manage contract amendments (`contract_amendment:write`) | + * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * */ -export const getV1ContractAmendments = ( - options: Options, -) => - (options.client ?? client).get< - GetV1ContractAmendmentsResponses, - GetV1ContractAmendmentsErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contract-amendments', - ...options, - }); +export const getV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetails = + ( + options: Options< + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData, + ThrowOnError + >, + ) => + (options.client ?? client).get< + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses, + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors, + ThrowOnError + >({ + url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details', + ...options, + }); /** - * Create Contract Amendment + * Update Legal Entity Administrative details * - * Creates a Contract Amendment request. + * Update administrative details of legal entity for the authorized company specified in the request. + * + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | + * + */ +export const putV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetails = + ( + options: Options< + PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData, + ThrowOnError + >, + ) => + (options.client ?? client).put< + PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses, + PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors, + ThrowOnError + >({ + url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); + +/** + * Update bank account details + * + * Updates employment's bank account details. * * This endpoint requires and returns country-specific data. The exact required and returned fields will * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Contract Amendments](#tag/Contract-Amendments) category. + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. * * Please note that the compliance requirements for each country are subject to change according to local * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid @@ -3656,7 +3211,7 @@ export const getV1ContractAmendments = ( * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. * * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. * * * @@ -3664,22 +3219,23 @@ export const getV1ContractAmendments = ( * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage contract amendments (`contract_amendment:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1ContractAmendments = ( - options: Options, +export const putV2EmploymentsEmploymentIdBankAccountDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + PutV2EmploymentsEmploymentIdBankAccountDetailsData, + ThrowOnError + >, ) => - (options.client ?? client).post< - PostV1ContractAmendmentsResponses, - PostV1ContractAmendmentsErrors, + (options.client ?? client).put< + PutV2EmploymentsEmploymentIdBankAccountDetailsResponses, + PutV2EmploymentsEmploymentIdBankAccountDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contract-amendments', + url: '/v2/employments/{employment_id}/bank_account_details', ...options, headers: { 'Content-Type': 'application/json', @@ -3688,203 +3244,211 @@ export const postV1ContractAmendments = ( }); /** - * Show Company Payroll Runs - * - * Given an ID, shows a payroll run. - * `employee_details` field is deprecated in favour of the `employee_details` endpoint and will be removed in the future. + * List Contractor Invoices * + * Lists Contractor Invoice records. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage payroll runs (`payroll`) | View payroll runs (`payroll_run:read`) | - | + * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | * */ -export const getV1PayrollRunsPayrollRunId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1ContractorInvoices = ( + options?: Options, ) => - (options.client ?? client).get< - GetV1PayrollRunsPayrollRunIdResponses, - GetV1PayrollRunsPayrollRunIdErrors, + (options?.client ?? client).get< + GetV1ContractorInvoicesResponses, + GetV1ContractorInvoicesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/payroll-runs/{payroll_run_id}', - ...options, - }); + >({ url: '/v1/contractor-invoices', ...options }); /** - * Download a receipt - * - * Downloads an expense receipt. + * List expense categories * - * Deprecated since late February 2024 in favour of **[Download a receipt by id](#tag/Expenses/operation/get_download_by_id_expense_receipt)** endpoint. + * Lists the effective hierarchy of expense categories. At least one of employment_id, expense_id, or country_code must be provided. + */ +export const getV1ExpensesCategories = ( + options?: Options, +) => + (options?.client ?? client).get< + GetV1ExpensesCategoriesResponses, + GetV1ExpensesCategoriesErrors, + ThrowOnError + >({ url: '/v1/expenses/categories', ...options }); + +/** + * List contract documents for an employment * + * Only contractor employment types are supported. Lists contract documents for a specific employment with pagination, filtering by status, and sorted by updated_at descending (latest first). * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | - * + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | * - * @deprecated */ -export const getV1ExpensesExpenseIdReceipt = < +export const getV1EmploymentsEmploymentIdContractDocuments = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1EmploymentsEmploymentIdContractDocumentsData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1ExpensesExpenseIdReceiptResponses, - GetV1ExpensesExpenseIdReceiptErrors, + GetV1EmploymentsEmploymentIdContractDocumentsResponses, + GetV1EmploymentsEmploymentIdContractDocumentsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses/{expense_id}/receipt', - ...options, - }); + >({ url: '/v1/employments/{employment_id}/contract-documents', ...options }); /** - * Show travel letter request + * Show contractor contract details * - * Show a single travel letter request. + * Returns the contract details JSON Schema for contractors given a country * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | - | View travel letters (`travel_letter:read`) | - | + * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | * */ -export const getV1TravelLetterRequestsId = < +export const getV1CountriesCountryCodeContractorContractDetails = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1CountriesCountryCodeContractorContractDetailsData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1TravelLetterRequestsIdResponses, - GetV1TravelLetterRequestsIdErrors, + GetV1CountriesCountryCodeContractorContractDetailsResponses, + GetV1CountriesCountryCodeContractorContractDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/travel-letter-requests/{id}', + url: '/v1/countries/{country_code}/contractor-contract-details', ...options, }); /** - * Updates a travel letter request + * Get user by ID via SCIM v2.0 + * + * Retrieves a single user for the authenticated company by user ID + */ +export const getV1ScimV2UsersId = ( + options: Options, +) => + (options.client ?? client).get< + GetV1ScimV2UsersIdResponses, + GetV1ScimV2UsersIdErrors, + ThrowOnError + >({ + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/scim/v2/Users/{id}', + ...options, + }); + +/** + * List employment files + * + * Lists files associated with a specific employment. + * + * Supports filtering by file type and sub_type. * - * Updates a travel letter request * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | - | - | Manage travel letters (`travel_letter:write`) | + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | * */ -export const patchV1TravelLetterRequestsId2 = < +export const getV1EmploymentsEmploymentIdFiles = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).patch< - PatchV1TravelLetterRequestsId2Responses, - PatchV1TravelLetterRequestsId2Errors, + (options.client ?? client).get< + GetV1EmploymentsEmploymentIdFilesResponses, + GetV1EmploymentsEmploymentIdFilesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/travel-letter-requests/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/employments/{employment_id}/files', ...options }); /** - * Updates a travel letter request + * Manage contractor plus subscription + * + * Endpoint that can be used to upgrade, assign or downgrade a contractor's subscription. + * This can be used when company admins desire to assign someone to the Contractor Plus plan, + * but also to change the contractor's subscription between Plus and Standard. * - * Updates a travel letter request * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | - | - | Manage travel letters (`travel_letter:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const patchV1TravelLetterRequestsId = < - ThrowOnError extends boolean = false, ->( - options: Options, -) => - (options.client ?? client).put< - PatchV1TravelLetterRequestsIdResponses, - PatchV1TravelLetterRequestsIdErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/travel-letter-requests/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); +export const postV1ContractorsEmploymentsEmploymentIdContractorPlusSubscription = + ( + options: Options< + PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionData, + ThrowOnError + >, + ) => + (options.client ?? client).post< + PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses, + PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors, + ThrowOnError + >({ + url: '/v1/contractors/employments/{employment_id}/contractor-plus-subscription', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); /** - * Show Time Off Balance + * Submit eligibility questionnaire * - * Shows the time off balance for the given employment_id. + * Submits an eligibility questionnaire for a contractor employment. * - * Deprecated since February 2025 in favour of **[List Leave Policies Summary](#tag/Leave-Policies/operation/get_index_leave_policies_summary)** endpoint. + * The questionnaire determines if the contractor is eligible for certain products or features. + * The responses are validated against the JSON schema for the questionnaire type. + * + * **Requirements:** + * - Employment must be of type `contractor` + * - Employment must be in `created` status + * - Responses must conform to the questionnaire JSON schema * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | - * + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * - * @deprecated */ -export const getV1TimeoffBalancesEmploymentId = < +export const postV1ContractorsEligibilityQuestionnaire = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).get< - GetV1TimeoffBalancesEmploymentIdResponses, - GetV1TimeoffBalancesEmploymentIdErrors, + (options.client ?? client).post< + PostV1ContractorsEligibilityQuestionnaireResponses, + PostV1ContractorsEligibilityQuestionnaireErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff-balances/{employment_id}', + url: '/v1/contractors/eligibility-questionnaire', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** @@ -3932,10 +3496,6 @@ export const putV1EmploymentsEmploymentIdBasicInformation = < PutV1EmploymentsEmploymentIdBasicInformationErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], url: '/v1/employments/{employment_id}/basic_information', ...options, headers: { @@ -3945,50 +3505,58 @@ export const putV1EmploymentsEmploymentIdBasicInformation = < }); /** - * List expense categories + * Show a contractor of record (COR) termination request * - * Lists the effective hierarchy of expense categories. At least one of employment_id, expense_id, or country_code must be provided. - */ -export const getV1ExpensesCategories = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1ExpensesCategoriesResponses, - GetV1ExpensesCategoriesErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses/categories', - ...options, - }); - -/** - * Cancel Time Off as Employee + * Retrieves a Contractor of Record termination request by ID. * - * Cancels a Time Off record as Employee * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const postV1EmployeeTimeoffIdCancel = < +export const getV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestId = + ( + options: Options< + GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdData, + ThrowOnError + >, + ) => + (options.client ?? client).get< + GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses, + GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors, + ThrowOnError + >({ + url: '/v1/contractors/employments/{employment_id}/cor-termination-requests/{termination_request_id}', + ...options, + }); + +/** + * Create a legal entity + * + * Create a new legal entity for a company in a given country, with KYB automatically passed. + * + * The entity is created with active status and can be set as the company's default + * using the reassign default entity endpoint. + * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * + */ +export const postV1SandboxCompaniesCompanyIdLegalEntities = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PostV1SandboxCompaniesCompanyIdLegalEntitiesData, + ThrowOnError + >, ) => (options.client ?? client).post< - PostV1EmployeeTimeoffIdCancelResponses, - PostV1EmployeeTimeoffIdCancelErrors, + PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses, + PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/timeoff/{id}/cancel', + url: '/v1/sandbox/companies/{company_id}/legal-entities', ...options, headers: { 'Content-Type': 'application/json', @@ -3997,172 +3565,93 @@ export const postV1EmployeeTimeoffIdCancel = < }); /** - * Show form schema - * - * Returns the json schema of a supported form. Possible form names are: - * ``` - * - address_details - * - administrative_details - * - bank_account_details - * - employment_basic_information - * - contractor_basic_information - * - contractor_contract_details - * - billing_address_details - * - contract_details - * - emergency_contact - * - emergency_contact_details - * - employment_document_details - * - personal_details - * - pricing_plan_details - * - company_basic_information - * - global_payroll_administrative_details - * - global_payroll_basic_information - * - global_payroll_contract_details - * - global_payroll_federal_taxes - * - global_payroll_personal_details - * - benefit_renewal_request - * - hris_personal_details - * - * ``` - * - * Most forms require a company access token, as they are dependent on certain - * properties of companies and their current employments. However, the `address_details` - * and `company_basic_information` forms can be accessed using client_credentials - * authentication (without a company). - * - * - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | + * Payroll processing details data API resource * + * API to retrieve the run details of a pay group */ -export const getV1CountriesCountryCodeForm = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1WdGphPayDetailData = ( + options: Options, ) => (options.client ?? client).get< - GetV1CountriesCountryCodeFormResponses, - GetV1CountriesCountryCodeFormErrors, + GetV1WdGphPayDetailDataResponses, + GetV1WdGphPayDetailDataErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/countries/{country_code}/{form}', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/wd/gph/payDetailData', ...options, }); /** - * Download file - * - * Downloads a file. - * - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | + * Show region fields * + * Returns required fields JSON Schema for a given region. These are required in order to calculate + * the cost of employment for the region. These fields are based on employer contributions that are associated + * with the region or any of it's parent regions. */ -export const getV1FilesId = ( - options: Options, +export const getV1CostCalculatorRegionsSlugFields = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => (options.client ?? client).get< - GetV1FilesIdResponses, - GetV1FilesIdErrors, + GetV1CostCalculatorRegionsSlugFieldsResponses, + GetV1CostCalculatorRegionsSlugFieldsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/files/{id}', - ...options, - }); + >({ url: '/v1/cost-calculator/regions/{slug}/fields', ...options }); /** - * Show Contract Amendment + * Cancel onboarding + * + * Cancel onboarding. + * + * Requirements for the cancellation to succeed: + * + * * Employment has to be in `invited`, `created`, `created_awaiting_reserve`, `created_reserve_paid`, `pre_hire` status + * * Employee must not have signed the employment contract * - * Show a single Contract Amendment request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View contract amendments (`contract_amendment:read`) | Manage contract amendments (`contract_amendment:write`) | + * | Manage employments (`employments`) | - | Manage onboarding (`onboarding:write`) | * */ -export const getV1ContractAmendmentsId = ( - options: Options, +export const postV1CancelOnboardingEmploymentId = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).get< - GetV1ContractAmendmentsIdResponses, - GetV1ContractAmendmentsIdErrors, + (options.client ?? client).post< + PostV1CancelOnboardingEmploymentIdResponses, + PostV1CancelOnboardingEmploymentIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contract-amendments/{id}', - ...options, - }); + >({ url: '/v1/cancel-onboarding/{employment_id}', ...options }); /** - * Update bank account details - * - * Updates employment's bank account details. - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. - * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. - * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. - * + * Cancel Time Off as Employee * + * Cancels a Time Off record as Employee * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const putV2EmploymentsEmploymentIdBankAccountDetails = < +export const postV1EmployeeTimeoffIdCancel = < ThrowOnError extends boolean = false, >( - options: Options< - PutV2EmploymentsEmploymentIdBankAccountDetailsData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdBankAccountDetailsResponses, - PutV2EmploymentsEmploymentIdBankAccountDetailsErrors, + (options.client ?? client).post< + PostV1EmployeeTimeoffIdCancelResponses, + PostV1EmployeeTimeoffIdCancelErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/bank_account_details', + url: '/v1/employee/timeoff/{id}/cancel', ...options, headers: { 'Content-Type': 'application/json', @@ -4171,243 +3660,139 @@ export const putV2EmploymentsEmploymentIdBankAccountDetails = < }); /** - * List Company Managers - * - * List all company managers of an integration. If filtered by the company_id param, - * it lists only company managers belonging to the specified company. - * - * - * ## Scopes + * Download a receipt * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | View managers (`company_manager:read`) | Manage managers (`company_manager:write`) | + * Downloads an expense receipt. * - */ -export const getV1CompanyManagers = ( - options: Options, -) => - (options.client ?? client).get< - GetV1CompanyManagersResponses, - GetV1CompanyManagersErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/company-managers', - ...options, - }); - -/** - * Create and invite a Company Manager + * Deprecated since late February 2024 in favour of **[Download a receipt by id](#tag/Expenses/operation/get_download_by_id_expense_receipt)** endpoint. * - * Create a Company Manager and sends the invitation email for signing in to the Remote Platform. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage managers (`company_manager:write`) | + * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | * - */ -export const postV1CompanyManagers = ( - options: Options, -) => - (options.client ?? client).post< - PostV1CompanyManagersResponses, - PostV1CompanyManagersErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/company-managers', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); - -/** - * List countries for Cost Calculator * - * Lists active and processing countries + * @deprecated */ -export const getV1CostCalculatorCountries = < +export const getV1ExpensesExpenseIdReceipt = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options, ) => - (options?.client ?? client).get< - GetV1CostCalculatorCountriesResponses, - unknown, + (options.client ?? client).get< + GetV1ExpensesExpenseIdReceiptResponses, + GetV1ExpensesExpenseIdReceiptErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/cost-calculator/countries', - ...options, - }); + >({ url: '/v1/expenses/{expense_id}/receipt', ...options }); /** - * Decline Identity Verification + * List Benefit Offers * - * Declines the identity verification of an employee. + * List benefit offers for each country. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage identity verification (`identity_verification:write`) | + * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | * */ -export const postV1IdentityVerificationEmploymentIdDecline = < +export const getV1BenefitOffersCountrySummaries = < ThrowOnError extends boolean = false, >( - options: Options< - PostV1IdentityVerificationEmploymentIdDeclineData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).post< - PostV1IdentityVerificationEmploymentIdDeclineResponses, - PostV1IdentityVerificationEmploymentIdDeclineErrors, + (options.client ?? client).get< + GetV1BenefitOffersCountrySummariesResponses, + GetV1BenefitOffersCountrySummariesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/identity-verification/{employment_id}/decline', - ...options, - }); + >({ url: '/v1/benefit-offers/country-summaries', ...options }); /** - * Show engagement agreement details - * - * Returns the engagement agreement details JSON Schema for a country. Only DEU country is supported for now. + * List Leave Policies Details * + * Describe the leave policies (custom or not) for a given employment * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | * */ -export const getV1CountriesCountryCodeEngagementAgreementDetails = < +export const getV1LeavePoliciesDetailsEmploymentId = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1CountriesCountryCodeEngagementAgreementDetailsData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1CountriesCountryCodeEngagementAgreementDetailsResponses, - GetV1CountriesCountryCodeEngagementAgreementDetailsErrors, + GetV1LeavePoliciesDetailsEmploymentIdResponses, + GetV1LeavePoliciesDetailsEmploymentIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/countries/{country_code}/engagement-agreement-details', - ...options, - }); + >({ url: '/v1/leave-policies/details/{employment_id}', ...options }); /** - * List Billing Documents + * List work authorization requests * - * List billing documents for a company + * List work authorization requests. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | + * | Manage employments (`employments`) | View work authorizations (`work_authorization:read`) | Manage work authorizations (`work_authorization:write`) | * */ -export const getV1BillingDocuments = ( - options: Options, +export const getV1WorkAuthorizationRequests = < + ThrowOnError extends boolean = false, +>( + options?: Options, ) => - (options.client ?? client).get< - GetV1BillingDocumentsResponses, - GetV1BillingDocumentsErrors, + (options?.client ?? client).get< + GetV1WorkAuthorizationRequestsResponses, + GetV1WorkAuthorizationRequestsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/billing-documents', - ...options, - }); + >({ url: '/v1/work-authorization-requests', ...options }); /** - * Delete a Webhook Callback - * - * Delete a callback previously registered for webhooks + * Get employment benefit offers * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | + * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | * */ -export const deleteV1WebhookCallbacksId = < +export const getV1EmploymentsEmploymentIdBenefitOffers = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).delete< - DeleteV1WebhookCallbacksIdResponses, - DeleteV1WebhookCallbacksIdErrors, + (options.client ?? client).get< + GetV1EmploymentsEmploymentIdBenefitOffersResponses, + GetV1EmploymentsEmploymentIdBenefitOffersErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/webhook-callbacks/{id}', - ...options, - }); + >({ url: '/v1/employments/{employment_id}/benefit-offers', ...options }); /** - * Update a Webhook Callback - * - * Update a callback previously registered for webhooks - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | - * + * Upserts employment benefit offers */ -export const patchV1WebhookCallbacksId = ( - options: Options, +export const putV1EmploymentsEmploymentIdBenefitOffers = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).patch< - PatchV1WebhookCallbacksIdResponses, - PatchV1WebhookCallbacksIdErrors, + (options.client ?? client).put< + PutV1EmploymentsEmploymentIdBenefitOffersResponses, + PutV1EmploymentsEmploymentIdBenefitOffersErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/webhook-callbacks/{id}', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/employments/{employment_id}/benefit-offers', ...options, headers: { 'Content-Type': 'application/json', @@ -4416,34 +3801,54 @@ export const patchV1WebhookCallbacksId = ( }); /** - * List timesheets for the authenticated employee + * List employments * - * Returns a paginated list of timesheets for the authenticated employee. + * Lists all employments, except for the deleted ones. * - * ## Scopes + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timesheets (`timesheet:read`) | Manage timesheets (`timesheet:write`) | * */ -export const getV1EmployeeTimesheets = ( - options?: Options, +export const getV1Employments = ( + options: Options, ) => - (options?.client ?? client).get< - GetV1EmployeeTimesheetsResponses, - GetV1EmployeeTimesheetsErrors, + (options.client ?? client).get< + GetV1EmploymentsResponses, + GetV1EmploymentsErrors, ThrowOnError >({ security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/timesheets', + url: '/v1/employments', ...options, }); /** - * Update personal details + * Create employment * - * Updates employment's personal details. + * Creates an employment. We support creating employees and contractors. + * + * ## Global Payroll Employees + * + * To create a Global Payroll employee, pass `global_payroll_employee` as the `type` parameter, + * and provide the slug of the specific legal entity that the employee will be engaged by and billed to as the `engaged_by_entity_slug` parameter. + * + * ## HRIS Employees + * + * To create a HRIS employee, pass `hris` as the `type` parameter. * * This endpoint requires and returns country-specific data. The exact required and returned fields will * vary depending on which country the employment is in. To see the list of parameters for each country, @@ -4459,7 +3864,7 @@ export const getV1EmployeeTimesheets = ( * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. * * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. * * * @@ -4470,24 +3875,15 @@ export const getV1EmployeeTimesheets = ( * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const putV1EmploymentsEmploymentIdPersonalDetails = < - ThrowOnError extends boolean = false, ->( - options: Options< - PutV1EmploymentsEmploymentIdPersonalDetailsData, - ThrowOnError - >, +export const postV1Employments = ( + options: Options, ) => - (options.client ?? client).put< - PutV1EmploymentsEmploymentIdPersonalDetailsResponses, - PutV1EmploymentsEmploymentIdPersonalDetailsErrors, + (options.client ?? client).post< + PostV1EmploymentsResponses, + PostV1EmploymentsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/personal_details', + url: '/v1/employments', ...options, headers: { 'Content-Type': 'application/json', @@ -4496,88 +3892,81 @@ export const putV1EmploymentsEmploymentIdPersonalDetails = < }); /** - * List travel letter requests + * Show Time Off * - * List travel letter requests. + * Shows a single Time Off record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | - | View travel letters (`travel_letter:read`) | - | + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | * */ -export const getV1TravelLetterRequests = ( - options?: Options, +export const getV1TimeoffId = ( + options: Options, ) => - (options?.client ?? client).get< - GetV1TravelLetterRequestsResponses, - GetV1TravelLetterRequestsErrors, + (options.client ?? client).get< + GetV1TimeoffIdResponses, + GetV1TimeoffIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/travel-letter-requests', - ...options, - }); + >({ url: '/v1/timeoff/{id}', ...options }); /** - * List Benefit Renewal Requests + * Update Time Off + * + * Updates a Time Off record. + * Warning: Updating the status of a time off through this endpoint is deprecated and will be removed on January 13, 2025. + * To approve or cancel an approved time off, use the `/approve` and `/cancel` endpoints instead. * - * List Benefit Renewal Requests for each country. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View benefit renewals (`benefit_renewal:read`) | Manage benefit renewals (`benefit_renewal:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const getV1BenefitRenewalRequests = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const patchV1TimeoffId2 = ( + options: Options, ) => - (options.client ?? client).get< - GetV1BenefitRenewalRequestsResponses, - GetV1BenefitRenewalRequestsErrors, + (options.client ?? client).patch< + PatchV1TimeoffId2Responses, + PatchV1TimeoffId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/benefit-renewal-requests', + url: '/v1/timeoff/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Create a Webhook Callback + * Update Time Off + * + * Updates a Time Off record. + * Warning: Updating the status of a time off through this endpoint is deprecated and will be removed on January 13, 2025. + * To approve or cancel an approved time off, use the `/approve` and `/cancel` endpoints instead. * - * Register a callback to be used for webhooks * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const postV1WebhookCallbacks = ( - options: Options, +export const patchV1TimeoffId = ( + options: Options, ) => - (options.client ?? client).post< - PostV1WebhookCallbacksResponses, - PostV1WebhookCallbacksErrors, + (options.client ?? client).put< + PatchV1TimeoffIdResponses, + PatchV1TimeoffIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/webhook-callbacks', + url: '/v1/timeoff/{id}', ...options, headers: { 'Content-Type': 'application/json', @@ -4586,270 +3975,302 @@ export const postV1WebhookCallbacks = ( }); /** - * Approve timesheet - * - * Approves the given timesheet. + * Get token identity * - * ## Scopes + * Shows information about the entities that can be controlled by the current auth token. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timesheets (`timesheet:write`) | + */ +export const getV1IdentityCurrent = ( + options: Options, +) => + (options.client ?? client).get< + GetV1IdentityCurrentResponses, + GetV1IdentityCurrentErrors, + ThrowOnError + >({ url: '/v1/identity/current', ...options }); + +/** + * Payroll Variance Analysis API resource * + * API to retrieve the variance analysis data of a pay group */ -export const postV1TimesheetsTimesheetIdApprove = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1WdGphPayVariance = ( + options: Options, ) => - (options.client ?? client).post< - PostV1TimesheetsTimesheetIdApproveResponses, - PostV1TimesheetsTimesheetIdApproveErrors, + (options.client ?? client).get< + GetV1WdGphPayVarianceResponses, + GetV1WdGphPayVarianceErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timesheets/{timesheet_id}/approve', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/wd/gph/payVariance', ...options, }); /** - * Show payslip - * - * Given an ID, shows a payslip. - * - * Please contact api-support@remote.com to request access to this endpoint. + * List Company Payroll Calendar * + * List all payroll calendars for the company within the requested cycle. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View payslips (`payslip:read`) | - | + * | Manage payroll runs (`payroll`) | View payroll calendars (`payroll_calendar:read`) | - | * */ -export const getV1PayslipsId = ( - options: Options, +export const getV1PayrollCalendarsCycle = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => (options.client ?? client).get< - GetV1PayslipsIdResponses, - GetV1PayslipsIdErrors, + GetV1PayrollCalendarsCycleResponses, + GetV1PayrollCalendarsCycleErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/payslips/{id}', - ...options, - }); + >({ url: '/v1/payroll-calendars/{cycle}', ...options }); /** - * List Leave Policies Summary + * Terminate contractor of record employment + * + * **Deprecated.** Use `POST /contractors/employments/{employment_id}/cor-termination-requests` instead. + * + * Initiates a termination request for a Contractor of Record employment. + * When a termination request is sent, a stop work order is issued and the contractor remains active until a final invoice is paid or waived. + * Currently, only Contractor of Record employments can be terminated. * - * List all the data related to time off for a given employment * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * * + * @deprecated */ -export const getV1LeavePoliciesSummaryEmploymentId = < +export const postV1ContractorsEmploymentsEmploymentIdTerminateCorEmployment = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentData, + ThrowOnError + >, ) => - (options.client ?? client).get< - GetV1LeavePoliciesSummaryEmploymentIdResponses, - GetV1LeavePoliciesSummaryEmploymentIdErrors, + (options.client ?? client).post< + PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses, + PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/leave-policies/summary/{employment_id}', + url: '/v1/contractors/employments/{employment_id}/terminate-cor-employment', ...options, }); /** - * List expense categories for the authenticated employee + * Send back a timesheet for review or modification * - * Returns the flat list of expense categories applicable to the current employee. Only active categories are returned, filtered by the employee's country / legal-entity visibility rules. Leaf nodes have `is_selectable: true`; parent nodes are excluded unless `include_parents=true`. + * Sends the given timesheet back to the employee for review or modification. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timesheets (`timesheet:write`) | * */ -export const getV1EmployeeExpenseCategories = < +export const postV1TimesheetsTimesheetIdSendBack = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options, ) => - (options?.client ?? client).get< - GetV1EmployeeExpenseCategoriesResponses, - GetV1EmployeeExpenseCategoriesErrors, + (options.client ?? client).post< + PostV1TimesheetsTimesheetIdSendBackResponses, + PostV1TimesheetsTimesheetIdSendBackErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/expense-categories', + url: '/v1/timesheets/{timesheet_id}/send-back', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List Company Departments + * Sign a pre-onboarding document * - * Lists all departments for the authorized company specified in the request. + * Signs the latest contract document associated with the given pre-onboarding document on behalf + * of the company signatory. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View departments (`company_department:read`) | Manage departments (`company_department:write`) | + * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | * */ -export const getV1CompanyDepartments = ( - options: Options, -) => - (options.client ?? client).get< - GetV1CompanyDepartmentsResponses, - GetV1CompanyDepartmentsErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/company-departments', - ...options, - }); +export const postV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSign = + ( + options: Options< + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignData, + ThrowOnError + >, + ) => + (options.client ?? client).post< + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponses, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignErrors, + ThrowOnError + >({ + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents/{id}/sign', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); /** - * Create New Department + * List Benefit Renewal Requests * - * Creates a new department in the specified company. Department names may be non-unique and must be non-empty with no more than 255 characters (Unicode code points). + * List Benefit Renewal Requests for each country. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage departments (`company_department:write`) | + * | Manage company resources (`company_admin`) | View benefit renewals (`benefit_renewal:read`) | Manage benefit renewals (`benefit_renewal:write`) | * */ -export const postV1CompanyDepartments = ( - options: Options, +export const getV1BenefitRenewalRequests = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).post< - PostV1CompanyDepartmentsResponses, - PostV1CompanyDepartmentsErrors, + (options.client ?? client).get< + GetV1BenefitRenewalRequestsResponses, + GetV1BenefitRenewalRequestsErrors, + ThrowOnError + >({ url: '/v1/benefit-renewal-requests', ...options }); + +/** + * Reassign default legal entity + * + * Set a different legal entity as the company's default entity. + * + * The default entity is used when creating new employments without an explicit entity. + * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * + */ +export const putV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityId = < + ThrowOnError extends boolean = false, +>( + options: Options< + PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdData, + ThrowOnError + >, +) => + (options.client ?? client).put< + PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses, + PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/company-departments', + url: '/v1/sandbox/companies/{company_id}/default-legal-entity/{legal_entity_id}', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Decline a time off cancellation request - * - * Decline a time off cancellation request. + * List Employment Contract. * + * Get the employment contract history for a given employment. If `only_active` is true, it will return only the active or last active contract. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | View contracts (`contract:read`) | - | * */ -export const postV1TimeoffTimeoffIdCancelRequestDecline = < +export const getV1EmploymentContracts = ( + options: Options, +) => + (options.client ?? client).get< + GetV1EmploymentContractsResponses, + GetV1EmploymentContractsErrors, + ThrowOnError + >({ url: '/v1/employment-contracts', ...options }); + +/** + * Cancel Contract Amendment + * + * Use this endpoint to cancel an existing contract amendment request. + * + * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * + */ +export const putV1SandboxContractAmendmentsContractAmendmentRequestIdCancel = < ThrowOnError extends boolean = false, >( options: Options< - PostV1TimeoffTimeoffIdCancelRequestDeclineData, + PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelData, ThrowOnError >, ) => - (options.client ?? client).post< - PostV1TimeoffTimeoffIdCancelRequestDeclineResponses, - PostV1TimeoffTimeoffIdCancelRequestDeclineErrors, + (options.client ?? client).put< + PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses, + PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{timeoff_id}/cancel-request/decline', + url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/cancel', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Update administrative details - * - * Updates employment's administrative details. - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * Download payslip in the PDF format * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. + * Given a Payslip ID, downloads a payslip. + * It is important to note that each country has a different payslip format and they are not authored by Remote. * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * ## Scopes * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage payroll runs (`payroll`) | View payslips (`payslip:read`) | - | * + */ +export const getV1PayslipsPayslipIdPdf = ( + options: Options, +) => + (options.client ?? client).get< + GetV1PayslipsPayslipIdPdfResponses, + GetV1PayslipsPayslipIdPdfErrors, + ThrowOnError + >({ url: '/v1/payslips/{payslip_id}/pdf', ...options }); + +/** + * Approve Time Off * + * Approve a time off request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const putV2EmploymentsEmploymentIdAdministrativeDetails = < +export const postV1TimeoffTimeoffIdApprove = < ThrowOnError extends boolean = false, >( - options: Options< - PutV2EmploymentsEmploymentIdAdministrativeDetailsData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses, - PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors, + (options.client ?? client).post< + PostV1TimeoffTimeoffIdApproveResponses, + PostV1TimeoffTimeoffIdApproveErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/administrative_details', + url: '/v1/timeoff/{timeoff_id}/approve', ...options, headers: { 'Content-Type': 'application/json', @@ -4858,72 +4279,79 @@ export const putV2EmploymentsEmploymentIdAdministrativeDetails = < }); /** - * Get a employment benefit offers JSON schema + * List all companies + * + * List all companies that authorized your integration to act on their behalf. In other words, these are all the companies that your integration can manage. Any company that has completed the authorization flow for your integration will be included in the response. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | + * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * */ -export const getV1EmploymentsEmploymentIdBenefitOffersSchema = < - ThrowOnError extends boolean = false, ->( - options: Options< - GetV1EmploymentsEmploymentIdBenefitOffersSchemaData, - ThrowOnError - >, +export const getV1Companies = ( + options: Options, ) => (options.client ?? client).get< - GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses, - GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors, + GetV1CompaniesResponses, + GetV1CompaniesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/benefit-offers/schema', - ...options, - }); + >({ url: '/v1/companies', ...options }); /** - * Submit eligibility questionnaire + * Create a company * - * Submits an eligibility questionnaire for a contractor employment. + * Creates a new company. * - * The questionnaire determines if the contractor is eligible for certain products or features. - * The responses are validated against the JSON schema for the questionnaire type. + * ### Creating a company with only the required request body parameters + * When you call this endpoint and omit all the optional parameters in the request body, + * the following resources get created upon a successful response: + * * A new company with status `pending`. + * * A company owner for the new company with status `initiated`. * - * **Requirements:** - * - Employment must be of type `contractor` - * - Employment must be in `created` status - * - Responses must conform to the questionnaire JSON schema + * See the [update a company endpoint](#tag/Companies/operation/patch_update_company) for + * more details on how to get your company and its owner to `active` status. + * + * If you'd like to create a company and its owner with `active` status in a single request, + * please provide the optional `address_details` parameter as well. + * + * ### Accepting the Terms of Service + * + * A required step for creating a company in Remote is to accept our Terms of Service (ToS). + * + * Company managers need to be aware of our Terms of Service and Privacy Policy, + * hence **it's the responsibility of our partners to advise and ensure company managers read + * and accept the ToS**. The terms have to be accepted only once, before creating a company, + * and the Remote API will collect the acceptance timestamp as its confirmation. + * + * To ensure users read the most recent version of Remote's Terms of Service, their **acceptance + * must be done within the last fifteen minutes prior the company creation action**. + * + * To retrieve this information, partners can provide an element with any text and a description + * explaining that by performing that action they are accepting Remote's Term of Service. For + * instance, the partner can add a checkbox or a "Create Remote Account" button followed by a + * description saying "By creating an account, you agree to + * [Remote's Terms of Service](https://remote.com/terms-of-service). Also see Remote's + * [Privacy Policy](https://remote.com/privacy-policy)". * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | * */ -export const postV1ContractorsEligibilityQuestionnaire = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1Companies = ( + options: Options, ) => (options.client ?? client).post< - PostV1ContractorsEligibilityQuestionnaireResponses, - PostV1ContractorsEligibilityQuestionnaireErrors, + PostV1CompaniesResponses, + PostV1CompaniesErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/eligibility-questionnaire', + url: '/v1/companies', ...options, headers: { 'Content-Type': 'application/json', @@ -4932,117 +4360,228 @@ export const postV1ContractorsEligibilityQuestionnaire = < }); /** - * Show personal information for the authenticated employee + * List company structure nodes + * + * Shows all the company structure nodes of an employment. * - * Returns personal information for the authenticated employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View personal details (`personal_detail:read`) | - | + * | Manage company resources (`company_admin`) | View company structure (`company_structure:read`) | - | * */ -export const getV1EmployeePersonalInformation = < +export const getV1EmploymentsEmploymentIdCompanyStructureNodes = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options< + GetV1EmploymentsEmploymentIdCompanyStructureNodesData, + ThrowOnError + >, ) => - (options?.client ?? client).get< - GetV1EmployeePersonalInformationResponses, - GetV1EmployeePersonalInformationErrors, + (options.client ?? client).get< + GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses, + GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors, + ThrowOnError + >({ + url: '/v1/employments/{employment_id}/company-structure-nodes', + ...options, + }); + +/** + * Update employment + */ +export const patchV2EmploymentsEmploymentId2 = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).patch< + PatchV2EmploymentsEmploymentId2Responses, + PatchV2EmploymentsEmploymentId2Errors, ThrowOnError >({ security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/personal-information', + url: '/v2/employments/{employment_id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List timesheets + * Update employment + */ +export const patchV2EmploymentsEmploymentId = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).put< + PatchV2EmploymentsEmploymentIdResponses, + PatchV2EmploymentsEmploymentIdErrors, + ThrowOnError + >({ + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v2/employments/{employment_id}', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); + +/** + * Create probation completion letter * - * Lists all timesheets. + * Create a new probation completion letter request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timesheets (`timesheet:read`) | Manage timesheets (`timesheet:write`) | + * | Manage employment documents (`employment_documents`) | - | Manage probation documents (`probation_document:write`) | * */ -export const getV1Timesheets = ( - options?: Options, +export const postV1ProbationCompletionLetter = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options?.client ?? client).get< - GetV1TimesheetsResponses, - GetV1TimesheetsErrors, + (options.client ?? client).post< + PostV1ProbationCompletionLetterResponses, + PostV1ProbationCompletionLetterErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timesheets', + url: '/v1/probation-completion-letter', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Create a legal entity - * - * Create a new legal entity for a company in a given country, with KYB automatically passed. - * - * The entity is created with active status and can be set as the company's default - * using the reassign default entity endpoint. - * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * Creates PDF cost estimation of employments * + * Creates a PDF cost estimation of employments based on the provided parameters. */ -export const postV1SandboxCompaniesCompanyIdLegalEntities = < +export const postV1CostCalculatorEstimationPdf = < ThrowOnError extends boolean = false, >( - options: Options< - PostV1SandboxCompaniesCompanyIdLegalEntitiesData, + options?: Options, +) => + (options?.client ?? client).post< + PostV1CostCalculatorEstimationPdfResponses, + PostV1CostCalculatorEstimationPdfErrors, ThrowOnError - >, + >({ + url: '/v1/cost-calculator/estimation-pdf', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options?.headers, + }, + }); + +/** + * Token + * + * Endpoint to exchange tokens in the Authorization Code, Assertion Flow, Client Credentials and Refresh Token flows + */ +export const postAuthOauth2Token2 = ( + options?: Options, ) => - (options.client ?? client).post< - PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses, - PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors, + (options?.client ?? client).post< + PostAuthOauth2Token2Responses, + PostAuthOauth2Token2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/companies/{company_id}/legal-entities', + url: '/api/eor/auth/oauth2/token', ...options, headers: { 'Content-Type': 'application/json', - ...options.headers, + ...options?.headers, }, }); /** - * Show employment + * Download a document for the employee * - * Shows all the information of an employment. + * ## Scopes * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. + */ +export const getV1EmployeeDocumentsId = ( + options: Options, +) => + (options.client ?? client).get< + GetV1EmployeeDocumentsIdResponses, + GetV1EmployeeDocumentsIdErrors, + ThrowOnError + >({ url: '/v1/employee/documents/{id}', ...options }); + +/** + * Replay Webhook Events * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * Replay webhook events * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * ## Scopes * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | * + */ +export const postV1WebhookEventsReplay = ( + options: Options, +) => + (options.client ?? client).post< + PostV1WebhookEventsReplayResponses, + PostV1WebhookEventsReplayErrors, + ThrowOnError + >({ + url: '/v1/webhook-events/replay', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); + +/** + * Trigger a Webhook * + * Triggers a callback previously registered for webhooks. Use this endpoint to + * emit a webhook for testing in the Sandbox environment. This endpoint will + * respond with a 404 outside of the Sandbox environment. + * + */ +export const postV1SandboxWebhookCallbacksTrigger = < + ThrowOnError extends boolean = false, +>( + options?: Options, +) => + (options?.client ?? client).post< + PostV1SandboxWebhookCallbacksTriggerResponses, + PostV1SandboxWebhookCallbacksTriggerErrors, + ThrowOnError + >({ + url: '/v1/sandbox/webhook-callbacks/trigger', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options?.headers, + }, + }); + +/** + * Show bulk employment job * * ## Scopes * @@ -5051,94 +4590,136 @@ export const postV1SandboxCompaniesCompanyIdLegalEntities = < * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const getV1EmploymentsEmploymentId = < +export const getV1BulkEmploymentJobsJobId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).get< - GetV1EmploymentsEmploymentIdResponses, - GetV1EmploymentsEmploymentIdErrors, + GetV1BulkEmploymentJobsJobIdResponses, + GetV1BulkEmploymentJobsJobIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}', - ...options, - }); + >({ url: '/v1/bulk-employment-jobs/{job_id}', ...options }); /** - * Update employment + * List bulk employment rows * - * Updates an employment. + * Returns grouped bulk employment rows, including field-level validation errors in `errors`, row-level failures in `row_errors`, and submission-phase failures in `submission_errors`. If a row passes validation but later fails during Global Payroll activation, that failure is surfaced here after submission rather than in the initial create response. * - * **For `created` employments:** You can change all basic params and onboarding tasks or perform a per onboarding task update. You can also update basic_information. + * ## Scopes * - * **For `active` employments:** You can update the manager (`manager_id` field), emergency_contact_details, address_details and work_email. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * - * **For `invited` employments:** You can update the work_email. + */ +export const getV1BulkEmploymentJobsJobIdRows = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).get< + GetV1BulkEmploymentJobsJobIdRowsResponses, + GetV1BulkEmploymentJobsJobIdRowsErrors, + ThrowOnError + >({ url: '/v1/bulk-employment-jobs/{job_id}/rows', ...options }); + +/** + * Magic links generator * - * After onboarding, only a limited set of employment data will be available for updates, such as `emergency_contact_details`. - * If you want to provide additional information for an employment, please make sure to do so **before** the employee is invited. - * We block updates to some employment data because employees need to agree to amendments in certain cases, such as when there are changes to their contract_details. - * Currently, these amendments can only be done through the Remote UI. + * Generates a magic link for a passwordless authentication. + * To create a magic link for a company admin, you need to provide the `user_id` parameter. + * To create a magic link for an employee, you need to provide the `employment_id` parameter. * - * It is possible to update the `external_id` of the employment for all employment statuses. * - * ## Global Payroll Employees + * ## Scopes * - * To update a Global Payment employment your input data must comply with the global payroll json schemas. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage company resources (`company_admin`) | - | Create magic links (`magic_link:write`) | * - * **For `active` employments:** In addition to the above list, you can update personal_details. + */ +export const postV1MagicLink = ( + options: Options, +) => + (options.client ?? client).post< + PostV1MagicLinkResponses, + PostV1MagicLinkErrors, + ThrowOnError + >({ + url: '/v1/magic-link', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); + +/** + * Show a company * - * ## Direct Employees + * Given an ID, shows a company. * - * To update an HRIS employment your input data must comply with the HRIS json schemas. + * If the used access token was issued by the OAuth 2.0 Authorization Code flow, + * then only the associated company can be accessed through the endpoint. * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. + * ## Scopes * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + */ +export const getV1CompaniesCompanyId = ( + options: Options, +) => + (options.client ?? client).get< + GetV1CompaniesCompanyIdResponses, + GetV1CompaniesCompanyIdErrors, + ThrowOnError + >({ url: '/v1/companies/{company_id}', ...options }); + +/** + * Update a company * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * Given an ID and a request object with new information, updates a company. * + * ### Getting a company and its owner to `active` status + * If you created a company using the + * [create a company endpoint](#tag/Companies/operation/post_create_company) without all the required + * request body parameters, you can use this endpoint to provide the missing data. Once the company + * and its owner have all the necessary data, both their statuses will be set to `active` and the company + * onboarding will be marked as "completed". * - * Please contact Remote if you need to update contractors via API since it's currently not supported. + * The following constitutes a company with "all the necessary data": + * * Complete `address`, with valid `address`, `postal_code`, `country` and `state` parameters (Varies by country. Use the + * [show form schema endpoint](#tag/Countries/operation/get_show_form_country) to see which address parameters + * are required). + * * Company `tax_number` or `registration_number` is not nil + * * Company `name` is not nil (already required when creating the company) + * * Company has a `desired_currency` in their bank account (already required when creating the company) + * * Company has accepted terms of service (already required when creating the company) * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | * */ -export const patchV1EmploymentsEmploymentId2 = < +export const patchV1CompaniesCompanyId2 = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).patch< - PatchV1EmploymentsEmploymentId2Responses, - PatchV1EmploymentsEmploymentId2Errors, + PatchV1CompaniesCompanyId2Responses, + PatchV1CompaniesCompanyId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}', + url: '/v1/companies/{company_id}', ...options, headers: { 'Content-Type': 'application/json', @@ -5147,75 +4728,43 @@ export const patchV1EmploymentsEmploymentId2 = < }); /** - * Update employment - * - * Updates an employment. - * - * **For `created` employments:** You can change all basic params and onboarding tasks or perform a per onboarding task update. You can also update basic_information. - * - * **For `active` employments:** You can update the manager (`manager_id` field), emergency_contact_details, address_details and work_email. - * - * **For `invited` employments:** You can update the work_email. - * - * After onboarding, only a limited set of employment data will be available for updates, such as `emergency_contact_details`. - * If you want to provide additional information for an employment, please make sure to do so **before** the employee is invited. - * We block updates to some employment data because employees need to agree to amendments in certain cases, such as when there are changes to their contract_details. - * Currently, these amendments can only be done through the Remote UI. - * - * It is possible to update the `external_id` of the employment for all employment statuses. - * - * ## Global Payroll Employees - * - * To update a Global Payment employment your input data must comply with the global payroll json schemas. - * - * **For `active` employments:** In addition to the above list, you can update personal_details. - * - * ## Direct Employees - * - * To update an HRIS employment your input data must comply with the HRIS json schemas. - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. - * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * Update a company * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * Given an ID and a request object with new information, updates a company. * + * ### Getting a company and its owner to `active` status + * If you created a company using the + * [create a company endpoint](#tag/Companies/operation/post_create_company) without all the required + * request body parameters, you can use this endpoint to provide the missing data. Once the company + * and its owner have all the necessary data, both their statuses will be set to `active` and the company + * onboarding will be marked as "completed". * - * Please contact Remote if you need to update contractors via API since it's currently not supported. + * The following constitutes a company with "all the necessary data": + * * Complete `address`, with valid `address`, `postal_code`, `country` and `state` parameters (Varies by country. Use the + * [show form schema endpoint](#tag/Countries/operation/get_show_form_country) to see which address parameters + * are required). + * * Company `tax_number` or `registration_number` is not nil + * * Company `name` is not nil (already required when creating the company) + * * Company has a `desired_currency` in their bank account (already required when creating the company) + * * Company has accepted terms of service (already required when creating the company) * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | * */ -export const patchV1EmploymentsEmploymentId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const patchV1CompaniesCompanyId = ( + options: Options, ) => (options.client ?? client).put< - PatchV1EmploymentsEmploymentIdResponses, - PatchV1EmploymentsEmploymentIdErrors, + PatchV1CompaniesCompanyIdResponses, + PatchV1CompaniesCompanyIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}', + url: '/v1/companies/{company_id}', ...options, headers: { 'Content-Type': 'application/json', @@ -5224,122 +4773,81 @@ export const patchV1EmploymentsEmploymentId = < }); /** - * List users via SCIM v2.0 + * Show form schema * - * Retrieves a list of users for the authenticated company following SCIM 2.0 standard - */ -export const getV1ScimV2Users = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1ScimV2UsersResponses, - GetV1ScimV2UsersErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/scim/v2/Users', - ...options, - }); - -/** - * List Company Payroll Calendar + * Returns the json schema of the requested company form. + * Currently only supports the `address_details` form. * - * List all payroll calendars for the company within the requested cycle. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage payroll runs (`payroll`) | View payroll calendars (`payroll_calendar:read`) | - | + * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * */ -export const getV1PayrollCalendarsCycle = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1CompaniesSchema = ( + options: Options, ) => (options.client ?? client).get< - GetV1PayrollCalendarsCycleResponses, - GetV1PayrollCalendarsCycleErrors, + GetV1CompaniesSchemaResponses, + GetV1CompaniesSchemaErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/payroll-calendars/{cycle}', - ...options, - }); + >({ url: '/v1/companies/schema', ...options }); /** - * Show Legal Entity Administrative details + * List pricing plan partner templates * - * Show administrative details of legal entity for the authorized company specified in the request. + * List all pricing plan partner templates. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | + * | Manage companies (`company_management`) | View pricing plans (`pricing_plan:read`) | Manage pricing plans (`pricing_plan:write`) | * */ -export const getV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetails = - ( - options: Options< - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData, - ThrowOnError - >, - ) => - (options.client ?? client).get< - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses, - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details', - ...options, - }); +export const getV1PricingPlanPartnerTemplates = < + ThrowOnError extends boolean = false, +>( + options?: Options, +) => + (options?.client ?? client).get< + GetV1PricingPlanPartnerTemplatesResponses, + GetV1PricingPlanPartnerTemplatesErrors, + ThrowOnError + >({ url: '/v1/pricing-plan-partner-templates', ...options }); /** - * Update Legal Entity Administrative details + * Show engagement agreement details * - * Update administrative details of legal entity for the authorized company specified in the request. + * Returns the engagement agreement details JSON Schema for a country. Only DEU country is supported for now. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | + * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | * */ -export const putV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetails = - ( - options: Options< - PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData, - ThrowOnError - >, - ) => - (options.client ?? client).put< - PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses, - PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); +export const getV1CountriesCountryCodeEngagementAgreementDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + GetV1CountriesCountryCodeEngagementAgreementDetailsData, + ThrowOnError + >, +) => + (options.client ?? client).get< + GetV1CountriesCountryCodeEngagementAgreementDetailsResponses, + GetV1CountriesCountryCodeEngagementAgreementDetailsErrors, + ThrowOnError + >({ + url: '/v1/countries/{country_code}/engagement-agreement-details', + ...options, + }); /** * Update contract details @@ -5384,10 +4892,6 @@ export const putV2EmploymentsEmploymentIdContractDetails = < PutV2EmploymentsEmploymentIdContractDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], url: '/v2/employments/{employment_id}/contract_details', ...options, headers: { @@ -5397,193 +4901,154 @@ export const putV2EmploymentsEmploymentIdContractDetails = < }); /** - * Show region fields + * Show product prices in the company's desired currency + * + * list product prices in the company's desired currency. + * the endpoint currently only returns the product prices for the EOR monthly product and the contractor products (Standard, Plus and COR). + * the product prices are then used to create a pricing plan for the company. + * + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage companies (`company_management`) | View pricing plans (`pricing_plan:read`) | Manage pricing plans (`pricing_plan:write`) | * - * Returns required fields JSON Schema for a given region. These are required in order to calculate - * the cost of employment for the region. These fields are based on employer contributions that are associated - * with the region or any of it's parent regions. */ -export const getV1CostCalculatorRegionsSlugFields = < +export const getV1CompaniesCompanyIdProductPrices = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).get< - GetV1CostCalculatorRegionsSlugFieldsResponses, - GetV1CostCalculatorRegionsSlugFieldsErrors, + GetV1CompaniesCompanyIdProductPricesResponses, + GetV1CompaniesCompanyIdProductPricesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/cost-calculator/regions/{slug}/fields', - ...options, - }); + >({ url: '/v1/companies/{company_id}/product-prices', ...options }); /** - * Show Offboarding - * - * Shows an Offboarding request. - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employments (`employments`) | View offboarding requests (`offboarding:read`) | Manage offboarding (`offboarding:write`) | + * Create a new token for a company * + * Creates new tokens for a given company */ -export const getV1OffboardingsId = ( - options: Options, +export const postV1CompaniesCompanyIdCreateToken = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).get< - GetV1OffboardingsIdResponses, - GetV1OffboardingsIdErrors, + (options.client ?? client).post< + PostV1CompaniesCompanyIdCreateTokenResponses, + PostV1CompaniesCompanyIdCreateTokenErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/offboardings/{id}', - ...options, - }); + >({ url: '/v1/companies/{company_id}/create-token', ...options }); /** - * Get Employee Details for a Payroll Run + * Get Employment Profile + * + * Gets necessary information to perform the identity verification of an employee. * - * Gets the employee details for a payroll run * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage payroll runs (`payroll`) | View payroll runs (`payroll_run:read`) | - | + * | Manage employment documents (`employment_documents`) | View identity verification (`identity_verification:read`) | Manage identity verification (`identity_verification:write`) | * */ -export const getV1PayrollRunsPayrollRunIdEmployeeDetails = < +export const getV1IdentityVerificationEmploymentId = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1PayrollRunsPayrollRunIdEmployeeDetailsData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses, - GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors, + GetV1IdentityVerificationEmploymentIdResponses, + GetV1IdentityVerificationEmploymentIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/payroll-runs/{payroll_run_id}/employee-details', - ...options, - }); + >({ url: '/v1/identity-verification/{employment_id}', ...options }); /** - * List bulk employment rows + * Download a receipt by id * - * Returns grouped bulk employment rows, including field-level validation errors in `errors`, row-level failures in `row_errors`, and submission-phase failures in `submission_errors`. If a row passes validation but later fails during Global Payroll activation, that failure is surfaced here after submission rather than in the initial create response. + * Download a receipt by id. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | * */ -export const getV1BulkEmploymentJobsJobIdRows = < +export const getV1ExpensesExpenseIdReceiptsReceiptId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).get< - GetV1BulkEmploymentJobsJobIdRowsResponses, - GetV1BulkEmploymentJobsJobIdRowsErrors, + GetV1ExpensesExpenseIdReceiptsReceiptIdResponses, + GetV1ExpensesExpenseIdReceiptsReceiptIdErrors, + ThrowOnError + >({ url: '/v1/expenses/{expense_id}/receipts/{receipt_id}', ...options }); + +/** + * List groups via SCIM v2.0 + * + * Retrieves a list of groups (departments) for the authenticated company following SCIM 2.0 standard + */ +export const getV1ScimV2Groups = ( + options?: Options, +) => + (options?.client ?? client).get< + GetV1ScimV2GroupsResponses, + GetV1ScimV2GroupsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/bulk-employment-jobs/{job_id}/rows', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/scim/v2/Groups', ...options, }); /** - * Create employment - * - * Creates an employment without provisional_start_date validation. + * Show expense * - * This endpoint is only available in Sandbox and allows creating employments which - * `provisional_start_date` is in the past. This is especially helpful for: - * * Testing the Timeoff Balance endpoints - * * Testing the Offboarding endpoints - * * Testing features around probation periods + * Shows a single expense record * - * This endpoint will respond with a 404 outside of the Sandbox environment. + * ## Scopes * - * For creating an employment's parameters outside of testing purposes, use [this - * Employment create endpoint](#operation/post_create_employment) + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | * */ -export const postV1SandboxEmployments = ( - options: Options, +export const getV1ExpensesId = ( + options: Options, ) => - (options.client ?? client).post< - PostV1SandboxEmploymentsResponses, - PostV1SandboxEmploymentsErrors, + (options.client ?? client).get< + GetV1ExpensesIdResponses, + GetV1ExpensesIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/employments', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/expenses/{id}', ...options }); /** - * Create contract eligibility - * - * Create contract eligibility for an employment. - * - * This will create a new contract eligibility for the employment. + * Update an expense * + * Updates an expense * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage contract eligibility (`contract_eligibility:write`) | + * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | * */ -export const postV1EmploymentsEmploymentIdContractEligibility = < - ThrowOnError extends boolean = false, ->( - options: Options< - PostV1EmploymentsEmploymentIdContractEligibilityData, - ThrowOnError - >, +export const patchV1ExpensesId2 = ( + options: Options, ) => - (options.client ?? client).post< - PostV1EmploymentsEmploymentIdContractEligibilityResponses, - PostV1EmploymentsEmploymentIdContractEligibilityErrors, + (options.client ?? client).patch< + PatchV1ExpensesId2Responses, + PatchV1ExpensesId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/contract-eligibility', + url: '/v1/expenses/{id}', ...options, headers: { 'Content-Type': 'application/json', @@ -5592,117 +5057,102 @@ export const postV1EmploymentsEmploymentIdContractEligibility = < }); /** - * List countries - * - * Returns a list of all countries that are supported by Remote API alphabetically ordered. - * The supported list accounts for creating employment with basic information and it does not imply fully onboarding employment via JSON Schema. - * The countries present in the list are the ones where creating a company is allowed. + * Update an expense * + * Updates an expense * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View countries (`country:read`) | - | + * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | * */ -export const getV1Countries = ( - options: Options, +export const patchV1ExpensesId = ( + options: Options, ) => - (options.client ?? client).get< - GetV1CountriesResponses, - GetV1CountriesErrors, + (options.client ?? client).put< + PatchV1ExpensesIdResponses, + PatchV1ExpensesIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/countries', + url: '/v1/expenses/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List payslip files for the authenticated employee + * Update emergency contact + * + * Updates the employment's emergency contact details. + * + * This endpoint requires country-specific data. Query the **Show form schema** endpoint + * passing the country code and `emergency_contact_details` as path parameters to see + * the required fields for a given country. * - * Returns a paginated list of payslip files belonging to the current employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View payslips (`payslip:read`) | - | - * - */ -export const getV1EmployeePayslipFiles = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1EmployeePayslipFilesResponses, - GetV1EmployeePayslipFilesErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/payslip-files', - ...options, - }); - -/** - * Create a new token for a company + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * - * Creates new tokens for a given company */ -export const postV1CompaniesCompanyIdCreateToken = < +export const putV2EmploymentsEmploymentIdEmergencyContact = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PutV2EmploymentsEmploymentIdEmergencyContactData, + ThrowOnError + >, ) => - (options.client ?? client).post< - PostV1CompaniesCompanyIdCreateTokenResponses, - PostV1CompaniesCompanyIdCreateTokenErrors, + (options.client ?? client).put< + PutV2EmploymentsEmploymentIdEmergencyContactResponses, + PutV2EmploymentsEmploymentIdEmergencyContactErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies/{company_id}/create-token', + url: '/v2/employments/{employment_id}/emergency_contact', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List Company Legal Entities - * - * Lists all active legal entities for the authorized company specified in the request. - * - * - * ## Scopes + * Creates a Benefit Renewal Request * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | + * Creates a Benefit Renewal Request for a specific Benefit Group. + * This endpoint is only available in Sandbox, otherwise it will respond with a 404. * */ -export const getV1CompaniesCompanyIdLegalEntities = < +export const postV1SandboxBenefitRenewalRequests = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).get< - GetV1CompaniesCompanyIdLegalEntitiesResponses, - GetV1CompaniesCompanyIdLegalEntitiesErrors, + (options.client ?? client).post< + PostV1SandboxBenefitRenewalRequestsResponses, + PostV1SandboxBenefitRenewalRequestsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/legal-entities', + url: '/v1/sandbox/benefit-renewal-requests', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Update personal details + * Update basic information * - * Updates employment's personal details. + * Updates employment's basic information. + * + * Supported employment statuses: `created`, `job_title_review`, `created_reserve_paid`, `created_awaiting_reserve`. * * This endpoint requires and returns country-specific data. The exact required and returned fields will * vary depending on which country the employment is in. To see the list of parameters for each country, @@ -5718,7 +5168,7 @@ export const getV1CompaniesCompanyIdLegalEntities = < * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. * * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. * * * @@ -5729,24 +5179,20 @@ export const getV1CompaniesCompanyIdLegalEntities = < * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const putV2EmploymentsEmploymentIdPersonalDetails = < +export const putV2EmploymentsEmploymentIdBasicInformation = < ThrowOnError extends boolean = false, >( options: Options< - PutV2EmploymentsEmploymentIdPersonalDetailsData, + PutV2EmploymentsEmploymentIdBasicInformationData, ThrowOnError >, ) => (options.client ?? client).put< - PutV2EmploymentsEmploymentIdPersonalDetailsResponses, - PutV2EmploymentsEmploymentIdPersonalDetailsErrors, + PutV2EmploymentsEmploymentIdBasicInformationResponses, + PutV2EmploymentsEmploymentIdBasicInformationErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/personal_details', + url: '/v2/employments/{employment_id}/basic_information', ...options, headers: { 'Content-Type': 'application/json', @@ -5755,22 +5201,51 @@ export const putV2EmploymentsEmploymentIdPersonalDetails = < }); /** - * Complete onboarding + * List Leave Policies Summary * - * Completes the employee onboarding. When all tasks are completed, the employee is marked as in `review` status + * List all the data related to time off for a given employment + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | * - * @deprecated */ -export const postV1Ready = ( - options: Options, +export const getV1LeavePoliciesSummaryEmploymentId = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).get< + GetV1LeavePoliciesSummaryEmploymentIdResponses, + GetV1LeavePoliciesSummaryEmploymentIdErrors, + ThrowOnError + >({ url: '/v1/leave-policies/summary/{employment_id}', ...options }); + +/** + * Cancel Time Off + * + * Cancel a time off request that was already approved. + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * + */ +export const postV1TimeoffTimeoffIdCancel = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => (options.client ?? client).post< - PostV1ReadyResponses, - PostV1ReadyErrors, + PostV1TimeoffTimeoffIdCancelResponses, + PostV1TimeoffTimeoffIdCancelErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/ready', + url: '/v1/timeoff/{timeoff_id}/cancel', ...options, headers: { 'Content-Type': 'application/json', @@ -5779,146 +5254,127 @@ export const postV1Ready = ( }); /** - * List Leave Policies Details + * Get Help Center Article * - * Describe the leave policies (custom or not) for a given employment + * Get a help center article by its ID * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * | Manage company resources (`company_admin`) | View help articles (`help_center_article:read`) | - | * */ -export const getV1LeavePoliciesDetailsEmploymentId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1HelpCenterArticlesId = ( + options: Options, ) => (options.client ?? client).get< - GetV1LeavePoliciesDetailsEmploymentIdResponses, - GetV1LeavePoliciesDetailsEmploymentIdErrors, + GetV1HelpCenterArticlesIdResponses, + GetV1HelpCenterArticlesIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/leave-policies/details/{employment_id}', - ...options, - }); + >({ url: '/v1/help-center-articles/{id}', ...options }); /** - * List Time Off Types - * - * Lists all time off types that can be used for the `timeoff_type` parameter. + * Upload file * - * **Backward compatibility:** Calling this endpoint without the `type` query parameter returns the same response as before (time off types for full-time employments). Existing integrations do not need to change. + * Uploads a file associated with a specified employment. * - * Optionally, pass `type=contractor` to get time off types for contractor employments, or `type=full_time` for full-time employments (same as omitting the parameter). + * Please contact api-support@remote.com to request access to this endpoint. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | * */ -export const getV1TimeoffTypes = ( - options: Options, +export const postV1Documents = ( + options: Options, ) => - (options.client ?? client).get< - GetV1TimeoffTypesResponses, - GetV1TimeoffTypesErrors, + (options.client ?? client).post< + PostV1DocumentsResponses, + PostV1DocumentsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/types', + ...formDataBodySerializer, + url: '/v1/documents', ...options, + headers: { + 'Content-Type': null, + ...options.headers, + }, }); /** - * Creates a CSV cost estimation of employments + * Verify Employment Identity + * + * Endpoint to confirms the employment profile is from the actual employee + * + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employment documents (`employment_documents`) | - | Manage identity verification (`identity_verification:write`) | * - * Creates CSV cost estimation of employments */ -export const postV1CostCalculatorEstimationCsv = < +export const postV1IdentityVerificationEmploymentIdVerify = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options< + PostV1IdentityVerificationEmploymentIdVerifyData, + ThrowOnError + >, ) => - (options?.client ?? client).post< - PostV1CostCalculatorEstimationCsvResponses, - PostV1CostCalculatorEstimationCsvErrors, + (options.client ?? client).post< + PostV1IdentityVerificationEmploymentIdVerifyResponses, + PostV1IdentityVerificationEmploymentIdVerifyErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/cost-calculator/estimation-csv', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options?.headers, - }, - }); + >({ url: '/v1/identity-verification/{employment_id}/verify', ...options }); /** - * List groups via SCIM v2.0 + * Lists custom fields definitions + * + * Returns custom fields definitions + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employments (`employments`) | - | Manage custom fields (`custom_field:write`) | * - * Retrieves a list of groups (departments) for the authenticated company following SCIM 2.0 standard */ -export const getV1ScimV2Groups = ( - options?: Options, +export const getV1CustomFields = ( + options?: Options, ) => (options?.client ?? client).get< - GetV1ScimV2GroupsResponses, - GetV1ScimV2GroupsErrors, + GetV1CustomFieldsResponses, + GetV1CustomFieldsErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/scim/v2/Groups', - ...options, - }); + >({ url: '/v1/custom-fields', ...options }); /** - * Create a contract document for a contractor - * - * Create a contract document for a contractor. + * Create Custom Field Definition * + * Creates a new custom field definition. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | + * | Manage employments (`employments`) | View custom fields (`custom_field:read`) | Manage custom fields (`custom_field:write`) | * */ -export const postV1ContractorsEmploymentsEmploymentIdContractDocuments = < - ThrowOnError extends boolean = false, ->( - options: Options< - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsData, - ThrowOnError - >, +export const postV1CustomFields = ( + options: Options, ) => (options.client ?? client).post< - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses, - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors, + PostV1CustomFieldsResponses, + PostV1CustomFieldsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contract-documents', + url: '/v1/custom-fields', ...options, headers: { 'Content-Type': 'application/json', @@ -5927,290 +5383,208 @@ export const postV1ContractorsEmploymentsEmploymentIdContractDocuments = < }); /** - * Trigger a Webhook + * Approve risk reserve proof of payment * - * Triggers a callback previously registered for webhooks. Use this endpoint to - * emit a webhook for testing in the Sandbox environment. This endpoint will - * respond with a 404 outside of the Sandbox environment. + * Approves a risk reserve proof of payment without the intervention of a Remote admin. + * + * Triggers an `employment.cor_hiring.proof_of_payment_accepted` webhook event. + * + * This endpoint is only available in Sandbox, otherwise it will respond with a 404. * */ -export const postV1SandboxWebhookCallbacksTrigger = < - ThrowOnError extends boolean = false, ->( - options?: Options, -) => - (options?.client ?? client).post< - PostV1SandboxWebhookCallbacksTriggerResponses, - PostV1SandboxWebhookCallbacksTriggerErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/webhook-callbacks/trigger', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options?.headers, - }, - }); +export const postV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApprove = + ( + options: Options< + PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveData, + ThrowOnError + >, + ) => + (options.client ?? client).post< + PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses, + PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors, + ThrowOnError + >({ + url: '/v1/sandbox/employments/{employment_id}/risk-reserve-proof-of-payments/approve', + ...options, + }); /** - * Download payslip in the PDF format - * - * Given a Payslip ID, downloads a payslip. - * It is important to note that each country has a different payslip format and they are not authored by Remote. + * Create a Webhook Callback * + * Register a callback to be used for webhooks * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View payslips (`payslip:read`) | - | + * | Manage company resources (`company_admin`) | - | Manage webhooks (`webhook:write`) | * */ -export const getV1PayslipsPayslipIdPdf = ( - options: Options, +export const postV1WebhookCallbacks = ( + options: Options, ) => - (options.client ?? client).get< - GetV1PayslipsPayslipIdPdfResponses, - GetV1PayslipsPayslipIdPdfErrors, + (options.client ?? client).post< + PostV1WebhookCallbacksResponses, + PostV1WebhookCallbacksErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/payslips/{payslip_id}/pdf', + url: '/v1/webhook-callbacks', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Convert currency using dynamic rates + * Show the SSO Configuration Details * - * Convert currency using the rates Remote applies during employment creation and invoicing. + * Shows the SSO Configuration details for the company. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | Convert currencies (`convert_currency:read`) | - | + * | Manage company resources (`company_admin`) | - | Manage SSO (`sso_configuration:write`) | * */ -export const postV1CurrencyConverterEffective = < +export const getV1SsoConfigurationDetails = < ThrowOnError extends boolean = false, >( - options: Options, + options?: Options, ) => - (options.client ?? client).post< - PostV1CurrencyConverterEffectiveResponses, - PostV1CurrencyConverterEffectiveErrors, + (options?.client ?? client).get< + GetV1SsoConfigurationDetailsResponses, + GetV1SsoConfigurationDetailsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/currency-converter/effective', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/sso-configuration/details', ...options }); /** - * Show Time Off - * - * Shows a single Time Off record + * Sign a document for a contractor * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | * */ -export const getV1TimeoffId = ( - options: Options, -) => - (options.client ?? client).get< - GetV1TimeoffIdResponses, - GetV1TimeoffIdErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{id}', - ...options, - }); +export const postV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSign = + ( + options: Options< + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignData, + ThrowOnError + >, + ) => + (options.client ?? client).post< + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses, + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors, + ThrowOnError + >({ + url: '/v1/contractors/employments/{employment_id}/contract-documents/{contract_document_id}/sign', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); /** - * Update Time Off - * - * Updates a Time Off record. - * Warning: Updating the status of a time off through this endpoint is deprecated and will be removed on January 13, 2025. - * To approve or cancel an approved time off, use the `/approve` and `/cancel` endpoints instead. + * List Pay Items * + * Lists pay items for a company with optional filtering by employment, date range, and pagination. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage payroll runs (`payroll`) | View pay items (`pay_item:read`) | Manage pay items (`pay_item:write`) | * */ -export const patchV1TimeoffId2 = ( - options: Options, +export const getV1PayItems = ( + options?: Options, ) => - (options.client ?? client).patch< - PatchV1TimeoffId2Responses, - PatchV1TimeoffId2Errors, + (options?.client ?? client).get< + GetV1PayItemsResponses, + GetV1PayItemsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/pay-items', ...options }); /** - * Update Time Off - * - * Updates a Time Off record. - * Warning: Updating the status of a time off through this endpoint is deprecated and will be removed on January 13, 2025. - * To approve or cancel an approved time off, use the `/approve` and `/cancel` endpoints instead. - * - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * List users via SCIM v2.0 * + * Retrieves a list of users for the authenticated company following SCIM 2.0 standard */ -export const patchV1TimeoffId = ( - options: Options, +export const getV1ScimV2Users = ( + options?: Options, ) => - (options.client ?? client).put< - PatchV1TimeoffIdResponses, - PatchV1TimeoffIdErrors, + (options?.client ?? client).get< + GetV1ScimV2UsersResponses, + GetV1ScimV2UsersErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{id}', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/scim/v2/Users', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Decline Time Off + * Show Resignation * - * Decline a time off request. Please note that only time off requests on the `requested` status can be declined. + * Shows the details of a resignation with status `submitted`. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | View resignations (`resignation:read`) | Manage resignations (`resignation:write`) | * */ -export const postV1TimeoffTimeoffIdDecline = < +export const getV1ResignationsOffboardingRequestId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).post< - PostV1TimeoffTimeoffIdDeclineResponses, - PostV1TimeoffTimeoffIdDeclineErrors, + (options.client ?? client).get< + GetV1ResignationsOffboardingRequestIdResponses, + GetV1ResignationsOffboardingRequestIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{timeoff_id}/decline', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/resignations/{offboarding_request_id}', ...options }); /** - * Automatable Contract Amendment - * - * Check if a contract amendment request is automatable. - * If the contract amendment request is automatable, then after submission, it will instantly amend the employee's contract - * and send them an updated document. - * - * This endpoint requires and returns country-specific data. The exact required and returned fields will - * vary depending on which country the employment is in. To see the list of parameters for each country, - * see the **Show form schema** endpoint under the [Contract Amendments](#tag/Contract-Amendments) category. - * - * Please note that the compliance requirements for each country are subject to change according to local - * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid - * compliance issues and to have the latest version of a country requirements. - * - * If you are using this endpoint to build an integration, make sure you are dynamically collecting or - * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. - * - * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. - * - * To learn how you can dynamically generate forms to display in your UI, see the documentation for - * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. - * + * Get Billing Document Breakdown * + * Get billing document breakdown * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage contract amendments (`contract_amendment:write`) | + * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | * */ -export const postV1ContractAmendmentsAutomatable = < +export const getV1BillingDocumentsBillingDocumentIdBreakdown = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1BillingDocumentsBillingDocumentIdBreakdownData, + ThrowOnError + >, ) => - (options.client ?? client).post< - PostV1ContractAmendmentsAutomatableResponses, - PostV1ContractAmendmentsAutomatableErrors, + (options.client ?? client).get< + GetV1BillingDocumentsBillingDocumentIdBreakdownResponses, + GetV1BillingDocumentsBillingDocumentIdBreakdownErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contract-amendments/automatable', + url: '/v1/billing-documents/{billing_document_id}/breakdown', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Approve Time Off + * Decline a time off cancellation request + * + * Decline a time off cancellation request. * - * Approve a time off request. * * ## Scopes * @@ -6219,21 +5593,20 @@ export const postV1ContractAmendmentsAutomatable = < * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const postV1TimeoffTimeoffIdApprove = < +export const postV1TimeoffTimeoffIdCancelRequestDecline = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PostV1TimeoffTimeoffIdCancelRequestDeclineData, + ThrowOnError + >, ) => (options.client ?? client).post< - PostV1TimeoffTimeoffIdApproveResponses, - PostV1TimeoffTimeoffIdApproveErrors, + PostV1TimeoffTimeoffIdCancelRequestDeclineResponses, + PostV1TimeoffTimeoffIdCancelRequestDeclineErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{timeoff_id}/approve', + url: '/v1/timeoff/{timeoff_id}/cancel-request/decline', ...options, headers: { 'Content-Type': 'application/json', @@ -6242,154 +5615,105 @@ export const postV1TimeoffTimeoffIdApprove = < }); /** - * List employment files - * - * Lists files associated with a specific employment. - * - * Supports filtering by file type and sub_type. + * List EOR Payroll Calendar * + * List all active payroll calendars for EOR. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | + * | Manage payroll runs (`payroll`) | View payroll calendars (`payroll_calendar:read`) | - | * */ -export const getV1EmploymentsEmploymentIdFiles = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1PayrollCalendars = ( + options?: Options, ) => - (options.client ?? client).get< - GetV1EmploymentsEmploymentIdFilesResponses, - GetV1EmploymentsEmploymentIdFilesErrors, + (options?.client ?? client).get< + GetV1PayrollCalendarsResponses, + GetV1PayrollCalendarsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/files', - ...options, - }); + >({ url: '/v1/payroll-calendars', ...options }); /** - * Lists custom fields definitions - * - * Returns custom fields definitions - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employments (`employments`) | - | Manage custom fields (`custom_field:write`) | + * Payroll processing details API resource * + * API to retrieve header details of a pay group */ -export const getV1CustomFields = ( - options?: Options, +export const getV1WdGphPayDetail = ( + options: Options, ) => - (options?.client ?? client).get< - GetV1CustomFieldsResponses, - GetV1CustomFieldsErrors, + (options.client ?? client).get< + GetV1WdGphPayDetailResponses, + GetV1WdGphPayDetailErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/custom-fields', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/wd/gph/payDetail', ...options, }); /** - * Create Custom Field Definition + * Show form schema + * + * Returns the json schema of the `contract_amendment` form for a specific employment. + * This endpoint requires a company access token, as forms are dependent on certain + * properties of companies and their current employments. * - * Creates a new custom field definition. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View custom fields (`custom_field:read`) | Manage custom fields (`custom_field:write`) | + * | Manage employments (`employments`) | View contract amendments (`contract_amendment:read`) | Manage contract amendments (`contract_amendment:write`) | * */ -export const postV1CustomFields = ( - options: Options, +export const getV1ContractAmendmentsSchema = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).post< - PostV1CustomFieldsResponses, - PostV1CustomFieldsErrors, + (options.client ?? client).get< + GetV1ContractAmendmentsSchemaResponses, + GetV1ContractAmendmentsSchemaErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/custom-fields', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/contract-amendments/schema', ...options }); /** - * List company supported currencies - * - * List company supported currencies - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage company resources (`company_admin`) | View company currencies (`company_currencies:read`) | - | + * Get a mock JSON Schema * + * Get a mock JSON Schema for testing purposes */ -export const getV1CompanyCurrencies = ( - options?: Options, +export const getV1TestSchema = ( + options?: Options, ) => (options?.client ?? client).get< - GetV1CompanyCurrenciesResponses, - GetV1CompanyCurrenciesErrors, + GetV1TestSchemaResponses, + unknown, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/company-currencies', - ...options, - }); + >({ url: '/v1/test-schema', ...options }); /** - * Update employment + * Update Time Off as Employee * - * Updates an employment. Use this endpoint to: - * - modify employment states for testing - * - Backdate employment start dates + * Updates a Time Off record as Employee * - * This endpoint will respond with a 404 outside of the Sandbox environment. + * ## Scopes * - * For updating an employment's parameters outside of testing purposes, use [this Employment update endpoint](#operation/patch_update_employment). + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const patchV1SandboxEmploymentsEmploymentId2 = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const patchV1EmployeeTimeoffId2 = ( + options: Options, ) => (options.client ?? client).patch< - PatchV1SandboxEmploymentsEmploymentId2Responses, - PatchV1SandboxEmploymentsEmploymentId2Errors, + PatchV1EmployeeTimeoffId2Responses, + PatchV1EmployeeTimeoffId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/employments/{employment_id}', + url: '/v1/employee/timeoff/{id}', ...options, headers: { 'Content-Type': 'application/json', @@ -6398,32 +5722,26 @@ export const patchV1SandboxEmploymentsEmploymentId2 = < }); /** - * Update employment + * Update Time Off as Employee * - * Updates an employment. Use this endpoint to: - * - modify employment states for testing - * - Backdate employment start dates + * Updates a Time Off record as Employee * - * This endpoint will respond with a 404 outside of the Sandbox environment. + * ## Scopes * - * For updating an employment's parameters outside of testing purposes, use [this Employment update endpoint](#operation/patch_update_employment). + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const patchV1SandboxEmploymentsEmploymentId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const patchV1EmployeeTimeoffId = ( + options: Options, ) => (options.client ?? client).put< - PatchV1SandboxEmploymentsEmploymentIdResponses, - PatchV1SandboxEmploymentsEmploymentIdErrors, + PatchV1EmployeeTimeoffIdResponses, + PatchV1EmployeeTimeoffIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/employments/{employment_id}', + url: '/v1/employee/timeoff/{id}', ...options, headers: { 'Content-Type': 'application/json', @@ -6432,304 +5750,288 @@ export const patchV1SandboxEmploymentsEmploymentId = < }); /** - * Get employment contract pending changes + * Get group by ID via SCIM v2.0 + * + * Retrieves a single group (department) for the authenticated company by group ID + */ +export const getV1ScimV2GroupsId = ( + options: Options, +) => + (options.client ?? client).get< + GetV1ScimV2GroupsIdResponses, + GetV1ScimV2GroupsIdErrors, + ThrowOnError + >({ + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/scim/v2/Groups/{id}', + ...options, + }); + +/** + * Show legal entity administrative details form schema + * + * Returns the json schema of a supported form. Possible form names are: + * ``` + * - administrative_details + * ``` + * + * Most forms require a company access token, as they are dependent on certain + * properties of companies and their current employments. + * * - * Get all the pending changes (waiting for aproval or signature) for the employment contract. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View contracts (`contract:read`) | - | + * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | * */ -export const getV1EmploymentContractsEmploymentIdPendingChanges = < +export const getV1CountriesCountryCodeLegalEntityFormsForm = < ThrowOnError extends boolean = false, >( options: Options< - GetV1EmploymentContractsEmploymentIdPendingChangesData, + GetV1CountriesCountryCodeLegalEntityFormsFormData, ThrowOnError >, ) => (options.client ?? client).get< - GetV1EmploymentContractsEmploymentIdPendingChangesResponses, - GetV1EmploymentContractsEmploymentIdPendingChangesErrors, + GetV1CountriesCountryCodeLegalEntityFormsFormResponses, + GetV1CountriesCountryCodeLegalEntityFormsFormErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employment-contracts/{employment_id}/pending-changes', + url: '/v1/countries/{country_code}/legal_entity_forms/{form}', ...options, }); /** - * Show Resignation + * Get employment contract pending changes * - * Shows the details of a resignation with status `submitted`. + * Get all the pending changes (waiting for aproval or signature) for the employment contract. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View resignations (`resignation:read`) | Manage resignations (`resignation:write`) | + * | Manage employments (`employments`) | View contracts (`contract:read`) | - | * */ -export const getV1ResignationsOffboardingRequestId = < +export const getV1EmploymentContractsEmploymentIdPendingChanges = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1EmploymentContractsEmploymentIdPendingChangesData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1ResignationsOffboardingRequestIdResponses, - GetV1ResignationsOffboardingRequestIdErrors, + GetV1EmploymentContractsEmploymentIdPendingChangesResponses, + GetV1EmploymentContractsEmploymentIdPendingChangesErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/resignations/{offboarding_request_id}', + url: '/v1/employment-contracts/{employment_id}/pending-changes', ...options, }); /** - * Upload file - * - * Uploads a file associated with a specified employment. - * - * Please contact api-support@remote.com to request access to this endpoint. - * - * - * ## Scopes + * Report SDK errors * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | + * Receives error telemetry from the frontend SDK. + * Errors are logged to observability backend for monitoring and debugging. * */ -export const postV1Documents = ( - options: Options, +export const postV1SdkTelemetryErrors = ( + options: Options, ) => (options.client ?? client).post< - PostV1DocumentsResponses, - PostV1DocumentsErrors, + PostV1SdkTelemetryErrorsResponses, + PostV1SdkTelemetryErrorsErrors, ThrowOnError >({ - ...formDataBodySerializer, - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/documents', + url: '/v1/sdk/telemetry-errors', ...options, headers: { - 'Content-Type': null, + 'Content-Type': 'application/json', ...options.headers, }, }); /** - * Invite employment + * Get Company Compliance Profile * - * Invite an employment to start the self-enrollment. + * Returns the KYB and credit risk status for the company's default legal entity. * - * Requirements for the invitation to succeed: * - * * Employment needs to have the following JSON Schema forms filled: `contract_details` and `pricing_plan_details` - * * `provisional_start_date` must consider the minimum onboarding time of the employment's country + * ## Scopes * - * If there are validations errors, they are returned with a Conflict HTTP Status (409) and a descriptive message. - * HTTP Status OK (200) is returned in case of success. + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * - * In case of the following error message: - * `"Please reselect benefits - the previous selection is no longer available"` - * it means that the benefit options have been updated and the employment's benefits are no longer compliant with the new schema. + */ +export const getV1CompaniesCompanyIdComplianceProfile = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).get< + GetV1CompaniesCompanyIdComplianceProfileResponses, + GetV1CompaniesCompanyIdComplianceProfileErrors, + ThrowOnError + >({ url: '/v1/companies/{company_id}/compliance-profile', ...options }); + +/** + * Show payslip * - * In this case, reselect benefits by updating `contract_details` JSON Schema form. + * Given an ID, shows a payslip. + * + * Please contact api-support@remote.com to request access to this endpoint. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage payroll runs (`payroll`) | View payslips (`payslip:read`) | - | * */ -export const postV1EmploymentsEmploymentIdInvite = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1PayslipsId = ( + options: Options, ) => - (options.client ?? client).post< - PostV1EmploymentsEmploymentIdInviteResponses, - PostV1EmploymentsEmploymentIdInviteErrors, + (options.client ?? client).get< + GetV1PayslipsIdResponses, + GetV1PayslipsIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/invite', - ...options, - }); + >({ url: '/v1/payslips/{id}', ...options }); /** - * Show expense + * Approve a time off cancellation request + * + * Approve a time off cancellation request. + * In order to approve a time off cancellation request, the timeoff status must be `cancel_requested`. * - * Shows a single expense record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const getV1ExpensesId = ( - options: Options, +export const postV1TimeoffTimeoffIdCancelRequestApprove = < + ThrowOnError extends boolean = false, +>( + options: Options< + PostV1TimeoffTimeoffIdCancelRequestApproveData, + ThrowOnError + >, ) => - (options.client ?? client).get< - GetV1ExpensesIdResponses, - GetV1ExpensesIdErrors, + (options.client ?? client).post< + PostV1TimeoffTimeoffIdCancelRequestApproveResponses, + PostV1TimeoffTimeoffIdCancelRequestApproveErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses/{id}', - ...options, - }); + >({ url: '/v1/timeoff/{timeoff_id}/cancel-request/approve', ...options }); /** - * Update an expense + * List Webhook Events * - * Updates an expense + * List all webhook events * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | + * | Manage company resources (`company_admin`) | View webhooks (`webhook:read`) | Manage webhooks (`webhook:write`) | * */ -export const patchV1ExpensesId2 = ( - options: Options, +export const getV1WebhookEvents = ( + options?: Options, ) => - (options.client ?? client).patch< - PatchV1ExpensesId2Responses, - PatchV1ExpensesId2Errors, + (options?.client ?? client).get< + GetV1WebhookEventsResponses, + GetV1WebhookEventsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/webhook-events', ...options }); /** - * Update an expense + * List Time Off Types + * + * Lists all time off types that can be used for the `timeoff_type` parameter. + * + * **Backward compatibility:** Calling this endpoint without the `type` query parameter returns the same response as before (time off types for full-time employments). Existing integrations do not need to change. + * + * Optionally, pass `type=contractor` to get time off types for contractor employments, or `type=full_time` for full-time employments (same as omitting the parameter). * - * Updates an expense * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | * */ -export const patchV1ExpensesId = ( - options: Options, +export const getV1TimeoffTypes = ( + options: Options, ) => - (options.client ?? client).put< - PatchV1ExpensesIdResponses, - PatchV1ExpensesIdErrors, + (options.client ?? client).get< + GetV1TimeoffTypesResponses, + GetV1TimeoffTypesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/timeoff/types', ...options }); /** - * Show Benefit Renewal Request + * List Company Legal Entities + * + * Lists all active legal entities for the authorized company specified in the request. * - * Show Benefit Renewal Request details. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View benefit renewals (`benefit_renewal:read`) | Manage benefit renewals (`benefit_renewal:write`) | + * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | * */ -export const getV1BenefitRenewalRequestsBenefitRenewalRequestId = < +export const getV1CompaniesCompanyIdLegalEntities = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses, - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors, + GetV1CompaniesCompanyIdLegalEntitiesResponses, + GetV1CompaniesCompanyIdLegalEntitiesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}', - ...options, - }); + >({ url: '/v1/companies/{company_id}/legal-entities', ...options }); /** - * Updates a Benefit Renewal Request Response + * Create contract eligibility + * + * Create contract eligibility for an employment. + * + * This will create a new contract eligibility for the employment. * - * Updates a Benefit Renewal Request with the given response. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage benefit renewals (`benefit_renewal:write`) | + * | Manage employment documents (`employment_documents`) | - | Manage contract eligibility (`contract_eligibility:write`) | * */ -export const postV1BenefitRenewalRequestsBenefitRenewalRequestId = < +export const postV1EmploymentsEmploymentIdContractEligibility = < ThrowOnError extends boolean = false, >( options: Options< - PostV1BenefitRenewalRequestsBenefitRenewalRequestIdData, + PostV1EmploymentsEmploymentIdContractEligibilityData, ThrowOnError >, ) => (options.client ?? client).post< - PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses, - PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors, + PostV1EmploymentsEmploymentIdContractEligibilityResponses, + PostV1EmploymentsEmploymentIdContractEligibilityErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}', + url: '/v1/employments/{employment_id}/contract-eligibility', ...options, headers: { 'Content-Type': 'application/json', @@ -6738,9 +6040,14 @@ export const postV1BenefitRenewalRequestsBenefitRenewalRequestId = < }); /** - * Show onboarding steps for an employment + * List all currencies for the contractor + * + * The currencies are listed in the following order: + * 1. billing currency of the company + * 2. currencies of contractor’s existing withdrawal methods + * 3. currency of the contractor’s country + * 4. the rest, alphabetical. * - * Returns onboarding steps and substeps in a hierarchical, ordered structure. * * ## Scopes * @@ -6749,287 +6056,284 @@ export const postV1BenefitRenewalRequestsBenefitRenewalRequestId = < * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const getV1EmploymentsEmploymentIdOnboardingSteps = < +export const getV1ContractorsEmploymentsEmploymentIdContractorCurrencies = < ThrowOnError extends boolean = false, >( options: Options< - GetV1EmploymentsEmploymentIdOnboardingStepsData, + GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesData, ThrowOnError >, ) => (options.client ?? client).get< - GetV1EmploymentsEmploymentIdOnboardingStepsResponses, - GetV1EmploymentsEmploymentIdOnboardingStepsErrors, + GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses, + GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/onboarding-steps', + url: '/v1/contractors/employments/{employment_id}/contractor-currencies', ...options, }); /** - * List company structure nodes + * List payslips * - * Shows all the company structure nodes of an employment. + * Lists all payslips belonging to a company. Can also filter for a single employment belonging + * to that company. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View company structure (`company_structure:read`) | - | + * | Manage payroll runs (`payroll`) | View payslips (`payslip:read`) | - | * */ -export const getV1EmploymentsEmploymentIdCompanyStructureNodes = < - ThrowOnError extends boolean = false, ->( - options: Options< - GetV1EmploymentsEmploymentIdCompanyStructureNodesData, +export const getV1Payslips = ( + options?: Options, +) => + (options?.client ?? client).get< + GetV1PayslipsResponses, + GetV1PayslipsErrors, ThrowOnError - >, + >({ url: '/v1/payslips', ...options }); + +/** + * Create employment + * + * Creates an employment without provisional_start_date validation. + * + * This endpoint is only available in Sandbox and allows creating employments which + * `provisional_start_date` is in the past. This is especially helpful for: + * * Testing the Timeoff Balance endpoints + * * Testing the Offboarding endpoints + * * Testing features around probation periods + * + * This endpoint will respond with a 404 outside of the Sandbox environment. + * + * For creating an employment's parameters outside of testing purposes, use [this + * Employment create endpoint](#operation/post_create_employment) + * + */ +export const postV1SandboxEmployments = ( + options: Options, ) => - (options.client ?? client).get< - GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses, - GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors, + (options.client ?? client).post< + PostV1SandboxEmploymentsResponses, + PostV1SandboxEmploymentsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/company-structure-nodes', + url: '/v1/sandbox/employments', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List custom field value for an employment + * Show Company Payroll Runs + * + * Given an ID, shows a payroll run. + * `employee_details` field is deprecated in favour of the `employee_details` endpoint and will be removed in the future. * - * Returns a list of custom field values for a given employment * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View custom field values (`custom_field_value:read`) | Manage custom field values (`custom_field_value:write`) | + * | Manage payroll runs (`payroll`) | View payroll runs (`payroll_run:read`) | - | * */ -export const getV1EmploymentsEmploymentIdCustomFields = < +export const getV1PayrollRunsPayrollRunId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => (options.client ?? client).get< - GetV1EmploymentsEmploymentIdCustomFieldsResponses, - GetV1EmploymentsEmploymentIdCustomFieldsErrors, + GetV1PayrollRunsPayrollRunIdResponses, + GetV1PayrollRunsPayrollRunIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/custom-fields', - ...options, - }); + >({ url: '/v1/payroll-runs/{payroll_run_id}', ...options }); /** - * Validate resignation request + * List pre-onboarding document requirements for an employment + * + * Returns the list of pre-onboarding document requirements (e.g. master service agreements, + * individual labour agreements) that must be fulfilled before the given employment can be onboarded. * - * Validates a resignation employment request * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage resignations (`resignation:write`) | + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | * */ -export const putV1ResignationsOffboardingRequestIdValidate = < - ThrowOnError extends boolean = false, ->( - options: Options< - PutV1ResignationsOffboardingRequestIdValidateData, - ThrowOnError - >, +export const getV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirements = + ( + options: Options< + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsData, + ThrowOnError + >, + ) => + (options.client ?? client).get< + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponses, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsErrors, + ThrowOnError + >({ + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents/requirements', + ...options, + }); + +/** + * Show Offboarding + * + * Shows an Offboarding request. + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employments (`employments`) | View offboarding requests (`offboarding:read`) | Manage offboarding (`offboarding:write`) | + * + */ +export const getV1OffboardingsId = ( + options: Options, ) => - (options.client ?? client).put< - PutV1ResignationsOffboardingRequestIdValidateResponses, - PutV1ResignationsOffboardingRequestIdValidateErrors, + (options.client ?? client).get< + GetV1OffboardingsIdResponses, + GetV1OffboardingsIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/resignations/{offboarding_request_id}/validate', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); + >({ url: '/v1/offboardings/{id}', ...options }); /** - * Reassign default legal entity + * List expenses * - * Set a different legal entity as the company's default entity. + * Lists all expenses records * - * The default entity is used when creating new employments without an explicit entity. - * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | * */ -export const putV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityId = < - ThrowOnError extends boolean = false, ->( - options: Options< - PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdData, - ThrowOnError - >, +export const getV1Expenses = ( + options: Options, ) => - (options.client ?? client).put< - PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses, - PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors, + (options.client ?? client).get< + GetV1ExpensesResponses, + GetV1ExpensesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/companies/{company_id}/default-legal-entity/{legal_entity_id}', - ...options, - }); + >({ url: '/v1/expenses', ...options }); /** - * List Webhook Callbacks + * Create expense * - * List callbacks for a given company + * Creates an **approved** expense * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View webhooks (`webhook:read`) | Manage webhooks (`webhook:write`) | + * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | * */ -export const getV1CompaniesCompanyIdWebhookCallbacks = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1Expenses = ( + options: Options, ) => - (options.client ?? client).get< - GetV1CompaniesCompanyIdWebhookCallbacksResponses, - GetV1CompaniesCompanyIdWebhookCallbacksErrors, + (options.client ?? client).post< + PostV1ExpensesResponses, + PostV1ExpensesErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/webhook-callbacks', + url: '/v1/expenses', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Show contractor eligibility and COR-supported countries for legal entity - * - * Returns which contractor products (standard, plus, cor) the legal entity is eligible to use, - * and the list of country codes where COR is supported for this legal entity. - * COR-supported countries exclude sanctioned and signup-prevented countries and apply entity rules (same-country, local-to-local). - * When the legal entity is not COR-eligible, `cor_supported_country_codes` is an empty list. + * List payslip files for the authenticated employee * + * Returns a paginated list of payslip files belonging to the current employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | + * | Manage payroll runs (`payroll`) | View payslips (`payslip:read`) | - | * */ -export const getV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibility = - ( - options: Options< - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityData, - ThrowOnError - >, - ) => - (options.client ?? client).get< - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses, - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/contractor-eligibility', - ...options, - }); +export const getV1EmployeePayslipFiles = ( + options?: Options, +) => + (options?.client ?? client).get< + GetV1EmployeePayslipFilesResponses, + GetV1EmployeePayslipFilesErrors, + ThrowOnError + >({ url: '/v1/employee/payslip-files', ...options }); /** - * Show a custom field value + * Invite employment + * + * Invite an employment to start the self-enrollment. + * + * Requirements for the invitation to succeed: + * + * * Employment needs to have the following JSON Schema forms filled: `contract_details` and `pricing_plan_details` + * * `provisional_start_date` must consider the minimum onboarding time of the employment's country + * + * If there are validations errors, they are returned with a Conflict HTTP Status (409) and a descriptive message. + * HTTP Status OK (200) is returned in case of success. + * + * In case of the following error message: + * `"Please reselect benefits - the previous selection is no longer available"` + * it means that the benefit options have been updated and the employment's benefits are no longer compliant with the new schema. + * + * In this case, reselect benefits by updating `contract_details` JSON Schema form. * - * Returns a custom field value for a given employment * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View custom field values (`custom_field_value:read`) | Manage custom field values (`custom_field_value:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const getV1CustomFieldsCustomFieldIdValuesEmploymentId = < +export const postV1EmploymentsEmploymentIdInvite = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1CustomFieldsCustomFieldIdValuesEmploymentIdData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).get< - GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses, - GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors, + (options.client ?? client).post< + PostV1EmploymentsEmploymentIdInviteResponses, + PostV1EmploymentsEmploymentIdInviteErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}', - ...options, - }); + >({ url: '/v1/employments/{employment_id}/invite', ...options }); /** - * Update a Custom Field Value + * Create Probation Extension * - * Updates a custom field value for a given employment. + * Create a probation extension request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage custom field values (`custom_field_value:write`) | + * | Manage employment documents (`employment_documents`) | - | Manage probation documents (`probation_document:write`) | * */ -export const patchV1CustomFieldsCustomFieldIdValuesEmploymentId2 = < - ThrowOnError extends boolean = false, ->( - options: Options< - PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Data, - ThrowOnError - >, +export const postV1ProbationExtensions = ( + options: Options, ) => - (options.client ?? client).patch< - PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses, - PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors, + (options.client ?? client).post< + PostV1ProbationExtensionsResponses, + PostV1ProbationExtensionsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}', + url: '/v1/probation-extensions', ...options, headers: { 'Content-Type': 'application/json', @@ -7038,46 +6342,38 @@ export const patchV1CustomFieldsCustomFieldIdValuesEmploymentId2 = < }); /** - * Update a Custom Field Value - * - * Updates a custom field value for a given employment. + * Approve Contract Amendment * - * ## Scopes + * Approves a contract amendment request without the intervention of a Remote admin. + * Approvals done via this endpoint are effective immediately, + * regardless of the effective date entered on the contract amendment creation. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employments (`employments`) | - | Manage custom field values (`custom_field_value:write`) | + * This endpoint is only available in Sandbox, otherwise it will respond with a 404. * */ -export const patchV1CustomFieldsCustomFieldIdValuesEmploymentId = < +export const putV1SandboxContractAmendmentsContractAmendmentRequestIdApprove = < ThrowOnError extends boolean = false, >( options: Options< - PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdData, + PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveData, ThrowOnError >, ) => (options.client ?? client).put< - PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses, - PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors, + PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses, + PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}', + url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/approve', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Show a contractor of record (COR) termination request + * Get Onboarding Reserves Status for Employment * - * Retrieves a Contractor of Record termination request by ID. + * Returns the onboarding reserves status for a specific employment. + * + * The status is the same as the credit risk status but takes the onboarding reserves policies into account. * * * ## Scopes @@ -7087,251 +6383,177 @@ export const patchV1CustomFieldsCustomFieldIdValuesEmploymentId = < * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const getV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestId = +export const getV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatus = ( options: Options< - GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdData, + GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusData, ThrowOnError >, ) => (options.client ?? client).get< - GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses, - GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors, + GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses, + GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/cor-termination-requests/{termination_request_id}', + url: '/v1/companies/{company_id}/employments/{employment_id}/onboarding-reserves-status', ...options, }); /** - * Terminate contractor of record employment - * - * **Deprecated.** Use `POST /contractors/employments/{employment_id}/cor-termination-requests` instead. - * - * Initiates a termination request for a Contractor of Record employment. - * When a termination request is sent, a stop work order is issued and the contractor remains active until a final invoice is paid or waived. - * Currently, only Contractor of Record employments can be terminated. + * Show Contractor Invoice * + * Shows a single Contractor Invoice record. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | * + */ +export const getV1ContractorInvoicesId = ( + options: Options, +) => + (options.client ?? client).get< + GetV1ContractorInvoicesIdResponses, + GetV1ContractorInvoicesIdErrors, + ThrowOnError + >({ url: '/v1/contractor-invoices/{id}', ...options }); + +/** + * Payroll Feature API resource * - * @deprecated + * API to retrieve feature properties from the vendor system */ -export const postV1ContractorsEmploymentsEmploymentIdTerminateCorEmployment = < +export const getV1WdGphPayProcessingFeature = < ThrowOnError extends boolean = false, >( - options: Options< - PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentData, - ThrowOnError - >, + options?: Options, ) => - (options.client ?? client).post< - PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses, - PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors, + (options?.client ?? client).get< + GetV1WdGphPayProcessingFeatureResponses, + GetV1WdGphPayProcessingFeatureErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/terminate-cor-employment', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/wd/gph/payProcessingFeature', ...options, }); /** - * Sign a document for a contractor - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | - * - */ -export const postV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSign = - ( - options: Options< - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignData, - ThrowOnError - >, - ) => - (options.client ?? client).post< - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses, - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contract-documents/{contract_document_id}/sign', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); - -/** - * Get token identity - * - * Shows information about the entities that can be controlled by the current auth token. + * Payroll processing progress API resource * + * API to retrieve the processing stages of a pay group */ -export const getV1IdentityCurrent = ( - options: Options, +export const getV1WdGphPayProgress = ( + options: Options, ) => (options.client ?? client).get< - GetV1IdentityCurrentResponses, - GetV1IdentityCurrentErrors, + GetV1WdGphPayProgressResponses, + GetV1WdGphPayProgressErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/identity/current', + security: [{ scheme: 'bearer', type: 'http' }], + url: '/v1/wd/gph/payProgress', ...options, }); /** - * Delete an Incentive - * - * Delete an incentive. - * - * `one_time` incentives that have the following status **CANNOT** be deleted: - * * `processing` - * * `paid` + * List company supported currencies * + * List company supported currencies * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | + * | Manage company resources (`company_admin`) | View company currencies (`company_currencies:read`) | - | * */ -export const deleteV1IncentivesId = ( - options: Options, +export const getV1CompanyCurrencies = ( + options?: Options, ) => - (options.client ?? client).delete< - DeleteV1IncentivesIdResponses, - DeleteV1IncentivesIdErrors, + (options?.client ?? client).get< + GetV1CompanyCurrenciesResponses, + GetV1CompanyCurrenciesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives/{id}', - ...options, - }); + >({ url: '/v1/company-currencies', ...options }); /** - * Show Incentive - * - * Show an Incentive's details + * Get a employment benefit offers JSON schema * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View incentives (`incentive:read`) | Manage incentives (`incentive:write`) | + * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | * */ -export const getV1IncentivesId = ( - options: Options, +export const getV1EmploymentsEmploymentIdBenefitOffersSchema = < + ThrowOnError extends boolean = false, +>( + options: Options< + GetV1EmploymentsEmploymentIdBenefitOffersSchemaData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1IncentivesIdResponses, - GetV1IncentivesIdErrors, + GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses, + GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives/{id}', + url: '/v1/employments/{employment_id}/benefit-offers/schema', ...options, }); /** - * Update Incentive - * - * Updates an Incentive. - * - * Incentives use the currency of the employment specified provided in the `employment_id` field. - * - * The API doesn't support updating paid incentives. + * List Contractor Invoice Schedules * + * Lists Contractor Invoice Schedule records. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | + * | Manage invoices (`invoices`) | - | Manage invoices (`invoices:write`) | * */ -export const patchV1IncentivesId2 = ( - options: Options, +export const getV1ContractorInvoiceSchedules = < + ThrowOnError extends boolean = false, +>( + options?: Options, ) => - (options.client ?? client).patch< - PatchV1IncentivesId2Responses, - PatchV1IncentivesId2Errors, + (options?.client ?? client).get< + GetV1ContractorInvoiceSchedulesResponses, + GetV1ContractorInvoiceSchedulesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives/{id}', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); - -/** - * Update Incentive - * - * Updates an Incentive. - * - * Incentives use the currency of the employment specified provided in the `employment_id` field. + >({ url: '/v1/contractor-invoice-schedules', ...options }); + +/** + * Create Contractor Invoice Schedules * - * The API doesn't support updating paid incentives. + * Creates many invoice schedules records. + * It's supposed to return two lists: one containing created records, and another one containing the schedules that failed to be inserted. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage incentives (`incentive:write`) | + * | Manage invoices (`invoices`) | - | Manage invoices (`invoices:write`) | * */ -export const patchV1IncentivesId = ( - options: Options, +export const postV1ContractorInvoiceSchedules = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).put< - PatchV1IncentivesIdResponses, - PatchV1IncentivesIdErrors, + (options.client ?? client).post< + PostV1ContractorInvoiceSchedulesResponses, + PostV1ContractorInvoiceSchedulesErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/incentives/{id}', + url: '/v1/contractor-invoice-schedules', ...options, headers: { 'Content-Type': 'application/json', @@ -7340,286 +6562,275 @@ export const patchV1IncentivesId = ( }); /** - * Get eligibility questionnaire schema - * - * Returns the JSON schema for the eligibility questionnaire by type. - * - * The schema defines the structure and validation rules for the questionnaire responses. - * Supports versioning to allow for schema evolution while maintaining backwards compatibility. + * Show work authorization request * + * Show a single work authorization request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | View work authorizations (`work_authorization:read`) | Manage work authorizations (`work_authorization:write`) | * */ -export const getV1ContractorsSchemasEligibilityQuestionnaire = < +export const getV1WorkAuthorizationRequestsId = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1ContractorsSchemasEligibilityQuestionnaireData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1ContractorsSchemasEligibilityQuestionnaireResponses, - GetV1ContractorsSchemasEligibilityQuestionnaireErrors, + GetV1WorkAuthorizationRequestsIdResponses, + GetV1WorkAuthorizationRequestsIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/schemas/eligibility-questionnaire', - ...options, - }); + >({ url: '/v1/work-authorization-requests/{id}', ...options }); /** - * List work authorization requests + * Update work authorization request * - * List work authorization requests. + * Updates a work authorization request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View work authorizations (`work_authorization:read`) | Manage work authorizations (`work_authorization:write`) | + * | Manage employments (`employments`) | - | Manage work authorizations (`work_authorization:write`) | * */ -export const getV1WorkAuthorizationRequests = < +export const patchV1WorkAuthorizationRequestsId2 = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options, ) => - (options?.client ?? client).get< - GetV1WorkAuthorizationRequestsResponses, - GetV1WorkAuthorizationRequestsErrors, + (options.client ?? client).patch< + PatchV1WorkAuthorizationRequestsId2Responses, + PatchV1WorkAuthorizationRequestsId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/work-authorization-requests', + url: '/v1/work-authorization-requests/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Show bulk employment job + * Update work authorization request + * + * Updates a work authorization request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | - | Manage work authorizations (`work_authorization:write`) | * */ -export const getV1BulkEmploymentJobsJobId = < +export const patchV1WorkAuthorizationRequestsId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).get< - GetV1BulkEmploymentJobsJobIdResponses, - GetV1BulkEmploymentJobsJobIdErrors, + (options.client ?? client).put< + PatchV1WorkAuthorizationRequestsIdResponses, + PatchV1WorkAuthorizationRequestsIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/bulk-employment-jobs/{job_id}', + url: '/v1/work-authorization-requests/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List Pay Items + * Decline Time Off * - * Lists pay items for a company with optional filtering by employment, date range, and pagination. + * Decline a time off request. Please note that only time off requests on the `requested` status can be declined. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage payroll runs (`payroll`) | View pay items (`pay_item:read`) | Manage pay items (`pay_item:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const getV1PayItems = ( - options?: Options, +export const postV1TimeoffTimeoffIdDecline = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options?.client ?? client).get< - GetV1PayItemsResponses, - GetV1PayItemsErrors, + (options.client ?? client).post< + PostV1TimeoffTimeoffIdDeclineResponses, + PostV1TimeoffTimeoffIdDeclineErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/pay-items', + url: '/v1/timeoff/{timeoff_id}/decline', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * List Benefit Offers + * Get eligibility questionnaire schema * - * List benefit offers for each country. + * Returns the JSON schema for the eligibility questionnaire by type. + * + * The schema defines the structure and validation rules for the questionnaire responses. + * Supports versioning to allow for schema evolution while maintaining backwards compatibility. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | * */ -export const getV1BenefitOffersCountrySummaries = < +export const getV1ContractorsSchemasEligibilityQuestionnaire = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1ContractorsSchemasEligibilityQuestionnaireData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1BenefitOffersCountrySummariesResponses, - GetV1BenefitOffersCountrySummariesErrors, + GetV1ContractorsSchemasEligibilityQuestionnaireResponses, + GetV1ContractorsSchemasEligibilityQuestionnaireErrors, + ThrowOnError + >({ url: '/v1/contractors/schemas/eligibility-questionnaire', ...options }); + +/** + * Token + * + * Endpoint to exchange tokens in the Authorization Code, Assertion Flow, Client Credentials and Refresh Token flows + */ +export const postAuthOauth2Token = ( + options?: Options, +) => + (options?.client ?? client).post< + PostAuthOauth2TokenResponses, + PostAuthOauth2TokenErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/benefit-offers/country-summaries', + url: '/api/eor/oauth2/token', ...options, + headers: { + 'Content-Type': 'application/json', + ...options?.headers, + }, }); /** - * List Benefit Offers By Employment + * Delete contractor of record subscription intent * - * List benefit offers by employment. + * Deletes Contractor of Record subscription intent. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View benefit offers (`benefit_offer:read`) | Manage benefit offers (`benefit_offer:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const getV1BenefitOffers = ( - options: Options, -) => - (options.client ?? client).get< - GetV1BenefitOffersResponses, - GetV1BenefitOffersErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/benefit-offers', - ...options, - }); +export const deleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscription = + ( + options: Options< + DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData, + ThrowOnError + >, + ) => + (options.client ?? client).delete< + DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses, + DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors, + ThrowOnError + >({ + url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription', + ...options, + }); /** - * Cancel Contract Amendment - * - * Use this endpoint to cancel an existing contract amendment request. + * Create contractor of record subscription intent * - * This endpoint is only available in Sandbox, otherwise it will respond with a 404. + * Assigns Contractor of Record subscription in pending state to employment. + * Once risk analysis is performed, subscription may start upon contract signing, + * or might be denied. * - */ -export const putV1SandboxContractAmendmentsContractAmendmentRequestIdCancel = < - ThrowOnError extends boolean = false, ->( - options: Options< - PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelData, - ThrowOnError - >, -) => - (options.client ?? client).put< - PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses, - PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/cancel', - ...options, - }); - -/** - * List employee time offs + * Requires a non-blocking eligibility questionnaire to be submitted before creating the subscription intent. * - * Lists the current employee's time off records * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const getV1EmployeeTimeoff = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1EmployeeTimeoffResponses, - GetV1EmployeeTimeoffErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/timeoff', - ...options, - }); +export const postV1ContractorsEmploymentsEmploymentIdContractorCorSubscription = + ( + options: Options< + PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData, + ThrowOnError + >, + ) => + (options.client ?? client).post< + PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses, + PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors, + ThrowOnError + >({ + url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription', + ...options, + }); /** - * Create a Pending Time Off + * Update personal details + * + * Updates employment's personal details. + * + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. + * * - * Creates a pending Time Off record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1EmployeeTimeoff = ( - options: Options, -) => - (options.client ?? client).post< - PostV1EmployeeTimeoffResponses, - PostV1EmployeeTimeoffErrors, - ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/timeoff', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); - -/** - * Update employment - */ -export const patchV2EmploymentsEmploymentId2 = < +export const putV2EmploymentsEmploymentIdPersonalDetails = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PutV2EmploymentsEmploymentIdPersonalDetailsData, + ThrowOnError + >, ) => - (options.client ?? client).patch< - PatchV2EmploymentsEmploymentId2Responses, - PatchV2EmploymentsEmploymentId2Errors, + (options.client ?? client).put< + PutV2EmploymentsEmploymentIdPersonalDetailsResponses, + PutV2EmploymentsEmploymentIdPersonalDetailsErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v2/employments/{employment_id}', + url: '/v2/employments/{employment_id}/personal_details', ...options, headers: { 'Content-Type': 'application/json', @@ -7628,20 +6839,34 @@ export const patchV2EmploymentsEmploymentId2 = < }); /** - * Update employment + * Find or create a pre-onboarding document for an employment + * + * Finds an existing unsigned pre-onboarding document for the given requirement, or creates a new one. + * Idempotent: repeated calls with the same `pre_onboarding_document_requirement_slug` return the same + * document until it is signed. + * + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employment documents (`employment_documents`) | - | Manage documents (`document:write`) | + * */ -export const patchV2EmploymentsEmploymentId = < +export const postV1OnboardingEmploymentsEmploymentIdPreOnboardingDocuments = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsData, + ThrowOnError + >, ) => - (options.client ?? client).put< - PatchV2EmploymentsEmploymentIdResponses, - PatchV2EmploymentsEmploymentIdErrors, + (options.client ?? client).post< + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponses, + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v2/employments/{employment_id}', + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents', ...options, headers: { 'Content-Type': 'application/json', @@ -7650,70 +6875,57 @@ export const patchV2EmploymentsEmploymentId = < }); /** - * Show Probation Extension - * - * Shows a Probation Extension Request. + * Show Contract Amendment * + * Show a single Contract Amendment request. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View probation documents (`probation_document:read`) | Manage probation documents (`probation_document:write`) | + * | Manage employments (`employments`) | View contract amendments (`contract_amendment:read`) | Manage contract amendments (`contract_amendment:write`) | * */ -export const getV1ProbationExtensionsId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1ContractAmendmentsId = ( + options: Options, ) => (options.client ?? client).get< - GetV1ProbationExtensionsIdResponses, - GetV1ProbationExtensionsIdErrors, + GetV1ContractAmendmentsIdResponses, + GetV1ContractAmendmentsIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/probation-extensions/{id}', - ...options, - }); + >({ url: '/v1/contract-amendments/{id}', ...options }); /** - * List payslips + * Decline Identity Verification * - * Lists all payslips belonging to a company. Can also filter for a single employment belonging - * to that company. + * Declines the identity verification of an employee. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View payslips (`payslip:read`) | - | + * | Manage employment documents (`employment_documents`) | - | Manage identity verification (`identity_verification:write`) | * */ -export const getV1Payslips = ( - options?: Options, +export const postV1IdentityVerificationEmploymentIdDecline = < + ThrowOnError extends boolean = false, +>( + options: Options< + PostV1IdentityVerificationEmploymentIdDeclineData, + ThrowOnError + >, ) => - (options?.client ?? client).get< - GetV1PayslipsResponses, - GetV1PayslipsErrors, + (options.client ?? client).post< + PostV1IdentityVerificationEmploymentIdDeclineResponses, + PostV1IdentityVerificationEmploymentIdDeclineErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/payslips', - ...options, - }); + >({ url: '/v1/identity-verification/{employment_id}/decline', ...options }); /** - * Download a receipt by id + * List expense categories for the authenticated employee * - * Download a receipt by id. + * Returns the flat list of expense categories applicable to the current employee. Only active categories are returned, filtered by the employee's country / legal-entity visibility rules. Leaf nodes have `is_selectable: true`; parent nodes are excluded unless `include_parents=true`. * * ## Scopes * @@ -7722,39 +6934,33 @@ export const getV1Payslips = ( * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | * */ -export const getV1ExpensesExpenseIdReceiptsReceiptId = < +export const getV1EmployeeExpenseCategories = < ThrowOnError extends boolean = false, >( - options: Options, + options?: Options, ) => - (options.client ?? client).get< - GetV1ExpensesExpenseIdReceiptsReceiptIdResponses, - GetV1ExpensesExpenseIdReceiptsReceiptIdErrors, + (options?.client ?? client).get< + GetV1EmployeeExpenseCategoriesResponses, + GetV1EmployeeExpenseCategoriesErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/expenses/{expense_id}/receipts/{receipt_id}', - ...options, - }); + >({ url: '/v1/employee/expense-categories', ...options }); /** - * Token + * Creates a CSV cost estimation of employments * - * Endpoint to exchange tokens in the Authorization Code, Assertion Flow, Client Credentials and Refresh Token flows + * Creates CSV cost estimation of employments */ -export const postAuthOauth2Token = ( - options?: Options, +export const postV1CostCalculatorEstimationCsv = < + ThrowOnError extends boolean = false, +>( + options?: Options, ) => (options?.client ?? client).post< - PostAuthOauth2TokenResponses, - PostAuthOauth2TokenErrors, + PostV1CostCalculatorEstimationCsvResponses, + PostV1CostCalculatorEstimationCsvErrors, ThrowOnError >({ - security: [{ scheme: 'basic', type: 'http' }], - url: '/auth/oauth2/token', + url: '/v1/cost-calculator/estimation-csv', ...options, headers: { 'Content-Type': 'application/json', @@ -7763,178 +6969,196 @@ export const postAuthOauth2Token = ( }); /** - * Update pricing plan details + * Retrieve a pre-onboarding document with its rendered PDF content * - * Updates the pricing plan for an employment. The frequency determines how often Remote bills the - * employer for management fees. Annual billing typically offers a discount. + * Returns the rendered contract PDF (base64-encoded) and the list of signatories for the given + * pre-onboarding document. The `content` field is prefixed with `data:application/pdf;base64,` so + * it can be embedded directly in a document viewer. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | * */ -export const putV2EmploymentsEmploymentIdPricingPlanDetails = < +export const getV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsId = < ThrowOnError extends boolean = false, >( options: Options< - PutV2EmploymentsEmploymentIdPricingPlanDetailsData, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdData, ThrowOnError >, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses, - PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors, + (options.client ?? client).get< + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponses, + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/pricing_plan_details', + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents/{id}', ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, }); /** - * Show legal entity administrative details form schema + * List Billing Documents * - * Returns the json schema of a supported form. Possible form names are: - * ``` - * - administrative_details - * ``` + * List billing documents for a company * - * Most forms require a company access token, as they are dependent on certain - * properties of companies and their current employments. + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | + * + */ +export const getV1BillingDocuments = ( + options: Options, +) => + (options.client ?? client).get< + GetV1BillingDocumentsResponses, + GetV1BillingDocumentsErrors, + ThrowOnError + >({ url: '/v1/billing-documents', ...options }); + +/** + * Show Billing Document + * + * Shows a billing document details. * + * Please contact api-support@remote.com to request access to this endpoint. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View forms (`form:read`) | - | + * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | * */ -export const getV1CountriesCountryCodeLegalEntityFormsForm = < +export const getV1BillingDocumentsBillingDocumentId = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1CountriesCountryCodeLegalEntityFormsFormData, - ThrowOnError - >, + options: Options, ) => (options.client ?? client).get< - GetV1CountriesCountryCodeLegalEntityFormsFormResponses, - GetV1CountriesCountryCodeLegalEntityFormsFormErrors, + GetV1BillingDocumentsBillingDocumentIdResponses, + GetV1BillingDocumentsBillingDocumentIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/countries/{country_code}/legal_entity_forms/{form}', - ...options, - }); + >({ url: '/v1/billing-documents/{billing_document_id}', ...options }); /** - * Manage contractor plus subscription + * Indexes all the documents for the employee * - * Endpoint that can be used to upgrade, assign or downgrade a contractor's subscription. - * This can be used when company admins desire to assign someone to the Contractor Plus plan, - * but also to change the contractor's subscription between Plus and Standard. + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | + * + */ +export const getV1EmployeeDocuments = ( + options?: Options, +) => + (options?.client ?? client).get< + GetV1EmployeeDocumentsResponses, + GetV1EmployeeDocumentsErrors, + ThrowOnError + >({ url: '/v1/employee/documents', ...options }); + +/** + * List employee time offs * + * Lists the current employee's time off records * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | * */ -export const postV1ContractorsEmploymentsEmploymentIdContractorPlusSubscription = - ( - options: Options< - PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionData, - ThrowOnError - >, - ) => - (options.client ?? client).post< - PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses, - PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contractor-plus-subscription', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options.headers, - }, - }); +export const getV1EmployeeTimeoff = ( + options?: Options, +) => + (options?.client ?? client).get< + GetV1EmployeeTimeoffResponses, + GetV1EmployeeTimeoffErrors, + ThrowOnError + >({ url: '/v1/employee/timeoff', ...options }); /** - * List Time Off + * Create a Pending Time Off * - * Lists all Time Off records. + * Creates a pending Time Off record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | View timeoffs (`timeoff:read`) | Manage timeoffs (`timeoff:write`) | + * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | * */ -export const getV1Timeoff = ( - options: Options, +export const postV1EmployeeTimeoff = ( + options: Options, ) => - (options.client ?? client).get< - GetV1TimeoffResponses, - GetV1TimeoffErrors, + (options.client ?? client).post< + PostV1EmployeeTimeoffResponses, + PostV1EmployeeTimeoffErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff', + url: '/v1/employee/timeoff', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Create Time Off + * Update personal details + * + * Updates employment's personal details. + * + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. + * * - * Creates a Time Off record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1Timeoff = ( - options: Options, +export const putV1EmploymentsEmploymentIdPersonalDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + PutV1EmploymentsEmploymentIdPersonalDetailsData, + ThrowOnError + >, ) => - (options.client ?? client).post< - PostV1TimeoffResponses, - PostV1TimeoffErrors, + (options.client ?? client).put< + PutV1EmploymentsEmploymentIdPersonalDetailsResponses, + PutV1EmploymentsEmploymentIdPersonalDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff', + url: '/v1/employments/{employment_id}/personal_details', ...options, headers: { 'Content-Type': 'application/json', @@ -7943,107 +7167,94 @@ export const postV1Timeoff = ( }); /** - * List Company Payroll Runs + * Show Probation Extension + * + * Shows a Probation Extension Request. * - * Lists all payroll runs for a company * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage payroll runs (`payroll`) | View payroll runs (`payroll_run:read`) | - | + * | Manage employment documents (`employment_documents`) | View probation documents (`probation_document:read`) | Manage probation documents (`probation_document:write`) | * */ -export const getV1PayrollRuns = ( - options?: Options, +export const getV1ProbationExtensionsId = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options?.client ?? client).get< - GetV1PayrollRunsResponses, - GetV1PayrollRunsErrors, + (options.client ?? client).get< + GetV1ProbationExtensionsIdResponses, + GetV1ProbationExtensionsIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/payroll-runs', - ...options, - }); + >({ url: '/v1/probation-extensions/{id}', ...options }); /** - * Get group by ID via SCIM v2.0 + * Download file + * + * Downloads a file. + * + * + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | * - * Retrieves a single group (department) for the authenticated company by group ID */ -export const getV1ScimV2GroupsId = ( - options: Options, +export const getV1FilesId = ( + options: Options, ) => (options.client ?? client).get< - GetV1ScimV2GroupsIdResponses, - GetV1ScimV2GroupsIdErrors, + GetV1FilesIdResponses, + GetV1FilesIdErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/scim/v2/Groups/{id}', - ...options, - }); + >({ url: '/v1/files/{id}', ...options }); /** - * List Employment Contract. + * List Company Departments + * + * Lists all departments for the authorized company specified in the request. * - * Get the employment contract history for a given employment. If `only_active` is true, it will return only the active or last active contract. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View contracts (`contract:read`) | - | + * | Manage company resources (`company_admin`) | View departments (`company_department:read`) | Manage departments (`company_department:write`) | * */ -export const getV1EmploymentContracts = ( - options: Options, +export const getV1CompanyDepartments = ( + options: Options, ) => (options.client ?? client).get< - GetV1EmploymentContractsResponses, - GetV1EmploymentContractsErrors, + GetV1CompanyDepartmentsResponses, + GetV1CompanyDepartmentsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employment-contracts', - ...options, - }); + >({ url: '/v1/company-departments', ...options }); /** - * Convert currency using dynamic rates + * Create New Department * - * Convert currency using the rates Remote applies during employment creation and invoicing. + * Creates a new department in the specified company. Department names may be non-unique and must be non-empty with no more than 255 characters (Unicode code points). * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | Convert currencies (`convert_currency:read`) | - | + * | Manage company resources (`company_admin`) | - | Manage departments (`company_department:write`) | * */ -export const postV1CurrencyConverterEffective2 = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const postV1CompanyDepartments = ( + options: Options, ) => (options.client ?? client).post< - PostV1CurrencyConverterEffective2Responses, - PostV1CurrencyConverterEffective2Errors, + PostV1CompanyDepartmentsResponses, + PostV1CompanyDepartmentsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/currency-converter', + url: '/v1/company-departments', ...options, headers: { 'Content-Type': 'application/json', @@ -8052,84 +7263,138 @@ export const postV1CurrencyConverterEffective2 = < }); /** - * List all companies + * Get Employee Details for a Payroll Run * - * List all companies that authorized your integration to act on their behalf. In other words, these are all the companies that your integration can manage. Any company that has completed the authorization flow for your integration will be included in the response. + * Gets the employee details for a payroll run * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View companies (`company:read`) | Manage companies (`company:write`) | + * | Manage payroll runs (`payroll`) | View payroll runs (`payroll_run:read`) | - | * */ -export const getV1Companies = ( - options: Options, +export const getV1PayrollRunsPayrollRunIdEmployeeDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + GetV1PayrollRunsPayrollRunIdEmployeeDetailsData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1CompaniesResponses, - GetV1CompaniesErrors, + GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses, + GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies', - ...options, - }); + >({ url: '/v1/payroll-runs/{payroll_run_id}/employee-details', ...options }); /** - * Create a company + * Show employment * - * Creates a new company. + * Shows all the information of an employment. * - * ### Creating a company with only the required request body parameters - * When you call this endpoint and omit all the optional parameters in the request body, - * the following resources get created upon a successful response: - * * A new company with status `pending`. - * * A company owner for the new company with status `initiated`. + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. * - * See the [update a company endpoint](#tag/Companies/operation/patch_update_company) for - * more details on how to get your company and its owner to `active` status. + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. * - * If you'd like to create a company and its owner with `active` status in a single request, - * please provide the optional `address_details` parameter as well. + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. * - * ### Accepting the Terms of Service + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. * - * A required step for creating a company in Remote is to accept our Terms of Service (ToS). + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. * - * Company managers need to be aware of our Terms of Service and Privacy Policy, - * hence **it's the responsibility of our partners to advise and ensure company managers read - * and accept the ToS**. The terms have to be accepted only once, before creating a company, - * and the Remote API will collect the acceptance timestamp as its confirmation. * - * To ensure users read the most recent version of Remote's Terms of Service, their **acceptance - * must be done within the last fifteen minutes prior the company creation action**. * - * To retrieve this information, partners can provide an element with any text and a description - * explaining that by performing that action they are accepting Remote's Term of Service. For - * instance, the partner can add a checkbox or a "Create Remote Account" button followed by a - * description saying "By creating an account, you agree to - * [Remote's Terms of Service](https://remote.com/terms-of-service). Also see Remote's - * [Privacy Policy](https://remote.com/privacy-policy)". + * ## Scopes + * + * | Category | Read only Scope | Write only Scope (read access implicit) | + * |---|---|---| + * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * + */ +export const getV1EmploymentsEmploymentId = < + ThrowOnError extends boolean = false, +>( + options: Options, +) => + (options.client ?? client).get< + GetV1EmploymentsEmploymentIdResponses, + GetV1EmploymentsEmploymentIdErrors, + ThrowOnError + >({ url: '/v1/employments/{employment_id}', ...options }); + +/** + * Update employment + * + * Updates an employment. + * + * **For `created` employments:** You can change all basic params and onboarding tasks or perform a per onboarding task update. You can also update basic_information. + * + * **For `active` employments:** You can update the manager (`manager_id` field), emergency_contact_details, address_details and work_email. + * + * **For `invited` employments:** You can update the work_email. + * + * After onboarding, only a limited set of employment data will be available for updates, such as `emergency_contact_details`. + * If you want to provide additional information for an employment, please make sure to do so **before** the employee is invited. + * We block updates to some employment data because employees need to agree to amendments in certain cases, such as when there are changes to their contract_details. + * Currently, these amendments can only be done through the Remote UI. + * + * It is possible to update the `external_id` of the employment for all employment statuses. + * + * ## Global Payroll Employees + * + * To update a Global Payment employment your input data must comply with the global payroll json schemas. + * + * **For `active` employments:** In addition to the above list, you can update personal_details. + * + * ## Direct Employees + * + * To update an HRIS employment your input data must comply with the HRIS json schemas. + * + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * + * + * Please contact Remote if you need to update contractors via API since it's currently not supported. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage companies (`company_management`) | - | Manage companies (`company:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1Companies = ( - options: Options, +export const patchV1EmploymentsEmploymentId2 = < + ThrowOnError extends boolean = false, +>( + options: Options, ) => - (options.client ?? client).post< - PostV1CompaniesResponses, - PostV1CompaniesErrors, + (options.client ?? client).patch< + PatchV1EmploymentsEmploymentId2Responses, + PatchV1EmploymentsEmploymentId2Errors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/companies', + url: '/v1/employments/{employment_id}', ...options, headers: { 'Content-Type': 'application/json', @@ -8138,64 +7403,71 @@ export const postV1Companies = ( }); /** - * Create bulk employment job + * Update employment * - * Creates a job to bulk-create employments for multiple employees at once. Each employee payload must match the employment schema for the selected country. + * Updates an employment. * - * ## Scopes + * **For `created` employments:** You can change all basic params and onboarding tasks or perform a per onboarding task update. You can also update basic_information. * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * **For `active` employments:** You can update the manager (`manager_id` field), emergency_contact_details, address_details and work_email. * - */ -export const postV1BulkEmploymentJobs = ( - options?: Options, -) => - (options?.client ?? client).post< - PostV1BulkEmploymentJobsResponses, - PostV1BulkEmploymentJobsErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/bulk-employment-jobs', - ...options, - headers: { - 'Content-Type': 'application/json', - ...options?.headers, - }, - }); - -/** - * Send back a timesheet for review or modification + * **For `invited` employments:** You can update the work_email. + * + * After onboarding, only a limited set of employment data will be available for updates, such as `emergency_contact_details`. + * If you want to provide additional information for an employment, please make sure to do so **before** the employee is invited. + * We block updates to some employment data because employees need to agree to amendments in certain cases, such as when there are changes to their contract_details. + * Currently, these amendments can only be done through the Remote UI. + * + * It is possible to update the `external_id` of the employment for all employment statuses. + * + * ## Global Payroll Employees + * + * To update a Global Payment employment your input data must comply with the global payroll json schemas. + * + * **For `active` employments:** In addition to the above list, you can update personal_details. + * + * ## Direct Employees + * + * To update an HRIS employment your input data must comply with the HRIS json schemas. + * + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) tool. + * + * + * Please contact Remote if you need to update contractors via API since it's currently not supported. * - * Sends the given timesheet back to the employee for review or modification. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timesheets (`timesheet:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1TimesheetsTimesheetIdSendBack = < +export const patchV1EmploymentsEmploymentId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).post< - PostV1TimesheetsTimesheetIdSendBackResponses, - PostV1TimesheetsTimesheetIdSendBackErrors, + (options.client ?? client).put< + PatchV1EmploymentsEmploymentIdResponses, + PatchV1EmploymentsEmploymentIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timesheets/{timesheet_id}/send-back', + url: '/v1/employments/{employment_id}', ...options, headers: { 'Content-Type': 'application/json', @@ -8204,100 +7476,81 @@ export const postV1TimesheetsTimesheetIdSendBack = < }); /** - * Deletes a Company Manager user + * List timesheets for the authenticated employee * - * Deletes a Company Manager user + * Returns a paginated list of timesheets for the authenticated employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | - | Manage managers (`company_manager:write`) | + * | Manage timeoffs (`time_and_attendance`) | View timesheets (`timesheet:read`) | Manage timesheets (`timesheet:write`) | * */ -export const deleteV1CompanyManagersUserId = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1EmployeeTimesheets = ( + options?: Options, ) => - (options.client ?? client).delete< - DeleteV1CompanyManagersUserIdResponses, - DeleteV1CompanyManagersUserIdErrors, + (options?.client ?? client).get< + GetV1EmployeeTimesheetsResponses, + GetV1EmployeeTimesheetsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/company-managers/{user_id}', - ...options, - }); + >({ url: '/v1/employee/timesheets', ...options }); /** - * Show company manager user + * Show a custom field value * - * Shows a single company manager user + * Returns a custom field value for a given employment * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage company resources (`company_admin`) | View managers (`company_manager:read`) | Manage managers (`company_manager:write`) | + * | Manage employments (`employments`) | View custom field values (`custom_field_value:read`) | Manage custom field values (`custom_field_value:write`) | * */ -export const getV1CompanyManagersUserId = < +export const getV1CustomFieldsCustomFieldIdValuesEmploymentId = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options< + GetV1CustomFieldsCustomFieldIdValuesEmploymentIdData, + ThrowOnError + >, ) => (options.client ?? client).get< - GetV1CompanyManagersUserIdResponses, - GetV1CompanyManagersUserIdErrors, + GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses, + GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/company-managers/{user_id}', + url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}', ...options, }); /** - * Update emergency contact - * - * Updates the employment's emergency contact details. - * - * This endpoint requires country-specific data. Query the **Show form schema** endpoint - * passing the country code and `emergency_contact_details` as path parameters to see - * the required fields for a given country. + * Update a Custom Field Value * + * Updates a custom field value for a given employment. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | - | Manage custom field values (`custom_field_value:write`) | * */ -export const putV2EmploymentsEmploymentIdEmergencyContact = < +export const patchV1CustomFieldsCustomFieldIdValuesEmploymentId2 = < ThrowOnError extends boolean = false, >( options: Options< - PutV2EmploymentsEmploymentIdEmergencyContactData, + PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Data, ThrowOnError >, ) => - (options.client ?? client).put< - PutV2EmploymentsEmploymentIdEmergencyContactResponses, - PutV2EmploymentsEmploymentIdEmergencyContactErrors, + (options.client ?? client).patch< + PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses, + PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v2/employments/{employment_id}/emergency_contact', + url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}', ...options, headers: { 'Content-Type': 'application/json', @@ -8306,165 +7559,98 @@ export const putV2EmploymentsEmploymentIdEmergencyContact = < }); /** - * List expenses for the authenticated employee + * Update a Custom Field Value * - * Returns a paginated list of expenses belonging to the current employee. + * Updates a custom field value for a given employment. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage expenses (`employment_payments`) | View expenses (`expense:read`) | Manage expenses (`expense:write`) | + * | Manage employments (`employments`) | - | Manage custom field values (`custom_field_value:write`) | * */ -export const getV1EmployeeExpenses = ( - options?: Options, -) => - (options?.client ?? client).get< - GetV1EmployeeExpensesResponses, - GetV1EmployeeExpensesErrors, +export const patchV1CustomFieldsCustomFieldIdValuesEmploymentId = < + ThrowOnError extends boolean = false, +>( + options: Options< + PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdData, ThrowOnError - >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/expenses', - ...options, - }); - -/** - * Create an expense for the authenticated employee - * - * Creates a new expense record for the current employee. - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage expenses (`employment_payments`) | - | Manage expenses (`expense:write`) | - * - */ -export const postV1EmployeeExpenses = ( - options?: Options, + >, ) => - (options?.client ?? client).post< - PostV1EmployeeExpensesResponses, - PostV1EmployeeExpensesErrors, + (options.client ?? client).put< + PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses, + PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/expenses', + url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}', ...options, headers: { 'Content-Type': 'application/json', - ...options?.headers, + ...options.headers, }, }); /** - * Delete contractor of record subscription intent - * - * Deletes Contractor of Record subscription intent. - * - * - * ## Scopes - * - * | Category | Read only Scope | Write only Scope (read access implicit) | - * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | - * - */ -export const deleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscription = - ( - options: Options< - DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData, - ThrowOnError - >, - ) => - (options.client ?? client).delete< - DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses, - DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription', - ...options, - }); - -/** - * Create contractor of record subscription intent - * - * Assigns Contractor of Record subscription in pending state to employment. - * Once risk analysis is performed, subscription may start upon contract signing, - * or might be denied. - * - * Requires a non-blocking eligibility questionnaire to be submitted before creating the subscription intent. + * Validate resignation request * + * Validates a resignation employment request * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | + * | Manage employments (`employments`) | - | Manage resignations (`resignation:write`) | * */ -export const postV1ContractorsEmploymentsEmploymentIdContractorCorSubscription = - ( - options: Options< - PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData, - ThrowOnError - >, - ) => - (options.client ?? client).post< - PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses, - PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors, - ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription', - ...options, - }); +export const putV1ResignationsOffboardingRequestIdValidate = < + ThrowOnError extends boolean = false, +>( + options: Options< + PutV1ResignationsOffboardingRequestIdValidateData, + ThrowOnError + >, +) => + (options.client ?? client).put< + PutV1ResignationsOffboardingRequestIdValidateResponses, + PutV1ResignationsOffboardingRequestIdValidateErrors, + ThrowOnError + >({ + url: '/v1/resignations/{offboarding_request_id}/validate', + ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, + }); /** - * List Contractor Invoice Schedules + * Show Contractor Invoice Schedule * - * Lists Contractor Invoice Schedule records. + * Shows a single Contractor Invoice Schedule record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | - | Manage invoices (`invoices:write`) | + * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | * */ -export const getV1ContractorInvoiceSchedules = < +export const getV1ContractorInvoiceSchedulesId = < ThrowOnError extends boolean = false, >( - options?: Options, + options: Options, ) => - (options?.client ?? client).get< - GetV1ContractorInvoiceSchedulesResponses, - GetV1ContractorInvoiceSchedulesErrors, + (options.client ?? client).get< + GetV1ContractorInvoiceSchedulesIdResponses, + GetV1ContractorInvoiceSchedulesIdErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractor-invoice-schedules', - ...options, - }); + >({ url: '/v1/contractor-invoice-schedules/{id}', ...options }); /** - * Create Contractor Invoice Schedules - * - * Creates many invoice schedules records. - * It's supposed to return two lists: one containing created records, and another one containing the schedules that failed to be inserted. + * Updates Contractor Invoice Schedule * + * Updates a contractor invoice schedule record * * ## Scopes * @@ -8473,21 +7659,17 @@ export const getV1ContractorInvoiceSchedules = < * | Manage invoices (`invoices`) | - | Manage invoices (`invoices:write`) | * */ -export const postV1ContractorInvoiceSchedules = < +export const patchV1ContractorInvoiceSchedulesId2 = < ThrowOnError extends boolean = false, >( - options: Options, + options: Options, ) => - (options.client ?? client).post< - PostV1ContractorInvoiceSchedulesResponses, - PostV1ContractorInvoiceSchedulesErrors, + (options.client ?? client).patch< + PatchV1ContractorInvoiceSchedulesId2Responses, + PatchV1ContractorInvoiceSchedulesId2Errors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/contractor-invoice-schedules', + url: '/v1/contractor-invoice-schedules/{id}', ...options, headers: { 'Content-Type': 'application/json', @@ -8496,51 +7678,40 @@ export const postV1ContractorInvoiceSchedules = < }); /** - * Get engagement agreement details + * Updates Contractor Invoice Schedule * - * Returns the engagement agreement details for an employment. + * Updates a contractor invoice schedule record * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employments (`employments`) | View employments (`employment:read`) | Manage employments (`employment:write`) | + * | Manage invoices (`invoices`) | - | Manage invoices (`invoices:write`) | * */ -export const getV1EmploymentsEmploymentIdEngagementAgreementDetails = < +export const patchV1ContractorInvoiceSchedulesId = < ThrowOnError extends boolean = false, >( - options: Options< - GetV1EmploymentsEmploymentIdEngagementAgreementDetailsData, - ThrowOnError - >, + options: Options, ) => - (options.client ?? client).get< - GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses, - GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors, + (options.client ?? client).put< + PatchV1ContractorInvoiceSchedulesIdResponses, + PatchV1ContractorInvoiceSchedulesIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/engagement-agreement-details', + url: '/v1/contractor-invoice-schedules/{id}', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Upsert engagement agreement details - * - * Creates or updates the engagement agreement details for an employment. - * - * This endpoint requires country-specific data. The exact required fields will vary depending on - * which country the employment is in. To see the list of parameters for each country, see the - * **Show form schema** endpoint under the [Countries](#tag/Countries) category. - * - * Please note that compliance requirements for each country are subject to change according to local laws. - * Using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) is recommended - * to avoid compliance issues and to have the latest version of a country's requirements. + * Update pricing plan details * + * Updates the pricing plan for an employment. The frequency determines how often Remote bills the + * employer for management fees. Annual billing typically offers a discount. * * * ## Scopes @@ -8550,24 +7721,20 @@ export const getV1EmploymentsEmploymentIdEngagementAgreementDetails = < * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1EmploymentsEmploymentIdEngagementAgreementDetails = < +export const putV2EmploymentsEmploymentIdPricingPlanDetails = < ThrowOnError extends boolean = false, >( options: Options< - PostV1EmploymentsEmploymentIdEngagementAgreementDetailsData, + PutV2EmploymentsEmploymentIdPricingPlanDetailsData, ThrowOnError >, ) => - (options.client ?? client).post< - PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses, - PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors, + (options.client ?? client).put< + PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses, + PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/employments/{employment_id}/engagement-agreement-details', + url: '/v2/employments/{employment_id}/pricing_plan_details', ...options, headers: { 'Content-Type': 'application/json', @@ -8576,156 +7743,160 @@ export const postV1EmploymentsEmploymentIdEngagementAgreementDetails = < }); /** - * Get Billing Document Breakdown + * Create risk reserve * - * Get billing document breakdown + * Create a new risk reserve * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | + * | Manage company resources (`company_admin`) | - | Manage risk reserves (`risk_reserve:write`) | * */ -export const getV1BillingDocumentsBillingDocumentIdBreakdown = < - ThrowOnError extends boolean = false, ->( - options: Options< - GetV1BillingDocumentsBillingDocumentIdBreakdownData, - ThrowOnError - >, +export const postV1RiskReserve = ( + options: Options, ) => - (options.client ?? client).get< - GetV1BillingDocumentsBillingDocumentIdBreakdownResponses, - GetV1BillingDocumentsBillingDocumentIdBreakdownErrors, + (options.client ?? client).post< + PostV1RiskReserveResponses, + PostV1RiskReserveErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/billing-documents/{billing_document_id}/breakdown', + url: '/v1/risk-reserve', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Indexes all the documents for the employee + * Update address details + * + * Updates employment's address details. + * + * This endpoint requires and returns country-specific data. The exact required and returned fields will + * vary depending on which country the employment is in. To see the list of parameters for each country, + * see the **Show form schema** endpoint under the [Countries](#tag/Countries) category. + * + * Please note that the compliance requirements for each country are subject to change according to local + * laws. Given its continual updates, using Remote's [json-schema-form](https://developer.remote.com/docs/how-json-schemas-work) should be considered in order to avoid + * compliance issues and to have the latest version of a country requirements. + * + * If you are using this endpoint to build an integration, make sure you are dynamically collecting or + * displaying the latest parameters for each country by querying the _"Show form schema"_ endpoint. + * + * For more information on JSON Schemas, see the **How JSON Schemas work** documentation. + * + * To learn how you can dynamically generate forms to display in your UI, see the documentation for + * the [json-schema-form](https://developer.remote.com/docs/how-json-schemas-form) tool. + * + * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const getV1EmployeeDocuments = ( - options?: Options, +export const putV2EmploymentsEmploymentIdAddressDetails = < + ThrowOnError extends boolean = false, +>( + options: Options< + PutV2EmploymentsEmploymentIdAddressDetailsData, + ThrowOnError + >, ) => - (options?.client ?? client).get< - GetV1EmployeeDocumentsResponses, - GetV1EmployeeDocumentsErrors, + (options.client ?? client).put< + PutV2EmploymentsEmploymentIdAddressDetailsResponses, + PutV2EmploymentsEmploymentIdAddressDetailsErrors, ThrowOnError >({ - security: [{ scheme: 'bearer', type: 'http' }], - url: '/v1/employee/documents', + url: '/v2/employments/{employment_id}/address_details', ...options, + headers: { + 'Content-Type': 'application/json', + ...options.headers, + }, }); /** - * Approve a time off cancellation request - * - * Approve a time off cancellation request. - * In order to approve a time off cancellation request, the timeoff status must be `cancel_requested`. - * + * Return a base64 encoded version of the contract document * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage timeoffs (`time_and_attendance`) | - | Manage timeoffs (`timeoff:write`) | + * | Manage employment documents (`employment_documents`) | View documents (`document:read`) | Manage documents (`document:write`) | * */ -export const postV1TimeoffTimeoffIdCancelRequestApprove = < +export const getV1ContractorsEmploymentsEmploymentIdContractDocumentsId = < ThrowOnError extends boolean = false, >( options: Options< - PostV1TimeoffTimeoffIdCancelRequestApproveData, + GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdData, ThrowOnError >, ) => - (options.client ?? client).post< - PostV1TimeoffTimeoffIdCancelRequestApproveResponses, - PostV1TimeoffTimeoffIdCancelRequestApproveErrors, + (options.client ?? client).get< + GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses, + GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/timeoff/{timeoff_id}/cancel-request/approve', + url: '/v1/contractors/employments/{employment_id}/contract-documents/{id}', ...options, }); /** - * Verify Employment Identity + * Create a contractor of record (COR) termination request * - * Endpoint to confirms the employment profile is from the actual employee + * Initiates a termination request for a Contractor of Record employment. + * When a termination request is sent, a stop work order is issued and the contractor remains active until a final invoice is paid or waived. + * Currently, only Contractor of Record employments can be terminated. * * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage employment documents (`employment_documents`) | - | Manage identity verification (`identity_verification:write`) | + * | Manage employments (`employments`) | - | Manage employments (`employment:write`) | * */ -export const postV1IdentityVerificationEmploymentIdVerify = < +export const postV1ContractorsEmploymentsEmploymentIdCorTerminationRequests = < ThrowOnError extends boolean = false, >( options: Options< - PostV1IdentityVerificationEmploymentIdVerifyData, + PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsData, ThrowOnError >, ) => (options.client ?? client).post< - PostV1IdentityVerificationEmploymentIdVerifyResponses, - PostV1IdentityVerificationEmploymentIdVerifyErrors, + PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses, + PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors, ThrowOnError >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/identity-verification/{employment_id}/verify', + url: '/v1/contractors/employments/{employment_id}/cor-termination-requests', ...options, }); /** - * Download a billing document PDF + * List approved payslip files for the authenticated employee * - * Downloads a billing document PDF + * Returns a paginated list of payslip files belonging to the current employee. * * ## Scopes * * | Category | Read only Scope | Write only Scope (read access implicit) | * |---|---|---| - * | Manage invoices (`invoices`) | View invoices (`invoices:read`) | Manage invoices (`invoices:write`) | + * | Manage payroll runs (`payroll`) | View payslips (`payslip:read`) | - | * */ -export const getV1BillingDocumentsBillingDocumentIdPdf = < - ThrowOnError extends boolean = false, ->( - options: Options, +export const getV1EmployeePayslips = ( + options?: Options, ) => - (options.client ?? client).get< - GetV1BillingDocumentsBillingDocumentIdPdfResponses, - GetV1BillingDocumentsBillingDocumentIdPdfErrors, + (options?.client ?? client).get< + GetV1EmployeePayslipsResponses, + GetV1EmployeePayslipsErrors, ThrowOnError - >({ - security: [ - { scheme: 'bearer', type: 'http' }, - { scheme: 'bearer', type: 'http' }, - ], - url: '/v1/billing-documents/{billing_document_id}/pdf', - ...options, - }); + >({ url: '/v1/employee/payslips', ...options }); diff --git a/src/client/types.gen.ts b/src/client/types.gen.ts index 465b40eb3..79bda2780 100644 --- a/src/client/types.gen.ts +++ b/src/client/types.gen.ts @@ -1,10 +1,7 @@ // This file is auto-generated by @hey-api/openapi-ts export type ClientOptions = { - baseUrl: - | 'https://gateway.remote.com/' - | 'https://gateway.remote-sandbox.com/' - | (string & {}); + baseUrl: string; }; /** @@ -54,6 +51,19 @@ export type CreateEmployeeTimeoffParams = { timezone: Timezone; }; +/** + * CreatePreOnboardingDocumentResponse + * + * Returns the slug of the found-or-created pre-onboarding document. + */ +export type CreatePreOnboardingDocumentResponse = { + data: { + pre_onboarding_document: { + id: UuidSlug; + }; + }; +}; + /** * CreateCurrencyCustomFieldDefinitionParams * @@ -1046,6 +1056,51 @@ export type CreateRiskReserveParams = { employment_slug: string; }; +/** + * PreOnboardingDocumentRequirement + * + * A pre-onboarding document requirement that must be fulfilled before an employee can be onboarded. + */ +export type PreOnboardingDocumentRequirement = { + /** + * The requirement that must be fulfilled before this one becomes available (if any). + */ + depends_on_requirement?: PreOnboardingDocumentRequirement | null; + /** + * Human-readable description of the requirement. + */ + description: string; + /** + * Timestamp when the customer acknowledged the constraints (if any). + */ + document_constraints_ack_at?: string | null; + /** + * Whether the employment data is frozen because a document for this requirement exists. + */ + freeze_employment_data?: boolean | null; + /** + * Human-readable name of the requirement. + */ + name: string; + /** + * Whether the customer must acknowledge the hiring constraints of the country before creating a document. + */ + needs_constraints_ack: boolean; + /** + * Email address to contact for help with redlining when supported. + */ + redlining_help_email?: string | null; + slug: UuidSlug; + /** + * Current status of this requirement for the given employment. + */ + status?: 'blocked' | 'awaiting_signatures' | 'finished' | 'revised'; + /** + * Whether the requirement supports redlining (collaborative editing) of the generated document. + */ + supports_redlining: boolean; +}; + /** * HolidaysResponse * @@ -3853,6 +3908,31 @@ export type BulkEmploymentImportJob = { updated_at: DateTime; }; +/** + * ShowPreOnboardingDocumentResponse + * + * Returns the rendered contract PDF (base64) and signatories for a pre-onboarding document. + */ +export type ShowPreOnboardingDocumentResponse = { + data: { + pre_onboarding_document: { + /** + * Base64-encoded PDF, prefixed with `data:application/pdf;base64,`. + */ + content: Blob | File; + /** + * File name of the rendered document. + */ + name: string; + /** + * Parties that must sign or have signed the document. + */ + signatories: Array; + status: ContractorContractDocumentStatus; + }; + }; +}; + /** * JSONSchema * @@ -5491,8 +5571,8 @@ export type ResourceErrorResponse = { | 'parameter_value_unknown' | 'request_body_empty' | 'request_internal_server_error' - | 'parameter_one_of_required_missing' | 'parameter_required_missing' + | 'parameter_one_of_required_missing' | 'parameter_too_many' | 'parameter_unknown' | 'parameter_map_empty' @@ -8535,6 +8615,15 @@ export type IdentityCompany = { name: string; }; +/** + * IndexPreOnboardingDocumentRequirementsResponse + * + * List of pre-onboarding document requirements for an employment. + */ +export type IndexPreOnboardingDocumentRequirementsResponse = { + data: Array; +}; + /** * CreateGeneralCustomFieldDefinitionParams * @@ -11811,6 +11900,19 @@ export type BillingDocumentAmountItem = { */ export type EmploymentId = string; +/** + * FindOrCreatePreOnboardingDocumentParams + * + * Parameters to find an existing unsigned pre-onboarding document or create a new one. + */ +export type FindOrCreatePreOnboardingDocumentParams = { + /** + * Timestamp when the customer acknowledged the hiring constraints. Required when the requirement has `needs_constraints_ack: true`. + */ + constraints_ack_at?: string | null; + pre_onboarding_document_requirement_slug: UuidSlug; +}; + /** * ContractAmendmentResponse * @@ -11868,37 +11970,22 @@ export type ContractorInvoiceScheduleCreateResponseSuccess = { start_date: string; }; -export type GetV1OffboardingsData = { - body?: never; - path?: never; - query?: { - /** - * Filter by Employment ID - */ - employment_id?: string; - /** - * Filter by offboarding type - */ - type?: string; - /** - * By default, the results do not include confidential termination requests. - * Send `include_confidential=true` to include confidential requests in the response. - * - */ - include_confidential?: string; - /** - * Starts fetching records after the given page - */ - page?: number; +export type PutV2EmploymentsEmploymentIdAdministrativeDetailsData = { + /** + * Employment administrative details params + */ + body?: EmploymentAdministrativeDetailsParams; + path: { /** - * Change the amount of records returned per page, defaults to 20, limited to 100 + * Employment ID */ - page_size?: number; + employment_id: string; }; - url: '/v1/offboardings'; + query?: never; + url: '/v2/employments/{employment_id}/administrative_details'; }; -export type GetV1OffboardingsErrors = { +export type PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors = { /** * Bad Request */ @@ -11907,52 +11994,62 @@ export type GetV1OffboardingsErrors = { * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV1OffboardingsError = - GetV1OffboardingsErrors[keyof GetV1OffboardingsErrors]; +export type PutV2EmploymentsEmploymentIdAdministrativeDetailsError = + PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors[keyof PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors]; -export type GetV1OffboardingsResponses = { +export type PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses = { /** * Success */ - 200: ListOffboardingResponse; + 200: EmploymentResponse; }; -export type GetV1OffboardingsResponse = - GetV1OffboardingsResponses[keyof GetV1OffboardingsResponses]; +export type PutV2EmploymentsEmploymentIdAdministrativeDetailsResponse = + PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses[keyof PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses]; -export type PostV1OffboardingsData = { - /** - * Offboarding - */ - body?: CreateOffboardingParams; - path?: never; +export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsData = { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; query?: never; - url: '/v1/offboardings'; + url: '/v1/employments/{employment_id}/engagement-agreement-details'; }; -export type PostV1OffboardingsErrors = { +export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** * Not Found */ @@ -11962,148 +12059,171 @@ export type PostV1OffboardingsErrors = { */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; - /** - * Internal Server Error - */ - 500: RequestError; }; -export type PostV1OffboardingsError = - PostV1OffboardingsErrors[keyof PostV1OffboardingsErrors]; +export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsError = + GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; -export type PostV1OffboardingsResponses = { +export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { /** * Success */ - 201: OffboardingResponse; + 200: EmploymentEngagementAgreementDetailsResponse; }; -export type PostV1OffboardingsResponse = - PostV1OffboardingsResponses[keyof PostV1OffboardingsResponses]; +export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponse = + GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; -export type GetV1TimesheetsIdData = { - body?: never; +export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsData = { + /** + * Employment engagement agreement details params + */ + body?: EmploymentEngagementAgreementDetailsParams; path: { /** - * Timesheet ID + * Employment ID */ - id: string; + employment_id: string; }; query?: never; - url: '/v1/timesheets/{id}'; + url: '/v1/employments/{employment_id}/engagement-agreement-details'; }; -export type GetV1TimesheetsIdErrors = { +export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1TimesheetsIdError = - GetV1TimesheetsIdErrors[keyof GetV1TimesheetsIdErrors]; +export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsError = + PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; -export type GetV1TimesheetsIdResponses = { +export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { /** * Success */ - 200: TimesheetResponse; + 200: SuccessResponse; }; -export type GetV1TimesheetsIdResponse = - GetV1TimesheetsIdResponses[keyof GetV1TimesheetsIdResponses]; +export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponse = + PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; -export type PostV1CancelOnboardingEmploymentIdData = { - body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; - query?: { - /** - * Whether the request should be performed async - * - */ - async?: boolean; - }; - url: '/v1/cancel-onboarding/{employment_id}'; +export type PostV1CurrencyConverterEffective2Data = { + /** + * Convert currency parameters + */ + body: ConvertCurrencyParams; + path?: never; + query?: never; + url: '/v1/currency-converter'; }; -export type PostV1CancelOnboardingEmploymentIdErrors = { +export type PostV1CurrencyConverterEffective2Errors = { /** - * Bad Request + * Unauthorized */ - 400: BadRequestResponse; + 401: UnauthorizedResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ - 429: TooManyRequestsResponse; + 422: UnprocessableEntityResponse; }; -export type PostV1CancelOnboardingEmploymentIdError = - PostV1CancelOnboardingEmploymentIdErrors[keyof PostV1CancelOnboardingEmploymentIdErrors]; +export type PostV1CurrencyConverterEffective2Error = + PostV1CurrencyConverterEffective2Errors[keyof PostV1CurrencyConverterEffective2Errors]; -export type PostV1CancelOnboardingEmploymentIdResponses = { +export type PostV1CurrencyConverterEffective2Responses = { /** * Success */ - 200: SuccessResponse; + 200: ConvertCurrencyResponse; }; -export type PostV1CancelOnboardingEmploymentIdResponse = - PostV1CancelOnboardingEmploymentIdResponses[keyof PostV1CancelOnboardingEmploymentIdResponses]; +export type PostV1CurrencyConverterEffective2Response = + PostV1CurrencyConverterEffective2Responses[keyof PostV1CurrencyConverterEffective2Responses]; -export type GetV1ContractAmendmentsSchemaData = { - body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; +export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsData = + { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/contractor-subscriptions'; }; - path?: never; - query: { + +export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors = + { /** - * The ID of the employment concerned by the contract amendment request. + * Unauthorized */ - employment_id: string; + 401: UnauthorizedResponse; /** - * Country code according to ISO 3-digit alphabetic codes. + * Forbidden */ - country_code: string; + 403: ForbiddenResponse; /** - * Name of the desired form + * Not Found */ - form?: 'contract_amendment'; + 404: NotFoundResponse; + }; + +export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsError = + GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors[keyof GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors]; + +export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses = + { /** - * Version of the form schema + * Success */ - json_schema_version?: number | 'latest'; + 200: ContractorSubscriptionSummariesResponse; }; - url: '/v1/contract-amendments/schema'; + +export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponse = + GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses[keyof GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses]; + +export type PostV1CurrencyConverterRawData = { + /** + * Convert currency parameters + */ + body: ConvertCurrencyParams; + path?: never; + query?: never; + url: '/v1/currency-converter/raw'; }; -export type GetV1ContractAmendmentsSchemaErrors = { +export type PostV1CurrencyConverterRawErrors = { /** * Unauthorized */ @@ -12118,73 +12238,112 @@ export type GetV1ContractAmendmentsSchemaErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1ContractAmendmentsSchemaError = - GetV1ContractAmendmentsSchemaErrors[keyof GetV1ContractAmendmentsSchemaErrors]; +export type PostV1CurrencyConverterRawError = + PostV1CurrencyConverterRawErrors[keyof PostV1CurrencyConverterRawErrors]; -export type GetV1ContractAmendmentsSchemaResponses = { +export type PostV1CurrencyConverterRawResponses = { /** * Success */ - 200: ContractAmendmentFormResponse; + 200: ConvertCurrencyResponse; }; -export type GetV1ContractAmendmentsSchemaResponse = - GetV1ContractAmendmentsSchemaResponses[keyof GetV1ContractAmendmentsSchemaResponses]; +export type PostV1CurrencyConverterRawResponse = + PostV1CurrencyConverterRawResponses[keyof PostV1CurrencyConverterRawResponses]; -export type PostV1PayItemsBulkData = { - /** - * Pay Items - */ - body: BulkCreatePayItemsParams; +export type GetV1IncentivesData = { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path?: never; - query?: never; - url: '/v1/pay-items/bulk'; + query?: { + /** + * Filter by Employment ID + */ + employment_id?: string; + /** + * Filter by Incentive status + */ + status?: string; + /** + * Filter by Recurring Incentive id + */ + recurring_incentive_id?: string; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Change the amount of records returned per page, defaults to 20, limited to 100 + */ + page_size?: number; + }; + url: '/v1/incentives'; }; -export type PostV1PayItemsBulkErrors = { +export type GetV1IncentivesErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PostV1PayItemsBulkError = - PostV1PayItemsBulkErrors[keyof PostV1PayItemsBulkErrors]; +export type GetV1IncentivesError = + GetV1IncentivesErrors[keyof GetV1IncentivesErrors]; -export type PostV1PayItemsBulkResponses = { +export type GetV1IncentivesResponses = { /** * Success */ - 200: BulkCreatePayItemsResponse; + 200: ListIncentivesResponse; }; -export type PostV1PayItemsBulkResponse = - PostV1PayItemsBulkResponses[keyof PostV1PayItemsBulkResponses]; +export type GetV1IncentivesResponse = + GetV1IncentivesResponses[keyof GetV1IncentivesResponses]; -export type GetV1DataSyncData = { - body?: never; +export type PostV1IncentivesData = { + /** + * Incentive + */ + body?: CreateOneTimeIncentiveParams; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path?: never; query?: never; - url: '/v1/data-sync'; + url: '/v1/incentives'; }; -export type GetV1DataSyncErrors = { +export type PostV1IncentivesErrors = { /** * Bad Request */ @@ -12194,46 +12353,88 @@ export type GetV1DataSyncErrors = { */ 401: UnauthorizedResponse; /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type GetV1DataSyncError = GetV1DataSyncErrors[keyof GetV1DataSyncErrors]; +export type PostV1IncentivesError = + PostV1IncentivesErrors[keyof PostV1IncentivesErrors]; -export type GetV1DataSyncResponses = { +export type PostV1IncentivesResponses = { /** * Success */ - 200: ListDataSyncEventsResponse; + 201: IncentiveResponse; }; -export type GetV1DataSyncResponse = - GetV1DataSyncResponses[keyof GetV1DataSyncResponses]; +export type PostV1IncentivesResponse = + PostV1IncentivesResponses[keyof PostV1IncentivesResponses]; -export type PostV1DataSyncData = { +export type GetV1BenefitOffersData = { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; + path?: never; + query?: never; + url: '/v1/benefit-offers'; +}; + +export type GetV1BenefitOffersErrors = { /** - * DataSync + * Not Found */ - body: CreateDataSyncParams; + 404: NotFoundResponse; +}; + +export type GetV1BenefitOffersError = + GetV1BenefitOffersErrors[keyof GetV1BenefitOffersErrors]; + +export type GetV1BenefitOffersResponses = { + /** + * Success + */ + 200: BenefitOfferByEmploymentResponse; +}; + +export type GetV1BenefitOffersResponse = + GetV1BenefitOffersResponses[keyof GetV1BenefitOffersResponses]; + +export type PostV1ReadyData = { + /** + * Employment slug + */ + body?: CompleteOnboarding; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path?: never; query?: never; - url: '/v1/data-sync'; + url: '/v1/ready'; }; -export type PostV1DataSyncErrors = { +export type PostV1ReadyErrors = { /** * Bad Request */ @@ -12245,7 +12446,7 @@ export type PostV1DataSyncErrors = { /** * Conflict */ - 409: ConflictErrorResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ @@ -12256,33 +12457,29 @@ export type PostV1DataSyncErrors = { 429: TooManyRequestsResponse; }; -export type PostV1DataSyncError = - PostV1DataSyncErrors[keyof PostV1DataSyncErrors]; +export type PostV1ReadyError = PostV1ReadyErrors[keyof PostV1ReadyErrors]; -export type PostV1DataSyncResponses = { +export type PostV1ReadyResponses = { /** - * Accepted + * Success */ - 202: unknown; + 200: EmploymentResponse; }; -export type GetV1CompaniesCompanyIdPricingPlansData = { - body?: never; - path: { - /** - * Company ID - */ - company_id: UuidSlug; - }; - query?: never; - url: '/v1/companies/{company_id}/pricing-plans'; -}; +export type PostV1ReadyResponse = + PostV1ReadyResponses[keyof PostV1ReadyResponses]; -export type GetV1CompaniesCompanyIdPricingPlansErrors = { +export type PostV1CostCalculatorEstimationData = { /** - * Unauthorized + * Estimate params */ - 401: UnauthorizedResponse; + body: CostCalculatorEstimateParams; + path?: never; + query?: never; + url: '/v1/cost-calculator/estimation'; +}; + +export type PostV1CostCalculatorEstimationErrors = { /** * Not Found */ @@ -12293,35 +12490,61 @@ export type GetV1CompaniesCompanyIdPricingPlansErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1CompaniesCompanyIdPricingPlansError = - GetV1CompaniesCompanyIdPricingPlansErrors[keyof GetV1CompaniesCompanyIdPricingPlansErrors]; +export type PostV1CostCalculatorEstimationError = + PostV1CostCalculatorEstimationErrors[keyof PostV1CostCalculatorEstimationErrors]; -export type GetV1CompaniesCompanyIdPricingPlansResponses = { +export type PostV1CostCalculatorEstimationResponses = { /** * Success */ - 200: ListCompanyPricingPlansResponse; + 200: CostCalculatorEstimateResponse; }; -export type GetV1CompaniesCompanyIdPricingPlansResponse = - GetV1CompaniesCompanyIdPricingPlansResponses[keyof GetV1CompaniesCompanyIdPricingPlansResponses]; +export type PostV1CostCalculatorEstimationResponse = + PostV1CostCalculatorEstimationResponses[keyof PostV1CostCalculatorEstimationResponses]; -export type PostV1CompaniesCompanyIdPricingPlansData = { - /** - * Create Pricing Plan parameters - */ - body: CreatePricingPlanParams; - path: { +export type GetV1IncentivesRecurringData = { + body?: never; + headers: { /** - * Company ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - company_id: UuidSlug; + Authorization: string; }; - query?: never; - url: '/v1/companies/{company_id}/pricing-plans'; + path?: never; + query?: { + /** + * Filter by recurring incentive status: active or deactive. + */ + status?: string; + /** + * Filter by recurring incentive type. + */ + type?: string; + /** + * Filter by recurring incentives that contain the value in their notes. + */ + note?: string; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Change the amount of records returned per page, defaults to 20, limited to 100 + */ + page_size?: number; + }; + url: '/v1/incentives/recurring'; }; -export type PostV1CompaniesCompanyIdPricingPlansErrors = { +export type GetV1IncentivesRecurringErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -12334,34 +12557,49 @@ export type PostV1CompaniesCompanyIdPricingPlansErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type PostV1CompaniesCompanyIdPricingPlansError = - PostV1CompaniesCompanyIdPricingPlansErrors[keyof PostV1CompaniesCompanyIdPricingPlansErrors]; +export type GetV1IncentivesRecurringError = + GetV1IncentivesRecurringErrors[keyof GetV1IncentivesRecurringErrors]; -export type PostV1CompaniesCompanyIdPricingPlansResponses = { +export type GetV1IncentivesRecurringResponses = { /** * Success */ - 200: CreatePricingPlanResponse; + 201: ListRecurringIncentivesResponse; }; -export type PostV1CompaniesCompanyIdPricingPlansResponse = - PostV1CompaniesCompanyIdPricingPlansResponses[keyof PostV1CompaniesCompanyIdPricingPlansResponses]; +export type GetV1IncentivesRecurringResponse = + GetV1IncentivesRecurringResponses[keyof GetV1IncentivesRecurringResponses]; -export type GetV1ProbationCompletionLetterIdData = { - body?: never; - path: { +export type PostV1IncentivesRecurringData = { + /** + * RecurringIncentive + */ + body?: CreateRecurringIncentiveParams; + headers: { /** - * probation completion letter ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - id: string; + Authorization: string; }; + path?: never; query?: never; - url: '/v1/probation-completion-letter/{id}'; + url: '/v1/incentives/recurring'; }; -export type GetV1ProbationCompletionLetterIdErrors = { +export type PostV1IncentivesRecurringErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -12374,42 +12612,58 @@ export type GetV1ProbationCompletionLetterIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1ProbationCompletionLetterIdError = - GetV1ProbationCompletionLetterIdErrors[keyof GetV1ProbationCompletionLetterIdErrors]; +export type PostV1IncentivesRecurringError = + PostV1IncentivesRecurringErrors[keyof PostV1IncentivesRecurringErrors]; -export type GetV1ProbationCompletionLetterIdResponses = { +export type PostV1IncentivesRecurringResponses = { /** * Success */ - 200: ProbationCompletionLetterResponse; + 201: RecurringIncentiveResponse; }; -export type GetV1ProbationCompletionLetterIdResponse = - GetV1ProbationCompletionLetterIdResponses[keyof GetV1ProbationCompletionLetterIdResponses]; +export type PostV1IncentivesRecurringResponse = + PostV1IncentivesRecurringResponses[keyof PostV1IncentivesRecurringResponses]; -export type GetV1ContractorInvoicesIdData = { +export type GetV1TimesheetsData = { body?: never; - path: { + path?: never; + query?: { /** - * Resource unique identifier + * Filter timesheets by their status */ - id: UuidSlug; + status?: TimesheetStatus; + /** + * Sort order + */ + order?: 'asc' | 'desc'; + /** + * Field to sort by + */ + sort_by?: 'submitted_at'; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - query?: never; - url: '/v1/contractor-invoices/{id}'; + url: '/v1/timesheets'; }; -export type GetV1ContractorInvoicesIdErrors = { +export type GetV1TimesheetsErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -12420,30 +12674,34 @@ export type GetV1ContractorInvoicesIdErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1ContractorInvoicesIdError = - GetV1ContractorInvoicesIdErrors[keyof GetV1ContractorInvoicesIdErrors]; +export type GetV1TimesheetsError = + GetV1TimesheetsErrors[keyof GetV1TimesheetsErrors]; -export type GetV1ContractorInvoicesIdResponses = { +export type GetV1TimesheetsResponses = { /** * Success */ - 200: ContractorInvoiceResponse; + 200: ListTimesheetsResponse; }; -export type GetV1ContractorInvoicesIdResponse = - GetV1ContractorInvoicesIdResponses[keyof GetV1ContractorInvoicesIdResponses]; +export type GetV1TimesheetsResponse = + GetV1TimesheetsResponses[keyof GetV1TimesheetsResponses]; -export type PostV1CurrencyConverterRawData = { +export type PostV1TimesheetsData = { /** - * Convert currency parameters + * Timesheet */ - body: ConvertCurrencyParams; + body?: CreateTimesheetParams; path?: never; query?: never; - url: '/v1/currency-converter/raw'; + url: '/v1/timesheets'; }; -export type PostV1CurrencyConverterRawErrors = { +export type PostV1TimesheetsErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -12458,45 +12716,32 @@ export type PostV1CurrencyConverterRawErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1CurrencyConverterRawError = - PostV1CurrencyConverterRawErrors[keyof PostV1CurrencyConverterRawErrors]; +export type PostV1TimesheetsError = + PostV1TimesheetsErrors[keyof PostV1TimesheetsErrors]; -export type PostV1CurrencyConverterRawResponses = { +export type PostV1TimesheetsResponses = { /** * Success */ - 200: ConvertCurrencyResponse; + 200: TimesheetResponse; }; -export type PostV1CurrencyConverterRawResponse = - PostV1CurrencyConverterRawResponses[keyof PostV1CurrencyConverterRawResponses]; +export type PostV1TimesheetsResponse = + PostV1TimesheetsResponses[keyof PostV1TimesheetsResponses]; -export type GetV1CountriesCountryCodeContractorContractDetailsData = { +export type PostV1TimesheetsTimesheetIdApproveData = { body?: never; path: { /** - * Country code according to ISO 3-digit alphabetic codes - */ - country_code: string; - }; - query?: { - /** - * Employment ID - */ - employment_id?: string; - /** - * Version of the form schema + * Timesheet ID */ - json_schema_version?: number | 'latest'; + timesheet_id: string; }; - url: '/v1/countries/{country_code}/contractor-contract-details'; + query?: never; + url: '/v1/timesheets/{timesheet_id}/approve'; }; -export type GetV1CountriesCountryCodeContractorContractDetailsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PostV1TimesheetsTimesheetIdApproveErrors = { /** * Unauthorized */ @@ -12509,33 +12754,33 @@ export type GetV1CountriesCountryCodeContractorContractDetailsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type GetV1CountriesCountryCodeContractorContractDetailsError = - GetV1CountriesCountryCodeContractorContractDetailsErrors[keyof GetV1CountriesCountryCodeContractorContractDetailsErrors]; +export type PostV1TimesheetsTimesheetIdApproveError = + PostV1TimesheetsTimesheetIdApproveErrors[keyof PostV1TimesheetsTimesheetIdApproveErrors]; -export type GetV1CountriesCountryCodeContractorContractDetailsResponses = { +export type PostV1TimesheetsTimesheetIdApproveResponses = { /** * Success */ - 200: ContractorContractDetailsResponse; + 200: MinimalTimesheetResponse; }; -export type GetV1CountriesCountryCodeContractorContractDetailsResponse = - GetV1CountriesCountryCodeContractorContractDetailsResponses[keyof GetV1CountriesCountryCodeContractorContractDetailsResponses]; +export type PostV1TimesheetsTimesheetIdApproveResponse = + PostV1TimesheetsTimesheetIdApproveResponses[keyof PostV1TimesheetsTimesheetIdApproveResponses]; -export type GetV1EmployeeIncentivesData = { +export type GetV1DataSyncData = { body?: never; path?: never; query?: never; - url: '/v1/employee/incentives'; + url: '/v1/data-sync'; }; -export type GetV1EmployeeIncentivesErrors = { +export type GetV1DataSyncErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -12545,89 +12790,7 @@ export type GetV1EmployeeIncentivesErrors = { */ 403: ForbiddenResponse; /** - * Not Found - */ - 404: NotFoundResponse; -}; - -export type GetV1EmployeeIncentivesError = - GetV1EmployeeIncentivesErrors[keyof GetV1EmployeeIncentivesErrors]; - -export type GetV1EmployeeIncentivesResponses = { - /** - * Success - */ - 200: SuccessResponse; -}; - -export type GetV1EmployeeIncentivesResponse = - GetV1EmployeeIncentivesResponses[keyof GetV1EmployeeIncentivesResponses]; - -export type GetV1EmploymentsData = { - body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; - path?: never; - query?: { - /** - * Company ID - */ - company_id?: string; - /** - * Filters the results by employments whose login email matches the value - */ - email?: string; - /** - * Filters the results by employments whose status matches the value. - * Supports multiple values separated by commas. - * Also supports the value `incomplete` to get all employments that are not onboarded yet. - * - */ - status?: string; - /** - * Filters the results by employments whose employment product type matches the value - */ - employment_type?: string; - /** - * Filters the results by employments whose employment model matches the value. - * Possible values: `global_payroll`, `peo`, `eor` - * - */ - employment_model?: 'global_payroll' | 'peo' | 'eor'; - /** - * Filters the results by the employment's short ID. Returns at most one result. - */ - short_id?: string; - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page - */ - page_size?: number; - }; - url: '/v1/employments'; -}; - -export type GetV1EmploymentsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Conflict + * Conflict */ 409: ConflictResponse; /** @@ -12640,44 +12803,29 @@ export type GetV1EmploymentsErrors = { 429: TooManyRequestsResponse; }; -export type GetV1EmploymentsError = - GetV1EmploymentsErrors[keyof GetV1EmploymentsErrors]; +export type GetV1DataSyncError = GetV1DataSyncErrors[keyof GetV1DataSyncErrors]; -export type GetV1EmploymentsResponses = { +export type GetV1DataSyncResponses = { /** * Success */ - 200: ListEmploymentsResponse; + 200: ListDataSyncEventsResponse; }; -export type GetV1EmploymentsResponse = - GetV1EmploymentsResponses[keyof GetV1EmploymentsResponses]; +export type GetV1DataSyncResponse = + GetV1DataSyncResponses[keyof GetV1DataSyncResponses]; -export type PostV1EmploymentsData = { +export type PostV1DataSyncData = { /** - * Employment params + * DataSync */ - body?: EmploymentCreateParams; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; + body: CreateDataSyncParams; path?: never; - query?: { - /** - * Version of the form schema - */ - json_schema_version?: number | 'latest'; - }; - url: '/v1/employments'; + query?: never; + url: '/v1/data-sync'; }; -export type PostV1EmploymentsErrors = { +export type PostV1DataSyncErrors = { /** * Bad Request */ @@ -12689,7 +12837,7 @@ export type PostV1EmploymentsErrors = { /** * Conflict */ - 409: ConflictResponse; + 409: ConflictErrorResponse; /** * Unprocessable Entity */ @@ -12700,210 +12848,114 @@ export type PostV1EmploymentsErrors = { 429: TooManyRequestsResponse; }; -export type PostV1EmploymentsError = - PostV1EmploymentsErrors[keyof PostV1EmploymentsErrors]; - -export type PostV1EmploymentsResponses = { - /** - * Success - */ - 200: EmploymentCreationResponse; -}; - -export type PostV1EmploymentsResponse = - PostV1EmploymentsResponses[keyof PostV1EmploymentsResponses]; - -export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusData = - { - body?: never; - path: { - /** - * Company ID - */ - company_id: UuidSlug; - /** - * Employment ID - */ - employment_id: UuidSlug; - }; - query?: never; - url: '/v1/companies/{company_id}/employments/{employment_id}/onboarding-reserves-status'; - }; - -export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors = - { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - }; - -export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusError = - GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors[keyof GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors]; - -export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses = - { - /** - * Success - */ - 200: OnboardingReservesStatusResponse; - }; - -export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponse = - GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses[keyof GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses]; - -export type GetV1HelpCenterArticlesIdData = { - body?: never; - path: { - /** - * Help Center Article Zendesk ID - */ - id: number; - }; - query?: never; - url: '/v1/help-center-articles/{id}'; -}; - -export type GetV1HelpCenterArticlesIdErrors = { - /** - * Not Found - */ - 404: NotFoundResponse; -}; - -export type GetV1HelpCenterArticlesIdError = - GetV1HelpCenterArticlesIdErrors[keyof GetV1HelpCenterArticlesIdErrors]; +export type PostV1DataSyncError = + PostV1DataSyncErrors[keyof PostV1DataSyncErrors]; -export type GetV1HelpCenterArticlesIdResponses = { +export type PostV1DataSyncResponses = { /** - * Success + * Accepted */ - 200: HelpCenterArticleResponse; + 202: unknown; }; -export type GetV1HelpCenterArticlesIdResponse = - GetV1HelpCenterArticlesIdResponses[keyof GetV1HelpCenterArticlesIdResponses]; - -export type GetV1ScimV2UsersIdData = { +export type GetV1ProbationCompletionLetterIdData = { body?: never; path: { /** - * User ID (slug) + * probation completion letter ID */ id: string; }; query?: never; - url: '/v1/scim/v2/Users/{id}'; + url: '/v1/probation-completion-letter/{id}'; }; -export type GetV1ScimV2UsersIdErrors = { +export type GetV1ProbationCompletionLetterIdErrors = { /** * Unauthorized */ - 401: IntegrationsScimErrorResponse; + 401: UnauthorizedResponse; /** - * Forbidden + * Not Found */ - 403: IntegrationsScimErrorResponse; + 404: NotFoundResponse; /** - * Not Found + * Unprocessable Entity */ - 404: IntegrationsScimErrorResponse; + 422: UnprocessableEntityResponse; }; -export type GetV1ScimV2UsersIdError = - GetV1ScimV2UsersIdErrors[keyof GetV1ScimV2UsersIdErrors]; +export type GetV1ProbationCompletionLetterIdError = + GetV1ProbationCompletionLetterIdErrors[keyof GetV1ProbationCompletionLetterIdErrors]; -export type GetV1ScimV2UsersIdResponses = { +export type GetV1ProbationCompletionLetterIdResponses = { /** * Success */ - 200: IntegrationsScimUser; + 200: ProbationCompletionLetterResponse; }; -export type GetV1ScimV2UsersIdResponse = - GetV1ScimV2UsersIdResponses[keyof GetV1ScimV2UsersIdResponses]; +export type GetV1ProbationCompletionLetterIdResponse = + GetV1ProbationCompletionLetterIdResponses[keyof GetV1ProbationCompletionLetterIdResponses]; -export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsData = { +export type GetV1SsoConfigurationData = { body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; + path?: never; query?: never; - url: '/v2/employments/{employment_id}/engagement-agreement-details'; + url: '/v1/sso-configuration'; }; -export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { +export type GetV1SsoConfigurationErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; /** * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsError = - GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; +export type GetV1SsoConfigurationError = + GetV1SsoConfigurationErrors[keyof GetV1SsoConfigurationErrors]; -export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { +export type GetV1SsoConfigurationResponses = { /** * Success */ - 200: EmploymentEngagementAgreementDetailsResponse; + 200: SsoConfigurationResponse; }; -export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponse = - GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; +export type GetV1SsoConfigurationResponse = + GetV1SsoConfigurationResponses[keyof GetV1SsoConfigurationResponses]; -export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsData = { +export type PostV1SsoConfigurationData = { /** - * Employment engagement agreement details params + * CreateSSOConfiguration */ - body?: EmploymentEngagementAgreementDetailsParams; - path: { - /** - * Employment ID - */ - employment_id: string; - }; + body: CreateSsoConfigurationParams; + path?: never; query?: never; - url: '/v2/employments/{employment_id}/engagement-agreement-details'; + url: '/v1/sso-configuration'; }; -export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { +export type PostV1SsoConfigurationErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ @@ -12922,132 +12974,58 @@ export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { 429: TooManyRequestsResponse; }; -export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsError = - PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; - -export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { - /** - * Success - */ - 200: SuccessResponse; -}; - -export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponse = - PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; - -export type GetV1EmployeeDocumentsIdData = { - body?: never; - path: { - /** - * Document ID - */ - id: string; - }; - query?: never; - url: '/v1/employee/documents/{id}'; -}; - -export type GetV1EmployeeDocumentsIdErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; -}; - -export type GetV1EmployeeDocumentsIdError = - GetV1EmployeeDocumentsIdErrors[keyof GetV1EmployeeDocumentsIdErrors]; +export type PostV1SsoConfigurationError = + PostV1SsoConfigurationErrors[keyof PostV1SsoConfigurationErrors]; -export type GetV1EmployeeDocumentsIdResponses = { +export type PostV1SsoConfigurationResponses = { /** - * Success + * Created */ - 200: DownloadDocumentResponse; + 201: CreateSsoConfigurationResponse; }; -export type GetV1EmployeeDocumentsIdResponse = - GetV1EmployeeDocumentsIdResponses[keyof GetV1EmployeeDocumentsIdResponses]; +export type PostV1SsoConfigurationResponse = + PostV1SsoConfigurationResponses[keyof PostV1SsoConfigurationResponses]; -export type GetV1ContractorInvoicesData = { +export type GetV1OffboardingsData = { body?: never; path?: never; query?: { /** - * Filters contractor invoices by status matching the value. - */ - status?: ContractorInvoiceStatus; - /** - * Filters contractor invoices by invoice schedule ID matching the value. - */ - contractor_invoice_schedule_id?: UuidSlug; - /** - * Filters contractor invoices by date greater than or equal to the value. - */ - date_from?: Date; - /** - * Filters contractor invoices by date less than or equal to the value. - */ - date_to?: Date; - /** - * Filters contractor invoices by due date greater than or equal to the value. - */ - due_date_from?: Date; - /** - * Filters contractor invoices by due date less than or equal to the value. - */ - due_date_to?: Date; - /** - * Filters contractor invoices by approved date greater than or equal to the value. - */ - approved_date_from?: Date; - /** - * Filters contractor invoices by approved date less than or equal to the value. - */ - approved_date_to?: Date; - /** - * Filters contractor invoices by paid out date greater than or equal to the value. - */ - paid_out_date_from?: Date; - /** - * Filters contractor invoices by paid out date less than or equal to the value. + * Filter by Employment ID */ - paid_out_date_to?: Date; + employment_id?: string; /** - * Field to sort by + * Filter by offboarding type */ - sort_by?: 'date' | 'due_date' | 'approved_at' | 'paid_out_at'; + type?: string; /** - * Sort order + * By default, the results do not include confidential termination requests. + * Send `include_confidential=true` to include confidential requests in the response. + * */ - order?: 'asc' | 'desc'; + include_confidential?: string; /** * Starts fetching records after the given page */ page?: number; /** - * Number of items per page + * Change the amount of records returned per page, defaults to 20, limited to 100 */ page_size?: number; }; - url: '/v1/contractor-invoices'; + url: '/v1/offboardings'; }; -export type GetV1ContractorInvoicesErrors = { +export type GetV1OffboardingsErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ @@ -13056,60 +13034,36 @@ export type GetV1ContractorInvoicesErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; -}; - -export type GetV1ContractorInvoicesError = - GetV1ContractorInvoicesErrors[keyof GetV1ContractorInvoicesErrors]; - -export type GetV1ContractorInvoicesResponses = { /** - * Success + * Too many requests */ - 200: ListContractorInvoicesResponse; + 429: TooManyRequestsResponse; }; -export type GetV1ContractorInvoicesResponse = - GetV1ContractorInvoicesResponses[keyof GetV1ContractorInvoicesResponses]; - -export type PostV1SdkTelemetryErrorsData = { - /** - * SDK Error Report - */ - body: SdkErrorPayload; - path?: never; - query?: never; - url: '/v1/sdk/telemetry-errors'; -}; +export type GetV1OffboardingsError = + GetV1OffboardingsErrors[keyof GetV1OffboardingsErrors]; -export type PostV1SdkTelemetryErrorsErrors = { - /** - * Bad Request - */ - 400: ErrorResponse; +export type GetV1OffboardingsResponses = { /** - * Too Many Requests + * Success */ - 429: RateLimitResponse; + 200: ListOffboardingResponse; }; -export type PostV1SdkTelemetryErrorsError = - PostV1SdkTelemetryErrorsErrors[keyof PostV1SdkTelemetryErrorsErrors]; +export type GetV1OffboardingsResponse = + GetV1OffboardingsResponses[keyof GetV1OffboardingsResponses]; -export type PostV1SdkTelemetryErrorsResponses = { +export type PostV1OffboardingsData = { /** - * No Content + * Offboarding */ - 204: unknown; -}; - -export type GetV1SsoConfigurationDetailsData = { - body?: never; + body?: CreateOffboardingParams; path?: never; query?: never; - url: '/v1/sso-configuration/details'; + url: '/v1/offboardings'; }; -export type GetV1SsoConfigurationDetailsErrors = { +export type PostV1OffboardingsErrors = { /** * Bad Request */ @@ -13125,33 +13079,50 @@ export type GetV1SsoConfigurationDetailsErrors = { /** * Unprocessable Entity */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ 429: TooManyRequestsResponse; + /** + * Internal Server Error + */ + 500: RequestError; }; -export type GetV1SsoConfigurationDetailsError = - GetV1SsoConfigurationDetailsErrors[keyof GetV1SsoConfigurationDetailsErrors]; +export type PostV1OffboardingsError = + PostV1OffboardingsErrors[keyof PostV1OffboardingsErrors]; -export type GetV1SsoConfigurationDetailsResponses = { +export type PostV1OffboardingsResponses = { /** * Success */ - 200: SsoConfigurationDetailsResponse; + 201: OffboardingResponse; }; -export type GetV1SsoConfigurationDetailsResponse = - GetV1SsoConfigurationDetailsResponses[keyof GetV1SsoConfigurationDetailsResponses]; +export type PostV1OffboardingsResponse = + PostV1OffboardingsResponses[keyof PostV1OffboardingsResponses]; -export type PostV1CostCalculatorEstimationData = { +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsData = { /** - * Estimate params + * CreateContractDocumentParams */ - body: CostCalculatorEstimateParams; - path?: never; + body: CreateContractDocument; + path: { + /** + * Employment ID + */ + employment_id: string; + }; query?: never; - url: '/v1/cost-calculator/estimation'; + url: '/v1/contractors/employments/{employment_id}/contract-documents'; }; -export type PostV1CostCalculatorEstimationErrors = { +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; /** * Not Found */ @@ -13162,97 +13133,92 @@ export type PostV1CostCalculatorEstimationErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1CostCalculatorEstimationError = - PostV1CostCalculatorEstimationErrors[keyof PostV1CostCalculatorEstimationErrors]; +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsError = + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors]; -export type PostV1CostCalculatorEstimationResponses = { - /** - * Success - */ - 200: CostCalculatorEstimateResponse; -}; - -export type PostV1CostCalculatorEstimationResponse = - PostV1CostCalculatorEstimationResponses[keyof PostV1CostCalculatorEstimationResponses]; - -export type GetV1CompaniesSchemaData = { - body?: never; - path?: never; - query: { - /** - * Country code according to ISO 3-digit alphabetic codes. - */ - country_code: string; +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses = + { /** - * Name of the desired form + * Success */ - form: 'address_details'; + 200: CreateContractDocumentResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponse = + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses]; + +export type PutV1EmploymentsEmploymentIdFederalTaxesData = { + /** + * Employment federal taxes params + */ + body?: EmploymentFederalTaxesParams; + path: { /** - * Version of the form schema + * Employment ID */ - json_schema_version?: number | 'latest'; + employment_id: string; }; - url: '/v1/companies/schema'; + query?: never; + url: '/v1/employments/{employment_id}/federal-taxes'; }; -export type GetV1CompaniesSchemaErrors = { +export type PutV1EmploymentsEmploymentIdFederalTaxesErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1CompaniesSchemaError = - GetV1CompaniesSchemaErrors[keyof GetV1CompaniesSchemaErrors]; +export type PutV1EmploymentsEmploymentIdFederalTaxesError = + PutV1EmploymentsEmploymentIdFederalTaxesErrors[keyof PutV1EmploymentsEmploymentIdFederalTaxesErrors]; -export type GetV1CompaniesSchemaResponses = { +export type PutV1EmploymentsEmploymentIdFederalTaxesResponses = { /** * Success */ - 200: CompanyFormResponse; + 200: SuccessResponse; }; -export type GetV1CompaniesSchemaResponse = - GetV1CompaniesSchemaResponses[keyof GetV1CompaniesSchemaResponses]; +export type PutV1EmploymentsEmploymentIdFederalTaxesResponse = + PutV1EmploymentsEmploymentIdFederalTaxesResponses[keyof PutV1EmploymentsEmploymentIdFederalTaxesResponses]; -export type GetV1EmploymentsEmploymentIdBenefitOffersData = { +export type GetV1CompaniesCompanyIdPricingPlansData = { body?: never; path: { /** - * Unique identifier of the employment - */ - employment_id: UuidSlug; - }; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page + * Company ID */ - page_size?: number; + company_id: UuidSlug; }; - url: '/v1/employments/{employment_id}/benefit-offers'; + query?: never; + url: '/v1/companies/{company_id}/pricing-plans'; }; -export type GetV1EmploymentsEmploymentIdBenefitOffersErrors = { +export type GetV1CompaniesCompanyIdPricingPlansErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -13263,48 +13229,39 @@ export type GetV1EmploymentsEmploymentIdBenefitOffersErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1EmploymentsEmploymentIdBenefitOffersError = - GetV1EmploymentsEmploymentIdBenefitOffersErrors[keyof GetV1EmploymentsEmploymentIdBenefitOffersErrors]; +export type GetV1CompaniesCompanyIdPricingPlansError = + GetV1CompaniesCompanyIdPricingPlansErrors[keyof GetV1CompaniesCompanyIdPricingPlansErrors]; -export type GetV1EmploymentsEmploymentIdBenefitOffersResponses = { +export type GetV1CompaniesCompanyIdPricingPlansResponses = { /** * Success */ - 200: EmploymentsBenefitOffersListBenefitOffers; + 200: ListCompanyPricingPlansResponse; }; -export type GetV1EmploymentsEmploymentIdBenefitOffersResponse = - GetV1EmploymentsEmploymentIdBenefitOffersResponses[keyof GetV1EmploymentsEmploymentIdBenefitOffersResponses]; +export type GetV1CompaniesCompanyIdPricingPlansResponse = + GetV1CompaniesCompanyIdPricingPlansResponses[keyof GetV1CompaniesCompanyIdPricingPlansResponses]; -export type PutV1EmploymentsEmploymentIdBenefitOffersData = { +export type PostV1CompaniesCompanyIdPricingPlansData = { /** - * Upsert employment benefit offers request + * Create Pricing Plan parameters */ - body: UnifiedEmploymentUpsertBenefitOffersRequest; + body: CreatePricingPlanParams; path: { /** - * Unique identifier of the employment - */ - employment_id: UuidSlug; - }; - query?: { - /** - * Version of the form schema + * Company ID */ - json_schema_version?: number | 'latest'; + company_id: UuidSlug; }; - url: '/v1/employments/{employment_id}/benefit-offers'; + query?: never; + url: '/v1/companies/{company_id}/pricing-plans'; }; -export type PutV1EmploymentsEmploymentIdBenefitOffersErrors = { +export type PostV1CompaniesCompanyIdPricingPlansErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -13315,21 +13272,24 @@ export type PutV1EmploymentsEmploymentIdBenefitOffersErrors = { 422: UnprocessableEntityResponse; }; -export type PutV1EmploymentsEmploymentIdBenefitOffersError = - PutV1EmploymentsEmploymentIdBenefitOffersErrors[keyof PutV1EmploymentsEmploymentIdBenefitOffersErrors]; +export type PostV1CompaniesCompanyIdPricingPlansError = + PostV1CompaniesCompanyIdPricingPlansErrors[keyof PostV1CompaniesCompanyIdPricingPlansErrors]; -export type PutV1EmploymentsEmploymentIdBenefitOffersResponses = { +export type PostV1CompaniesCompanyIdPricingPlansResponses = { /** * Success */ - 200: SuccessResponse; + 200: CreatePricingPlanResponse; }; -export type PutV1EmploymentsEmploymentIdBenefitOffersResponse = - PutV1EmploymentsEmploymentIdBenefitOffersResponses[keyof PutV1EmploymentsEmploymentIdBenefitOffersResponses]; +export type PostV1CompaniesCompanyIdPricingPlansResponse = + PostV1CompaniesCompanyIdPricingPlansResponses[keyof PostV1CompaniesCompanyIdPricingPlansResponses]; -export type GetV1IdentityVerificationEmploymentIdData = { - body?: never; +export type PutV2EmploymentsEmploymentIdFederalTaxesData = { + /** + * Employment federal taxes params + */ + body?: EmploymentFederalTaxesParams; path: { /** * Employment ID @@ -13337,84 +13297,79 @@ export type GetV1IdentityVerificationEmploymentIdData = { employment_id: string; }; query?: never; - url: '/v1/identity-verification/{employment_id}'; + url: '/v2/employments/{employment_id}/federal-taxes'; }; -export type GetV1IdentityVerificationEmploymentIdErrors = { +export type PutV2EmploymentsEmploymentIdFederalTaxesErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1IdentityVerificationEmploymentIdError = - GetV1IdentityVerificationEmploymentIdErrors[keyof GetV1IdentityVerificationEmploymentIdErrors]; +export type PutV2EmploymentsEmploymentIdFederalTaxesError = + PutV2EmploymentsEmploymentIdFederalTaxesErrors[keyof PutV2EmploymentsEmploymentIdFederalTaxesErrors]; -export type GetV1IdentityVerificationEmploymentIdResponses = { +export type PutV2EmploymentsEmploymentIdFederalTaxesResponses = { /** * Success */ - 200: IdentityVerificationResponse; + 200: SuccessResponse; }; -export type GetV1IdentityVerificationEmploymentIdResponse = - GetV1IdentityVerificationEmploymentIdResponses[keyof GetV1IdentityVerificationEmploymentIdResponses]; - -export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsData = - { - body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; - query?: never; - url: '/v1/contractors/employments/{employment_id}/contractor-subscriptions'; - }; +export type PutV2EmploymentsEmploymentIdFederalTaxesResponse = + PutV2EmploymentsEmploymentIdFederalTaxesResponses[keyof PutV2EmploymentsEmploymentIdFederalTaxesResponses]; -export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors = - { +export type GetV1TravelLetterRequestsData = { + body?: never; + path?: never; + query?: { /** - * Unauthorized + * Filter results on the given status */ - 401: UnauthorizedResponse; + status?: + | 'pending' + | 'cancelled' + | 'declined_by_manager' + | 'declined_by_remote' + | 'approved_by_manager' + | 'approved_by_remote'; /** - * Forbidden + * Filter results on the given employment slug */ - 403: ForbiddenResponse; + employment_id?: string; /** - * Not Found + * Filter results on the given employee name */ - 404: NotFoundResponse; - }; - -export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsError = - GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors[keyof GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsErrors]; - -export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses = - { + employee_name?: string; /** - * Success + * Sort order */ - 200: ContractorSubscriptionSummariesResponse; - }; - -export type GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponse = - GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses[keyof GetV1ContractorsEmploymentsEmploymentIdContractorSubscriptionsResponses]; - -export type GetV1EmployeePayslipsData = { - body?: never; - path?: never; - query?: { + order?: 'asc' | 'desc'; + /** + * Field to sort by + */ + sort_by?: 'submitted_at'; /** * Starts fetching records after the given page */ @@ -13424,86 +13379,54 @@ export type GetV1EmployeePayslipsData = { */ page_size?: number; }; - url: '/v1/employee/payslips'; + url: '/v1/travel-letter-requests'; }; -export type GetV1EmployeePayslipsErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; +export type GetV1TravelLetterRequestsErrors = { /** * Not Found */ 404: NotFoundResponse; -}; - -export type GetV1EmployeePayslipsError = - GetV1EmployeePayslipsErrors[keyof GetV1EmployeePayslipsErrors]; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; -export type GetV1EmployeePayslipsResponses = { +export type GetV1TravelLetterRequestsError = + GetV1TravelLetterRequestsErrors[keyof GetV1TravelLetterRequestsErrors]; + +export type GetV1TravelLetterRequestsResponses = { /** * Success */ - 200: ListEmployeePayslipsResponse; + 200: ListTravelLettersResponse; }; -export type GetV1EmployeePayslipsResponse = - GetV1EmployeePayslipsResponses[keyof GetV1EmployeePayslipsResponses]; +export type GetV1TravelLetterRequestsResponse = + GetV1TravelLetterRequestsResponses[keyof GetV1TravelLetterRequestsResponses]; -export type GetV1WebhookEventsData = { +export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsData = { body?: never; - path?: never; - query?: { - /** - * Filter by webhook event type - */ - event_type?: string; - /** - * Filter by delivery status (true = 200, false = 4xx/5xx) - */ - successfully_delivered?: boolean; - /** - * Filter by company ID - */ - company_id?: string; - /** - * Filter by date before (ISO 8601 format) - */ - before?: string; - /** - * Filter by date after (ISO 8601 format) - */ - after?: string; - /** - * Sort order - */ - order?: 'asc' | 'desc'; - /** - * Field to sort by - */ - sort_by?: 'first_triggered_at'; - /** - * Starts fetching records after the given page - */ - page?: number; + path: { /** - * Number of items per page + * Employment ID */ - page_size?: number; + employment_id: string; }; - url: '/v1/webhook-events'; + query?: never; + url: '/v2/employments/{employment_id}/engagement-agreement-details'; }; -export type GetV1WebhookEventsErrors = { +export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ @@ -13512,182 +13435,143 @@ export type GetV1WebhookEventsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1WebhookEventsError = - GetV1WebhookEventsErrors[keyof GetV1WebhookEventsErrors]; +export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsError = + GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof GetV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; -export type GetV1WebhookEventsResponses = { +export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { /** * Success */ - 200: ListWebhookEventsResponse; + 200: EmploymentEngagementAgreementDetailsResponse; }; -export type GetV1WebhookEventsResponse = - GetV1WebhookEventsResponses[keyof GetV1WebhookEventsResponses]; +export type GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponse = + GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof GetV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; -export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksData = { - body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; +export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsData = { + /** + * Employment engagement agreement details params + */ + body?: EmploymentEngagementAgreementDetailsParams; path: { /** - * Company ID + * Employment ID */ - company_id: string; + employment_id: string; }; query?: never; - url: '/v1/sandbox/companies/{company_id}/bypass-eligibility-checks'; + url: '/v2/employments/{employment_id}/engagement-agreement-details'; }; -export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors = { +export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksError = - PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors[keyof PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors]; +export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsError = + PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof PostV2EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; -export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses = { +export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { /** * Success */ 200: SuccessResponse; }; -export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponse = - PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses[keyof PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses]; - -export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveData = - { - body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; - query?: never; - url: '/v1/sandbox/employments/{employment_id}/risk-reserve-proof-of-payments/approve'; - }; - -export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors = - { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; - }; - -export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveError = - PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors[keyof PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors]; +export type PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponse = + PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof PostV2EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; -export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses = - { +export type GetV1WdGphPaySummaryData = { + body?: never; + headers?: { /** - * Success + * The preferred language of the inquiring user in Workday */ - 200: RiskReserveProofOfPaymentResponse; + accept_language?: string; }; - -export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponse = - PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses[keyof PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses]; - -export type GetV1TestSchemaData = { - body?: never; path?: never; query?: { /** - * Version of the form schema + * The pay group ids to lookup (comma separated). Returns all pay groups if not provided */ - json_schema_version?: number | 'latest'; + payGroupExternalId?: string; + /** + * Optional country filter (ISO 3166 alpha-2, comma separated) + */ + countryCode?: string; }; - url: '/v1/test-schema'; + url: '/v1/wd/gph/paySummary'; }; -export type GetV1TestSchemaResponses = { +export type GetV1WdGphPaySummaryErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; +}; + +export type GetV1WdGphPaySummaryError = + GetV1WdGphPaySummaryErrors[keyof GetV1WdGphPaySummaryErrors]; + +export type GetV1WdGphPaySummaryResponses = { /** * Success */ - 200: CompanyFormResponse; + 200: PaySummaryResponse; }; -export type GetV1TestSchemaResponse = - GetV1TestSchemaResponses[keyof GetV1TestSchemaResponses]; +export type GetV1WdGphPaySummaryResponse = + GetV1WdGphPaySummaryResponses[keyof GetV1WdGphPaySummaryResponses]; -export type GetV1CountriesCountryCodeHolidaysYearData = { +export type GetV1EmploymentsEmploymentIdJobData = { body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; path: { /** - * Country code according to ISO 3166-1 3-digit alphabetic codes - */ - country_code: string; - /** - * Year for the holidays - */ - year: string; - }; - query?: { - /** - * Country subdivision code according to ISO 3166-2 codes + * Employment ID */ - country_subdivision_code?: string; + employment_id: string; }; - url: '/v1/countries/{country_code}/holidays/{year}'; + query?: never; + url: '/v1/employments/{employment_id}/job'; }; -export type GetV1CountriesCountryCodeHolidaysYearErrors = { +export type GetV1EmploymentsEmploymentIdJobErrors = { /** * Unauthorized */ @@ -13702,47 +13586,38 @@ export type GetV1CountriesCountryCodeHolidaysYearErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1CountriesCountryCodeHolidaysYearError = - GetV1CountriesCountryCodeHolidaysYearErrors[keyof GetV1CountriesCountryCodeHolidaysYearErrors]; +export type GetV1EmploymentsEmploymentIdJobError = + GetV1EmploymentsEmploymentIdJobErrors[keyof GetV1EmploymentsEmploymentIdJobErrors]; -export type GetV1CountriesCountryCodeHolidaysYearResponses = { +export type GetV1EmploymentsEmploymentIdJobResponses = { /** * Success */ - 200: HolidaysResponse; + 200: EmploymentJobResponse; }; -export type GetV1CountriesCountryCodeHolidaysYearResponse = - GetV1CountriesCountryCodeHolidaysYearResponses[keyof GetV1CountriesCountryCodeHolidaysYearResponses]; +export type GetV1EmploymentsEmploymentIdJobResponse = + GetV1EmploymentsEmploymentIdJobResponses[keyof GetV1EmploymentsEmploymentIdJobResponses]; -export type PostV1TimeoffTimeoffIdCancelData = { +export type PostV1BulkEmploymentJobsData = { /** - * CancelTimeoff + * Bulk employment params */ - body: CancelTimeoffParams; - path: { - /** - * Time Off ID - */ - timeoff_id: string; - }; + body?: BulkEmploymentCreateParams; + path?: never; query?: never; - url: '/v1/timeoff/{timeoff_id}/cancel'; + url: '/v1/bulk-employment-jobs'; }; -export type PostV1TimeoffTimeoffIdCancelErrors = { +export type PostV1BulkEmploymentJobsErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; /** * Unprocessable Entity */ @@ -13753,32 +13628,53 @@ export type PostV1TimeoffTimeoffIdCancelErrors = { 429: TooManyRequestsResponse; }; -export type PostV1TimeoffTimeoffIdCancelError = - PostV1TimeoffTimeoffIdCancelErrors[keyof PostV1TimeoffTimeoffIdCancelErrors]; +export type PostV1BulkEmploymentJobsError = + PostV1BulkEmploymentJobsErrors[keyof PostV1BulkEmploymentJobsErrors]; -export type PostV1TimeoffTimeoffIdCancelResponses = { +export type PostV1BulkEmploymentJobsResponses = { /** - * Success + * Accepted */ - 200: TimeoffResponse; + 202: BulkEmploymentImportJobResponse; }; -export type PostV1TimeoffTimeoffIdCancelResponse = - PostV1TimeoffTimeoffIdCancelResponses[keyof PostV1TimeoffTimeoffIdCancelResponses]; +export type PostV1BulkEmploymentJobsResponse = + PostV1BulkEmploymentJobsResponses[keyof PostV1BulkEmploymentJobsResponses]; -export type GetV1EmploymentsEmploymentIdJobData = { +export type GetV1ContractAmendmentsData = { body?: never; - path: { + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; + path?: never; + query?: { /** * Employment ID */ - employment_id: string; + employment_id?: string; + /** + * Contract Amendment status + */ + status?: ContractAmendmentStatus; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - query?: never; - url: '/v1/employments/{employment_id}/job'; + url: '/v1/contract-amendments'; }; -export type GetV1EmploymentsEmploymentIdJobErrors = { +export type GetV1ContractAmendmentsErrors = { /** * Unauthorized */ @@ -13793,79 +13689,44 @@ export type GetV1EmploymentsEmploymentIdJobErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1EmploymentsEmploymentIdJobError = - GetV1EmploymentsEmploymentIdJobErrors[keyof GetV1EmploymentsEmploymentIdJobErrors]; +export type GetV1ContractAmendmentsError = + GetV1ContractAmendmentsErrors[keyof GetV1ContractAmendmentsErrors]; -export type GetV1EmploymentsEmploymentIdJobResponses = { +export type GetV1ContractAmendmentsResponses = { /** * Success */ - 200: EmploymentJobResponse; -}; - -export type GetV1EmploymentsEmploymentIdJobResponse = - GetV1EmploymentsEmploymentIdJobResponses[keyof GetV1EmploymentsEmploymentIdJobResponses]; - -export type GetV1PricingPlanPartnerTemplatesData = { - body?: never; - path?: never; - query?: never; - url: '/v1/pricing-plan-partner-templates'; -}; - -export type GetV1PricingPlanPartnerTemplatesErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; + 200: ListContractAmendmentResponse; }; -export type GetV1PricingPlanPartnerTemplatesError = - GetV1PricingPlanPartnerTemplatesErrors[keyof GetV1PricingPlanPartnerTemplatesErrors]; +export type GetV1ContractAmendmentsResponse = + GetV1ContractAmendmentsResponses[keyof GetV1ContractAmendmentsResponses]; -export type GetV1PricingPlanPartnerTemplatesResponses = { +export type PostV1ContractAmendmentsData = { /** - * Success + * Contract Amendment */ - 200: ListPricingPlanPartnerTemplatesResponse; -}; - -export type GetV1PricingPlanPartnerTemplatesResponse = - GetV1PricingPlanPartnerTemplatesResponses[keyof GetV1PricingPlanPartnerTemplatesResponses]; - -export type GetV1PayrollCalendarsData = { - body?: never; - path?: never; - query?: { - /** - * Filter payroll calendars by country code - */ - country_code?: string; - /** - * Filter payroll calendars by year - */ - year?: string; + body?: CreateContractAmendmentParams; + headers: { /** - * Starts fetching records after the given page + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - page?: number; + Authorization: string; + }; + path?: never; + query?: { /** - * Number of items per page + * Version of the form schema */ - page_size?: number; + json_schema_version?: number | 'latest'; }; - url: '/v1/payroll-calendars'; + url: '/v1/contract-amendments'; }; -export type GetV1PayrollCalendarsErrors = { +export type PostV1ContractAmendmentsErrors = { /** * Unauthorized */ @@ -13880,35 +13741,41 @@ export type GetV1PayrollCalendarsErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1PayrollCalendarsError = - GetV1PayrollCalendarsErrors[keyof GetV1PayrollCalendarsErrors]; +export type PostV1ContractAmendmentsError = + PostV1ContractAmendmentsErrors[keyof PostV1ContractAmendmentsErrors]; -export type GetV1PayrollCalendarsResponses = { +export type PostV1ContractAmendmentsResponses = { /** * Success */ - 200: PayrollCalendarsEorResponse; + 200: ContractAmendmentResponse; }; -export type GetV1PayrollCalendarsResponse = - GetV1PayrollCalendarsResponses[keyof GetV1PayrollCalendarsResponses]; +export type PostV1ContractAmendmentsResponse = + PostV1ContractAmendmentsResponses[keyof PostV1ContractAmendmentsResponses]; -export type PatchV1EmployeeTimeoffId2Data = { - /** - * UpdateTimeoff - */ - body: UpdateEmployeeTimeoffParams; +export type DeleteV1IncentivesRecurringIdData = { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * Timeoff ID + * Recurring Incentive ID */ id: string; }; query?: never; - url: '/v1/employee/timeoff/{id}'; + url: '/v1/incentives/recurring/{id}'; }; -export type PatchV1EmployeeTimeoffId2Errors = { +export type DeleteV1IncentivesRecurringIdErrors = { /** * Bad Request */ @@ -13926,44 +13793,46 @@ export type PatchV1EmployeeTimeoffId2Errors = { */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PatchV1EmployeeTimeoffId2Error = - PatchV1EmployeeTimeoffId2Errors[keyof PatchV1EmployeeTimeoffId2Errors]; +export type DeleteV1IncentivesRecurringIdError = + DeleteV1IncentivesRecurringIdErrors[keyof DeleteV1IncentivesRecurringIdErrors]; -export type PatchV1EmployeeTimeoffId2Responses = { +export type DeleteV1IncentivesRecurringIdResponses = { /** * Success */ - 200: TimeoffResponse; + 200: DeleteRecurringIncentiveResponse; }; -export type PatchV1EmployeeTimeoffId2Response = - PatchV1EmployeeTimeoffId2Responses[keyof PatchV1EmployeeTimeoffId2Responses]; +export type DeleteV1IncentivesRecurringIdResponse = + DeleteV1IncentivesRecurringIdResponses[keyof DeleteV1IncentivesRecurringIdResponses]; -export type PatchV1EmployeeTimeoffIdData = { - /** - * UpdateTimeoff - */ - body: UpdateEmployeeTimeoffParams; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdData = { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * Timeoff ID + * Benefit Renewal Request Id */ - id: string; + benefit_renewal_request_id: UuidSlug; }; query?: never; - url: '/v1/employee/timeoff/{id}'; + url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}'; }; -export type PatchV1EmployeeTimeoffIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors = { /** * Unauthorized */ @@ -13976,27 +13845,26 @@ export type PatchV1EmployeeTimeoffIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PatchV1EmployeeTimeoffIdError = - PatchV1EmployeeTimeoffIdErrors[keyof PatchV1EmployeeTimeoffIdErrors]; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdError = + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors]; -export type PatchV1EmployeeTimeoffIdResponses = { +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses = { /** * Success */ - 200: TimeoffResponse; + 200: BenefitRenewalRequestsBenefitRenewalRequestResponse; }; -export type PatchV1EmployeeTimeoffIdResponse = - PatchV1EmployeeTimeoffIdResponses[keyof PatchV1EmployeeTimeoffIdResponses]; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponse = + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses]; -export type GetV1IncentivesRecurringData = { - body?: never; +export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdData = { + /** + * Benefit Renewal Request Response + */ + body?: BenefitRenewalRequestsUpdateBenefitRenewalRequest; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -14006,73 +13874,51 @@ export type GetV1IncentivesRecurringData = { */ Authorization: string; }; - path?: never; - query?: { + path: { /** - * Filter by recurring incentive status: active or deactive. + * Benefit Renewal Request Id */ - status?: string; + benefit_renewal_request_id: UuidSlug; + }; + query?: { /** - * Filter by recurring incentive type. + * Version of the form schema */ - type?: string; - /** - * Filter by recurring incentives that contain the value in their notes. - */ - note?: string; - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Change the amount of records returned per page, defaults to 20, limited to 100 - */ - page_size?: number; + json_schema_version?: number | 'latest'; }; - url: '/v1/incentives/recurring'; + url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}'; }; -export type GetV1IncentivesRecurringErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV1IncentivesRecurringError = - GetV1IncentivesRecurringErrors[keyof GetV1IncentivesRecurringErrors]; +export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdError = + PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors[keyof PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors]; -export type GetV1IncentivesRecurringResponses = { +export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses = { /** * Success */ - 201: ListRecurringIncentivesResponse; + 200: SuccessResponse; }; -export type GetV1IncentivesRecurringResponse = - GetV1IncentivesRecurringResponses[keyof GetV1IncentivesRecurringResponses]; +export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponse = + PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses[keyof PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses]; -export type PostV1IncentivesRecurringData = { - /** - * RecurringIncentive - */ - body?: CreateRecurringIncentiveParams; +export type GetV1CountriesCountryCodeHolidaysYearData = { + body?: never; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -14082,16 +13928,26 @@ export type PostV1IncentivesRecurringData = { */ Authorization: string; }; - path?: never; - query?: never; - url: '/v1/incentives/recurring'; + path: { + /** + * Country code according to ISO 3166-1 3-digit alphabetic codes + */ + country_code: string; + /** + * Year for the holidays + */ + year: string; + }; + query?: { + /** + * Country subdivision code according to ISO 3166-2 codes + */ + country_subdivision_code?: string; + }; + url: '/v1/countries/{country_code}/holidays/{year}'; }; -export type PostV1IncentivesRecurringErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1CountriesCountryCodeHolidaysYearErrors = { /** * Unauthorized */ @@ -14104,93 +13960,83 @@ export type PostV1IncentivesRecurringErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PostV1IncentivesRecurringError = - PostV1IncentivesRecurringErrors[keyof PostV1IncentivesRecurringErrors]; +export type GetV1CountriesCountryCodeHolidaysYearError = + GetV1CountriesCountryCodeHolidaysYearErrors[keyof GetV1CountriesCountryCodeHolidaysYearErrors]; -export type PostV1IncentivesRecurringResponses = { +export type GetV1CountriesCountryCodeHolidaysYearResponses = { /** * Success */ - 201: RecurringIncentiveResponse; + 200: HolidaysResponse; }; -export type PostV1IncentivesRecurringResponse = - PostV1IncentivesRecurringResponses[keyof PostV1IncentivesRecurringResponses]; +export type GetV1CountriesCountryCodeHolidaysYearResponse = + GetV1CountriesCountryCodeHolidaysYearResponses[keyof GetV1CountriesCountryCodeHolidaysYearResponses]; -export type PostV1SandboxBenefitRenewalRequestsData = { - /** - * Benefit Renewal Request - */ - body: BenefitRenewalRequestsCreateBenefitRenewalRequest; - headers: { +export type GetV1EmploymentsEmploymentIdCustomFieldsData = { + body?: never; + path: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Employment ID */ - Authorization: string; + employment_id: string; }; - path?: never; - query?: never; - url: '/v1/sandbox/benefit-renewal-requests'; + query?: { + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/employments/{employment_id}/custom-fields'; }; -export type PostV1SandboxBenefitRenewalRequestsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmploymentsEmploymentIdCustomFieldsErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ - 429: TooManyRequestsResponse; + 422: UnprocessableEntityResponse; }; -export type PostV1SandboxBenefitRenewalRequestsError = - PostV1SandboxBenefitRenewalRequestsErrors[keyof PostV1SandboxBenefitRenewalRequestsErrors]; +export type GetV1EmploymentsEmploymentIdCustomFieldsError = + GetV1EmploymentsEmploymentIdCustomFieldsErrors[keyof GetV1EmploymentsEmploymentIdCustomFieldsErrors]; -export type PostV1SandboxBenefitRenewalRequestsResponses = { +export type GetV1EmploymentsEmploymentIdCustomFieldsResponses = { /** * Success */ - 200: BenefitRenewalRequestsCreateBenefitRenewalRequestResponse; + 200: ListEmploymentCustomFieldValuePaginatedResponse; }; -export type PostV1SandboxBenefitRenewalRequestsResponse = - PostV1SandboxBenefitRenewalRequestsResponses[keyof PostV1SandboxBenefitRenewalRequestsResponses]; +export type GetV1EmploymentsEmploymentIdCustomFieldsResponse = + GetV1EmploymentsEmploymentIdCustomFieldsResponses[keyof GetV1EmploymentsEmploymentIdCustomFieldsResponses]; -export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdData = { +export type GetV1TimesheetsIdData = { body?: never; path: { /** - * Employment ID - */ - employment_id: string; - /** - * Document ID + * Timesheet ID */ id: string; }; query?: never; - url: '/v1/contractors/employments/{employment_id}/contract-documents/{id}'; + url: '/v1/timesheets/{id}'; }; -export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors = { +export type GetV1TimesheetsIdErrors = { /** * Unauthorized */ @@ -14205,50 +14051,53 @@ export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdError = - GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors[keyof GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors]; +export type GetV1TimesheetsIdError = + GetV1TimesheetsIdErrors[keyof GetV1TimesheetsIdErrors]; -export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses = - { - /** - * Success - */ - 200: ContractDocumentResponse; - }; +export type GetV1TimesheetsIdResponses = { + /** + * Success + */ + 200: TimesheetResponse; +}; -export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponse = - GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses[keyof GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses]; +export type GetV1TimesheetsIdResponse = + GetV1TimesheetsIdResponses[keyof GetV1TimesheetsIdResponses]; -export type GetV1EmploymentsEmploymentIdContractDocumentsData = { +export type GetV1CompanyManagersData = { body?: never; - path: { + headers: { /** - * Employment ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - employment_id: string; + Authorization: string; }; + path?: never; query?: { /** - * Filter by contract document statuses - */ - statuses?: Array; - /** - * Exclude contract documents with specific statuses + * A Company ID to filter the results (only applicable for Integration Partners). */ - except_statuses?: Array; + company_id?: string; /** * Starts fetching records after the given page */ page?: number; /** - * Number of items per page + * Change the amount of records returned per page, defaults to 20, limited to 100 */ page_size?: number; }; - url: '/v1/employments/{employment_id}/contract-documents'; + url: '/v1/company-managers'; }; -export type GetV1EmploymentsEmploymentIdContractDocumentsErrors = { +export type GetV1CompanyManagersErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -14261,23 +14110,30 @@ export type GetV1EmploymentsEmploymentIdContractDocumentsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1EmploymentsEmploymentIdContractDocumentsError = - GetV1EmploymentsEmploymentIdContractDocumentsErrors[keyof GetV1EmploymentsEmploymentIdContractDocumentsErrors]; +export type GetV1CompanyManagersError = + GetV1CompanyManagersErrors[keyof GetV1CompanyManagersErrors]; -export type GetV1EmploymentsEmploymentIdContractDocumentsResponses = { +export type GetV1CompanyManagersResponses = { /** * Success */ - 200: IndexContractDocumentsResponse; + 200: CompanyManagersResponse; }; -export type GetV1EmploymentsEmploymentIdContractDocumentsResponse = - GetV1EmploymentsEmploymentIdContractDocumentsResponses[keyof GetV1EmploymentsEmploymentIdContractDocumentsResponses]; +export type GetV1CompanyManagersResponse = + GetV1CompanyManagersResponses[keyof GetV1CompanyManagersResponses]; -export type GetV1ExpensesData = { - body?: never; +export type PostV1CompanyManagersData = { + /** + * Company Manager params + */ + body?: CompanyManagerParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -14290,18 +14146,17 @@ export type GetV1ExpensesData = { path?: never; query?: { /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Change the amount of records returned per page, defaults to 20, limited to 100 + * Complementary action(s) to perform when creating a company manager: + * + * - `no_invite` skips the email invitation step + * */ - page_size?: number; + actions?: string; }; - url: '/v1/expenses'; + url: '/v1/company-managers'; }; -export type GetV1ExpensesErrors = { +export type PostV1CompanyManagersErrors = { /** * Bad Request */ @@ -14324,85 +14179,78 @@ export type GetV1ExpensesErrors = { 429: TooManyRequestsResponse; }; -export type GetV1ExpensesError = GetV1ExpensesErrors[keyof GetV1ExpensesErrors]; +export type PostV1CompanyManagersError = + PostV1CompanyManagersErrors[keyof PostV1CompanyManagersErrors]; -export type GetV1ExpensesResponses = { +export type PostV1CompanyManagersResponses = { /** * Success */ - 201: ListExpenseResponse; + 201: CompanyManagerData; }; -export type GetV1ExpensesResponse = - GetV1ExpensesResponses[keyof GetV1ExpensesResponses]; +export type PostV1CompanyManagersResponse = + PostV1CompanyManagersResponses[keyof PostV1CompanyManagersResponses]; -export type PostV1ExpensesData = { +export type PostV1PayItemsBulkData = { /** - * Expenses + * Pay Items */ - body?: ParamsToCreateExpense; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; + body: BulkCreatePayItemsParams; path?: never; query?: never; - url: '/v1/expenses'; + url: '/v1/pay-items/bulk'; }; -export type PostV1ExpensesErrors = { +export type PostV1PayItemsBulkErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type PostV1ExpensesError = - PostV1ExpensesErrors[keyof PostV1ExpensesErrors]; +export type PostV1PayItemsBulkError = + PostV1PayItemsBulkErrors[keyof PostV1PayItemsBulkErrors]; -export type PostV1ExpensesResponses = { +export type PostV1PayItemsBulkResponses = { /** * Success */ - 201: ExpenseResponse; + 200: BulkCreatePayItemsResponse; }; -export type PostV1ExpensesResponse = - PostV1ExpensesResponses[keyof PostV1ExpensesResponses]; +export type PostV1PayItemsBulkResponse = + PostV1PayItemsBulkResponses[keyof PostV1PayItemsBulkResponses]; -export type GetV1SsoConfigurationData = { +export type GetV1TravelLetterRequestsIdData = { body?: never; - path?: never; + path: { + /** + * travel letter request ID + */ + id: UuidSlug; + }; query?: never; - url: '/v1/sso-configuration'; + url: '/v1/travel-letter-requests/{id}'; }; -export type GetV1SsoConfigurationErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1TravelLetterRequestsIdErrors = { /** * Unauthorized */ @@ -14414,37 +14262,38 @@ export type GetV1SsoConfigurationErrors = { /** * Unprocessable Entity */ - 429: TooManyRequestsResponse; + 422: UnprocessableEntityResponse; }; -export type GetV1SsoConfigurationError = - GetV1SsoConfigurationErrors[keyof GetV1SsoConfigurationErrors]; +export type GetV1TravelLetterRequestsIdError = + GetV1TravelLetterRequestsIdErrors[keyof GetV1TravelLetterRequestsIdErrors]; -export type GetV1SsoConfigurationResponses = { +export type GetV1TravelLetterRequestsIdResponses = { /** * Success */ - 200: SsoConfigurationResponse; + 200: TravelLetterResponse; }; -export type GetV1SsoConfigurationResponse = - GetV1SsoConfigurationResponses[keyof GetV1SsoConfigurationResponses]; +export type GetV1TravelLetterRequestsIdResponse = + GetV1TravelLetterRequestsIdResponses[keyof GetV1TravelLetterRequestsIdResponses]; -export type PostV1SsoConfigurationData = { +export type PatchV1TravelLetterRequestsId2Data = { /** - * CreateSSOConfiguration + * Travel letter Request */ - body: CreateSsoConfigurationParams; - path?: never; + body: UpdateTravelLetterRequestParams; + path: { + /** + * Travel letter Request ID + */ + id: string; + }; query?: never; - url: '/v1/sso-configuration'; + url: '/v1/travel-letter-requests/{id}'; }; -export type PostV1SsoConfigurationErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PatchV1TravelLetterRequestsId2Errors = { /** * Unauthorized */ @@ -14453,83 +14302,124 @@ export type PostV1SsoConfigurationErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; +}; + +export type PatchV1TravelLetterRequestsId2Error = + PatchV1TravelLetterRequestsId2Errors[keyof PatchV1TravelLetterRequestsId2Errors]; + +export type PatchV1TravelLetterRequestsId2Responses = { /** - * Unprocessable Entity + * Success */ - 429: TooManyRequestsResponse; + 200: TravelLetterResponse; }; -export type PostV1SsoConfigurationError = - PostV1SsoConfigurationErrors[keyof PostV1SsoConfigurationErrors]; +export type PatchV1TravelLetterRequestsId2Response = + PatchV1TravelLetterRequestsId2Responses[keyof PatchV1TravelLetterRequestsId2Responses]; -export type PostV1SsoConfigurationResponses = { +export type PatchV1TravelLetterRequestsIdData = { /** - * Created + * Travel letter Request */ - 201: CreateSsoConfigurationResponse; + body: UpdateTravelLetterRequestParams; + path: { + /** + * Travel letter Request ID + */ + id: string; + }; + query?: never; + url: '/v1/travel-letter-requests/{id}'; }; -export type PostV1SsoConfigurationResponse = - PostV1SsoConfigurationResponses[keyof PostV1SsoConfigurationResponses]; +export type PatchV1TravelLetterRequestsIdErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveData = - { - body?: never; - path: { - /** - * Contract amendment request ID - */ - contract_amendment_request_id: string; - }; - query?: never; - url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/approve'; - }; +export type PatchV1TravelLetterRequestsIdError = + PatchV1TravelLetterRequestsIdErrors[keyof PatchV1TravelLetterRequestsIdErrors]; -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors = - { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; +export type PatchV1TravelLetterRequestsIdResponses = { + /** + * Success + */ + 200: TravelLetterResponse; +}; + +export type PatchV1TravelLetterRequestsIdResponse = + PatchV1TravelLetterRequestsIdResponses[keyof PatchV1TravelLetterRequestsIdResponses]; + +export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksData = { + body?: never; + headers: { /** - * Unprocessable Entity + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - 422: UnprocessableEntityResponse; + Authorization: string; + }; + path: { /** - * Too many requests + * Company ID */ - 429: TooManyRequestsResponse; + company_id: string; }; + query?: never; + url: '/v1/sandbox/companies/{company_id}/bypass-eligibility-checks'; +}; -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveError = - PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors]; +export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; +}; -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses = - { - /** - * Success - */ - 200: ContractAmendmentResponse; - }; +export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksError = + PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors[keyof PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksErrors]; -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponse = - PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses]; +export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses = { + /** + * Success + */ + 200: SuccessResponse; +}; + +export type PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponse = + PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses[keyof PostV1SandboxCompaniesCompanyIdBypassEligibilityChecksResponses]; export type GetV1EmployeeLeavePoliciesData = { body?: never; @@ -14562,68 +14452,19 @@ export type GetV1EmployeeLeavePoliciesResponses = { export type GetV1EmployeeLeavePoliciesResponse = GetV1EmployeeLeavePoliciesResponses[keyof GetV1EmployeeLeavePoliciesResponses]; -export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesData = { +export type GetV1CompaniesCompanyIdWebhookCallbacksData = { body?: never; path: { /** - * Employment ID - */ - employment_id: string; - }; - query?: { - /** - * Restrict to currencies which payout is guaranteed (default: true) + * Company ID */ - restrict_to_guaranteed_pay_out_currencies?: boolean; + company_id: string; }; - url: '/v1/contractors/employments/{employment_id}/contractor-currencies'; + query?: never; + url: '/v1/companies/{company_id}/webhook-callbacks'; }; -export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors = - { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Internal Server Error - */ - 500: InternalServerErrorResponse; - }; - -export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesError = - GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors[keyof GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors]; - -export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses = - { - /** - * Success - */ - 200: ContractorCurrencyResponse; - }; - -export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponse = - GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses[keyof GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses]; - -export type PostV1WebhookEventsReplayData = { - /** - * WebhookEvent - */ - body: ReplayWebhookEventsParams; - path?: never; - query?: never; - url: '/v1/webhook-events/replay'; -}; - -export type PostV1WebhookEventsReplayErrors = { +export type GetV1CompaniesCompanyIdWebhookCallbacksErrors = { /** * Unauthorized */ @@ -14632,120 +14473,22 @@ export type PostV1WebhookEventsReplayErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; }; -export type PostV1WebhookEventsReplayError = - PostV1WebhookEventsReplayErrors[keyof PostV1WebhookEventsReplayErrors]; +export type GetV1CompaniesCompanyIdWebhookCallbacksError = + GetV1CompaniesCompanyIdWebhookCallbacksErrors[keyof GetV1CompaniesCompanyIdWebhookCallbacksErrors]; -export type PostV1WebhookEventsReplayResponses = { +export type GetV1CompaniesCompanyIdWebhookCallbacksResponses = { /** * Success */ - 200: SuccessResponse; + 200: ListWebhookCallbacksResponse; }; -export type PostV1WebhookEventsReplayResponse = - PostV1WebhookEventsReplayResponses[keyof PostV1WebhookEventsReplayResponses]; - -export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsData = - { - body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; - query?: never; - url: '/v1/contractors/employments/{employment_id}/cor-termination-requests'; - }; - -export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors = - { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - }; - -export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsError = - PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors[keyof PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors]; - -export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses = - { - /** - * Created - */ - 201: CorTerminationRequestCreatedResponse; - }; - -export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponse = - PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses[keyof PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses]; - -export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdData = - { - body?: never; - path: { - /** - * Employment Id - */ - employment_id: UuidSlug; - /** - * Background Check Id - */ - background_check_id: UuidSlug; - }; - query?: never; - url: '/v1/employments/{employment_id}/background-checks/{background_check_id}'; - }; - -export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors = - { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - }; - -export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdError = - GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors[keyof GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors]; - -export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses = - { - /** - * Success - */ - 200: BackgroundChecksBackgroundCheckResponse; - }; - -export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponse = - GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses[keyof GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses]; +export type GetV1CompaniesCompanyIdWebhookCallbacksResponse = + GetV1CompaniesCompanyIdWebhookCallbacksResponses[keyof GetV1CompaniesCompanyIdWebhookCallbacksResponses]; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaData = { +export type GetV1BillingDocumentsBillingDocumentIdPdfData = { body?: never; headers: { /** @@ -14758,20 +14501,15 @@ export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaData = { }; path: { /** - * Benefit Renewal Request Id - */ - benefit_renewal_request_id: UuidSlug; - }; - query?: { - /** - * Version of the form schema + * The billing document's ID */ - json_schema_version?: number | 'latest'; + billing_document_id: string; }; - url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}/schema'; + query?: never; + url: '/v1/billing-documents/{billing_document_id}/pdf'; }; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors = { +export type GetV1BillingDocumentsBillingDocumentIdPdfErrors = { /** * Unauthorized */ @@ -14786,25 +14524,21 @@ export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaError = - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors]; - -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses = - { - /** - * Success - */ - 200: BenefitRenewalRequestsBenefitRenewalRequestFormResponse; - }; - -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponse = - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses]; +export type GetV1BillingDocumentsBillingDocumentIdPdfError = + GetV1BillingDocumentsBillingDocumentIdPdfErrors[keyof GetV1BillingDocumentsBillingDocumentIdPdfErrors]; -export type PostV1MagicLinkData = { +export type GetV1BillingDocumentsBillingDocumentIdPdfResponses = { /** - * Magic links generator body + * Success */ - body: MagicLinkParams; + 200: GenericFile; +}; + +export type GetV1BillingDocumentsBillingDocumentIdPdfResponse = + GetV1BillingDocumentsBillingDocumentIdPdfResponses[keyof GetV1BillingDocumentsBillingDocumentIdPdfResponses]; + +export type DeleteV1WebhookCallbacksIdData = { + body?: never; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -14814,104 +14548,103 @@ export type PostV1MagicLinkData = { */ Authorization: string; }; - path?: never; + path: { + /** + * Webhook Callback ID + */ + id: string; + }; query?: never; - url: '/v1/magic-link'; + url: '/v1/webhook-callbacks/{id}'; }; -export type PostV1MagicLinkErrors = { +export type DeleteV1WebhookCallbacksIdErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; }; -export type PostV1MagicLinkError = - PostV1MagicLinkErrors[keyof PostV1MagicLinkErrors]; +export type DeleteV1WebhookCallbacksIdError = + DeleteV1WebhookCallbacksIdErrors[keyof DeleteV1WebhookCallbacksIdErrors]; -export type PostV1MagicLinkResponses = { +export type DeleteV1WebhookCallbacksIdResponses = { /** * Success */ - 200: MagicLinkResponse; + 200: SuccessResponse; }; -export type PostV1MagicLinkResponse = - PostV1MagicLinkResponses[keyof PostV1MagicLinkResponses]; +export type DeleteV1WebhookCallbacksIdResponse = + DeleteV1WebhookCallbacksIdResponses[keyof DeleteV1WebhookCallbacksIdResponses]; -export type PutV2EmploymentsEmploymentIdBasicInformationData = { +export type PatchV1WebhookCallbacksIdData = { /** - * Employment basic information params + * WebhookCallback */ - body?: EmploymentBasicInformationParams; + body?: UpdateWebhookCallbackParams; path: { /** - * Employment ID + * Webhook Callback ID */ - employment_id: string; + id: string; }; query?: never; - url: '/v2/employments/{employment_id}/basic_information'; + url: '/v1/webhook-callbacks/{id}'; }; -export type PutV2EmploymentsEmploymentIdBasicInformationErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PatchV1WebhookCallbacksIdErrors = { /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdBasicInformationError = - PutV2EmploymentsEmploymentIdBasicInformationErrors[keyof PutV2EmploymentsEmploymentIdBasicInformationErrors]; +export type PatchV1WebhookCallbacksIdError = + PatchV1WebhookCallbacksIdErrors[keyof PatchV1WebhookCallbacksIdErrors]; -export type PutV2EmploymentsEmploymentIdBasicInformationResponses = { +export type PatchV1WebhookCallbacksIdResponses = { /** * Success */ - 200: EmploymentResponse; + 200: WebhookCallbackResponse; }; -export type PutV2EmploymentsEmploymentIdBasicInformationResponse = - PutV2EmploymentsEmploymentIdBasicInformationResponses[keyof PutV2EmploymentsEmploymentIdBasicInformationResponses]; +export type PatchV1WebhookCallbacksIdResponse = + PatchV1WebhookCallbacksIdResponses[keyof PatchV1WebhookCallbacksIdResponses]; -export type DeleteV1IncentivesRecurringIdData = { +export type GetV1CountriesData = { body?: never; headers: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. + * This endpoint works with any of the access tokens provided. You can use an access + * token obtained through the Client Credentials flow, the Authorization Code flow, or the Refresh Token flow. * */ Authorization: string; }; - path: { - /** - * Recurring Incentive ID - */ - id: string; - }; + path?: never; query?: never; - url: '/v1/incentives/recurring/{id}'; + url: '/v1/countries'; }; -export type DeleteV1IncentivesRecurringIdErrors = { +export type GetV1CountriesErrors = { /** * Bad Request */ @@ -14934,20 +14667,136 @@ export type DeleteV1IncentivesRecurringIdErrors = { 429: TooManyRequestsResponse; }; -export type DeleteV1IncentivesRecurringIdError = - DeleteV1IncentivesRecurringIdErrors[keyof DeleteV1IncentivesRecurringIdErrors]; +export type GetV1CountriesError = + GetV1CountriesErrors[keyof GetV1CountriesErrors]; -export type DeleteV1IncentivesRecurringIdResponses = { +export type GetV1CountriesResponses = { /** * Success */ - 200: DeleteRecurringIncentiveResponse; + 200: CountriesResponse; }; -export type DeleteV1IncentivesRecurringIdResponse = - DeleteV1IncentivesRecurringIdResponses[keyof DeleteV1IncentivesRecurringIdResponses]; +export type GetV1CountriesResponse = + GetV1CountriesResponses[keyof GetV1CountriesResponses]; -export type GetV1IncentivesData = { +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityData = + { + body?: never; + path: { + /** + * Company ID + */ + company_id: UuidSlug; + /** + * Legal entity ID + */ + legal_entity_id: UuidSlug; + }; + query?: never; + url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/contractor-eligibility'; + }; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors = + { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + }; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityError = + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors]; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses = + { + /** + * Success + */ + 200: ContractorEligibilityResponse; + }; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponse = + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses]; + +export type PostV1CurrencyConverterEffectiveData = { + /** + * Convert currency parameters + */ + body: ConvertCurrencyParams; + path?: never; + query?: never; + url: '/v1/currency-converter/effective'; +}; + +export type PostV1CurrencyConverterEffectiveErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type PostV1CurrencyConverterEffectiveError = + PostV1CurrencyConverterEffectiveErrors[keyof PostV1CurrencyConverterEffectiveErrors]; + +export type PostV1CurrencyConverterEffectiveResponses = { + /** + * Success + */ + 200: ConvertCurrencyResponse; +}; + +export type PostV1CurrencyConverterEffectiveResponse = + PostV1CurrencyConverterEffectiveResponses[keyof PostV1CurrencyConverterEffectiveResponses]; + +export type GetV1EmployeePersonalInformationData = { + body?: never; + path?: never; + query?: never; + url: '/v1/employee/personal-information'; +}; + +export type GetV1EmployeePersonalInformationErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; +}; + +export type GetV1EmployeePersonalInformationError = + GetV1EmployeePersonalInformationErrors[keyof GetV1EmployeePersonalInformationErrors]; + +export type GetV1EmployeePersonalInformationResponses = { + /** + * Success + */ + 200: SuccessResponse; +}; + +export type GetV1EmployeePersonalInformationResponse = + GetV1EmployeePersonalInformationResponses[keyof GetV1EmployeePersonalInformationResponses]; + +export type GetV1CountriesCountryCodeFormData = { body?: never; headers: { /** @@ -14958,33 +14807,38 @@ export type GetV1IncentivesData = { */ Authorization: string; }; - path?: never; - query?: { + path: { /** - * Filter by Employment ID + * Country code according to ISO 3-digit alphabetic codes */ - employment_id?: string; + country_code: string; /** - * Filter by Incentive status + * Name of the desired form */ - status?: string; + form: string; + }; + query?: { /** - * Filter by Recurring Incentive id + * Required for `contract_amendment` form */ - recurring_incentive_id?: string; + employment_id?: string; /** - * Starts fetching records after the given page + * FOR TESTING PURPOSES ONLY: Include scheduled benefit groups. */ - page?: number; + only_for_testing_include_scheduled_benefit_groups?: boolean; /** - * Change the amount of records returned per page, defaults to 20, limited to 100 + * Skips the dynamic benefits part of the schema if set. To be used when benefits are set via its own API. */ - page_size?: number; + skip_benefits?: boolean; + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; }; - url: '/v1/incentives'; + url: '/v1/countries/{country_code}/{form}'; }; -export type GetV1IncentivesErrors = { +export type GetV1CountriesCountryCodeFormErrors = { /** * Bad Request */ @@ -15002,29 +14856,26 @@ export type GetV1IncentivesErrors = { */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV1IncentivesError = - GetV1IncentivesErrors[keyof GetV1IncentivesErrors]; +export type GetV1CountriesCountryCodeFormError = + GetV1CountriesCountryCodeFormErrors[keyof GetV1CountriesCountryCodeFormErrors]; -export type GetV1IncentivesResponses = { +export type GetV1CountriesCountryCodeFormResponses = { /** * Success */ - 200: ListIncentivesResponse; + 200: CountryFormResponse; }; -export type GetV1IncentivesResponse = - GetV1IncentivesResponses[keyof GetV1IncentivesResponses]; +export type GetV1CountriesCountryCodeFormResponse = + GetV1CountriesCountryCodeFormResponses[keyof GetV1CountriesCountryCodeFormResponses]; -export type PostV1IncentivesData = { - /** - * Incentive - */ - body?: CreateOneTimeIncentiveParams; +export type GetV1TimeoffData = { + body?: never; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -15035,11 +14886,40 @@ export type PostV1IncentivesData = { Authorization: string; }; path?: never; - query?: never; - url: '/v1/incentives'; + query?: { + /** + * Only show time off for a specific employment + */ + employment_id?: string; + /** + * Filter time off by its type + */ + timeoff_type?: TimeoffType; + /** + * Filter time off by its status + */ + status?: TimeoffStatus; + /** + * Sort order + */ + order?: 'asc' | 'desc'; + /** + * Field to sort by + */ + sort_by?: 'timeoff_type' | 'status'; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/timeoff'; }; -export type PostV1IncentivesErrors = { +export type GetV1TimeoffErrors = { /** * Bad Request */ @@ -15057,75 +14937,43 @@ export type PostV1IncentivesErrors = { */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type PostV1IncentivesError = - PostV1IncentivesErrors[keyof PostV1IncentivesErrors]; +export type GetV1TimeoffError = GetV1TimeoffErrors[keyof GetV1TimeoffErrors]; -export type PostV1IncentivesResponses = { +export type GetV1TimeoffResponses = { /** * Success */ - 201: IncentiveResponse; -}; - -export type PostV1IncentivesResponse = - PostV1IncentivesResponses[keyof PostV1IncentivesResponses]; - -export type PostV1ProbationCompletionLetterData = { - /** - * Work Authorization Request - */ - body: CreateProbationCompletionLetterParams; - path?: never; - query?: never; - url: '/v1/probation-completion-letter'; -}; - -export type PostV1ProbationCompletionLetterErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; + 200: ListTimeoffResponse; }; -export type PostV1ProbationCompletionLetterError = - PostV1ProbationCompletionLetterErrors[keyof PostV1ProbationCompletionLetterErrors]; +export type GetV1TimeoffResponse = + GetV1TimeoffResponses[keyof GetV1TimeoffResponses]; -export type PostV1ProbationCompletionLetterResponses = { +export type PostV1TimeoffData = { /** - * Success + * Timeoff */ - 200: ProbationCompletionLetterResponse; -}; - -export type PostV1ProbationCompletionLetterResponse = - PostV1ProbationCompletionLetterResponses[keyof PostV1ProbationCompletionLetterResponses]; - -export type GetV1ContractorInvoiceSchedulesIdData = { - body?: never; - path: { + body: CreateApprovedTimeoffParams; + headers: { /** - * Resource unique identifier + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - id: UuidSlug; + Authorization: string; }; + path?: never; query?: never; - url: '/v1/contractor-invoice-schedules/{id}'; + url: '/v1/timeoff'; }; -export type GetV1ContractorInvoiceSchedulesIdErrors = { +export type PostV1TimeoffErrors = { /** * Bad Request */ @@ -15134,10 +14982,6 @@ export type GetV1ContractorInvoiceSchedulesIdErrors = { * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -15152,90 +14996,60 @@ export type GetV1ContractorInvoiceSchedulesIdErrors = { 429: TooManyRequestsResponse; }; -export type GetV1ContractorInvoiceSchedulesIdError = - GetV1ContractorInvoiceSchedulesIdErrors[keyof GetV1ContractorInvoiceSchedulesIdErrors]; +export type PostV1TimeoffError = PostV1TimeoffErrors[keyof PostV1TimeoffErrors]; -export type GetV1ContractorInvoiceSchedulesIdResponses = { +export type PostV1TimeoffResponses = { /** - * Success + * Created */ - 200: ContractorInvoiceScheduleResponse; + 201: TimeoffResponse; }; -export type GetV1ContractorInvoiceSchedulesIdResponse = - GetV1ContractorInvoiceSchedulesIdResponses[keyof GetV1ContractorInvoiceSchedulesIdResponses]; +export type PostV1TimeoffResponse = + PostV1TimeoffResponses[keyof PostV1TimeoffResponses]; -export type PatchV1ContractorInvoiceSchedulesId2Data = { - /** - * Update parameters - */ - body: UpdateScheduleContractorInvoiceParams; - path: { +export type GetV1CostCalculatorCountriesData = { + body?: never; + path?: never; + query?: { /** - * Resource unique identifier + * If the premium benefits should be included in the response */ - id: UuidSlug; + include_premium_benefits?: boolean; }; - query?: never; - url: '/v1/contractor-invoice-schedules/{id}'; -}; - -export type PatchV1ContractorInvoiceSchedulesId2Errors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; + url: '/v1/cost-calculator/countries'; }; -export type PatchV1ContractorInvoiceSchedulesId2Error = - PatchV1ContractorInvoiceSchedulesId2Errors[keyof PatchV1ContractorInvoiceSchedulesId2Errors]; - -export type PatchV1ContractorInvoiceSchedulesId2Responses = { +export type GetV1CostCalculatorCountriesResponses = { /** * Success */ - 200: ContractorInvoiceScheduleResponse; + 200: CostCalculatorListCountryResponse; }; -export type PatchV1ContractorInvoiceSchedulesId2Response = - PatchV1ContractorInvoiceSchedulesId2Responses[keyof PatchV1ContractorInvoiceSchedulesId2Responses]; +export type GetV1CostCalculatorCountriesResponse = + GetV1CostCalculatorCountriesResponses[keyof GetV1CostCalculatorCountriesResponses]; -export type PatchV1ContractorInvoiceSchedulesIdData = { +export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsData = { /** - * Update parameters + * Proof of Payment */ - body: UpdateScheduleContractorInvoiceParams; + body: CreateRiskReserveProofOfPaymentParams; path: { /** - * Resource unique identifier + * Employment ID */ - id: UuidSlug; + employment_id: string; }; query?: never; - url: '/v1/contractor-invoice-schedules/{id}'; + url: '/v1/employments/{employment_id}/risk-reserve-proof-of-payments'; }; -export type PatchV1ContractorInvoiceSchedulesIdErrors = { +export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -15246,20 +15060,67 @@ export type PatchV1ContractorInvoiceSchedulesIdErrors = { 422: UnprocessableEntityResponse; }; -export type PatchV1ContractorInvoiceSchedulesIdError = - PatchV1ContractorInvoiceSchedulesIdErrors[keyof PatchV1ContractorInvoiceSchedulesIdErrors]; +export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsError = + PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors[keyof PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors]; -export type PatchV1ContractorInvoiceSchedulesIdResponses = { +export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses = { /** * Success */ - 200: ContractorInvoiceScheduleResponse; + 200: RiskReserveProofOfPaymentResponse; }; -export type PatchV1ContractorInvoiceSchedulesIdResponse = - PatchV1ContractorInvoiceSchedulesIdResponses[keyof PatchV1ContractorInvoiceSchedulesIdResponses]; +export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponse = + PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses[keyof PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses]; -export type GetV1BillingDocumentsBillingDocumentIdData = { +export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdData = + { + body?: never; + path: { + /** + * Employment Id + */ + employment_id: UuidSlug; + /** + * Background Check Id + */ + background_check_id: UuidSlug; + }; + query?: never; + url: '/v1/employments/{employment_id}/background-checks/{background_check_id}'; + }; + +export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors = + { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + }; + +export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdError = + GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors[keyof GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdErrors]; + +export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses = + { + /** + * Success + */ + 200: BackgroundChecksBackgroundCheckResponse; + }; + +export type GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponse = + GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses[keyof GetV1EmploymentsEmploymentIdBackgroundChecksBackgroundCheckIdResponses]; + +export type GetV1TimeoffBalancesEmploymentIdData = { body?: never; headers: { /** @@ -15272,20 +15133,15 @@ export type GetV1BillingDocumentsBillingDocumentIdData = { }; path: { /** - * The billing document's ID - */ - billing_document_id: string; - }; - query?: { - /** - * When true, includes billing document items whose type is not part of the standard set for the invoice type. + * Employment ID for which to show the time off balance */ - include_unrecognized_types?: boolean; + employment_id: string; }; - url: '/v1/billing-documents/{billing_document_id}'; + query?: never; + url: '/v1/timeoff-balances/{employment_id}'; }; -export type GetV1BillingDocumentsBillingDocumentIdErrors = { +export type GetV1TimeoffBalancesEmploymentIdErrors = { /** * Bad Request */ @@ -15295,122 +15151,134 @@ export type GetV1BillingDocumentsBillingDocumentIdErrors = { */ 401: UnauthorizedResponse; /** - * Not Found + * TimeoffBalanceNotFoundResponse */ - 404: NotFoundResponse; + 404: TimeoffBalanceNotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type GetV1BillingDocumentsBillingDocumentIdError = - GetV1BillingDocumentsBillingDocumentIdErrors[keyof GetV1BillingDocumentsBillingDocumentIdErrors]; +export type GetV1TimeoffBalancesEmploymentIdError = + GetV1TimeoffBalancesEmploymentIdErrors[keyof GetV1TimeoffBalancesEmploymentIdErrors]; -export type GetV1BillingDocumentsBillingDocumentIdResponses = { +export type GetV1TimeoffBalancesEmploymentIdResponses = { /** * Success */ - 200: BillingDocumentResponse; + 200: TimeoffBalanceResponse; }; -export type GetV1BillingDocumentsBillingDocumentIdResponse = - GetV1BillingDocumentsBillingDocumentIdResponses[keyof GetV1BillingDocumentsBillingDocumentIdResponses]; +export type GetV1TimeoffBalancesEmploymentIdResponse = + GetV1TimeoffBalancesEmploymentIdResponses[keyof GetV1TimeoffBalancesEmploymentIdResponses]; -export type PostV1CostCalculatorEstimationPdfData = { - /** - * Estimate params - */ - body?: CostCalculatorEstimateParams; +export type GetV1EmployeeExpensesData = { + body?: never; path?: never; query?: never; - url: '/v1/cost-calculator/estimation-pdf'; + url: '/v1/employee/expenses'; }; -export type PostV1CostCalculatorEstimationPdfErrors = { +export type GetV1EmployeeExpensesErrors = { /** - * Not Found + * Unauthorized */ - 404: NotFoundResponse; + 401: UnauthorizedResponse; /** - * Unprocessable Entity + * Forbidden */ - 422: UnprocessableEntityResponse; + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; }; -export type PostV1CostCalculatorEstimationPdfError = - PostV1CostCalculatorEstimationPdfErrors[keyof PostV1CostCalculatorEstimationPdfErrors]; +export type GetV1EmployeeExpensesError = + GetV1EmployeeExpensesErrors[keyof GetV1EmployeeExpensesErrors]; -export type PostV1CostCalculatorEstimationPdfResponses = { +export type GetV1EmployeeExpensesResponses = { /** * Success */ - 200: CostCalculatorEstimatePdfResponse; + 200: SuccessResponse; }; -export type PostV1CostCalculatorEstimationPdfResponse = - PostV1CostCalculatorEstimationPdfResponses[keyof PostV1CostCalculatorEstimationPdfResponses]; +export type GetV1EmployeeExpensesResponse = + GetV1EmployeeExpensesResponses[keyof GetV1EmployeeExpensesResponses]; -export type GetV1WorkAuthorizationRequestsIdData = { - body?: never; - path: { - /** - * work authorization request ID - */ - id: string; - }; +export type PostV1EmployeeExpensesData = { + /** + * Expense params + */ + body?: ParamsToCreateEmployeeExpense; + path?: never; query?: never; - url: '/v1/work-authorization-requests/{id}'; + url: '/v1/employee/expenses'; }; -export type GetV1WorkAuthorizationRequestsIdErrors = { +export type PostV1EmployeeExpensesErrors = { /** - * Not Found + * Bad Request */ - 404: NotFoundResponse; + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; }; -export type GetV1WorkAuthorizationRequestsIdError = - GetV1WorkAuthorizationRequestsIdErrors[keyof GetV1WorkAuthorizationRequestsIdErrors]; +export type PostV1EmployeeExpensesError = + PostV1EmployeeExpensesErrors[keyof PostV1EmployeeExpensesErrors]; -export type GetV1WorkAuthorizationRequestsIdResponses = { +export type PostV1EmployeeExpensesResponses = { /** - * Success + * Created */ - 200: WorkAuthorizationRequestResponse; + 201: SuccessResponse; }; -export type GetV1WorkAuthorizationRequestsIdResponse = - GetV1WorkAuthorizationRequestsIdResponses[keyof GetV1WorkAuthorizationRequestsIdResponses]; +export type PostV1EmployeeExpensesResponse = + PostV1EmployeeExpensesResponses[keyof PostV1EmployeeExpensesResponses]; -export type PatchV1WorkAuthorizationRequestsId2Data = { - /** - * Work Authorization Request - */ - body: UpdateWorkAuthorizationRequestParams; +export type GetV1ResignationsOffboardingRequestIdResignationLetterData = { + body?: never; path: { /** - * work authorization request ID + * Offboarding request ID */ - id: string; + offboarding_request_id: string; }; query?: never; - url: '/v1/work-authorization-requests/{id}'; + url: '/v1/resignations/{offboarding_request_id}/resignation-letter'; }; -export type PatchV1WorkAuthorizationRequestsId2Errors = { +export type GetV1ResignationsOffboardingRequestIdResignationLetterErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ @@ -15419,37 +15287,51 @@ export type PatchV1WorkAuthorizationRequestsId2Errors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type PatchV1WorkAuthorizationRequestsId2Error = - PatchV1WorkAuthorizationRequestsId2Errors[keyof PatchV1WorkAuthorizationRequestsId2Errors]; +export type GetV1ResignationsOffboardingRequestIdResignationLetterError = + GetV1ResignationsOffboardingRequestIdResignationLetterErrors[keyof GetV1ResignationsOffboardingRequestIdResignationLetterErrors]; -export type PatchV1WorkAuthorizationRequestsId2Responses = { +export type GetV1ResignationsOffboardingRequestIdResignationLetterResponses = { /** * Success */ - 200: WorkAuthorizationRequestResponse; + 200: GenericFile; }; -export type PatchV1WorkAuthorizationRequestsId2Response = - PatchV1WorkAuthorizationRequestsId2Responses[keyof PatchV1WorkAuthorizationRequestsId2Responses]; +export type GetV1ResignationsOffboardingRequestIdResignationLetterResponse = + GetV1ResignationsOffboardingRequestIdResignationLetterResponses[keyof GetV1ResignationsOffboardingRequestIdResignationLetterResponses]; -export type PatchV1WorkAuthorizationRequestsIdData = { - /** - * Work Authorization Request - */ - body: UpdateWorkAuthorizationRequestParams; +export type DeleteV1CompanyManagersUserIdData = { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * work authorization request ID + * User ID */ - id: string; + user_id: string; }; query?: never; - url: '/v1/work-authorization-requests/{id}'; + url: '/v1/company-managers/{user_id}'; }; -export type PatchV1WorkAuthorizationRequestsIdErrors = { +export type DeleteV1CompanyManagersUserIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -15462,91 +15344,86 @@ export type PatchV1WorkAuthorizationRequestsIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type PatchV1WorkAuthorizationRequestsIdError = - PatchV1WorkAuthorizationRequestsIdErrors[keyof PatchV1WorkAuthorizationRequestsIdErrors]; +export type DeleteV1CompanyManagersUserIdError = + DeleteV1CompanyManagersUserIdErrors[keyof DeleteV1CompanyManagersUserIdErrors]; -export type PatchV1WorkAuthorizationRequestsIdResponses = { +export type DeleteV1CompanyManagersUserIdResponses = { /** * Success */ - 200: WorkAuthorizationRequestResponse; + 200: SuccessResponse; }; -export type PatchV1WorkAuthorizationRequestsIdResponse = - PatchV1WorkAuthorizationRequestsIdResponses[keyof PatchV1WorkAuthorizationRequestsIdResponses]; +export type DeleteV1CompanyManagersUserIdResponse = + DeleteV1CompanyManagersUserIdResponses[keyof DeleteV1CompanyManagersUserIdResponses]; -export type PutV2EmploymentsEmploymentIdFederalTaxesData = { - /** - * Employment federal taxes params - */ - body?: EmploymentFederalTaxesParams; +export type GetV1CompanyManagersUserIdData = { + body?: never; path: { /** - * Employment ID + * User ID */ - employment_id: string; + user_id: string; }; query?: never; - url: '/v2/employments/{employment_id}/federal-taxes'; + url: '/v1/company-managers/{user_id}'; }; -export type PutV2EmploymentsEmploymentIdFederalTaxesErrors = { +export type GetV1CompanyManagersUserIdErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdFederalTaxesError = - PutV2EmploymentsEmploymentIdFederalTaxesErrors[keyof PutV2EmploymentsEmploymentIdFederalTaxesErrors]; +export type GetV1CompanyManagersUserIdError = + GetV1CompanyManagersUserIdErrors[keyof GetV1CompanyManagersUserIdErrors]; -export type PutV2EmploymentsEmploymentIdFederalTaxesResponses = { +export type GetV1CompanyManagersUserIdResponses = { /** * Success */ - 200: SuccessResponse; + 200: CompanyManagerResponse; }; -export type PutV2EmploymentsEmploymentIdFederalTaxesResponse = - PutV2EmploymentsEmploymentIdFederalTaxesResponses[keyof PutV2EmploymentsEmploymentIdFederalTaxesResponses]; +export type GetV1CompanyManagersUserIdResponse = + GetV1CompanyManagersUserIdResponses[keyof GetV1CompanyManagersUserIdResponses]; -export type PostV1ProbationExtensionsData = { - /** - * ProbationExtension - */ - body: CreateProbationExtensionParams; - path?: never; +export type GetV1EmploymentsEmploymentIdOnboardingStepsData = { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: UuidSlug; + }; query?: never; - url: '/v1/probation-extensions'; + url: '/v1/employments/{employment_id}/onboarding-steps'; }; -export type PostV1ProbationExtensionsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmploymentsEmploymentIdOnboardingStepsErrors = { /** * Unauthorized */ @@ -15555,196 +15432,170 @@ export type PostV1ProbationExtensionsErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; }; -export type PostV1ProbationExtensionsError = - PostV1ProbationExtensionsErrors[keyof PostV1ProbationExtensionsErrors]; +export type GetV1EmploymentsEmploymentIdOnboardingStepsError = + GetV1EmploymentsEmploymentIdOnboardingStepsErrors[keyof GetV1EmploymentsEmploymentIdOnboardingStepsErrors]; -export type PostV1ProbationExtensionsResponses = { +export type GetV1EmploymentsEmploymentIdOnboardingStepsResponses = { /** * Success */ - 200: ProbationExtensionResponse; + 200: EmploymentOnboardingStepsResponse; }; -export type PostV1ProbationExtensionsResponse = - PostV1ProbationExtensionsResponses[keyof PostV1ProbationExtensionsResponses]; +export type GetV1EmploymentsEmploymentIdOnboardingStepsResponse = + GetV1EmploymentsEmploymentIdOnboardingStepsResponses[keyof GetV1EmploymentsEmploymentIdOnboardingStepsResponses]; -export type PutV2EmploymentsEmploymentIdBillingAddressDetailsData = { +export type PostV1ContractAmendmentsAutomatableData = { /** - * Employment billing address details params + * Contract Amendment */ - body?: EmploymentBillingAddressDetailsParams; - path: { + body?: CreateContractAmendmentParams; + headers: { /** - * Employment ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - employment_id: string; + Authorization: string; }; + path?: never; query?: { /** - * Version of the billing_address_details form schema + * Version of the form schema */ - billing_address_details_json_schema_version?: number | 'latest'; + json_schema_version?: number | 'latest'; }; - url: '/v2/employments/{employment_id}/billing_address_details'; + url: '/v1/contract-amendments/automatable'; }; -export type PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PostV1ContractAmendmentsAutomatableErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; /** - * Conflict - */ - 409: ConflictResponse; - /** - * Unprocessable Entity + * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdBillingAddressDetailsError = - PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors[keyof PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors]; +export type PostV1ContractAmendmentsAutomatableError = + PostV1ContractAmendmentsAutomatableErrors[keyof PostV1ContractAmendmentsAutomatableErrors]; -export type PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses = { +export type PostV1ContractAmendmentsAutomatableResponses = { /** * Success */ - 200: EmploymentResponse; + 200: ContractAmendmentAutomatableResponse; }; -export type PutV2EmploymentsEmploymentIdBillingAddressDetailsResponse = - PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses[keyof PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses]; +export type PostV1ContractAmendmentsAutomatableResponse = + PostV1ContractAmendmentsAutomatableResponses[keyof PostV1ContractAmendmentsAutomatableResponses]; -export type PutV2EmploymentsEmploymentIdAddressDetailsData = { - /** - * Employment address details params - */ - body?: EmploymentAddressDetailsParams; - path: { +export type GetV1PayrollRunsData = { + body?: never; + path?: never; + query?: { /** - * Employment ID + * Filters payroll runs where period_start or period_end match the given date */ - employment_id: string; - }; - query?: { + payroll_period?: Date; /** - * Version of the address_details form schema + * Starts fetching records after the given page */ - address_details_json_schema_version?: number | 'latest'; + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - url: '/v2/employments/{employment_id}/address_details'; + url: '/v1/payroll-runs'; }; -export type PutV2EmploymentsEmploymentIdAddressDetailsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1PayrollRunsErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdAddressDetailsError = - PutV2EmploymentsEmploymentIdAddressDetailsErrors[keyof PutV2EmploymentsEmploymentIdAddressDetailsErrors]; +export type GetV1PayrollRunsError = + GetV1PayrollRunsErrors[keyof GetV1PayrollRunsErrors]; -export type PutV2EmploymentsEmploymentIdAddressDetailsResponses = { +export type GetV1PayrollRunsResponses = { /** * Success */ - 200: EmploymentResponse; + 200: ListPayrollRunResponse; }; -export type PutV2EmploymentsEmploymentIdAddressDetailsResponse = - PutV2EmploymentsEmploymentIdAddressDetailsResponses[keyof PutV2EmploymentsEmploymentIdAddressDetailsResponses]; +export type GetV1PayrollRunsResponse = + GetV1PayrollRunsResponses[keyof GetV1PayrollRunsResponses]; -export type PostV1RiskReserveData = { - /** - * Risk Reserve - */ - body: CreateRiskReserveParams; +export type GetV1EmployeeIncentivesData = { + body?: never; path?: never; query?: never; - url: '/v1/risk-reserve'; + url: '/v1/employee/incentives'; }; -export type PostV1RiskReserveErrors = { +export type GetV1EmployeeIncentivesErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: NotFoundResponse; }; -export type PostV1RiskReserveError = - PostV1RiskReserveErrors[keyof PostV1RiskReserveErrors]; +export type GetV1EmployeeIncentivesError = + GetV1EmployeeIncentivesErrors[keyof GetV1EmployeeIncentivesErrors]; -export type PostV1RiskReserveResponses = { +export type GetV1EmployeeIncentivesResponses = { /** * Success */ 200: SuccessResponse; }; -export type PostV1RiskReserveResponse = - PostV1RiskReserveResponses[keyof PostV1RiskReserveResponses]; +export type GetV1EmployeeIncentivesResponse = + GetV1EmployeeIncentivesResponses[keyof GetV1EmployeeIncentivesResponses]; -export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsData = { +export type PatchV1SandboxEmploymentsEmploymentId2Data = { /** - * Proof of Payment + * Employment params */ - body: CreateRiskReserveProofOfPaymentParams; + body?: EmploymentUpdateParams; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** * Employment ID @@ -15752,10 +15603,14 @@ export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsData = { employment_id: string; }; query?: never; - url: '/v1/employments/{employment_id}/risk-reserve-proof-of-payments'; + url: '/v1/sandbox/employments/{employment_id}'; }; -export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors = { +export type PatchV1SandboxEmploymentsEmploymentId2Errors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -15764,78 +15619,62 @@ export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; -}; - -export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsError = - PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors[keyof PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsErrors]; - -export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses = { /** - * Success + * Too many requests */ - 200: RiskReserveProofOfPaymentResponse; + 429: TooManyRequestsResponse; }; -export type PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponse = - PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses[keyof PostV1EmploymentsEmploymentIdRiskReserveProofOfPaymentsResponses]; - -export type GetV1CompaniesCompanyIdComplianceProfileData = { - body?: never; - path: { - /** - * Company ID - */ - company_id: UuidSlug; - }; - query?: never; - url: '/v1/companies/{company_id}/compliance-profile'; -}; +export type PatchV1SandboxEmploymentsEmploymentId2Error = + PatchV1SandboxEmploymentsEmploymentId2Errors[keyof PatchV1SandboxEmploymentsEmploymentId2Errors]; -export type GetV1CompaniesCompanyIdComplianceProfileErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; +export type PatchV1SandboxEmploymentsEmploymentId2Responses = { /** - * Not Found + * Success */ - 404: NotFoundResponse; + 200: EmploymentResponse; }; -export type GetV1CompaniesCompanyIdComplianceProfileError = - GetV1CompaniesCompanyIdComplianceProfileErrors[keyof GetV1CompaniesCompanyIdComplianceProfileErrors]; +export type PatchV1SandboxEmploymentsEmploymentId2Response = + PatchV1SandboxEmploymentsEmploymentId2Responses[keyof PatchV1SandboxEmploymentsEmploymentId2Responses]; -export type GetV1CompaniesCompanyIdComplianceProfileResponses = { +export type PatchV1SandboxEmploymentsEmploymentIdData = { /** - * Success + * Employment params */ - 200: CompanyComplianceProfileResponse; -}; - -export type GetV1CompaniesCompanyIdComplianceProfileResponse = - GetV1CompaniesCompanyIdComplianceProfileResponses[keyof GetV1CompaniesCompanyIdComplianceProfileResponses]; - -export type GetV1CompaniesCompanyIdProductPricesData = { - body?: never; + body?: EmploymentUpdateParams; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * Company ID + * Employment ID */ - company_id: UuidSlug; + employment_id: string; }; query?: never; - url: '/v1/companies/{company_id}/product-prices'; + url: '/v1/sandbox/employments/{employment_id}'; }; -export type GetV1CompaniesCompanyIdProductPricesErrors = { +export type PatchV1SandboxEmploymentsEmploymentIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -15844,26 +15683,34 @@ export type GetV1CompaniesCompanyIdProductPricesErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1CompaniesCompanyIdProductPricesError = - GetV1CompaniesCompanyIdProductPricesErrors[keyof GetV1CompaniesCompanyIdProductPricesErrors]; +export type PatchV1SandboxEmploymentsEmploymentIdError = + PatchV1SandboxEmploymentsEmploymentIdErrors[keyof PatchV1SandboxEmploymentsEmploymentIdErrors]; -export type GetV1CompaniesCompanyIdProductPricesResponses = { +export type PatchV1SandboxEmploymentsEmploymentIdResponses = { /** * Success */ - 200: ListProductPricesResponse; + 200: EmploymentResponse; }; -export type GetV1CompaniesCompanyIdProductPricesResponse = - GetV1CompaniesCompanyIdProductPricesResponses[keyof GetV1CompaniesCompanyIdProductPricesResponses]; +export type PatchV1SandboxEmploymentsEmploymentIdResponse = + PatchV1SandboxEmploymentsEmploymentIdResponses[keyof PatchV1SandboxEmploymentsEmploymentIdResponses]; -export type GetV1CompaniesCompanyIdData = { +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaData = { body?: never; headers: { /** @@ -15876,19 +15723,20 @@ export type GetV1CompaniesCompanyIdData = { }; path: { /** - * Company ID + * Benefit Renewal Request Id */ - company_id: string; + benefit_renewal_request_id: UuidSlug; }; - query?: never; - url: '/v1/companies/{company_id}'; + query?: { + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; + }; + url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}/schema'; }; -export type GetV1CompaniesCompanyIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors = { /** * Unauthorized */ @@ -15901,60 +15749,43 @@ export type GetV1CompaniesCompanyIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type GetV1CompaniesCompanyIdError = - GetV1CompaniesCompanyIdErrors[keyof GetV1CompaniesCompanyIdErrors]; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaError = + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaErrors]; -export type GetV1CompaniesCompanyIdResponses = { - /** - * Success - */ - 200: CompanyResponse; -}; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses = + { + /** + * Success + */ + 200: BenefitRenewalRequestsBenefitRenewalRequestFormResponse; + }; -export type GetV1CompaniesCompanyIdResponse = - GetV1CompaniesCompanyIdResponses[keyof GetV1CompaniesCompanyIdResponses]; +export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponse = + GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdSchemaResponses]; -export type PatchV1CompaniesCompanyId2Data = { +export type PutV2EmploymentsEmploymentIdBillingAddressDetailsData = { /** - * Update Company params + * Employment billing address details params */ - body?: UpdateCompanyParams; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; + body?: EmploymentBillingAddressDetailsParams; path: { /** - * Company ID - * + * Employment ID */ - company_id: string; + employment_id: string; }; query?: { /** - * Version of the address_details form schema - */ - address_details_json_schema_version?: number | 'latest'; - /** - * Version of the bank_account_details form schema + * Version of the billing_address_details form schema */ - bank_account_details_json_schema_version?: number | 'latest'; + billing_address_details_json_schema_version?: number | 'latest'; }; - url: '/v1/companies/{company_id}'; + url: '/v2/employments/{employment_id}/billing_address_details'; }; -export type PatchV1CompaniesCompanyId2Errors = { +export type PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors = { /** * Bad Request */ @@ -15963,38 +15794,43 @@ export type PatchV1CompaniesCompanyId2Errors = { * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type PatchV1CompaniesCompanyId2Error = - PatchV1CompaniesCompanyId2Errors[keyof PatchV1CompaniesCompanyId2Errors]; +export type PutV2EmploymentsEmploymentIdBillingAddressDetailsError = + PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors[keyof PutV2EmploymentsEmploymentIdBillingAddressDetailsErrors]; -export type PatchV1CompaniesCompanyId2Responses = { +export type PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses = { /** * Success */ - 200: CompanyResponse; + 200: EmploymentResponse; }; -export type PatchV1CompaniesCompanyId2Response = - PatchV1CompaniesCompanyId2Responses[keyof PatchV1CompaniesCompanyId2Responses]; +export type PutV2EmploymentsEmploymentIdBillingAddressDetailsResponse = + PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses[keyof PutV2EmploymentsEmploymentIdBillingAddressDetailsResponses]; -export type PatchV1CompaniesCompanyIdData = { - /** - * Update Company params - */ - body?: UpdateCompanyParams; +export type DeleteV1IncentivesIdData = { + body?: never; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -16006,25 +15842,15 @@ export type PatchV1CompaniesCompanyIdData = { }; path: { /** - * Company ID - * - */ - company_id: string; - }; - query?: { - /** - * Version of the address_details form schema - */ - address_details_json_schema_version?: number | 'latest'; - /** - * Version of the bank_account_details form schema + * Incentive ID */ - bank_account_details_json_schema_version?: number | 'latest'; + id: string; }; - url: '/v1/companies/{company_id}'; + query?: never; + url: '/v1/incentives/{id}'; }; -export type PatchV1CompaniesCompanyIdErrors = { +export type DeleteV1IncentivesIdErrors = { /** * Bad Request */ @@ -16037,6 +15863,10 @@ export type PatchV1CompaniesCompanyIdErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ @@ -16047,32 +15877,41 @@ export type PatchV1CompaniesCompanyIdErrors = { 429: TooManyRequestsResponse; }; -export type PatchV1CompaniesCompanyIdError = - PatchV1CompaniesCompanyIdErrors[keyof PatchV1CompaniesCompanyIdErrors]; +export type DeleteV1IncentivesIdError = + DeleteV1IncentivesIdErrors[keyof DeleteV1IncentivesIdErrors]; -export type PatchV1CompaniesCompanyIdResponses = { +export type DeleteV1IncentivesIdResponses = { /** * Success */ - 200: CompanyResponse; + 200: SuccessResponse; }; -export type PatchV1CompaniesCompanyIdResponse = - PatchV1CompaniesCompanyIdResponses[keyof PatchV1CompaniesCompanyIdResponses]; +export type DeleteV1IncentivesIdResponse = + DeleteV1IncentivesIdResponses[keyof DeleteV1IncentivesIdResponses]; -export type GetV1ResignationsOffboardingRequestIdResignationLetterData = { +export type GetV1IncentivesIdData = { body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * Offboarding request ID + * Incentive ID */ - offboarding_request_id: string; + id: string; }; query?: never; - url: '/v1/resignations/{offboarding_request_id}/resignation-letter'; + url: '/v1/incentives/{id}'; }; -export type GetV1ResignationsOffboardingRequestIdResignationLetterErrors = { +export type GetV1IncentivesIdErrors = { /** * Bad Request */ @@ -16081,10 +15920,6 @@ export type GetV1ResignationsOffboardingRequestIdResignationLetterErrors = { * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -16094,48 +15929,57 @@ export type GetV1ResignationsOffboardingRequestIdResignationLetterErrors = { */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type GetV1ResignationsOffboardingRequestIdResignationLetterError = - GetV1ResignationsOffboardingRequestIdResignationLetterErrors[keyof GetV1ResignationsOffboardingRequestIdResignationLetterErrors]; +export type GetV1IncentivesIdError = + GetV1IncentivesIdErrors[keyof GetV1IncentivesIdErrors]; -export type GetV1ResignationsOffboardingRequestIdResignationLetterResponses = { +export type GetV1IncentivesIdResponses = { /** * Success */ - 200: GenericFile; + 200: IncentiveResponse; }; -export type GetV1ResignationsOffboardingRequestIdResignationLetterResponse = - GetV1ResignationsOffboardingRequestIdResignationLetterResponses[keyof GetV1ResignationsOffboardingRequestIdResignationLetterResponses]; +export type GetV1IncentivesIdResponse = + GetV1IncentivesIdResponses[keyof GetV1IncentivesIdResponses]; -export type PutV1EmploymentsEmploymentIdFederalTaxesData = { +export type PatchV1IncentivesId2Data = { /** - * Employment federal taxes params + * Incentive */ - body?: EmploymentFederalTaxesParams; + body?: UpdateIncentiveParams; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * Employment ID + * Incentive ID */ - employment_id: string; + id: string; }; query?: never; - url: '/v1/employments/{employment_id}/federal-taxes'; + url: '/v1/incentives/{id}'; }; -export type PutV1EmploymentsEmploymentIdFederalTaxesErrors = { +export type PatchV1IncentivesId2Errors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ @@ -16149,26 +15993,29 @@ export type PutV1EmploymentsEmploymentIdFederalTaxesErrors = { */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PutV1EmploymentsEmploymentIdFederalTaxesError = - PutV1EmploymentsEmploymentIdFederalTaxesErrors[keyof PutV1EmploymentsEmploymentIdFederalTaxesErrors]; +export type PatchV1IncentivesId2Error = + PatchV1IncentivesId2Errors[keyof PatchV1IncentivesId2Errors]; -export type PutV1EmploymentsEmploymentIdFederalTaxesResponses = { +export type PatchV1IncentivesId2Responses = { /** * Success */ - 200: SuccessResponse; + 200: IncentiveResponse; }; -export type PutV1EmploymentsEmploymentIdFederalTaxesResponse = - PutV1EmploymentsEmploymentIdFederalTaxesResponses[keyof PutV1EmploymentsEmploymentIdFederalTaxesResponses]; +export type PatchV1IncentivesId2Response = + PatchV1IncentivesId2Responses[keyof PatchV1IncentivesId2Responses]; -export type GetV1ContractAmendmentsData = { - body?: never; +export type PatchV1IncentivesIdData = { + /** + * Incentive + */ + body?: UpdateIncentiveParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -16178,29 +16025,21 @@ export type GetV1ContractAmendmentsData = { */ Authorization: string; }; - path?: never; - query?: { - /** - * Employment ID - */ - employment_id?: string; - /** - * Contract Amendment status - */ - status?: ContractAmendmentStatus; - /** - * Starts fetching records after the given page - */ - page?: number; + path: { /** - * Number of items per page + * Incentive ID */ - page_size?: number; + id: string; }; - url: '/v1/contract-amendments'; + query?: never; + url: '/v1/incentives/{id}'; }; -export type GetV1ContractAmendmentsErrors = { +export type PatchV1IncentivesIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -16209,31 +16048,771 @@ export type GetV1ContractAmendmentsErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1ContractAmendmentsError = - GetV1ContractAmendmentsErrors[keyof GetV1ContractAmendmentsErrors]; +export type PatchV1IncentivesIdError = + PatchV1IncentivesIdErrors[keyof PatchV1IncentivesIdErrors]; -export type GetV1ContractAmendmentsResponses = { +export type PatchV1IncentivesIdResponses = { /** * Success */ - 200: ListContractAmendmentResponse; + 200: IncentiveResponse; }; -export type GetV1ContractAmendmentsResponse = - GetV1ContractAmendmentsResponses[keyof GetV1ContractAmendmentsResponses]; +export type PatchV1IncentivesIdResponse = + PatchV1IncentivesIdResponses[keyof PatchV1IncentivesIdResponses]; -export type PostV1ContractAmendmentsData = { - /** - * Contract Amendment - */ - body?: CreateContractAmendmentParams; - headers: { +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData = + { + body?: never; + path: { + /** + * Company ID + */ + company_id: UuidSlug; + /** + * Legal entity ID + */ + legal_entity_id: UuidSlug; + }; + query?: never; + url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details'; + }; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors = + { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + }; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsError = + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors]; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses = + { + /** + * ShowLegalEntityAdministrativeDetailsResponse + * + * Country specific json schema driven administrative details for legal entities + */ + 200: { + data: { + [key: string]: unknown; + }; + }; + }; + +export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponse = + GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses]; + +export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData = + { + /** + * Legal entity administrative details params + */ + body?: AdministrativeDetailsParams; + path: { + /** + * Company ID + */ + company_id: UuidSlug; + /** + * Legal entity ID + */ + legal_entity_id: UuidSlug; + }; + query?: never; + url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details'; + }; + +export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors = + { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; + }; + +export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsError = + PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors[keyof PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors]; + +export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses = + { + /** + * ShowLegalEntityAdministrativeDetailsResponse + * + * Country specific json schema driven administrative details for legal entities + */ + 200: { + data: { + [key: string]: unknown; + }; + }; + }; + +export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponse = + PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses[keyof PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses]; + +export type PutV2EmploymentsEmploymentIdBankAccountDetailsData = { + /** + * Employment bank account details params + */ + body?: EmploymentBankAccountDetailsParams; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: { + /** + * Version of the bank_account_details form schema + */ + bank_account_details_json_schema_version?: number | 'latest'; + }; + url: '/v2/employments/{employment_id}/bank_account_details'; +}; + +export type PutV2EmploymentsEmploymentIdBankAccountDetailsErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; +}; + +export type PutV2EmploymentsEmploymentIdBankAccountDetailsError = + PutV2EmploymentsEmploymentIdBankAccountDetailsErrors[keyof PutV2EmploymentsEmploymentIdBankAccountDetailsErrors]; + +export type PutV2EmploymentsEmploymentIdBankAccountDetailsResponses = { + /** + * Success + */ + 200: EmploymentResponse; +}; + +export type PutV2EmploymentsEmploymentIdBankAccountDetailsResponse = + PutV2EmploymentsEmploymentIdBankAccountDetailsResponses[keyof PutV2EmploymentsEmploymentIdBankAccountDetailsResponses]; + +export type GetV1ContractorInvoicesData = { + body?: never; + path?: never; + query?: { + /** + * Filters contractor invoices by status matching the value. + */ + status?: ContractorInvoiceStatus; + /** + * Filters contractor invoices by invoice schedule ID matching the value. + */ + contractor_invoice_schedule_id?: UuidSlug; + /** + * Filters contractor invoices by date greater than or equal to the value. + */ + date_from?: Date; + /** + * Filters contractor invoices by date less than or equal to the value. + */ + date_to?: Date; + /** + * Filters contractor invoices by due date greater than or equal to the value. + */ + due_date_from?: Date; + /** + * Filters contractor invoices by due date less than or equal to the value. + */ + due_date_to?: Date; + /** + * Filters contractor invoices by approved date greater than or equal to the value. + */ + approved_date_from?: Date; + /** + * Filters contractor invoices by approved date less than or equal to the value. + */ + approved_date_to?: Date; + /** + * Filters contractor invoices by paid out date greater than or equal to the value. + */ + paid_out_date_from?: Date; + /** + * Filters contractor invoices by paid out date less than or equal to the value. + */ + paid_out_date_to?: Date; + /** + * Field to sort by + */ + sort_by?: 'date' | 'due_date' | 'approved_at' | 'paid_out_at'; + /** + * Sort order + */ + order?: 'asc' | 'desc'; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/contractor-invoices'; +}; + +export type GetV1ContractorInvoicesErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type GetV1ContractorInvoicesError = + GetV1ContractorInvoicesErrors[keyof GetV1ContractorInvoicesErrors]; + +export type GetV1ContractorInvoicesResponses = { + /** + * Success + */ + 200: ListContractorInvoicesResponse; +}; + +export type GetV1ContractorInvoicesResponse = + GetV1ContractorInvoicesResponses[keyof GetV1ContractorInvoicesResponses]; + +export type GetV1ExpensesCategoriesData = { + body?: never; + path?: never; + query?: { + /** + * The employment ID for which to list categories. Required if neither expense_id nor country_code is provided. + */ + employment_id?: string; + /** + * The expense ID for which to list categories (includes the expense's category, even if it is not selectable by default). If provided without employment_id, will use the expense's employment context. + */ + expense_id?: string; + /** + * Include un-selectable intermediate categories in the response + */ + include_parents?: boolean; + /** + * Filter categories by country (ISO 3166-1 alpha-3 code, e.g. "GBR"). Only used when neither employment_id nor expense_id is provided. + */ + country_code?: string; + }; + url: '/v1/expenses/categories'; +}; + +export type GetV1ExpensesCategoriesErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; +}; + +export type GetV1ExpensesCategoriesError = + GetV1ExpensesCategoriesErrors[keyof GetV1ExpensesCategoriesErrors]; + +export type GetV1ExpensesCategoriesResponses = { + /** + * Success + */ + 200: ListExpenseCategoriesResponse; +}; + +export type GetV1ExpensesCategoriesResponse = + GetV1ExpensesCategoriesResponses[keyof GetV1ExpensesCategoriesResponses]; + +export type GetV1EmploymentsEmploymentIdContractDocumentsData = { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: { + /** + * Filter by contract document statuses + */ + statuses?: Array; + /** + * Exclude contract documents with specific statuses + */ + except_statuses?: Array; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/employments/{employment_id}/contract-documents'; +}; + +export type GetV1EmploymentsEmploymentIdContractDocumentsErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type GetV1EmploymentsEmploymentIdContractDocumentsError = + GetV1EmploymentsEmploymentIdContractDocumentsErrors[keyof GetV1EmploymentsEmploymentIdContractDocumentsErrors]; + +export type GetV1EmploymentsEmploymentIdContractDocumentsResponses = { + /** + * Success + */ + 200: IndexContractDocumentsResponse; +}; + +export type GetV1EmploymentsEmploymentIdContractDocumentsResponse = + GetV1EmploymentsEmploymentIdContractDocumentsResponses[keyof GetV1EmploymentsEmploymentIdContractDocumentsResponses]; + +export type GetV1CountriesCountryCodeContractorContractDetailsData = { + body?: never; + path: { + /** + * Country code according to ISO 3-digit alphabetic codes + */ + country_code: string; + }; + query?: { + /** + * Employment ID + */ + employment_id?: string; + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; + }; + url: '/v1/countries/{country_code}/contractor-contract-details'; +}; + +export type GetV1CountriesCountryCodeContractorContractDetailsErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; +}; + +export type GetV1CountriesCountryCodeContractorContractDetailsError = + GetV1CountriesCountryCodeContractorContractDetailsErrors[keyof GetV1CountriesCountryCodeContractorContractDetailsErrors]; + +export type GetV1CountriesCountryCodeContractorContractDetailsResponses = { + /** + * Success + */ + 200: ContractorContractDetailsResponse; +}; + +export type GetV1CountriesCountryCodeContractorContractDetailsResponse = + GetV1CountriesCountryCodeContractorContractDetailsResponses[keyof GetV1CountriesCountryCodeContractorContractDetailsResponses]; + +export type GetV1ScimV2UsersIdData = { + body?: never; + path: { + /** + * User ID (slug) + */ + id: string; + }; + query?: never; + url: '/v1/scim/v2/Users/{id}'; +}; + +export type GetV1ScimV2UsersIdErrors = { + /** + * Unauthorized + */ + 401: IntegrationsScimErrorResponse; + /** + * Forbidden + */ + 403: IntegrationsScimErrorResponse; + /** + * Not Found + */ + 404: IntegrationsScimErrorResponse; +}; + +export type GetV1ScimV2UsersIdError = + GetV1ScimV2UsersIdErrors[keyof GetV1ScimV2UsersIdErrors]; + +export type GetV1ScimV2UsersIdResponses = { + /** + * Success + */ + 200: IntegrationsScimUser; +}; + +export type GetV1ScimV2UsersIdResponse = + GetV1ScimV2UsersIdResponses[keyof GetV1ScimV2UsersIdResponses]; + +export type GetV1EmploymentsEmploymentIdFilesData = { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: { + /** + * Filter by file type (optional) + */ + type?: string; + /** + * Filter by file sub_type (optional) + */ + sub_type?: string; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/employments/{employment_id}/files'; +}; + +export type GetV1EmploymentsEmploymentIdFilesErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type GetV1EmploymentsEmploymentIdFilesError = + GetV1EmploymentsEmploymentIdFilesErrors[keyof GetV1EmploymentsEmploymentIdFilesErrors]; + +export type GetV1EmploymentsEmploymentIdFilesResponses = { + /** + * Success + */ + 200: ListFilesResponse; +}; + +export type GetV1EmploymentsEmploymentIdFilesResponse = + GetV1EmploymentsEmploymentIdFilesResponses[keyof GetV1EmploymentsEmploymentIdFilesResponses]; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionData = + { + /** + * Manage Contractor Plus subscription params + */ + body: ManageContractorPlusSubscriptionOperationsParams; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/contractor-plus-subscription'; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors = + { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionError = + PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors]; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses = + { + /** + * Success + */ + 200: SuccessResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponse = + PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses]; + +export type PostV1ContractorsEligibilityQuestionnaireData = { + /** + * Eligibility questionnaire submission + */ + body: SubmitEligibilityQuestionnaireRequest; + path?: never; + query?: { + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; + }; + url: '/v1/contractors/eligibility-questionnaire'; +}; + +export type PostV1ContractorsEligibilityQuestionnaireErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Conflict + */ + 409: ConflictErrorResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type PostV1ContractorsEligibilityQuestionnaireError = + PostV1ContractorsEligibilityQuestionnaireErrors[keyof PostV1ContractorsEligibilityQuestionnaireErrors]; + +export type PostV1ContractorsEligibilityQuestionnaireResponses = { + /** + * Questionnaire submitted successfully + */ + 201: EligibilityQuestionnaireResponse; +}; + +export type PostV1ContractorsEligibilityQuestionnaireResponse = + PostV1ContractorsEligibilityQuestionnaireResponses[keyof PostV1ContractorsEligibilityQuestionnaireResponses]; + +export type PutV1EmploymentsEmploymentIdBasicInformationData = { + /** + * Employment basic information params + */ + body?: EmploymentBasicInformationParams; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/employments/{employment_id}/basic_information'; +}; + +export type PutV1EmploymentsEmploymentIdBasicInformationErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Conflict + */ + 409: ConflictResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; +}; + +export type PutV1EmploymentsEmploymentIdBasicInformationError = + PutV1EmploymentsEmploymentIdBasicInformationErrors[keyof PutV1EmploymentsEmploymentIdBasicInformationErrors]; + +export type PutV1EmploymentsEmploymentIdBasicInformationResponses = { + /** + * Success + */ + 200: EmploymentResponse; +}; + +export type PutV1EmploymentsEmploymentIdBasicInformationResponse = + PutV1EmploymentsEmploymentIdBasicInformationResponses[keyof PutV1EmploymentsEmploymentIdBasicInformationResponses]; + +export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdData = + { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + /** + * Termination Request ID + */ + termination_request_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/cor-termination-requests/{termination_request_id}'; + }; + +export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors = + { + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + }; + +export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdError = + GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors[keyof GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors]; + +export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses = + { + /** + * Success + */ + 200: CorTerminationRequestResponse; + }; + +export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponse = + GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses[keyof GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses]; + +export type PostV1SandboxCompaniesCompanyIdLegalEntitiesData = { + /** + * Create legal entity params + */ + body?: { + /** + * ISO 3166-1 alpha-3 country code + */ + country_code: string; + }; + headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. * @@ -16242,17 +16821,21 @@ export type PostV1ContractAmendmentsData = { */ Authorization: string; }; - path?: never; - query?: { + path: { /** - * Version of the form schema + * Company ID */ - json_schema_version?: number | 'latest'; + company_id: string; }; - url: '/v1/contract-amendments'; + query?: never; + url: '/v1/sandbox/companies/{company_id}/legal-entities'; }; -export type PostV1ContractAmendmentsErrors = { +export type PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -16265,34 +16848,205 @@ export type PostV1ContractAmendmentsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type PostV1ContractAmendmentsError = - PostV1ContractAmendmentsErrors[keyof PostV1ContractAmendmentsErrors]; +export type PostV1SandboxCompaniesCompanyIdLegalEntitiesError = + PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors[keyof PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors]; -export type PostV1ContractAmendmentsResponses = { +export type PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses = { + /** + * Legal entity created + */ + 201: { + data?: { + /** + * Legal entity slug + */ + legal_entity_id?: string; + /** + * Legal entity name + */ + name?: string; + /** + * Legal entity status + */ + status?: string; + }; + }; +}; + +export type PostV1SandboxCompaniesCompanyIdLegalEntitiesResponse = + PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses[keyof PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses]; + +export type GetV1WdGphPayDetailDataData = { + body?: never; + headers?: { + /** + * The preferred language of the inquiring user in Workday + */ + accept_language?: string; + }; + path?: never; + query: { + /** + * The pay group ID for identifying the pay group at the vendor system + */ + payGroupExternalId: string; + /** + * The run type id provided in the paySummary API + */ + runTypeId: string; + /** + * The cycle type id, defaults to the main run if not provided + */ + cycleTypeId?: string; + /** + * The period end date in question, defaults to current period if not provided + */ + periodEndDate?: Date; + }; + url: '/v1/wd/gph/payDetailData'; +}; + +export type GetV1WdGphPayDetailDataErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; +}; + +export type GetV1WdGphPayDetailDataError = + GetV1WdGphPayDetailDataErrors[keyof GetV1WdGphPayDetailDataErrors]; + +export type GetV1WdGphPayDetailDataResponses = { /** * Success */ - 200: ContractAmendmentResponse; + 200: PayDetailDataResponse; }; -export type PostV1ContractAmendmentsResponse = - PostV1ContractAmendmentsResponses[keyof PostV1ContractAmendmentsResponses]; +export type GetV1WdGphPayDetailDataResponse = + GetV1WdGphPayDetailDataResponses[keyof GetV1WdGphPayDetailDataResponses]; -export type GetV1PayrollRunsPayrollRunIdData = { +export type GetV1CostCalculatorRegionsSlugFieldsData = { body?: never; path: { /** - * Payroll run ID + * Slug */ - payroll_run_id: string; + slug: string; + }; + query?: { + /** + * If the premium benefits should be included in the response + */ + include_premium_benefits?: boolean; + }; + url: '/v1/cost-calculator/regions/{slug}/fields'; +}; + +export type GetV1CostCalculatorRegionsSlugFieldsErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Internal Server Error + */ + 500: InternalServerErrorResponse; +}; + +export type GetV1CostCalculatorRegionsSlugFieldsError = + GetV1CostCalculatorRegionsSlugFieldsErrors[keyof GetV1CostCalculatorRegionsSlugFieldsErrors]; + +export type GetV1CostCalculatorRegionsSlugFieldsResponses = { + /** + * Success + */ + 200: JsonSchemaResponse; +}; + +export type GetV1CostCalculatorRegionsSlugFieldsResponse = + GetV1CostCalculatorRegionsSlugFieldsResponses[keyof GetV1CostCalculatorRegionsSlugFieldsResponses]; + +export type PostV1CancelOnboardingEmploymentIdData = { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: { + /** + * Whether the request should be performed async + * + */ + async?: boolean; + }; + url: '/v1/cancel-onboarding/{employment_id}'; +}; + +export type PostV1CancelOnboardingEmploymentIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; +}; + +export type PostV1CancelOnboardingEmploymentIdError = + PostV1CancelOnboardingEmploymentIdErrors[keyof PostV1CancelOnboardingEmploymentIdErrors]; + +export type PostV1CancelOnboardingEmploymentIdResponses = { + /** + * Success + */ + 200: SuccessResponse; +}; + +export type PostV1CancelOnboardingEmploymentIdResponse = + PostV1CancelOnboardingEmploymentIdResponses[keyof PostV1CancelOnboardingEmploymentIdResponses]; + +export type PostV1EmployeeTimeoffIdCancelData = { + /** + * CancelTimeoff + */ + body: CancelTimeoffParams; + path: { + /** + * Timeoff ID + */ + id: string; }; query?: never; - url: '/v1/payroll-runs/{payroll_run_id}'; + url: '/v1/employee/timeoff/{id}/cancel'; }; -export type GetV1PayrollRunsPayrollRunIdErrors = { +export type PostV1EmployeeTimeoffIdCancelErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -16305,20 +17059,24 @@ export type GetV1PayrollRunsPayrollRunIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1PayrollRunsPayrollRunIdError = - GetV1PayrollRunsPayrollRunIdErrors[keyof GetV1PayrollRunsPayrollRunIdErrors]; +export type PostV1EmployeeTimeoffIdCancelError = + PostV1EmployeeTimeoffIdCancelErrors[keyof PostV1EmployeeTimeoffIdCancelErrors]; -export type GetV1PayrollRunsPayrollRunIdResponses = { +export type PostV1EmployeeTimeoffIdCancelResponses = { /** * Success */ - 200: PayrollRunResponse; + 200: TimeoffResponse; }; -export type GetV1PayrollRunsPayrollRunIdResponse = - GetV1PayrollRunsPayrollRunIdResponses[keyof GetV1PayrollRunsPayrollRunIdResponses]; +export type PostV1EmployeeTimeoffIdCancelResponse = + PostV1EmployeeTimeoffIdCancelResponses[keyof PostV1EmployeeTimeoffIdCancelResponses]; export type GetV1ExpensesExpenseIdReceiptData = { body?: never; @@ -16372,23 +17130,23 @@ export type GetV1ExpensesExpenseIdReceiptResponses = { export type GetV1ExpensesExpenseIdReceiptResponse = GetV1ExpensesExpenseIdReceiptResponses[keyof GetV1ExpensesExpenseIdReceiptResponses]; -export type GetV1TravelLetterRequestsIdData = { +export type GetV1BenefitOffersCountrySummariesData = { body?: never; - path: { + headers: { /** - * travel letter request ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - id: UuidSlug; + Authorization: string; }; + path?: never; query?: never; - url: '/v1/travel-letter-requests/{id}'; + url: '/v1/benefit-offers/country-summaries'; }; -export type GetV1TravelLetterRequestsIdErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; +export type GetV1BenefitOffersCountrySummariesErrors = { /** * Not Found */ @@ -16399,35 +17157,32 @@ export type GetV1TravelLetterRequestsIdErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1TravelLetterRequestsIdError = - GetV1TravelLetterRequestsIdErrors[keyof GetV1TravelLetterRequestsIdErrors]; +export type GetV1BenefitOffersCountrySummariesError = + GetV1BenefitOffersCountrySummariesErrors[keyof GetV1BenefitOffersCountrySummariesErrors]; -export type GetV1TravelLetterRequestsIdResponses = { +export type GetV1BenefitOffersCountrySummariesResponses = { /** * Success */ - 200: TravelLetterResponse; + 200: CountrySummariesResponse; }; -export type GetV1TravelLetterRequestsIdResponse = - GetV1TravelLetterRequestsIdResponses[keyof GetV1TravelLetterRequestsIdResponses]; +export type GetV1BenefitOffersCountrySummariesResponse = + GetV1BenefitOffersCountrySummariesResponses[keyof GetV1BenefitOffersCountrySummariesResponses]; -export type PatchV1TravelLetterRequestsId2Data = { - /** - * Travel letter Request - */ - body: UpdateTravelLetterRequestParams; +export type GetV1LeavePoliciesDetailsEmploymentIdData = { + body?: never; path: { /** - * Travel letter Request ID + * Employment ID */ - id: string; + employment_id: string; }; query?: never; - url: '/v1/travel-letter-requests/{id}'; + url: '/v1/leave-policies/details/{employment_id}'; }; -export type PatchV1TravelLetterRequestsId2Errors = { +export type GetV1LeavePoliciesDetailsEmploymentIdErrors = { /** * Unauthorized */ @@ -16442,39 +17197,62 @@ export type PatchV1TravelLetterRequestsId2Errors = { 422: UnprocessableEntityResponse; }; -export type PatchV1TravelLetterRequestsId2Error = - PatchV1TravelLetterRequestsId2Errors[keyof PatchV1TravelLetterRequestsId2Errors]; +export type GetV1LeavePoliciesDetailsEmploymentIdError = + GetV1LeavePoliciesDetailsEmploymentIdErrors[keyof GetV1LeavePoliciesDetailsEmploymentIdErrors]; -export type PatchV1TravelLetterRequestsId2Responses = { +export type GetV1LeavePoliciesDetailsEmploymentIdResponses = { /** * Success */ - 200: TravelLetterResponse; + 200: ListLeavePoliciesDetailsResponse; }; -export type PatchV1TravelLetterRequestsId2Response = - PatchV1TravelLetterRequestsId2Responses[keyof PatchV1TravelLetterRequestsId2Responses]; +export type GetV1LeavePoliciesDetailsEmploymentIdResponse = + GetV1LeavePoliciesDetailsEmploymentIdResponses[keyof GetV1LeavePoliciesDetailsEmploymentIdResponses]; -export type PatchV1TravelLetterRequestsIdData = { - /** - * Travel letter Request - */ - body: UpdateTravelLetterRequestParams; - path: { +export type GetV1WorkAuthorizationRequestsData = { + body?: never; + path?: never; + query?: { /** - * Travel letter Request ID + * Filter results on the given status */ - id: string; + status?: + | 'pending' + | 'cancelled' + | 'declined_by_manager' + | 'declined_by_remote' + | 'approved_by_manager' + | 'approved_by_remote'; + /** + * Filter results on the given employment slug + */ + employment_id?: string; + /** + * Filter results on the given employee name + */ + employee_name?: string; + /** + * Sort order + */ + order?: 'asc' | 'desc'; + /** + * Field to sort by + */ + sort_by?: 'submitted_at'; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - query?: never; - url: '/v1/travel-letter-requests/{id}'; + url: '/v1/work-authorization-requests'; }; -export type PatchV1TravelLetterRequestsIdErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; +export type GetV1WorkAuthorizationRequestsErrors = { /** * Not Found */ @@ -16485,160 +17263,101 @@ export type PatchV1TravelLetterRequestsIdErrors = { 422: UnprocessableEntityResponse; }; -export type PatchV1TravelLetterRequestsIdError = - PatchV1TravelLetterRequestsIdErrors[keyof PatchV1TravelLetterRequestsIdErrors]; +export type GetV1WorkAuthorizationRequestsError = + GetV1WorkAuthorizationRequestsErrors[keyof GetV1WorkAuthorizationRequestsErrors]; -export type PatchV1TravelLetterRequestsIdResponses = { +export type GetV1WorkAuthorizationRequestsResponses = { /** * Success */ - 200: TravelLetterResponse; + 200: ListWorkAuthorizationRequestsResponse; }; -export type PatchV1TravelLetterRequestsIdResponse = - PatchV1TravelLetterRequestsIdResponses[keyof PatchV1TravelLetterRequestsIdResponses]; +export type GetV1WorkAuthorizationRequestsResponse = + GetV1WorkAuthorizationRequestsResponses[keyof GetV1WorkAuthorizationRequestsResponses]; -export type GetV1TimeoffBalancesEmploymentIdData = { +export type GetV1EmploymentsEmploymentIdBenefitOffersData = { body?: never; - headers: { + path: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Unique identifier of the employment */ - Authorization: string; + employment_id: UuidSlug; }; - path: { + query?: { /** - * Employment ID for which to show the time off balance + * Starts fetching records after the given page */ - employment_id: string; + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - query?: never; - url: '/v1/timeoff-balances/{employment_id}'; + url: '/v1/employments/{employment_id}/benefit-offers'; }; -export type GetV1TimeoffBalancesEmploymentIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmploymentsEmploymentIdBenefitOffersErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * TimeoffBalanceNotFoundResponse + * Forbidden */ - 404: TimeoffBalanceNotFoundResponse; + 403: ForbiddenResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: NotFoundResponse; /** - * Too many requests + * Unprocessable Entity */ - 429: TooManyRequestsResponse; + 422: UnprocessableEntityResponse; }; -export type GetV1TimeoffBalancesEmploymentIdError = - GetV1TimeoffBalancesEmploymentIdErrors[keyof GetV1TimeoffBalancesEmploymentIdErrors]; +export type GetV1EmploymentsEmploymentIdBenefitOffersError = + GetV1EmploymentsEmploymentIdBenefitOffersErrors[keyof GetV1EmploymentsEmploymentIdBenefitOffersErrors]; -export type GetV1TimeoffBalancesEmploymentIdResponses = { +export type GetV1EmploymentsEmploymentIdBenefitOffersResponses = { /** * Success */ - 200: TimeoffBalanceResponse; + 200: EmploymentsBenefitOffersListBenefitOffers; }; -export type GetV1TimeoffBalancesEmploymentIdResponse = - GetV1TimeoffBalancesEmploymentIdResponses[keyof GetV1TimeoffBalancesEmploymentIdResponses]; +export type GetV1EmploymentsEmploymentIdBenefitOffersResponse = + GetV1EmploymentsEmploymentIdBenefitOffersResponses[keyof GetV1EmploymentsEmploymentIdBenefitOffersResponses]; -export type PutV1EmploymentsEmploymentIdBasicInformationData = { +export type PutV1EmploymentsEmploymentIdBenefitOffersData = { /** - * Employment basic information params + * Upsert employment benefit offers request */ - body?: EmploymentBasicInformationParams; + body: UnifiedEmploymentUpsertBenefitOffersRequest; path: { /** - * Employment ID + * Unique identifier of the employment */ - employment_id: string; + employment_id: UuidSlug; }; - query?: never; - url: '/v1/employments/{employment_id}/basic_information'; -}; - -export type PutV1EmploymentsEmploymentIdBasicInformationErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Conflict - */ - 409: ConflictResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; -}; - -export type PutV1EmploymentsEmploymentIdBasicInformationError = - PutV1EmploymentsEmploymentIdBasicInformationErrors[keyof PutV1EmploymentsEmploymentIdBasicInformationErrors]; - -export type PutV1EmploymentsEmploymentIdBasicInformationResponses = { - /** - * Success - */ - 200: EmploymentResponse; -}; - -export type PutV1EmploymentsEmploymentIdBasicInformationResponse = - PutV1EmploymentsEmploymentIdBasicInformationResponses[keyof PutV1EmploymentsEmploymentIdBasicInformationResponses]; - -export type GetV1ExpensesCategoriesData = { - body?: never; - path?: never; query?: { /** - * The employment ID for which to list categories. Required if neither expense_id nor country_code is provided. - */ - employment_id?: string; - /** - * The expense ID for which to list categories (includes the expense's category, even if it is not selectable by default). If provided without employment_id, will use the expense's employment context. - */ - expense_id?: string; - /** - * Include un-selectable intermediate categories in the response - */ - include_parents?: boolean; - /** - * Filter categories by country (ISO 3166-1 alpha-3 code, e.g. "GBR"). Only used when neither employment_id nor expense_id is provided. + * Version of the form schema */ - country_code?: string; + json_schema_version?: number | 'latest'; }; - url: '/v1/expenses/categories'; + url: '/v1/employments/{employment_id}/benefit-offers'; }; - -export type GetV1ExpensesCategoriesErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; + +export type PutV1EmploymentsEmploymentIdBenefitOffersErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ @@ -16647,53 +17366,88 @@ export type GetV1ExpensesCategoriesErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type GetV1ExpensesCategoriesError = - GetV1ExpensesCategoriesErrors[keyof GetV1ExpensesCategoriesErrors]; +export type PutV1EmploymentsEmploymentIdBenefitOffersError = + PutV1EmploymentsEmploymentIdBenefitOffersErrors[keyof PutV1EmploymentsEmploymentIdBenefitOffersErrors]; -export type GetV1ExpensesCategoriesResponses = { +export type PutV1EmploymentsEmploymentIdBenefitOffersResponses = { /** * Success */ - 200: ListExpenseCategoriesResponse; + 200: SuccessResponse; }; -export type GetV1ExpensesCategoriesResponse = - GetV1ExpensesCategoriesResponses[keyof GetV1ExpensesCategoriesResponses]; +export type PutV1EmploymentsEmploymentIdBenefitOffersResponse = + PutV1EmploymentsEmploymentIdBenefitOffersResponses[keyof PutV1EmploymentsEmploymentIdBenefitOffersResponses]; -export type PostV1EmployeeTimeoffIdCancelData = { - /** - * CancelTimeoff - */ - body: CancelTimeoffParams; - path: { +export type GetV1EmploymentsData = { + body?: never; + headers: { /** - * Timeoff ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - id: string; + Authorization: string; }; - query?: never; - url: '/v1/employee/timeoff/{id}/cancel'; + path?: never; + query?: { + /** + * Company ID + */ + company_id?: string; + /** + * Filters the results by employments whose login email matches the value + */ + email?: string; + /** + * Filters the results by employments whose status matches the value. + * Supports multiple values separated by commas. + * Also supports the value `incomplete` to get all employments that are not onboarded yet. + * + */ + status?: string; + /** + * Filters the results by employments whose employment product type matches the value + */ + employment_type?: string; + /** + * Filters the results by employments whose employment model matches the value. + * Possible values: `global_payroll`, `peo`, `eor` + * + */ + employment_model?: 'global_payroll' | 'peo' | 'eor'; + /** + * Filters the results by the employment's short ID. Returns at most one result. + */ + short_id?: string; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/employments'; }; -export type PostV1EmployeeTimeoffIdCancelErrors = { +export type GetV1EmploymentsErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ @@ -16704,21 +17458,24 @@ export type PostV1EmployeeTimeoffIdCancelErrors = { 429: TooManyRequestsResponse; }; -export type PostV1EmployeeTimeoffIdCancelError = - PostV1EmployeeTimeoffIdCancelErrors[keyof PostV1EmployeeTimeoffIdCancelErrors]; +export type GetV1EmploymentsError = + GetV1EmploymentsErrors[keyof GetV1EmploymentsErrors]; -export type PostV1EmployeeTimeoffIdCancelResponses = { +export type GetV1EmploymentsResponses = { /** * Success */ - 200: TimeoffResponse; + 200: ListEmploymentsResponse; }; -export type PostV1EmployeeTimeoffIdCancelResponse = - PostV1EmployeeTimeoffIdCancelResponses[keyof PostV1EmployeeTimeoffIdCancelResponses]; +export type GetV1EmploymentsResponse = + GetV1EmploymentsResponses[keyof GetV1EmploymentsResponses]; -export type GetV1CountriesCountryCodeFormData = { - body?: never; +export type PostV1EmploymentsData = { + /** + * Employment params + */ + body?: EmploymentCreateParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -16728,50 +17485,29 @@ export type GetV1CountriesCountryCodeFormData = { */ Authorization: string; }; - path: { - /** - * Country code according to ISO 3-digit alphabetic codes - */ - country_code: string; - /** - * Name of the desired form - */ - form: string; - }; + path?: never; query?: { - /** - * Required for `contract_amendment` form - */ - employment_id?: string; - /** - * FOR TESTING PURPOSES ONLY: Include scheduled benefit groups. - */ - only_for_testing_include_scheduled_benefit_groups?: boolean; - /** - * Skips the dynamic benefits part of the schema if set. To be used when benefits are set via its own API. - */ - skip_benefits?: boolean; /** * Version of the form schema */ json_schema_version?: number | 'latest'; }; - url: '/v1/countries/{country_code}/{form}'; + url: '/v1/employments'; }; -export type GetV1CountriesCountryCodeFormErrors = { +export type PostV1EmploymentsErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ @@ -16782,32 +17518,45 @@ export type GetV1CountriesCountryCodeFormErrors = { 429: TooManyRequestsResponse; }; -export type GetV1CountriesCountryCodeFormError = - GetV1CountriesCountryCodeFormErrors[keyof GetV1CountriesCountryCodeFormErrors]; +export type PostV1EmploymentsError = + PostV1EmploymentsErrors[keyof PostV1EmploymentsErrors]; -export type GetV1CountriesCountryCodeFormResponses = { +export type PostV1EmploymentsResponses = { /** * Success */ - 200: CountryFormResponse; + 200: EmploymentCreationResponse; }; -export type GetV1CountriesCountryCodeFormResponse = - GetV1CountriesCountryCodeFormResponses[keyof GetV1CountriesCountryCodeFormResponses]; +export type PostV1EmploymentsResponse = + PostV1EmploymentsResponses[keyof PostV1EmploymentsResponses]; -export type GetV1FilesIdData = { +export type GetV1TimeoffIdData = { body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * File ID + * Timeoff ID */ id: string; }; query?: never; - url: '/v1/files/{id}'; + url: '/v1/timeoff/{id}'; }; -export type GetV1FilesIdErrors = { +export type GetV1TimeoffIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -16820,22 +17569,30 @@ export type GetV1FilesIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1FilesIdError = GetV1FilesIdErrors[keyof GetV1FilesIdErrors]; +export type GetV1TimeoffIdError = + GetV1TimeoffIdErrors[keyof GetV1TimeoffIdErrors]; -export type GetV1FilesIdResponses = { +export type GetV1TimeoffIdResponses = { /** * Success */ - 200: DownloadFileResponse; + 200: TimeoffResponse; }; -export type GetV1FilesIdResponse = - GetV1FilesIdResponses[keyof GetV1FilesIdResponses]; +export type GetV1TimeoffIdResponse = + GetV1TimeoffIdResponses[keyof GetV1TimeoffIdResponses]; -export type GetV1ContractAmendmentsIdData = { - body?: never; +export type PatchV1TimeoffId2Data = { + /** + * UpdateTimeoff + */ + body: UpdateApprovedTimeoffParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -16847,15 +17604,19 @@ export type GetV1ContractAmendmentsIdData = { }; path: { /** - * Contract amendment request ID + * Timeoff ID */ id: string; }; query?: never; - url: '/v1/contract-amendments/{id}'; + url: '/v1/timeoff/{id}'; }; -export type GetV1ContractAmendmentsIdErrors = { +export type PatchV1TimeoffId2Errors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -16868,42 +17629,50 @@ export type GetV1ContractAmendmentsIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1ContractAmendmentsIdError = - GetV1ContractAmendmentsIdErrors[keyof GetV1ContractAmendmentsIdErrors]; +export type PatchV1TimeoffId2Error = + PatchV1TimeoffId2Errors[keyof PatchV1TimeoffId2Errors]; -export type GetV1ContractAmendmentsIdResponses = { +export type PatchV1TimeoffId2Responses = { /** * Success */ - 200: ContractAmendmentResponse; + 200: TimeoffResponse; }; -export type GetV1ContractAmendmentsIdResponse = - GetV1ContractAmendmentsIdResponses[keyof GetV1ContractAmendmentsIdResponses]; +export type PatchV1TimeoffId2Response = + PatchV1TimeoffId2Responses[keyof PatchV1TimeoffId2Responses]; -export type PutV2EmploymentsEmploymentIdBankAccountDetailsData = { +export type PatchV1TimeoffIdData = { /** - * Employment bank account details params + * UpdateTimeoff */ - body?: EmploymentBankAccountDetailsParams; - path: { + body: UpdateApprovedTimeoffParams; + headers: { /** - * Employment ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - employment_id: string; + Authorization: string; }; - query?: { + path: { /** - * Version of the bank_account_details form schema + * Timeoff ID */ - bank_account_details_json_schema_version?: number | 'latest'; + id: string; }; - url: '/v2/employments/{employment_id}/bank_account_details'; + query?: never; + url: '/v1/timeoff/{id}'; }; -export type PutV2EmploymentsEmploymentIdBankAccountDetailsErrors = { +export type PatchV1TimeoffIdErrors = { /** * Bad Request */ @@ -16911,19 +17680,11 @@ export type PutV2EmploymentsEmploymentIdBankAccountDetailsErrors = { /** * Unauthorized */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ @@ -16934,49 +17695,35 @@ export type PutV2EmploymentsEmploymentIdBankAccountDetailsErrors = { 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdBankAccountDetailsError = - PutV2EmploymentsEmploymentIdBankAccountDetailsErrors[keyof PutV2EmploymentsEmploymentIdBankAccountDetailsErrors]; +export type PatchV1TimeoffIdError = + PatchV1TimeoffIdErrors[keyof PatchV1TimeoffIdErrors]; -export type PutV2EmploymentsEmploymentIdBankAccountDetailsResponses = { +export type PatchV1TimeoffIdResponses = { /** * Success */ - 200: EmploymentResponse; + 200: TimeoffResponse; }; -export type PutV2EmploymentsEmploymentIdBankAccountDetailsResponse = - PutV2EmploymentsEmploymentIdBankAccountDetailsResponses[keyof PutV2EmploymentsEmploymentIdBankAccountDetailsResponses]; +export type PatchV1TimeoffIdResponse = + PatchV1TimeoffIdResponses[keyof PatchV1TimeoffIdResponses]; -export type GetV1CompanyManagersData = { +export type GetV1IdentityCurrentData = { body?: never; headers: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. + * This endpoint works with any of the access tokens provided. You can use an access + * token obtained through the Client Credentials flow, the Authorization Code flow, or the Refresh Token flow. * */ Authorization: string; }; path?: never; - query?: { - /** - * A Company ID to filter the results (only applicable for Integration Partners). - */ - company_id?: string; - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Change the amount of records returned per page, defaults to 20, limited to 100 - */ - page_size?: number; - }; - url: '/v1/company-managers'; + query?: never; + url: '/v1/identity/current'; }; -export type GetV1CompanyManagersErrors = { +export type GetV1IdentityCurrentErrors = { /** * Bad Request */ @@ -16999,47 +17746,50 @@ export type GetV1CompanyManagersErrors = { 429: TooManyRequestsResponse; }; -export type GetV1CompanyManagersError = - GetV1CompanyManagersErrors[keyof GetV1CompanyManagersErrors]; +export type GetV1IdentityCurrentError = + GetV1IdentityCurrentErrors[keyof GetV1IdentityCurrentErrors]; -export type GetV1CompanyManagersResponses = { +export type GetV1IdentityCurrentResponses = { /** * Success */ - 200: CompanyManagersResponse; + 201: IdentityCurrentResponse; }; -export type GetV1CompanyManagersResponse = - GetV1CompanyManagersResponses[keyof GetV1CompanyManagersResponses]; +export type GetV1IdentityCurrentResponse = + GetV1IdentityCurrentResponses[keyof GetV1IdentityCurrentResponses]; -export type PostV1CompanyManagersData = { - /** - * Company Manager params - */ - body?: CompanyManagerParams; - headers: { +export type GetV1WdGphPayVarianceData = { + body?: never; + headers?: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * The preferred language of the inquiring user in Workday */ - Authorization: string; + accept_language?: string; }; path?: never; - query?: { + query: { /** - * Complementary action(s) to perform when creating a company manager: - * - * - `no_invite` skips the email invitation step - * + * The pay group ID for identifying the pay group at the vendor system */ - actions?: string; + payGroupExternalId: string; + /** + * The run type id provided in the paySummary API + */ + runTypeId: string; + /** + * The cycle type id, defaults to the main run if not provided + */ + cycleTypeId?: string; + /** + * The period end date in question, defaults to current period if not provided + */ + periodEndDate?: Date; }; - url: '/v1/company-managers'; + url: '/v1/wd/gph/payVariance'; }; -export type PostV1CompanyManagersErrors = { +export type GetV1WdGphPayVarianceErrors = { /** * Bad Request */ @@ -17052,64 +17802,133 @@ export type PostV1CompanyManagersErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PostV1CompanyManagersError = - PostV1CompanyManagersErrors[keyof PostV1CompanyManagersErrors]; +export type GetV1WdGphPayVarianceError = + GetV1WdGphPayVarianceErrors[keyof GetV1WdGphPayVarianceErrors]; -export type PostV1CompanyManagersResponses = { +export type GetV1WdGphPayVarianceResponses = { /** * Success */ - 201: CompanyManagerData; + 200: PayVarianceResponse; }; -export type PostV1CompanyManagersResponse = - PostV1CompanyManagersResponses[keyof PostV1CompanyManagersResponses]; +export type GetV1WdGphPayVarianceResponse = + GetV1WdGphPayVarianceResponses[keyof GetV1WdGphPayVarianceResponses]; -export type GetV1CostCalculatorCountriesData = { +export type GetV1PayrollCalendarsCycleData = { body?: never; - path?: never; + path: { + /** + * The cycle for which to list the payroll calendars. Format: YYYY-MM + */ + cycle: string; + }; query?: { /** - * If the premium benefits should be included in the response + * Starts fetching records after the given page */ - include_premium_benefits?: boolean; + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - url: '/v1/cost-calculator/countries'; + url: '/v1/payroll-calendars/{cycle}'; }; -export type GetV1CostCalculatorCountriesResponses = { +export type GetV1PayrollCalendarsCycleErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type GetV1PayrollCalendarsCycleError = + GetV1PayrollCalendarsCycleErrors[keyof GetV1PayrollCalendarsCycleErrors]; + +export type GetV1PayrollCalendarsCycleResponses = { /** * Success */ - 200: CostCalculatorListCountryResponse; + 200: PayrollCalendarsResponse; }; -export type GetV1CostCalculatorCountriesResponse = - GetV1CostCalculatorCountriesResponses[keyof GetV1CostCalculatorCountriesResponses]; +export type GetV1PayrollCalendarsCycleResponse = + GetV1PayrollCalendarsCycleResponses[keyof GetV1PayrollCalendarsCycleResponses]; -export type PostV1IdentityVerificationEmploymentIdDeclineData = { - body?: never; +export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentData = + { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/terminate-cor-employment'; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors = + { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentError = + PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors[keyof PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors]; + +export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses = + { + /** + * Success + */ + 200: SuccessResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponse = + PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses[keyof PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses]; + +export type PostV1TimesheetsTimesheetIdSendBackData = { + /** + * SendBackTimesheetParams + */ + body?: SendBackTimesheetParams; path: { /** - * Employment ID + * Timesheet ID */ - employment_id: string; + timesheet_id: string; }; query?: never; - url: '/v1/identity-verification/{employment_id}/decline'; + url: '/v1/timesheets/{timesheet_id}/send-back'; }; -export type PostV1IdentityVerificationEmploymentIdDeclineErrors = { +export type PostV1TimesheetsTimesheetIdSendBackErrors = { /** * Unauthorized */ @@ -17124,32 +17943,103 @@ export type PostV1IdentityVerificationEmploymentIdDeclineErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1IdentityVerificationEmploymentIdDeclineError = - PostV1IdentityVerificationEmploymentIdDeclineErrors[keyof PostV1IdentityVerificationEmploymentIdDeclineErrors]; +export type PostV1TimesheetsTimesheetIdSendBackError = + PostV1TimesheetsTimesheetIdSendBackErrors[keyof PostV1TimesheetsTimesheetIdSendBackErrors]; + +export type PostV1TimesheetsTimesheetIdSendBackResponses = { + /** + * Success + */ + 200: SentBackTimesheetResponse; +}; + +export type PostV1TimesheetsTimesheetIdSendBackResponse = + PostV1TimesheetsTimesheetIdSendBackResponses[keyof PostV1TimesheetsTimesheetIdSendBackResponses]; + +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignData = + { + /** + * SignContractDocument + */ + body: SignContractDocument; + path: { + /** + * Employment ID + */ + employment_id: string; + /** + * Pre-onboarding document ID + */ + id: string; + }; + query?: never; + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents/{id}/sign'; + }; + +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignErrors = + { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + }; + +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignError = + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignErrors[keyof PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignErrors]; -export type PostV1IdentityVerificationEmploymentIdDeclineResponses = { - /** - * Success - */ - 200: SuccessResponse; -}; +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponses = + { + /** + * Success + */ + 200: SuccessResponse; + }; -export type PostV1IdentityVerificationEmploymentIdDeclineResponse = - PostV1IdentityVerificationEmploymentIdDeclineResponses[keyof PostV1IdentityVerificationEmploymentIdDeclineResponses]; +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponse = + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponses[keyof PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdSignResponses]; -export type GetV1CountriesCountryCodeEngagementAgreementDetailsData = { +export type GetV1BenefitRenewalRequestsData = { body?: never; - path: { + headers: { /** - * Country code according to ISO 3-digit alphabetic codes + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - country_code: string; + Authorization: string; }; - query?: never; - url: '/v1/countries/{country_code}/engagement-agreement-details'; + path?: never; + query?: { + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/benefit-renewal-requests'; }; -export type GetV1CountriesCountryCodeEngagementAgreementDetailsErrors = { +export type GetV1BenefitRenewalRequestsErrors = { /** * Bad Request */ @@ -17172,77 +18062,84 @@ export type GetV1CountriesCountryCodeEngagementAgreementDetailsErrors = { 429: TooManyRequestsResponse; }; -export type GetV1CountriesCountryCodeEngagementAgreementDetailsError = - GetV1CountriesCountryCodeEngagementAgreementDetailsErrors[keyof GetV1CountriesCountryCodeEngagementAgreementDetailsErrors]; +export type GetV1BenefitRenewalRequestsError = + GetV1BenefitRenewalRequestsErrors[keyof GetV1BenefitRenewalRequestsErrors]; -export type GetV1CountriesCountryCodeEngagementAgreementDetailsResponses = { +export type GetV1BenefitRenewalRequestsResponses = { /** * Success */ - 200: EngagementAgreementDetailsResponse; + 200: BenefitRenewalRequestsListBenefitRenewalRequestResponse; }; -export type GetV1CountriesCountryCodeEngagementAgreementDetailsResponse = - GetV1CountriesCountryCodeEngagementAgreementDetailsResponses[keyof GetV1CountriesCountryCodeEngagementAgreementDetailsResponses]; +export type GetV1BenefitRenewalRequestsResponse = + GetV1BenefitRenewalRequestsResponses[keyof GetV1BenefitRenewalRequestsResponses]; -export type GetV1BillingDocumentsData = { - body?: never; - headers: { +export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdData = + { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; + path: { + /** + * Company ID + */ + company_id: string; + /** + * Legal Entity ID to set as the new default + */ + legal_entity_id: string; + }; + query?: never; + url: '/v1/sandbox/companies/{company_id}/default-legal-entity/{legal_entity_id}'; + }; + +export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors = + { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Bad Request */ - Authorization: string; - }; - path?: never; - query?: { + 400: BadRequestResponse; /** - * The month for the billing documents (in ISO-8601 format) + * Unauthorized */ - period?: string; + 401: UnauthorizedResponse; /** - * Starts fetching records after the given page + * Not Found */ - page?: number; + 404: NotFoundResponse; /** - * Number of items per page + * Unprocessable Entity */ - page_size?: number; + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; - url: '/v1/billing-documents'; -}; - -export type GetV1BillingDocumentsErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; -}; -export type GetV1BillingDocumentsError = - GetV1BillingDocumentsErrors[keyof GetV1BillingDocumentsErrors]; +export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdError = + PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors[keyof PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors]; -export type GetV1BillingDocumentsResponses = { - /** - * Success - */ - 200: BillingDocumentsResponse; -}; +export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses = + { + /** + * Success + */ + 200: SuccessResponse; + }; -export type GetV1BillingDocumentsResponse = - GetV1BillingDocumentsResponses[keyof GetV1BillingDocumentsResponses]; +export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponse = + PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses[keyof PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses]; -export type DeleteV1WebhookCallbacksIdData = { +export type GetV1EmploymentContractsData = { body?: never; headers: { /** @@ -17253,64 +18150,29 @@ export type DeleteV1WebhookCallbacksIdData = { */ Authorization: string; }; - path: { + path?: never; + query: { /** - * Webhook Callback ID + * Employment ID */ - id: string; - }; - query?: never; - url: '/v1/webhook-callbacks/{id}'; -}; - -export type DeleteV1WebhookCallbacksIdErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; -}; - -export type DeleteV1WebhookCallbacksIdError = - DeleteV1WebhookCallbacksIdErrors[keyof DeleteV1WebhookCallbacksIdErrors]; - -export type DeleteV1WebhookCallbacksIdResponses = { - /** - * Success - */ - 200: SuccessResponse; -}; - -export type DeleteV1WebhookCallbacksIdResponse = - DeleteV1WebhookCallbacksIdResponses[keyof DeleteV1WebhookCallbacksIdResponses]; - -export type PatchV1WebhookCallbacksIdData = { - /** - * WebhookCallback - */ - body?: UpdateWebhookCallbackParams; - path: { + employment_id: string; /** - * Webhook Callback ID + * Only Active */ - id: string; + only_active?: boolean; }; - query?: never; - url: '/v1/webhook-callbacks/{id}'; + url: '/v1/employment-contracts'; }; -export type PatchV1WebhookCallbacksIdErrors = { +export type GetV1EmploymentContractsErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ @@ -17321,157 +18183,151 @@ export type PatchV1WebhookCallbacksIdErrors = { 422: UnprocessableEntityResponse; }; -export type PatchV1WebhookCallbacksIdError = - PatchV1WebhookCallbacksIdErrors[keyof PatchV1WebhookCallbacksIdErrors]; +export type GetV1EmploymentContractsError = + GetV1EmploymentContractsErrors[keyof GetV1EmploymentContractsErrors]; -export type PatchV1WebhookCallbacksIdResponses = { +export type GetV1EmploymentContractsResponses = { /** * Success */ - 200: WebhookCallbackResponse; + 200: ListEmploymentContractResponse; }; -export type PatchV1WebhookCallbacksIdResponse = - PatchV1WebhookCallbacksIdResponses[keyof PatchV1WebhookCallbacksIdResponses]; +export type GetV1EmploymentContractsResponse = + GetV1EmploymentContractsResponses[keyof GetV1EmploymentContractsResponses]; -export type GetV1EmployeeTimesheetsData = { - body?: never; - path?: never; - query?: { +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelData = + { + body?: never; + path: { + /** + * Contract amendment request ID + */ + contract_amendment_request_id: string; + }; + query?: never; + url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/cancel'; + }; + +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors = + { /** - * Starts fetching records after the given page + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity */ - page?: number; + 422: UnprocessableEntityResponse; /** - * Number of items per page + * Too many requests */ - page_size?: number; + 429: TooManyRequestsResponse; }; - url: '/v1/employee/timesheets'; -}; - -export type GetV1EmployeeTimesheetsErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; -}; -export type GetV1EmployeeTimesheetsError = - GetV1EmployeeTimesheetsErrors[keyof GetV1EmployeeTimesheetsErrors]; +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelError = + PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors]; -export type GetV1EmployeeTimesheetsResponses = { - /** - * Success - */ - 200: SuccessResponse; -}; +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses = + { + /** + * Success + */ + 200: SuccessResponse; + }; -export type GetV1EmployeeTimesheetsResponse = - GetV1EmployeeTimesheetsResponses[keyof GetV1EmployeeTimesheetsResponses]; +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponse = + PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses]; -export type PutV1EmploymentsEmploymentIdPersonalDetailsData = { - /** - * Employment personal details params - */ - body?: EmploymentPersonalDetailsParams; +export type GetV1PayslipsPayslipIdPdfData = { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * Employment ID + * Payslip ID */ - employment_id: string; + payslip_id: string; }; query?: never; - url: '/v1/employments/{employment_id}/personal_details'; + url: '/v1/payslips/{payslip_id}/pdf'; }; -export type PutV1EmploymentsEmploymentIdPersonalDetailsErrors = { +export type GetV1PayslipsPayslipIdPdfErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PutV1EmploymentsEmploymentIdPersonalDetailsError = - PutV1EmploymentsEmploymentIdPersonalDetailsErrors[keyof PutV1EmploymentsEmploymentIdPersonalDetailsErrors]; +export type GetV1PayslipsPayslipIdPdfError = + GetV1PayslipsPayslipIdPdfErrors[keyof GetV1PayslipsPayslipIdPdfErrors]; -export type PutV1EmploymentsEmploymentIdPersonalDetailsResponses = { +export type GetV1PayslipsPayslipIdPdfResponses = { /** * Success */ - 200: EmploymentResponse; + 200: PayslipDownloadResponse; }; -export type PutV1EmploymentsEmploymentIdPersonalDetailsResponse = - PutV1EmploymentsEmploymentIdPersonalDetailsResponses[keyof PutV1EmploymentsEmploymentIdPersonalDetailsResponses]; +export type GetV1PayslipsPayslipIdPdfResponse = + GetV1PayslipsPayslipIdPdfResponses[keyof GetV1PayslipsPayslipIdPdfResponses]; -export type GetV1TravelLetterRequestsData = { - body?: never; - path?: never; - query?: { - /** - * Filter results on the given status - */ - status?: - | 'pending' - | 'cancelled' - | 'declined_by_manager' - | 'declined_by_remote' - | 'approved_by_manager' - | 'approved_by_remote'; - /** - * Filter results on the given employment slug - */ - employment_id?: string; - /** - * Filter results on the given employee name - */ - employee_name?: string; - /** - * Sort order - */ - order?: 'asc' | 'desc'; - /** - * Field to sort by - */ - sort_by?: 'submitted_at'; - /** - * Starts fetching records after the given page - */ - page?: number; +export type PostV1TimeoffTimeoffIdApproveData = { + /** + * ApproveTimeoff + */ + body: ApproveTimeoffParams; + path: { /** - * Number of items per page + * Time Off ID */ - page_size?: number; + timeoff_id: string; }; - url: '/v1/travel-letter-requests'; + query?: never; + url: '/v1/timeoff/{timeoff_id}/approve'; }; -export type GetV1TravelLetterRequestsErrors = { +export type PostV1TimeoffTimeoffIdApproveErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; /** * Not Found */ @@ -17480,28 +18336,32 @@ export type GetV1TravelLetterRequestsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1TravelLetterRequestsError = - GetV1TravelLetterRequestsErrors[keyof GetV1TravelLetterRequestsErrors]; +export type PostV1TimeoffTimeoffIdApproveError = + PostV1TimeoffTimeoffIdApproveErrors[keyof PostV1TimeoffTimeoffIdApproveErrors]; -export type GetV1TravelLetterRequestsResponses = { +export type PostV1TimeoffTimeoffIdApproveResponses = { /** * Success */ - 200: ListTravelLettersResponse; + 200: TimeoffResponse; }; -export type GetV1TravelLetterRequestsResponse = - GetV1TravelLetterRequestsResponses[keyof GetV1TravelLetterRequestsResponses]; +export type PostV1TimeoffTimeoffIdApproveResponse = + PostV1TimeoffTimeoffIdApproveResponses[keyof PostV1TimeoffTimeoffIdApproveResponses]; -export type GetV1BenefitRenewalRequestsData = { +export type GetV1CompaniesData = { body?: never; headers: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * Requires a client credentials access token obtained through the Client Credentials flow or the Refresh Token flow. * - * The refresh token needs to have been obtained through the Authorization Code flow. + * The refresh token needs to have been obtained through the Client Credentials flow. * */ Authorization: string; @@ -17509,22 +18369,14 @@ export type GetV1BenefitRenewalRequestsData = { path?: never; query?: { /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page + * External ID */ - page_size?: number; + external_id?: string; }; - url: '/v1/benefit-renewal-requests'; + url: '/v1/companies'; }; -export type GetV1BenefitRenewalRequestsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1CompaniesErrors = { /** * Unauthorized */ @@ -17537,85 +18389,118 @@ export type GetV1BenefitRenewalRequestsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type GetV1BenefitRenewalRequestsError = - GetV1BenefitRenewalRequestsErrors[keyof GetV1BenefitRenewalRequestsErrors]; +export type GetV1CompaniesError = + GetV1CompaniesErrors[keyof GetV1CompaniesErrors]; -export type GetV1BenefitRenewalRequestsResponses = { +export type GetV1CompaniesResponses = { /** * Success */ - 200: BenefitRenewalRequestsListBenefitRenewalRequestResponse; + 200: CompaniesResponse; }; -export type GetV1BenefitRenewalRequestsResponse = - GetV1BenefitRenewalRequestsResponses[keyof GetV1BenefitRenewalRequestsResponses]; +export type GetV1CompaniesResponse = + GetV1CompaniesResponses[keyof GetV1CompaniesResponses]; -export type PostV1WebhookCallbacksData = { +export type PostV1CompaniesData = { /** - * WebhookCallback + * Create Company params */ - body?: CreateWebhookCallbackParams; + body?: CreateCompanyParams; headers: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * Requires a client credentials access token obtained through the Client Credentials flow or the Refresh Token flow. * - * The refresh token needs to have been obtained through the Authorization Code flow. + * The refresh token needs to have been obtained through the Client Credentials flow. * */ Authorization: string; }; path?: never; - query?: never; - url: '/v1/webhook-callbacks'; + query?: { + /** + * Version of the address_details form schema + */ + address_details_json_schema_version?: number | 'latest'; + /** + * Version of the bank_account_details form schema + */ + bank_account_details_json_schema_version?: number | 'latest'; + /** + * Complementary action(s) to perform when creating a company: + * + * - `get_oauth_access_tokens` returns the user's access and refresh tokens + * - `send_create_password_email ` sends a reset password token to the company owner's email so they can log in using Remote UI (not needed if integration plans to use SSO only) + * + * If `action` contains `send_create_password_email` you can redirect the user to [https://employ.remote.com/api-integration-new-password-send](https://employ.remote.com/api-integration-new-password-send) + * + */ + action?: string; + /** + * Whether the request should be performed async + * + */ + async?: boolean; + /** + * Scope of the access token + * + */ + scope?: string; + }; + url: '/v1/companies'; }; -export type PostV1WebhookCallbacksErrors = { +export type PostV1CompaniesErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** - * Not Found + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Conflict */ - 404: NotFoundResponse; + 409: CompanyCreationConflictErrorResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type PostV1WebhookCallbacksError = - PostV1WebhookCallbacksErrors[keyof PostV1WebhookCallbacksErrors]; +export type PostV1CompaniesError = + PostV1CompaniesErrors[keyof PostV1CompaniesErrors]; -export type PostV1WebhookCallbacksResponses = { +export type PostV1CompaniesResponses = { /** - * Success + * Created */ - 200: WebhookCallbackResponse; + 201: CompanyCreationResponse; }; -export type PostV1WebhookCallbacksResponse = - PostV1WebhookCallbacksResponses[keyof PostV1WebhookCallbacksResponses]; +export type PostV1CompaniesResponse = + PostV1CompaniesResponses[keyof PostV1CompaniesResponses]; -export type PostV1TimesheetsTimesheetIdApproveData = { +export type GetV1EmploymentsEmploymentIdCompanyStructureNodesData = { body?: never; path: { /** - * Timesheet ID + * Employment ID */ - timesheet_id: string; + employment_id: string; }; query?: never; - url: '/v1/timesheets/{timesheet_id}/approve'; + url: '/v1/employments/{employment_id}/company-structure-nodes'; }; -export type PostV1TimesheetsTimesheetIdApproveErrors = { +export type GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors = { /** * Unauthorized */ @@ -17630,78 +18515,75 @@ export type PostV1TimesheetsTimesheetIdApproveErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1TimesheetsTimesheetIdApproveError = - PostV1TimesheetsTimesheetIdApproveErrors[keyof PostV1TimesheetsTimesheetIdApproveErrors]; +export type GetV1EmploymentsEmploymentIdCompanyStructureNodesError = + GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors[keyof GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors]; -export type PostV1TimesheetsTimesheetIdApproveResponses = { +export type GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses = { /** * Success */ - 200: MinimalTimesheetResponse; + 200: CompanyStructureNodesResponse; }; -export type PostV1TimesheetsTimesheetIdApproveResponse = - PostV1TimesheetsTimesheetIdApproveResponses[keyof PostV1TimesheetsTimesheetIdApproveResponses]; +export type GetV1EmploymentsEmploymentIdCompanyStructureNodesResponse = + GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses[keyof GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses]; -export type GetV1PayslipsIdData = { - body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; +export type PatchV2EmploymentsEmploymentId2Data = { + /** + * Employment params + */ + body?: EmploymentV2UpdateParams; path: { /** - * Payslip ID + * Employment ID */ - id: string; + employment_id: string; }; query?: never; - url: '/v1/payslips/{id}'; + url: '/v2/employments/{employment_id}'; }; -export type GetV1PayslipsIdErrors = { +export type PatchV2EmploymentsEmploymentId2Errors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV1PayslipsIdError = - GetV1PayslipsIdErrors[keyof GetV1PayslipsIdErrors]; +export type PatchV2EmploymentsEmploymentId2Error = + PatchV2EmploymentsEmploymentId2Errors[keyof PatchV2EmploymentsEmploymentId2Errors]; -export type GetV1PayslipsIdResponses = { +export type PatchV2EmploymentsEmploymentId2Responses = { /** * Success */ - 200: PayslipResponse; + 200: EmploymentResponse; }; -export type GetV1PayslipsIdResponse = - GetV1PayslipsIdResponses[keyof GetV1PayslipsIdResponses]; +export type PatchV2EmploymentsEmploymentId2Response = + PatchV2EmploymentsEmploymentId2Responses[keyof PatchV2EmploymentsEmploymentId2Responses]; -export type GetV1LeavePoliciesSummaryEmploymentIdData = { - body?: never; +export type PatchV2EmploymentsEmploymentIdData = { + /** + * Employment params + */ + body?: EmploymentV2UpdateParams; path: { /** * Employment ID @@ -17709,106 +18591,60 @@ export type GetV1LeavePoliciesSummaryEmploymentIdData = { employment_id: string; }; query?: never; - url: '/v1/leave-policies/summary/{employment_id}'; + url: '/v2/employments/{employment_id}'; }; -export type GetV1LeavePoliciesSummaryEmploymentIdErrors = { +export type PatchV2EmploymentsEmploymentIdErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1LeavePoliciesSummaryEmploymentIdError = - GetV1LeavePoliciesSummaryEmploymentIdErrors[keyof GetV1LeavePoliciesSummaryEmploymentIdErrors]; +export type PatchV2EmploymentsEmploymentIdError = + PatchV2EmploymentsEmploymentIdErrors[keyof PatchV2EmploymentsEmploymentIdErrors]; -export type GetV1LeavePoliciesSummaryEmploymentIdResponses = { +export type PatchV2EmploymentsEmploymentIdResponses = { /** * Success */ - 200: ListLeavePoliciesSummaryResponse; + 200: EmploymentResponse; }; -export type GetV1LeavePoliciesSummaryEmploymentIdResponse = - GetV1LeavePoliciesSummaryEmploymentIdResponses[keyof GetV1LeavePoliciesSummaryEmploymentIdResponses]; +export type PatchV2EmploymentsEmploymentIdResponse = + PatchV2EmploymentsEmploymentIdResponses[keyof PatchV2EmploymentsEmploymentIdResponses]; -export type GetV1EmployeeExpenseCategoriesData = { - body?: never; +export type PostV1ProbationCompletionLetterData = { + /** + * Work Authorization Request + */ + body: CreateProbationCompletionLetterParams; path?: never; - query?: { - /** - * Include parent (non-selectable) categories in addition to selectable leaves - */ - include_parents?: boolean; - /** - * Expense ID (slug) whose category should be included in the result, even if it is not selectable by default - */ - expense_id?: string; - }; - url: '/v1/employee/expense-categories'; + query?: never; + url: '/v1/probation-completion-letter'; }; -export type GetV1EmployeeExpenseCategoriesErrors = { +export type PostV1ProbationCompletionLetterErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; -}; - -export type GetV1EmployeeExpenseCategoriesError = - GetV1EmployeeExpenseCategoriesErrors[keyof GetV1EmployeeExpenseCategoriesErrors]; - -export type GetV1EmployeeExpenseCategoriesResponses = { - /** - * Success - */ - 200: ListExpenseCategoriesResponse; -}; - -export type GetV1EmployeeExpenseCategoriesResponse = - GetV1EmployeeExpenseCategoriesResponses[keyof GetV1EmployeeExpenseCategoriesResponses]; - -export type GetV1CompanyDepartmentsData = { - body?: never; - path?: never; - query: { - /** - * Company ID - */ - company_id: string; - /** - * Paginate option. Default: true. When true, paginates response; otherwise, does not. - */ - paginate?: boolean; - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page - */ - page_size?: number; - }; - url: '/v1/company-departments'; -}; - -export type GetV1CompanyDepartmentsErrors = { /** * Not Found */ @@ -17819,30 +18655,30 @@ export type GetV1CompanyDepartmentsErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1CompanyDepartmentsError = - GetV1CompanyDepartmentsErrors[keyof GetV1CompanyDepartmentsErrors]; +export type PostV1ProbationCompletionLetterError = + PostV1ProbationCompletionLetterErrors[keyof PostV1ProbationCompletionLetterErrors]; -export type GetV1CompanyDepartmentsResponses = { +export type PostV1ProbationCompletionLetterResponses = { /** * Success */ - 200: ListCompanyDepartmentsPaginatedResponse; + 200: ProbationCompletionLetterResponse; }; -export type GetV1CompanyDepartmentsResponse = - GetV1CompanyDepartmentsResponses[keyof GetV1CompanyDepartmentsResponses]; +export type PostV1ProbationCompletionLetterResponse = + PostV1ProbationCompletionLetterResponses[keyof PostV1ProbationCompletionLetterResponses]; -export type PostV1CompanyDepartmentsData = { +export type PostV1CostCalculatorEstimationPdfData = { /** - * Create Company Department request params + * Estimate params */ - body: CreateCompanyDepartmentParams; + body?: CostCalculatorEstimateParams; path?: never; query?: never; - url: '/v1/company-departments'; + url: '/v1/cost-calculator/estimation-pdf'; }; -export type PostV1CompanyDepartmentsErrors = { +export type PostV1CostCalculatorEstimationPdfErrors = { /** * Not Found */ @@ -17853,147 +18689,120 @@ export type PostV1CompanyDepartmentsErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1CompanyDepartmentsError = - PostV1CompanyDepartmentsErrors[keyof PostV1CompanyDepartmentsErrors]; +export type PostV1CostCalculatorEstimationPdfError = + PostV1CostCalculatorEstimationPdfErrors[keyof PostV1CostCalculatorEstimationPdfErrors]; -export type PostV1CompanyDepartmentsResponses = { +export type PostV1CostCalculatorEstimationPdfResponses = { /** - * Created + * Success */ - 201: CompanyDepartmentCreatedResponse; + 200: CostCalculatorEstimatePdfResponse; }; -export type PostV1CompanyDepartmentsResponse = - PostV1CompanyDepartmentsResponses[keyof PostV1CompanyDepartmentsResponses]; +export type PostV1CostCalculatorEstimationPdfResponse = + PostV1CostCalculatorEstimationPdfResponses[keyof PostV1CostCalculatorEstimationPdfResponses]; -export type PostV1TimeoffTimeoffIdCancelRequestDeclineData = { +export type PostAuthOauth2Token2Data = { /** - * Timeoff + * OAuth2Token */ - body: DeclineTimeoffParams; - path: { - /** - * Time Off ID - */ - timeoff_id: string; - }; + body?: OAuth2TokenParams; + path?: never; query?: never; - url: '/v1/timeoff/{timeoff_id}/cancel-request/decline'; + url: '/api/eor/auth/oauth2/token'; }; -export type PostV1TimeoffTimeoffIdCancelRequestDeclineErrors = { +export type PostAuthOauth2Token2Errors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PostV1TimeoffTimeoffIdCancelRequestDeclineError = - PostV1TimeoffTimeoffIdCancelRequestDeclineErrors[keyof PostV1TimeoffTimeoffIdCancelRequestDeclineErrors]; +export type PostAuthOauth2Token2Error = + PostAuthOauth2Token2Errors[keyof PostAuthOauth2Token2Errors]; -export type PostV1TimeoffTimeoffIdCancelRequestDeclineResponses = { +export type PostAuthOauth2Token2Responses = { /** * Success */ - 200: SuccessResponse; + 200: OAuth2Tokens; }; -export type PostV1TimeoffTimeoffIdCancelRequestDeclineResponse = - PostV1TimeoffTimeoffIdCancelRequestDeclineResponses[keyof PostV1TimeoffTimeoffIdCancelRequestDeclineResponses]; +export type PostAuthOauth2Token2Response = + PostAuthOauth2Token2Responses[keyof PostAuthOauth2Token2Responses]; -export type PutV2EmploymentsEmploymentIdAdministrativeDetailsData = { - /** - * Employment administrative details params - */ - body?: EmploymentAdministrativeDetailsParams; +export type GetV1EmployeeDocumentsIdData = { + body?: never; path: { /** - * Employment ID + * Document ID */ - employment_id: string; + id: string; }; query?: never; - url: '/v2/employments/{employment_id}/administrative_details'; + url: '/v1/employee/documents/{id}'; }; -export type PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmployeeDocumentsIdErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdAdministrativeDetailsError = - PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors[keyof PutV2EmploymentsEmploymentIdAdministrativeDetailsErrors]; +export type GetV1EmployeeDocumentsIdError = + GetV1EmployeeDocumentsIdErrors[keyof GetV1EmployeeDocumentsIdErrors]; -export type PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses = { +export type GetV1EmployeeDocumentsIdResponses = { /** * Success */ - 200: EmploymentResponse; + 200: DownloadDocumentResponse; }; -export type PutV2EmploymentsEmploymentIdAdministrativeDetailsResponse = - PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses[keyof PutV2EmploymentsEmploymentIdAdministrativeDetailsResponses]; +export type GetV1EmployeeDocumentsIdResponse = + GetV1EmployeeDocumentsIdResponses[keyof GetV1EmployeeDocumentsIdResponses]; -export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaData = { - body?: never; - path: { - /** - * Unique identifier of the employment - */ - employment_id: UuidSlug; - }; - query?: { - /** - * Version of the form schema - */ - json_schema_version?: number | 'latest'; - }; - url: '/v1/employments/{employment_id}/benefit-offers/schema'; +export type PostV1WebhookEventsReplayData = { + /** + * WebhookEvent + */ + body: ReplayWebhookEventsParams; + path?: never; + query?: never; + url: '/v1/webhook-events/replay'; }; -export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors = { +export type PostV1WebhookEventsReplayErrors = { /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ @@ -18004,78 +18813,74 @@ export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaError = - GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors[keyof GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors]; +export type PostV1WebhookEventsReplayError = + PostV1WebhookEventsReplayErrors[keyof PostV1WebhookEventsReplayErrors]; -export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses = { +export type PostV1WebhookEventsReplayResponses = { /** * Success */ - 200: UnifiedEmploymentsBenefitOffersJsonSchemaResponse; + 200: SuccessResponse; }; -export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponse = - GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses[keyof GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses]; +export type PostV1WebhookEventsReplayResponse = + PostV1WebhookEventsReplayResponses[keyof PostV1WebhookEventsReplayResponses]; -export type PostV1ContractorsEligibilityQuestionnaireData = { +export type PostV1SandboxWebhookCallbacksTriggerData = { /** - * Eligibility questionnaire submission + * Webhook Trigger Params */ - body: SubmitEligibilityQuestionnaireRequest; + body?: WebhookTriggerParams; path?: never; - query?: { - /** - * Version of the form schema - */ - json_schema_version?: number | 'latest'; - }; - url: '/v1/contractors/eligibility-questionnaire'; + query?: never; + url: '/v1/sandbox/webhook-callbacks/trigger'; }; -export type PostV1ContractorsEligibilityQuestionnaireErrors = { +export type PostV1SandboxWebhookCallbacksTriggerErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Conflict + * Not Found */ - 409: ConflictErrorResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; }; -export type PostV1ContractorsEligibilityQuestionnaireError = - PostV1ContractorsEligibilityQuestionnaireErrors[keyof PostV1ContractorsEligibilityQuestionnaireErrors]; +export type PostV1SandboxWebhookCallbacksTriggerError = + PostV1SandboxWebhookCallbacksTriggerErrors[keyof PostV1SandboxWebhookCallbacksTriggerErrors]; -export type PostV1ContractorsEligibilityQuestionnaireResponses = { +export type PostV1SandboxWebhookCallbacksTriggerResponses = { /** - * Questionnaire submitted successfully + * Success */ - 201: EligibilityQuestionnaireResponse; + 200: SuccessResponse; }; -export type PostV1ContractorsEligibilityQuestionnaireResponse = - PostV1ContractorsEligibilityQuestionnaireResponses[keyof PostV1ContractorsEligibilityQuestionnaireResponses]; +export type PostV1SandboxWebhookCallbacksTriggerResponse = + PostV1SandboxWebhookCallbacksTriggerResponses[keyof PostV1SandboxWebhookCallbacksTriggerResponses]; -export type GetV1EmployeePersonalInformationData = { +export type GetV1BulkEmploymentJobsJobIdData = { body?: never; - path?: never; + path: { + /** + * Bulk employment job id + */ + job_id: string; + }; query?: never; - url: '/v1/employee/personal-information'; + url: '/v1/bulk-employment-jobs/{job_id}'; }; -export type GetV1EmployeePersonalInformationErrors = { +export type GetV1BulkEmploymentJobsJobIdErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** * Forbidden */ @@ -18084,37 +18889,34 @@ export type GetV1EmployeePersonalInformationErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1EmployeePersonalInformationError = - GetV1EmployeePersonalInformationErrors[keyof GetV1EmployeePersonalInformationErrors]; +export type GetV1BulkEmploymentJobsJobIdError = + GetV1BulkEmploymentJobsJobIdErrors[keyof GetV1BulkEmploymentJobsJobIdErrors]; -export type GetV1EmployeePersonalInformationResponses = { +export type GetV1BulkEmploymentJobsJobIdResponses = { /** * Success */ - 200: SuccessResponse; + 200: BulkEmploymentImportJobResponse; }; -export type GetV1EmployeePersonalInformationResponse = - GetV1EmployeePersonalInformationResponses[keyof GetV1EmployeePersonalInformationResponses]; +export type GetV1BulkEmploymentJobsJobIdResponse = + GetV1BulkEmploymentJobsJobIdResponses[keyof GetV1BulkEmploymentJobsJobIdResponses]; -export type GetV1TimesheetsData = { +export type GetV1BulkEmploymentJobsJobIdRowsData = { body?: never; - path?: never; - query?: { - /** - * Filter timesheets by their status - */ - status?: TimesheetStatus; - /** - * Sort order - */ - order?: 'asc' | 'desc'; + path: { /** - * Field to sort by + * Bulk employment job id */ - sort_by?: 'submitted_at'; + job_id: string; + }; + query?: { /** * Starts fetching records after the given page */ @@ -18124,14 +18926,18 @@ export type GetV1TimesheetsData = { */ page_size?: number; }; - url: '/v1/timesheets'; + url: '/v1/bulk-employment-jobs/{job_id}/rows'; }; -export type GetV1TimesheetsErrors = { +export type GetV1BulkEmploymentJobsJobIdRowsErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ @@ -18139,32 +18945,27 @@ export type GetV1TimesheetsErrors = { /** * Unprocessable Entity */ - 422: UnprocessableEntityResponse; + 429: TooManyRequestsResponse; }; -export type GetV1TimesheetsError = - GetV1TimesheetsErrors[keyof GetV1TimesheetsErrors]; +export type GetV1BulkEmploymentJobsJobIdRowsError = + GetV1BulkEmploymentJobsJobIdRowsErrors[keyof GetV1BulkEmploymentJobsJobIdRowsErrors]; -export type GetV1TimesheetsResponses = { +export type GetV1BulkEmploymentJobsJobIdRowsResponses = { /** * Success */ - 200: ListTimesheetsResponse; + 200: ImportJobRowsResponse; }; -export type GetV1TimesheetsResponse = - GetV1TimesheetsResponses[keyof GetV1TimesheetsResponses]; +export type GetV1BulkEmploymentJobsJobIdRowsResponse = + GetV1BulkEmploymentJobsJobIdRowsResponses[keyof GetV1BulkEmploymentJobsJobIdRowsResponses]; -export type PostV1SandboxCompaniesCompanyIdLegalEntitiesData = { +export type PostV1MagicLinkData = { /** - * Create legal entity params + * Magic links generator body */ - body?: { - /** - * ISO 3166-1 alpha-3 country code - */ - country_code: string; - }; + body: MagicLinkParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -18174,68 +18975,32 @@ export type PostV1SandboxCompaniesCompanyIdLegalEntitiesData = { */ Authorization: string; }; - path: { - /** - * Company ID - */ - company_id: string; - }; + path?: never; query?: never; - url: '/v1/sandbox/companies/{company_id}/legal-entities'; + url: '/v1/magic-link'; }; -export type PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; +export type PostV1MagicLinkErrors = { /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PostV1SandboxCompaniesCompanyIdLegalEntitiesError = - PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors[keyof PostV1SandboxCompaniesCompanyIdLegalEntitiesErrors]; +export type PostV1MagicLinkError = + PostV1MagicLinkErrors[keyof PostV1MagicLinkErrors]; -export type PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses = { +export type PostV1MagicLinkResponses = { /** - * Legal entity created + * Success */ - 201: { - data?: { - /** - * Legal entity slug - */ - legal_entity_id?: string; - /** - * Legal entity name - */ - name?: string; - /** - * Legal entity status - */ - status?: string; - }; - }; + 200: MagicLinkResponse; }; -export type PostV1SandboxCompaniesCompanyIdLegalEntitiesResponse = - PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses[keyof PostV1SandboxCompaniesCompanyIdLegalEntitiesResponses]; +export type PostV1MagicLinkResponse = + PostV1MagicLinkResponses[keyof PostV1MagicLinkResponses]; -export type GetV1EmploymentsEmploymentIdData = { +export type GetV1CompaniesCompanyIdData = { body?: never; headers: { /** @@ -18248,60 +19013,55 @@ export type GetV1EmploymentsEmploymentIdData = { }; path: { /** - * Employment ID - */ - employment_id: string; - }; - query?: { - /** - * Wether files should be excluded + * Company ID */ - exclude_files?: boolean; + company_id: string; }; - url: '/v1/employments/{employment_id}'; + query?: never; + url: '/v1/companies/{company_id}'; }; -export type GetV1EmploymentsEmploymentIdErrors = { +export type GetV1CompaniesCompanyIdErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type GetV1EmploymentsEmploymentIdError = - GetV1EmploymentsEmploymentIdErrors[keyof GetV1EmploymentsEmploymentIdErrors]; +export type GetV1CompaniesCompanyIdError = + GetV1CompaniesCompanyIdErrors[keyof GetV1CompaniesCompanyIdErrors]; -export type GetV1EmploymentsEmploymentIdResponses = { +export type GetV1CompaniesCompanyIdResponses = { /** * Success */ - 200: EmploymentShowResponse; + 200: CompanyResponse; }; -export type GetV1EmploymentsEmploymentIdResponse = - GetV1EmploymentsEmploymentIdResponses[keyof GetV1EmploymentsEmploymentIdResponses]; +export type GetV1CompaniesCompanyIdResponse = + GetV1CompaniesCompanyIdResponses[keyof GetV1CompaniesCompanyIdResponses]; -export type PatchV1EmploymentsEmploymentId2Data = { +export type PatchV1CompaniesCompanyId2Data = { /** - * Employment params + * Update Company params */ - body?: EmploymentFullParams; + body?: UpdateCompanyParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -18313,100 +19073,65 @@ export type PatchV1EmploymentsEmploymentId2Data = { }; path: { /** - * Employment ID + * Company ID + * */ - employment_id: string; + company_id: string; }; query?: { /** * Version of the address_details form schema */ address_details_json_schema_version?: number | 'latest'; - /** - * Version of the administrative_details form schema - */ - administrative_details_json_schema_version?: number | 'latest'; /** * Version of the bank_account_details form schema */ bank_account_details_json_schema_version?: number | 'latest'; - /** - * Version of the employment_basic_information form schema - */ - employment_basic_information_json_schema_version?: number | 'latest'; - /** - * Version of the billing_address_details form schema - */ - billing_address_details_json_schema_version?: number | 'latest'; - /** - * Version of the contract_details form schema - */ - contract_details_json_schema_version?: number | 'latest'; - /** - * Version of the emergency_contact_details form schema - */ - emergency_contact_details_json_schema_version?: number | 'latest'; - /** - * Version of the personal_details form schema - */ - personal_details_json_schema_version?: number | 'latest'; - /** - * Version of the pricing_plan_details form schema - */ - pricing_plan_details_json_schema_version?: number | 'latest'; - /** - * Skips the dynamic benefits part of the schema if set. To be used when benefits are set via its own API. - */ - skip_benefits?: boolean; - /** - * Complementary action(s) to perform when creating an employment. - */ - actions?: string; }; - url: '/v1/employments/{employment_id}'; + url: '/v1/companies/{company_id}'; }; -export type PatchV1EmploymentsEmploymentId2Errors = { +export type PatchV1CompaniesCompanyId2Errors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PatchV1EmploymentsEmploymentId2Error = - PatchV1EmploymentsEmploymentId2Errors[keyof PatchV1EmploymentsEmploymentId2Errors]; +export type PatchV1CompaniesCompanyId2Error = + PatchV1CompaniesCompanyId2Errors[keyof PatchV1CompaniesCompanyId2Errors]; -export type PatchV1EmploymentsEmploymentId2Responses = { +export type PatchV1CompaniesCompanyId2Responses = { /** * Success */ - 200: EmploymentResponse; + 200: CompanyResponse; }; -export type PatchV1EmploymentsEmploymentId2Response = - PatchV1EmploymentsEmploymentId2Responses[keyof PatchV1EmploymentsEmploymentId2Responses]; +export type PatchV1CompaniesCompanyId2Response = + PatchV1CompaniesCompanyId2Responses[keyof PatchV1CompaniesCompanyId2Responses]; -export type PatchV1EmploymentsEmploymentIdData = { +export type PatchV1CompaniesCompanyIdData = { /** - * Employment params + * Update Company params */ - body?: EmploymentFullParams; + body?: UpdateCompanyParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -18418,169 +19143,160 @@ export type PatchV1EmploymentsEmploymentIdData = { }; path: { /** - * Employment ID + * Company ID + * */ - employment_id: string; + company_id: string; }; query?: { /** * Version of the address_details form schema */ address_details_json_schema_version?: number | 'latest'; - /** - * Version of the administrative_details form schema - */ - administrative_details_json_schema_version?: number | 'latest'; /** * Version of the bank_account_details form schema */ bank_account_details_json_schema_version?: number | 'latest'; - /** - * Version of the employment_basic_information form schema - */ - employment_basic_information_json_schema_version?: number | 'latest'; - /** - * Version of the billing_address_details form schema - */ - billing_address_details_json_schema_version?: number | 'latest'; - /** - * Version of the contract_details form schema - */ - contract_details_json_schema_version?: number | 'latest'; - /** - * Version of the emergency_contact_details form schema - */ - emergency_contact_details_json_schema_version?: number | 'latest'; - /** - * Version of the personal_details form schema - */ - personal_details_json_schema_version?: number | 'latest'; - /** - * Version of the pricing_plan_details form schema - */ - pricing_plan_details_json_schema_version?: number | 'latest'; - /** - * Skips the dynamic benefits part of the schema if set. To be used when benefits are set via its own API. - */ - skip_benefits?: boolean; - /** - * Complementary action(s) to perform when creating an employment. - */ - actions?: string; }; - url: '/v1/employments/{employment_id}'; + url: '/v1/companies/{company_id}'; }; -export type PatchV1EmploymentsEmploymentIdErrors = { +export type PatchV1CompaniesCompanyIdErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Unprocessable Entity + * Too many requests */ 429: TooManyRequestsResponse; }; -export type PatchV1EmploymentsEmploymentIdError = - PatchV1EmploymentsEmploymentIdErrors[keyof PatchV1EmploymentsEmploymentIdErrors]; +export type PatchV1CompaniesCompanyIdError = + PatchV1CompaniesCompanyIdErrors[keyof PatchV1CompaniesCompanyIdErrors]; -export type PatchV1EmploymentsEmploymentIdResponses = { +export type PatchV1CompaniesCompanyIdResponses = { /** * Success */ - 200: EmploymentResponse; + 200: CompanyResponse; }; -export type PatchV1EmploymentsEmploymentIdResponse = - PatchV1EmploymentsEmploymentIdResponses[keyof PatchV1EmploymentsEmploymentIdResponses]; +export type PatchV1CompaniesCompanyIdResponse = + PatchV1CompaniesCompanyIdResponses[keyof PatchV1CompaniesCompanyIdResponses]; -export type GetV1ScimV2UsersData = { +export type GetV1CompaniesSchemaData = { body?: never; path?: never; - query?: { + query: { /** - * 1-based index of the first result + * Country code according to ISO 3-digit alphabetic codes. */ - startIndex?: number; + country_code: string; /** - * Maximum number of results per page + * Name of the desired form */ - count?: number; + form: 'address_details'; /** - * Filter expression for attributes (supports eq, ne, co, sw, ew, pr, lt, le, gt, ge) + * Version of the form schema */ - filter?: string; + json_schema_version?: number | 'latest'; }; - url: '/v1/scim/v2/Users'; + url: '/v1/companies/schema'; +}; + +export type GetV1CompaniesSchemaErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type GetV1CompaniesSchemaError = + GetV1CompaniesSchemaErrors[keyof GetV1CompaniesSchemaErrors]; + +export type GetV1CompaniesSchemaResponses = { + /** + * Success + */ + 200: CompanyFormResponse; +}; + +export type GetV1CompaniesSchemaResponse = + GetV1CompaniesSchemaResponses[keyof GetV1CompaniesSchemaResponses]; + +export type GetV1PricingPlanPartnerTemplatesData = { + body?: never; + path?: never; + query?: never; + url: '/v1/pricing-plan-partner-templates'; }; -export type GetV1ScimV2UsersErrors = { - /** - * Bad Request - */ - 400: IntegrationsScimErrorResponse; +export type GetV1PricingPlanPartnerTemplatesErrors = { /** * Unauthorized */ - 401: IntegrationsScimErrorResponse; + 401: UnauthorizedResponse; /** - * Forbidden + * Not Found */ - 403: IntegrationsScimErrorResponse; + 404: NotFoundResponse; /** - * Not Found + * Unprocessable Entity */ - 404: IntegrationsScimErrorResponse; + 422: UnprocessableEntityResponse; }; -export type GetV1ScimV2UsersError = - GetV1ScimV2UsersErrors[keyof GetV1ScimV2UsersErrors]; +export type GetV1PricingPlanPartnerTemplatesError = + GetV1PricingPlanPartnerTemplatesErrors[keyof GetV1PricingPlanPartnerTemplatesErrors]; -export type GetV1ScimV2UsersResponses = { +export type GetV1PricingPlanPartnerTemplatesResponses = { /** * Success */ - 200: IntegrationsScimUserListResponse; + 200: ListPricingPlanPartnerTemplatesResponse; }; -export type GetV1ScimV2UsersResponse = - GetV1ScimV2UsersResponses[keyof GetV1ScimV2UsersResponses]; +export type GetV1PricingPlanPartnerTemplatesResponse = + GetV1PricingPlanPartnerTemplatesResponses[keyof GetV1PricingPlanPartnerTemplatesResponses]; -export type GetV1PayrollCalendarsCycleData = { +export type GetV1CountriesCountryCodeEngagementAgreementDetailsData = { body?: never; path: { /** - * The cycle for which to list the payroll calendars. Format: YYYY-MM - */ - cycle: string; - }; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page + * Country code according to ISO 3-digit alphabetic codes */ - page_size?: number; + country_code: string; }; - url: '/v1/payroll-calendars/{cycle}'; + query?: never; + url: '/v1/countries/{country_code}/engagement-agreement-details'; }; -export type GetV1PayrollCalendarsCycleErrors = { +export type GetV1CountriesCountryCodeEngagementAgreementDetailsErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -18593,133 +19309,24 @@ export type GetV1PayrollCalendarsCycleErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1PayrollCalendarsCycleError = - GetV1PayrollCalendarsCycleErrors[keyof GetV1PayrollCalendarsCycleErrors]; +export type GetV1CountriesCountryCodeEngagementAgreementDetailsError = + GetV1CountriesCountryCodeEngagementAgreementDetailsErrors[keyof GetV1CountriesCountryCodeEngagementAgreementDetailsErrors]; -export type GetV1PayrollCalendarsCycleResponses = { +export type GetV1CountriesCountryCodeEngagementAgreementDetailsResponses = { /** * Success */ - 200: PayrollCalendarsResponse; + 200: EngagementAgreementDetailsResponse; }; -export type GetV1PayrollCalendarsCycleResponse = - GetV1PayrollCalendarsCycleResponses[keyof GetV1PayrollCalendarsCycleResponses]; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData = - { - body?: never; - path: { - /** - * Company ID - */ - company_id: UuidSlug; - /** - * Legal entity ID - */ - legal_entity_id: UuidSlug; - }; - query?: never; - url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details'; - }; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors = - { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - }; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsError = - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors]; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses = - { - /** - * ShowLegalEntityAdministrativeDetailsResponse - * - * Country specific json schema driven administrative details for legal entities - */ - 200: { - data: { - [key: string]: unknown; - }; - }; - }; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponse = - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses]; - -export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsData = - { - /** - * Legal entity administrative details params - */ - body?: AdministrativeDetailsParams; - path: { - /** - * Company ID - */ - company_id: UuidSlug; - /** - * Legal entity ID - */ - legal_entity_id: UuidSlug; - }; - query?: never; - url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/administrative-details'; - }; - -export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors = - { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; - }; - -export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsError = - PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors[keyof PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsErrors]; - -export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses = - { - /** - * ShowLegalEntityAdministrativeDetailsResponse - * - * Country specific json schema driven administrative details for legal entities - */ - 200: { - data: { - [key: string]: unknown; - }; - }; - }; - -export type PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponse = - PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses[keyof PutV1CompaniesCompanyIdLegalEntitiesLegalEntityIdAdministrativeDetailsResponses]; +export type GetV1CountriesCountryCodeEngagementAgreementDetailsResponse = + GetV1CountriesCountryCodeEngagementAgreementDetailsResponses[keyof GetV1CountriesCountryCodeEngagementAgreementDetailsResponses]; export type PutV2EmploymentsEmploymentIdContractDetailsData = { /** @@ -18789,64 +19396,19 @@ export type PutV2EmploymentsEmploymentIdContractDetailsResponses = { export type PutV2EmploymentsEmploymentIdContractDetailsResponse = PutV2EmploymentsEmploymentIdContractDetailsResponses[keyof PutV2EmploymentsEmploymentIdContractDetailsResponses]; -export type GetV1CostCalculatorRegionsSlugFieldsData = { - body?: never; - path: { - /** - * Slug - */ - slug: string; - }; - query?: { - /** - * If the premium benefits should be included in the response - */ - include_premium_benefits?: boolean; - }; - url: '/v1/cost-calculator/regions/{slug}/fields'; -}; - -export type GetV1CostCalculatorRegionsSlugFieldsErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Internal Server Error - */ - 500: InternalServerErrorResponse; -}; - -export type GetV1CostCalculatorRegionsSlugFieldsError = - GetV1CostCalculatorRegionsSlugFieldsErrors[keyof GetV1CostCalculatorRegionsSlugFieldsErrors]; - -export type GetV1CostCalculatorRegionsSlugFieldsResponses = { - /** - * Success - */ - 200: JsonSchemaResponse; -}; - -export type GetV1CostCalculatorRegionsSlugFieldsResponse = - GetV1CostCalculatorRegionsSlugFieldsResponses[keyof GetV1CostCalculatorRegionsSlugFieldsResponses]; - -export type GetV1OffboardingsIdData = { +export type GetV1CompaniesCompanyIdProductPricesData = { body?: never; path: { /** - * Offboarding request ID + * Company ID */ - id: string; + company_id: UuidSlug; }; query?: never; - url: '/v1/offboardings/{id}'; + url: '/v1/companies/{company_id}/product-prices'; }; -export type GetV1OffboardingsIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1CompaniesCompanyIdProductPricesErrors = { /** * Unauthorized */ @@ -18859,47 +19421,39 @@ export type GetV1OffboardingsIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type GetV1OffboardingsIdError = - GetV1OffboardingsIdErrors[keyof GetV1OffboardingsIdErrors]; +export type GetV1CompaniesCompanyIdProductPricesError = + GetV1CompaniesCompanyIdProductPricesErrors[keyof GetV1CompaniesCompanyIdProductPricesErrors]; -export type GetV1OffboardingsIdResponses = { +export type GetV1CompaniesCompanyIdProductPricesResponses = { /** * Success */ - 200: OffboardingResponse; + 200: ListProductPricesResponse; }; -export type GetV1OffboardingsIdResponse = - GetV1OffboardingsIdResponses[keyof GetV1OffboardingsIdResponses]; +export type GetV1CompaniesCompanyIdProductPricesResponse = + GetV1CompaniesCompanyIdProductPricesResponses[keyof GetV1CompaniesCompanyIdProductPricesResponses]; -export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsData = { +export type PostV1CompaniesCompanyIdCreateTokenData = { body?: never; path: { /** - * Payroll run ID + * The ID of the company */ - payroll_run_id: string; + company_id: string; }; query?: { /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page + * The scope of the token */ - page_size?: number; + scope?: string; }; - url: '/v1/payroll-runs/{payroll_run_id}/employee-details'; + url: '/v1/companies/{company_id}/create-token'; }; -export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors = { +export type PostV1CompaniesCompanyIdCreateTokenErrors = { /** * Unauthorized */ @@ -18914,49 +19468,36 @@ export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsError = - GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors[keyof GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors]; +export type PostV1CompaniesCompanyIdCreateTokenError = + PostV1CompaniesCompanyIdCreateTokenErrors[keyof PostV1CompaniesCompanyIdCreateTokenErrors]; -export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses = { +export type PostV1CompaniesCompanyIdCreateTokenResponses = { /** * Success */ - 200: EmployeeDetailsResponse; + 200: CompanyTokenResponse; }; -export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponse = - GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses[keyof GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses]; +export type PostV1CompaniesCompanyIdCreateTokenResponse = + PostV1CompaniesCompanyIdCreateTokenResponses[keyof PostV1CompaniesCompanyIdCreateTokenResponses]; -export type GetV1BulkEmploymentJobsJobIdRowsData = { +export type GetV1IdentityVerificationEmploymentIdData = { body?: never; path: { /** - * Bulk employment job id - */ - job_id: string; - }; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page + * Employment ID */ - page_size?: number; + employment_id: string; }; - url: '/v1/bulk-employment-jobs/{job_id}/rows'; + query?: never; + url: '/v1/identity-verification/{employment_id}'; }; -export type GetV1BulkEmploymentJobsJobIdRowsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1IdentityVerificationEmploymentIdErrors = { /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ @@ -18964,42 +19505,39 @@ export type GetV1BulkEmploymentJobsJobIdRowsErrors = { /** * Unprocessable Entity */ - 429: TooManyRequestsResponse; + 422: UnprocessableEntityResponse; }; -export type GetV1BulkEmploymentJobsJobIdRowsError = - GetV1BulkEmploymentJobsJobIdRowsErrors[keyof GetV1BulkEmploymentJobsJobIdRowsErrors]; +export type GetV1IdentityVerificationEmploymentIdError = + GetV1IdentityVerificationEmploymentIdErrors[keyof GetV1IdentityVerificationEmploymentIdErrors]; -export type GetV1BulkEmploymentJobsJobIdRowsResponses = { +export type GetV1IdentityVerificationEmploymentIdResponses = { /** * Success */ - 200: ImportJobRowsResponse; + 200: IdentityVerificationResponse; }; -export type GetV1BulkEmploymentJobsJobIdRowsResponse = - GetV1BulkEmploymentJobsJobIdRowsResponses[keyof GetV1BulkEmploymentJobsJobIdRowsResponses]; +export type GetV1IdentityVerificationEmploymentIdResponse = + GetV1IdentityVerificationEmploymentIdResponses[keyof GetV1IdentityVerificationEmploymentIdResponses]; -export type PostV1SandboxEmploymentsData = { - /** - * Employment params - */ - body?: EmploymentCreateParams; - headers: { +export type GetV1ExpensesExpenseIdReceiptsReceiptIdData = { + body?: never; + path: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * The expense ID */ - Authorization: string; + expense_id: string; + /** + * The receipt ID + */ + receipt_id: string; }; - path?: never; query?: never; - url: '/v1/sandbox/employments'; + url: '/v1/expenses/{expense_id}/receipts/{receipt_id}'; }; -export type PostV1SandboxEmploymentsErrors = { +export type GetV1ExpensesExpenseIdReceiptsReceiptIdErrors = { /** * Bad Request */ @@ -19008,6 +19546,10 @@ export type PostV1SandboxEmploymentsErrors = { * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ @@ -19017,83 +19559,98 @@ export type PostV1SandboxEmploymentsErrors = { */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type PostV1SandboxEmploymentsError = - PostV1SandboxEmploymentsErrors[keyof PostV1SandboxEmploymentsErrors]; +export type GetV1ExpensesExpenseIdReceiptsReceiptIdError = + GetV1ExpensesExpenseIdReceiptsReceiptIdErrors[keyof GetV1ExpensesExpenseIdReceiptsReceiptIdErrors]; -export type PostV1SandboxEmploymentsResponses = { +export type GetV1ExpensesExpenseIdReceiptsReceiptIdResponses = { /** * Success */ - 201: EmploymentCreationResponse; + 200: GenericFile; }; -export type PostV1SandboxEmploymentsResponse = - PostV1SandboxEmploymentsResponses[keyof PostV1SandboxEmploymentsResponses]; +export type GetV1ExpensesExpenseIdReceiptsReceiptIdResponse = + GetV1ExpensesExpenseIdReceiptsReceiptIdResponses[keyof GetV1ExpensesExpenseIdReceiptsReceiptIdResponses]; -export type PostV1EmploymentsEmploymentIdContractEligibilityData = { - /** - * Contract Eligibility Create Parameters - */ - body: CreateContractEligibilityParams; - path: { +export type GetV1ScimV2GroupsData = { + body?: never; + path?: never; + query?: { /** - * Employment ID + * 1-based index of the first result */ - employment_id: string; + startIndex?: number; + /** + * Maximum number of results per page + */ + count?: number; + /** + * Filter expression for attributes (supports eq, ne, co, sw, ew, pr, lt, le, gt, ge) + */ + filter?: string; }; - query?: never; - url: '/v1/employments/{employment_id}/contract-eligibility'; + url: '/v1/scim/v2/Groups'; }; -export type PostV1EmploymentsEmploymentIdContractEligibilityErrors = { +export type GetV1ScimV2GroupsErrors = { /** * Bad Request */ - 400: BadRequestResponse; + 400: IntegrationsScimErrorResponse; /** - * Unprocessable Entity + * Unauthorized */ - 422: UnprocessableEntityResponse; + 401: IntegrationsScimErrorResponse; /** - * Unprocessable Entity + * Forbidden */ - 429: TooManyRequestsResponse; + 403: IntegrationsScimErrorResponse; + /** + * Not Found + */ + 404: IntegrationsScimErrorResponse; }; -export type PostV1EmploymentsEmploymentIdContractEligibilityError = - PostV1EmploymentsEmploymentIdContractEligibilityErrors[keyof PostV1EmploymentsEmploymentIdContractEligibilityErrors]; +export type GetV1ScimV2GroupsError = + GetV1ScimV2GroupsErrors[keyof GetV1ScimV2GroupsErrors]; -export type PostV1EmploymentsEmploymentIdContractEligibilityResponses = { +export type GetV1ScimV2GroupsResponses = { /** * Success */ - 200: SuccessResponse; + 200: IntegrationsScimGroupListResponse; }; -export type PostV1EmploymentsEmploymentIdContractEligibilityResponse = - PostV1EmploymentsEmploymentIdContractEligibilityResponses[keyof PostV1EmploymentsEmploymentIdContractEligibilityResponses]; +export type GetV1ScimV2GroupsResponse = + GetV1ScimV2GroupsResponses[keyof GetV1ScimV2GroupsResponses]; -export type GetV1CountriesData = { +export type GetV1ExpensesIdData = { body?: never; headers: { /** - * This endpoint works with any of the access tokens provided. You can use an access - * token obtained through the Client Credentials flow, the Authorization Code flow, or the Refresh Token flow. + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. * */ Authorization: string; }; - path?: never; + path: { + /** + * Expense ID + */ + id: string; + }; query?: never; - url: '/v1/countries'; + url: '/v1/expenses/{id}'; }; -export type GetV1CountriesErrors = { +export type GetV1ExpensesIdErrors = { /** * Bad Request */ @@ -19116,81 +19673,39 @@ export type GetV1CountriesErrors = { 429: TooManyRequestsResponse; }; -export type GetV1CountriesError = - GetV1CountriesErrors[keyof GetV1CountriesErrors]; +export type GetV1ExpensesIdError = + GetV1ExpensesIdErrors[keyof GetV1ExpensesIdErrors]; -export type GetV1CountriesResponses = { +export type GetV1ExpensesIdResponses = { /** * Success */ - 200: CountriesResponse; -}; - -export type GetV1CountriesResponse = - GetV1CountriesResponses[keyof GetV1CountriesResponses]; - -export type GetV1EmployeePayslipFilesData = { - body?: never; - path?: never; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page - */ - page_size?: number; - }; - url: '/v1/employee/payslip-files'; -}; - -export type GetV1EmployeePayslipFilesErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; + 200: ExpenseResponse; }; -export type GetV1EmployeePayslipFilesError = - GetV1EmployeePayslipFilesErrors[keyof GetV1EmployeePayslipFilesErrors]; +export type GetV1ExpensesIdResponse = + GetV1ExpensesIdResponses[keyof GetV1ExpensesIdResponses]; -export type GetV1EmployeePayslipFilesResponses = { +export type PatchV1ExpensesId2Data = { /** - * Success + * Expenses */ - 200: ListPayslipFilesResponse; -}; - -export type GetV1EmployeePayslipFilesResponse = - GetV1EmployeePayslipFilesResponses[keyof GetV1EmployeePayslipFilesResponses]; - -export type PostV1CompaniesCompanyIdCreateTokenData = { - body?: never; + body?: UpdateExpenseParams; path: { /** - * The ID of the company - */ - company_id: string; - }; - query?: { - /** - * The scope of the token + * Expense ID */ - scope?: string; + id: string; }; - url: '/v1/companies/{company_id}/create-token'; + query?: never; + url: '/v1/expenses/{id}'; }; -export type PostV1CompaniesCompanyIdCreateTokenErrors = { +export type PatchV1ExpensesId2Errors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -19199,47 +19714,53 @@ export type PostV1CompaniesCompanyIdCreateTokenErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type PostV1CompaniesCompanyIdCreateTokenError = - PostV1CompaniesCompanyIdCreateTokenErrors[keyof PostV1CompaniesCompanyIdCreateTokenErrors]; +export type PatchV1ExpensesId2Error = + PatchV1ExpensesId2Errors[keyof PatchV1ExpensesId2Errors]; -export type PostV1CompaniesCompanyIdCreateTokenResponses = { +export type PatchV1ExpensesId2Responses = { /** * Success */ - 200: CompanyTokenResponse; + 200: ExpenseResponse; }; -export type PostV1CompaniesCompanyIdCreateTokenResponse = - PostV1CompaniesCompanyIdCreateTokenResponses[keyof PostV1CompaniesCompanyIdCreateTokenResponses]; +export type PatchV1ExpensesId2Response = + PatchV1ExpensesId2Responses[keyof PatchV1ExpensesId2Responses]; -export type GetV1CompaniesCompanyIdLegalEntitiesData = { - body?: never; +export type PatchV1ExpensesIdData = { + /** + * Expenses + */ + body?: UpdateExpenseParams; path: { /** - * Company ID - */ - company_id: UuidSlug; - }; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page + * Expense ID */ - page_size?: number; + id: string; }; - url: '/v1/companies/{company_id}/legal-entities'; + query?: never; + url: '/v1/expenses/{id}'; }; -export type GetV1CompaniesCompanyIdLegalEntitiesErrors = { +export type PatchV1ExpensesIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -19248,37 +19769,54 @@ export type GetV1CompaniesCompanyIdLegalEntitiesErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1CompaniesCompanyIdLegalEntitiesError = - GetV1CompaniesCompanyIdLegalEntitiesErrors[keyof GetV1CompaniesCompanyIdLegalEntitiesErrors]; +export type PatchV1ExpensesIdError = + PatchV1ExpensesIdErrors[keyof PatchV1ExpensesIdErrors]; -export type GetV1CompaniesCompanyIdLegalEntitiesResponses = { +export type PatchV1ExpensesIdResponses = { /** * Success */ - 200: ListCompanyLegalEntitiesResponse; + 200: ExpenseResponse; }; -export type GetV1CompaniesCompanyIdLegalEntitiesResponse = - GetV1CompaniesCompanyIdLegalEntitiesResponses[keyof GetV1CompaniesCompanyIdLegalEntitiesResponses]; +export type PatchV1ExpensesIdResponse = + PatchV1ExpensesIdResponses[keyof PatchV1ExpensesIdResponses]; -export type PutV2EmploymentsEmploymentIdPersonalDetailsData = { +export type PutV2EmploymentsEmploymentIdEmergencyContactData = { /** - * Employment personal details params + * Employment emergency contact params */ - body?: EmploymentPersonalDetailsParams; + body?: EmploymentEmergencyContactParams; path: { /** * Employment ID */ employment_id: string; }; - query?: never; - url: '/v2/employments/{employment_id}/personal_details'; + query?: { + /** + * Version of the emergency_contact_details form schema + */ + emergency_contact_details_json_schema_version?: number | 'latest'; + }; + url: '/v2/employments/{employment_id}/emergency_contact'; }; -export type PutV2EmploymentsEmploymentIdPersonalDetailsErrors = { +export type PutV2EmploymentsEmploymentIdEmergencyContactErrors = { /** * Bad Request */ @@ -19309,24 +19847,24 @@ export type PutV2EmploymentsEmploymentIdPersonalDetailsErrors = { 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdPersonalDetailsError = - PutV2EmploymentsEmploymentIdPersonalDetailsErrors[keyof PutV2EmploymentsEmploymentIdPersonalDetailsErrors]; +export type PutV2EmploymentsEmploymentIdEmergencyContactError = + PutV2EmploymentsEmploymentIdEmergencyContactErrors[keyof PutV2EmploymentsEmploymentIdEmergencyContactErrors]; -export type PutV2EmploymentsEmploymentIdPersonalDetailsResponses = { +export type PutV2EmploymentsEmploymentIdEmergencyContactResponses = { /** * Success */ 200: EmploymentResponse; }; -export type PutV2EmploymentsEmploymentIdPersonalDetailsResponse = - PutV2EmploymentsEmploymentIdPersonalDetailsResponses[keyof PutV2EmploymentsEmploymentIdPersonalDetailsResponses]; +export type PutV2EmploymentsEmploymentIdEmergencyContactResponse = + PutV2EmploymentsEmploymentIdEmergencyContactResponses[keyof PutV2EmploymentsEmploymentIdEmergencyContactResponses]; -export type PostV1ReadyData = { +export type PostV1SandboxBenefitRenewalRequestsData = { /** - * Employment slug + * Benefit Renewal Request */ - body?: CompleteOnboarding; + body: BenefitRenewalRequestsCreateBenefitRenewalRequest; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -19338,22 +19876,18 @@ export type PostV1ReadyData = { }; path?: never; query?: never; - url: '/v1/ready'; + url: '/v1/sandbox/benefit-renewal-requests'; }; -export type PostV1ReadyErrors = { +export type PostV1SandboxBenefitRenewalRequestsErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Conflict + * Unauthorized */ - 409: ConflictResponse; + 401: UnauthorizedResponse; /** * Unprocessable Entity */ @@ -19364,20 +19898,24 @@ export type PostV1ReadyErrors = { 429: TooManyRequestsResponse; }; -export type PostV1ReadyError = PostV1ReadyErrors[keyof PostV1ReadyErrors]; +export type PostV1SandboxBenefitRenewalRequestsError = + PostV1SandboxBenefitRenewalRequestsErrors[keyof PostV1SandboxBenefitRenewalRequestsErrors]; -export type PostV1ReadyResponses = { +export type PostV1SandboxBenefitRenewalRequestsResponses = { /** * Success */ - 200: EmploymentResponse; + 200: BenefitRenewalRequestsCreateBenefitRenewalRequestResponse; }; -export type PostV1ReadyResponse = - PostV1ReadyResponses[keyof PostV1ReadyResponses]; +export type PostV1SandboxBenefitRenewalRequestsResponse = + PostV1SandboxBenefitRenewalRequestsResponses[keyof PostV1SandboxBenefitRenewalRequestsResponses]; -export type GetV1LeavePoliciesDetailsEmploymentIdData = { - body?: never; +export type PutV2EmploymentsEmploymentIdBasicInformationData = { + /** + * Employment basic information params + */ + body?: EmploymentBasicInformationParams; path: { /** * Employment ID @@ -19385,63 +19923,58 @@ export type GetV1LeavePoliciesDetailsEmploymentIdData = { employment_id: string; }; query?: never; - url: '/v1/leave-policies/details/{employment_id}'; + url: '/v2/employments/{employment_id}/basic_information'; }; -export type GetV1LeavePoliciesDetailsEmploymentIdErrors = { +export type PutV2EmploymentsEmploymentIdBasicInformationErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1LeavePoliciesDetailsEmploymentIdError = - GetV1LeavePoliciesDetailsEmploymentIdErrors[keyof GetV1LeavePoliciesDetailsEmploymentIdErrors]; +export type PutV2EmploymentsEmploymentIdBasicInformationError = + PutV2EmploymentsEmploymentIdBasicInformationErrors[keyof PutV2EmploymentsEmploymentIdBasicInformationErrors]; -export type GetV1LeavePoliciesDetailsEmploymentIdResponses = { +export type PutV2EmploymentsEmploymentIdBasicInformationResponses = { /** * Success */ - 200: ListLeavePoliciesDetailsResponse; + 200: EmploymentResponse; }; -export type GetV1LeavePoliciesDetailsEmploymentIdResponse = - GetV1LeavePoliciesDetailsEmploymentIdResponses[keyof GetV1LeavePoliciesDetailsEmploymentIdResponses]; +export type PutV2EmploymentsEmploymentIdBasicInformationResponse = + PutV2EmploymentsEmploymentIdBasicInformationResponses[keyof PutV2EmploymentsEmploymentIdBasicInformationResponses]; -export type GetV1TimeoffTypesData = { +export type GetV1LeavePoliciesSummaryEmploymentIdData = { body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; - path?: never; - query?: { + path: { /** - * Optional. Employment type to list time off types for: `contractor` or `full_time`. Omit for backward-compatible behavior (full-time types). + * Employment ID */ - type?: TimeoffTypesEmploymentType; + employment_id: string; }; - url: '/v1/timeoff/types'; + query?: never; + url: '/v1/leave-policies/summary/{employment_id}'; }; -export type GetV1TimeoffTypesErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1LeavePoliciesSummaryEmploymentIdErrors = { /** * Unauthorized */ @@ -19454,36 +19987,45 @@ export type GetV1TimeoffTypesErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type GetV1TimeoffTypesError = - GetV1TimeoffTypesErrors[keyof GetV1TimeoffTypesErrors]; +export type GetV1LeavePoliciesSummaryEmploymentIdError = + GetV1LeavePoliciesSummaryEmploymentIdErrors[keyof GetV1LeavePoliciesSummaryEmploymentIdErrors]; -export type GetV1TimeoffTypesResponses = { +export type GetV1LeavePoliciesSummaryEmploymentIdResponses = { /** * Success */ - 200: ListTimeoffTypesResponse; + 200: ListLeavePoliciesSummaryResponse; }; -export type GetV1TimeoffTypesResponse = - GetV1TimeoffTypesResponses[keyof GetV1TimeoffTypesResponses]; +export type GetV1LeavePoliciesSummaryEmploymentIdResponse = + GetV1LeavePoliciesSummaryEmploymentIdResponses[keyof GetV1LeavePoliciesSummaryEmploymentIdResponses]; -export type PostV1CostCalculatorEstimationCsvData = { +export type PostV1TimeoffTimeoffIdCancelData = { /** - * Estimate params + * CancelTimeoff */ - body?: CostCalculatorEstimateParams; - path?: never; + body: CancelTimeoffParams; + path: { + /** + * Time Off ID + */ + timeoff_id: string; + }; query?: never; - url: '/v1/cost-calculator/estimation-csv'; + url: '/v1/timeoff/{timeoff_id}/cancel'; }; -export type PostV1CostCalculatorEstimationCsvErrors = { +export type PostV1TimeoffTimeoffIdCancelErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; /** * Not Found */ @@ -19492,89 +20034,76 @@ export type PostV1CostCalculatorEstimationCsvErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type PostV1CostCalculatorEstimationCsvError = - PostV1CostCalculatorEstimationCsvErrors[keyof PostV1CostCalculatorEstimationCsvErrors]; +export type PostV1TimeoffTimeoffIdCancelError = + PostV1TimeoffTimeoffIdCancelErrors[keyof PostV1TimeoffTimeoffIdCancelErrors]; -export type PostV1CostCalculatorEstimationCsvResponses = { +export type PostV1TimeoffTimeoffIdCancelResponses = { /** * Success */ - 200: CostCalculatorEstimateCsvResponse; + 200: TimeoffResponse; }; -export type PostV1CostCalculatorEstimationCsvResponse = - PostV1CostCalculatorEstimationCsvResponses[keyof PostV1CostCalculatorEstimationCsvResponses]; +export type PostV1TimeoffTimeoffIdCancelResponse = + PostV1TimeoffTimeoffIdCancelResponses[keyof PostV1TimeoffTimeoffIdCancelResponses]; -export type GetV1ScimV2GroupsData = { +export type GetV1HelpCenterArticlesIdData = { body?: never; - path?: never; - query?: { - /** - * 1-based index of the first result - */ - startIndex?: number; - /** - * Maximum number of results per page - */ - count?: number; + path: { /** - * Filter expression for attributes (supports eq, ne, co, sw, ew, pr, lt, le, gt, ge) + * Help Center Article Zendesk ID */ - filter?: string; + id: number; }; - url: '/v1/scim/v2/Groups'; + query?: never; + url: '/v1/help-center-articles/{id}'; }; -export type GetV1ScimV2GroupsErrors = { - /** - * Bad Request - */ - 400: IntegrationsScimErrorResponse; - /** - * Unauthorized - */ - 401: IntegrationsScimErrorResponse; - /** - * Forbidden - */ - 403: IntegrationsScimErrorResponse; +export type GetV1HelpCenterArticlesIdErrors = { /** * Not Found */ - 404: IntegrationsScimErrorResponse; + 404: NotFoundResponse; }; -export type GetV1ScimV2GroupsError = - GetV1ScimV2GroupsErrors[keyof GetV1ScimV2GroupsErrors]; +export type GetV1HelpCenterArticlesIdError = + GetV1HelpCenterArticlesIdErrors[keyof GetV1HelpCenterArticlesIdErrors]; -export type GetV1ScimV2GroupsResponses = { +export type GetV1HelpCenterArticlesIdResponses = { /** * Success */ - 200: IntegrationsScimGroupListResponse; + 200: HelpCenterArticleResponse; }; -export type GetV1ScimV2GroupsResponse = - GetV1ScimV2GroupsResponses[keyof GetV1ScimV2GroupsResponses]; +export type GetV1HelpCenterArticlesIdResponse = + GetV1HelpCenterArticlesIdResponses[keyof GetV1HelpCenterArticlesIdResponses]; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsData = { +export type PostV1DocumentsData = { /** - * CreateContractDocumentParams + * File */ - body: CreateContractDocument; - path: { + body: FileParams; + headers: { /** - * Employment ID + * This endpoint works with any of the access tokens provided. You can use an access + * token obtained through the Client Credentials flow, the Authorization Code flow, or the Refresh Token flow. + * */ - employment_id: string; + Authorization: string; }; + path?: never; query?: never; - url: '/v1/contractors/employments/{employment_id}/contract-documents'; + url: '/v1/documents'; }; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors = { +export type PostV1DocumentsErrors = { /** * Unauthorized */ @@ -19589,31 +20118,32 @@ export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsError = - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsErrors]; +export type PostV1DocumentsError = + PostV1DocumentsErrors[keyof PostV1DocumentsErrors]; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses = - { +export type PostV1DocumentsResponses = { + /** + * Success + */ + 200: UploadFileResponse; +}; + +export type PostV1DocumentsResponse = + PostV1DocumentsResponses[keyof PostV1DocumentsResponses]; + +export type PostV1IdentityVerificationEmploymentIdVerifyData = { + body?: never; + path: { /** - * Success + * Employment ID */ - 200: CreateContractDocumentResponse; + employment_id: string; }; - -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponse = - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsResponses]; - -export type PostV1SandboxWebhookCallbacksTriggerData = { - /** - * Webhook Trigger Params - */ - body?: WebhookTriggerParams; - path?: never; query?: never; - url: '/v1/sandbox/webhook-callbacks/trigger'; + url: '/v1/identity-verification/{employment_id}/verify'; }; -export type PostV1SandboxWebhookCallbacksTriggerErrors = { +export type PostV1IdentityVerificationEmploymentIdVerifyErrors = { /** * Unauthorized */ @@ -19628,45 +20158,36 @@ export type PostV1SandboxWebhookCallbacksTriggerErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1SandboxWebhookCallbacksTriggerError = - PostV1SandboxWebhookCallbacksTriggerErrors[keyof PostV1SandboxWebhookCallbacksTriggerErrors]; +export type PostV1IdentityVerificationEmploymentIdVerifyError = + PostV1IdentityVerificationEmploymentIdVerifyErrors[keyof PostV1IdentityVerificationEmploymentIdVerifyErrors]; -export type PostV1SandboxWebhookCallbacksTriggerResponses = { +export type PostV1IdentityVerificationEmploymentIdVerifyResponses = { /** * Success */ 200: SuccessResponse; }; -export type PostV1SandboxWebhookCallbacksTriggerResponse = - PostV1SandboxWebhookCallbacksTriggerResponses[keyof PostV1SandboxWebhookCallbacksTriggerResponses]; +export type PostV1IdentityVerificationEmploymentIdVerifyResponse = + PostV1IdentityVerificationEmploymentIdVerifyResponses[keyof PostV1IdentityVerificationEmploymentIdVerifyResponses]; -export type GetV1PayslipsPayslipIdPdfData = { +export type GetV1CustomFieldsData = { body?: never; - headers: { + path?: never; + query?: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Starts fetching records after the given page */ - Authorization: string; - }; - path: { + page?: number; /** - * Payslip ID + * Number of items per page */ - payslip_id: string; + page_size?: number; }; - query?: never; - url: '/v1/payslips/{payslip_id}/pdf'; + url: '/v1/custom-fields'; }; -export type GetV1PayslipsPayslipIdPdfErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1CustomFieldsErrors = { /** * Unauthorized */ @@ -19679,36 +20200,32 @@ export type GetV1PayslipsPayslipIdPdfErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type GetV1PayslipsPayslipIdPdfError = - GetV1PayslipsPayslipIdPdfErrors[keyof GetV1PayslipsPayslipIdPdfErrors]; +export type GetV1CustomFieldsError = + GetV1CustomFieldsErrors[keyof GetV1CustomFieldsErrors]; -export type GetV1PayslipsPayslipIdPdfResponses = { +export type GetV1CustomFieldsResponses = { /** * Success */ - 200: PayslipDownloadResponse; + 200: ListEmploymentCustomFieldsResponse; }; -export type GetV1PayslipsPayslipIdPdfResponse = - GetV1PayslipsPayslipIdPdfResponses[keyof GetV1PayslipsPayslipIdPdfResponses]; +export type GetV1CustomFieldsResponse = + GetV1CustomFieldsResponses[keyof GetV1CustomFieldsResponses]; -export type PostV1CurrencyConverterEffectiveData = { +export type PostV1CustomFieldsData = { /** - * Convert currency parameters + * Custom Field Definition Create Parameters */ - body: ConvertCurrencyParams; + body: CreateCustomFieldDefinitionParams; path?: never; query?: never; - url: '/v1/currency-converter/effective'; + url: '/v1/custom-fields'; }; -export type PostV1CurrencyConverterEffectiveErrors = { +export type PostV1CustomFieldsErrors = { /** * Unauthorized */ @@ -19723,81 +20240,75 @@ export type PostV1CurrencyConverterEffectiveErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1CurrencyConverterEffectiveError = - PostV1CurrencyConverterEffectiveErrors[keyof PostV1CurrencyConverterEffectiveErrors]; +export type PostV1CustomFieldsError = + PostV1CustomFieldsErrors[keyof PostV1CustomFieldsErrors]; -export type PostV1CurrencyConverterEffectiveResponses = { +export type PostV1CustomFieldsResponses = { /** * Success */ - 200: ConvertCurrencyResponse; + 200: CreateEmploymentCustomFieldResponse; }; -export type PostV1CurrencyConverterEffectiveResponse = - PostV1CurrencyConverterEffectiveResponses[keyof PostV1CurrencyConverterEffectiveResponses]; +export type PostV1CustomFieldsResponse = + PostV1CustomFieldsResponses[keyof PostV1CustomFieldsResponses]; -export type GetV1TimeoffIdData = { - body?: never; - headers: { +export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveData = + { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/sandbox/employments/{employment_id}/risk-reserve-proof-of-payments/approve'; + }; + +export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors = + { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Bad Request */ - Authorization: string; - }; - path: { + 400: BadRequestResponse; /** - * Timeoff ID + * Unauthorized */ - id: string; + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; - query?: never; - url: '/v1/timeoff/{id}'; -}; - -export type GetV1TimeoffIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; -}; -export type GetV1TimeoffIdError = - GetV1TimeoffIdErrors[keyof GetV1TimeoffIdErrors]; +export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveError = + PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors[keyof PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveErrors]; -export type GetV1TimeoffIdResponses = { - /** - * Success - */ - 200: TimeoffResponse; -}; +export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses = + { + /** + * Success + */ + 200: RiskReserveProofOfPaymentResponse; + }; -export type GetV1TimeoffIdResponse = - GetV1TimeoffIdResponses[keyof GetV1TimeoffIdResponses]; +export type PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponse = + PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses[keyof PostV1SandboxEmploymentsEmploymentIdRiskReserveProofOfPaymentsApproveResponses]; -export type PatchV1TimeoffId2Data = { +export type PostV1WebhookCallbacksData = { /** - * UpdateTimeoff + * WebhookCallback */ - body: UpdateApprovedTimeoffParams; + body?: CreateWebhookCallbackParams; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -19807,21 +20318,12 @@ export type PatchV1TimeoffId2Data = { */ Authorization: string; }; - path: { - /** - * Timeoff ID - */ - id: string; - }; + path?: never; query?: never; - url: '/v1/timeoff/{id}'; + url: '/v1/webhook-callbacks'; }; -export type PatchV1TimeoffId2Errors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PostV1WebhookCallbacksErrors = { /** * Unauthorized */ @@ -19834,50 +20336,29 @@ export type PatchV1TimeoffId2Errors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PatchV1TimeoffId2Error = - PatchV1TimeoffId2Errors[keyof PatchV1TimeoffId2Errors]; +export type PostV1WebhookCallbacksError = + PostV1WebhookCallbacksErrors[keyof PostV1WebhookCallbacksErrors]; -export type PatchV1TimeoffId2Responses = { +export type PostV1WebhookCallbacksResponses = { /** * Success */ - 200: TimeoffResponse; + 200: WebhookCallbackResponse; }; -export type PatchV1TimeoffId2Response = - PatchV1TimeoffId2Responses[keyof PatchV1TimeoffId2Responses]; +export type PostV1WebhookCallbacksResponse = + PostV1WebhookCallbacksResponses[keyof PostV1WebhookCallbacksResponses]; -export type PatchV1TimeoffIdData = { - /** - * UpdateTimeoff - */ - body: UpdateApprovedTimeoffParams; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; - path: { - /** - * Timeoff ID - */ - id: string; - }; +export type GetV1SsoConfigurationDetailsData = { + body?: never; + path?: never; query?: never; - url: '/v1/timeoff/{id}'; + url: '/v1/sso-configuration/details'; }; -export type PatchV1TimeoffIdErrors = { +export type GetV1SsoConfigurationDetailsErrors = { /** * Bad Request */ @@ -19890,53 +20371,108 @@ export type PatchV1TimeoffIdErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; /** * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type PatchV1TimeoffIdError = - PatchV1TimeoffIdErrors[keyof PatchV1TimeoffIdErrors]; +export type GetV1SsoConfigurationDetailsError = + GetV1SsoConfigurationDetailsErrors[keyof GetV1SsoConfigurationDetailsErrors]; -export type PatchV1TimeoffIdResponses = { +export type GetV1SsoConfigurationDetailsResponses = { /** * Success */ - 200: TimeoffResponse; + 200: SsoConfigurationDetailsResponse; }; -export type PatchV1TimeoffIdResponse = - PatchV1TimeoffIdResponses[keyof PatchV1TimeoffIdResponses]; +export type GetV1SsoConfigurationDetailsResponse = + GetV1SsoConfigurationDetailsResponses[keyof GetV1SsoConfigurationDetailsResponses]; -export type PostV1TimeoffTimeoffIdDeclineData = { - /** - * DeclineTimeoff - */ - body: DeclineTimeoffParams; - path: { +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignData = + { /** - * Time Off ID + * SignContractDocument */ - timeoff_id: string; + body: SignContractDocument; + path: { + /** + * Employment ID + */ + employment_id: string; + /** + * Document ID + */ + contract_document_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/contract-documents/{contract_document_id}/sign'; }; - query?: never; - url: '/v1/timeoff/{timeoff_id}/decline'; + +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors = + { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignError = + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors]; + +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses = + { + /** + * Success + */ + 200: SuccessResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponse = + PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses]; + +export type GetV1PayItemsData = { + body?: never; + path?: never; + query?: { + /** + * Filter by employment slug + */ + employment_slug?: UuidSlug; + /** + * Filter pay items with effective_date >= given date (YYYY-MM-DD) + */ + effective_from?: Date; + /** + * Filter pay items with effective_date <= given date (YYYY-MM-DD) + */ + effective_to?: Date; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/pay-items'; }; -export type PostV1TimeoffTimeoffIdDeclineErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1PayItemsErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ @@ -19945,93 +20481,85 @@ export type PostV1TimeoffTimeoffIdDeclineErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PostV1TimeoffTimeoffIdDeclineError = - PostV1TimeoffTimeoffIdDeclineErrors[keyof PostV1TimeoffTimeoffIdDeclineErrors]; +export type GetV1PayItemsError = GetV1PayItemsErrors[keyof GetV1PayItemsErrors]; -export type PostV1TimeoffTimeoffIdDeclineResponses = { +export type GetV1PayItemsResponses = { /** * Success */ - 200: TimeoffResponse; + 200: ListPayItemsResponse; }; -export type PostV1TimeoffTimeoffIdDeclineResponse = - PostV1TimeoffTimeoffIdDeclineResponses[keyof PostV1TimeoffTimeoffIdDeclineResponses]; +export type GetV1PayItemsResponse = + GetV1PayItemsResponses[keyof GetV1PayItemsResponses]; -export type PostV1ContractAmendmentsAutomatableData = { - /** - * Contract Amendment - */ - body?: CreateContractAmendmentParams; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; +export type GetV1ScimV2UsersData = { + body?: never; path?: never; query?: { /** - * Version of the form schema + * 1-based index of the first result */ - json_schema_version?: number | 'latest'; + startIndex?: number; + /** + * Maximum number of results per page + */ + count?: number; + /** + * Filter expression for attributes (supports eq, ne, co, sw, ew, pr, lt, le, gt, ge) + */ + filter?: string; }; - url: '/v1/contract-amendments/automatable'; + url: '/v1/scim/v2/Users'; }; -export type PostV1ContractAmendmentsAutomatableErrors = { +export type GetV1ScimV2UsersErrors = { + /** + * Bad Request + */ + 400: IntegrationsScimErrorResponse; /** * Unauthorized */ - 401: UnauthorizedResponse; + 401: IntegrationsScimErrorResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: IntegrationsScimErrorResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: IntegrationsScimErrorResponse; }; -export type PostV1ContractAmendmentsAutomatableError = - PostV1ContractAmendmentsAutomatableErrors[keyof PostV1ContractAmendmentsAutomatableErrors]; +export type GetV1ScimV2UsersError = + GetV1ScimV2UsersErrors[keyof GetV1ScimV2UsersErrors]; -export type PostV1ContractAmendmentsAutomatableResponses = { +export type GetV1ScimV2UsersResponses = { /** * Success */ - 200: ContractAmendmentAutomatableResponse; + 200: IntegrationsScimUserListResponse; }; -export type PostV1ContractAmendmentsAutomatableResponse = - PostV1ContractAmendmentsAutomatableResponses[keyof PostV1ContractAmendmentsAutomatableResponses]; +export type GetV1ScimV2UsersResponse = + GetV1ScimV2UsersResponses[keyof GetV1ScimV2UsersResponses]; -export type PostV1TimeoffTimeoffIdApproveData = { - /** - * ApproveTimeoff - */ - body: ApproveTimeoffParams; +export type GetV1ResignationsOffboardingRequestIdData = { + body?: never; path: { /** - * Time Off ID + * Offboarding request ID */ - timeoff_id: string; + offboarding_request_id: string; }; query?: never; - url: '/v1/timeoff/{timeoff_id}/approve'; + url: '/v1/resignations/{offboarding_request_id}'; }; -export type PostV1TimeoffTimeoffIdApproveErrors = { +export type GetV1ResignationsOffboardingRequestIdErrors = { /** * Bad Request */ @@ -20054,49 +20582,41 @@ export type PostV1TimeoffTimeoffIdApproveErrors = { 429: TooManyRequestsResponse; }; -export type PostV1TimeoffTimeoffIdApproveError = - PostV1TimeoffTimeoffIdApproveErrors[keyof PostV1TimeoffTimeoffIdApproveErrors]; +export type GetV1ResignationsOffboardingRequestIdError = + GetV1ResignationsOffboardingRequestIdErrors[keyof GetV1ResignationsOffboardingRequestIdErrors]; -export type PostV1TimeoffTimeoffIdApproveResponses = { +export type GetV1ResignationsOffboardingRequestIdResponses = { /** * Success */ - 200: TimeoffResponse; + 200: ResignationResponse; }; -export type PostV1TimeoffTimeoffIdApproveResponse = - PostV1TimeoffTimeoffIdApproveResponses[keyof PostV1TimeoffTimeoffIdApproveResponses]; +export type GetV1ResignationsOffboardingRequestIdResponse = + GetV1ResignationsOffboardingRequestIdResponses[keyof GetV1ResignationsOffboardingRequestIdResponses]; -export type GetV1EmploymentsEmploymentIdFilesData = { +export type GetV1BillingDocumentsBillingDocumentIdBreakdownData = { body?: never; path: { /** - * Employment ID + * The billing document's ID */ - employment_id: string; + billing_document_id: string; }; query?: { /** - * Filter by file type (optional) + * Filters the results by the type of the billing breakdown item. */ type?: string; - /** - * Filter by file sub_type (optional) - */ - sub_type?: string; - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page - */ - page_size?: number; }; - url: '/v1/employments/{employment_id}/files'; + url: '/v1/billing-documents/{billing_document_id}/breakdown'; }; -export type GetV1EmploymentsEmploymentIdFilesErrors = { +export type GetV1BillingDocumentsBillingDocumentIdBreakdownErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -20109,159 +20629,97 @@ export type GetV1EmploymentsEmploymentIdFilesErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; -}; - -export type GetV1EmploymentsEmploymentIdFilesError = - GetV1EmploymentsEmploymentIdFilesErrors[keyof GetV1EmploymentsEmploymentIdFilesErrors]; - -export type GetV1EmploymentsEmploymentIdFilesResponses = { - /** - * Success - */ - 200: ListFilesResponse; -}; - -export type GetV1EmploymentsEmploymentIdFilesResponse = - GetV1EmploymentsEmploymentIdFilesResponses[keyof GetV1EmploymentsEmploymentIdFilesResponses]; - -export type GetV1CustomFieldsData = { - body?: never; - path?: never; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page - */ - page_size?: number; - }; - url: '/v1/custom-fields'; -}; - -export type GetV1CustomFieldsErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; /** * Unprocessable Entity */ - 422: UnprocessableEntityResponse; + 429: TooManyRequestsResponse; }; -export type GetV1CustomFieldsError = - GetV1CustomFieldsErrors[keyof GetV1CustomFieldsErrors]; +export type GetV1BillingDocumentsBillingDocumentIdBreakdownError = + GetV1BillingDocumentsBillingDocumentIdBreakdownErrors[keyof GetV1BillingDocumentsBillingDocumentIdBreakdownErrors]; -export type GetV1CustomFieldsResponses = { +export type GetV1BillingDocumentsBillingDocumentIdBreakdownResponses = { /** * Success */ - 200: ListEmploymentCustomFieldsResponse; + 200: BillingDocumentBreakdownResponse; }; -export type GetV1CustomFieldsResponse = - GetV1CustomFieldsResponses[keyof GetV1CustomFieldsResponses]; +export type GetV1BillingDocumentsBillingDocumentIdBreakdownResponse = + GetV1BillingDocumentsBillingDocumentIdBreakdownResponses[keyof GetV1BillingDocumentsBillingDocumentIdBreakdownResponses]; -export type PostV1CustomFieldsData = { +export type PostV1TimeoffTimeoffIdCancelRequestDeclineData = { /** - * Custom Field Definition Create Parameters + * Timeoff */ - body: CreateCustomFieldDefinitionParams; - path?: never; + body: DeclineTimeoffParams; + path: { + /** + * Time Off ID + */ + timeoff_id: string; + }; query?: never; - url: '/v1/custom-fields'; + url: '/v1/timeoff/{timeoff_id}/cancel-request/decline'; }; -export type PostV1CustomFieldsErrors = { +export type PostV1TimeoffTimeoffIdCancelRequestDeclineErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; -}; - -export type PostV1CustomFieldsError = - PostV1CustomFieldsErrors[keyof PostV1CustomFieldsErrors]; - -export type PostV1CustomFieldsResponses = { - /** - * Success - */ - 200: CreateEmploymentCustomFieldResponse; -}; - -export type PostV1CustomFieldsResponse = - PostV1CustomFieldsResponses[keyof PostV1CustomFieldsResponses]; - -export type GetV1CompanyCurrenciesData = { - body?: never; - path?: never; - query?: never; - url: '/v1/company-currencies'; -}; - -export type GetV1CompanyCurrenciesErrors = { /** - * Not Found + * Unprocessable Entity */ - 404: NotFoundResponse; + 429: TooManyRequestsResponse; }; -export type GetV1CompanyCurrenciesError = - GetV1CompanyCurrenciesErrors[keyof GetV1CompanyCurrenciesErrors]; +export type PostV1TimeoffTimeoffIdCancelRequestDeclineError = + PostV1TimeoffTimeoffIdCancelRequestDeclineErrors[keyof PostV1TimeoffTimeoffIdCancelRequestDeclineErrors]; -export type GetV1CompanyCurrenciesResponses = { +export type PostV1TimeoffTimeoffIdCancelRequestDeclineResponses = { /** * Success */ - 200: CompanyCurrenciesResponse; + 200: SuccessResponse; }; -export type GetV1CompanyCurrenciesResponse = - GetV1CompanyCurrenciesResponses[keyof GetV1CompanyCurrenciesResponses]; +export type PostV1TimeoffTimeoffIdCancelRequestDeclineResponse = + PostV1TimeoffTimeoffIdCancelRequestDeclineResponses[keyof PostV1TimeoffTimeoffIdCancelRequestDeclineResponses]; -export type PatchV1SandboxEmploymentsEmploymentId2Data = { - /** - * Employment params - */ - body?: EmploymentUpdateParams; - headers: { +export type GetV1PayrollCalendarsData = { + body?: never; + path?: never; + query?: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Filter payroll calendars by country code */ - Authorization: string; - }; - path: { + country_code?: string; /** - * Employment ID + * Filter payroll calendars by year */ - employment_id: string; + year?: string; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - query?: never; - url: '/v1/sandbox/employments/{employment_id}'; + url: '/v1/payroll-calendars'; }; -export type PatchV1SandboxEmploymentsEmploymentId2Errors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1PayrollCalendarsErrors = { /** * Unauthorized */ @@ -20270,58 +20728,56 @@ export type PatchV1SandboxEmploymentsEmploymentId2Errors = { * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PatchV1SandboxEmploymentsEmploymentId2Error = - PatchV1SandboxEmploymentsEmploymentId2Errors[keyof PatchV1SandboxEmploymentsEmploymentId2Errors]; +export type GetV1PayrollCalendarsError = + GetV1PayrollCalendarsErrors[keyof GetV1PayrollCalendarsErrors]; -export type PatchV1SandboxEmploymentsEmploymentId2Responses = { +export type GetV1PayrollCalendarsResponses = { /** * Success */ - 200: EmploymentResponse; + 200: PayrollCalendarsEorResponse; }; -export type PatchV1SandboxEmploymentsEmploymentId2Response = - PatchV1SandboxEmploymentsEmploymentId2Responses[keyof PatchV1SandboxEmploymentsEmploymentId2Responses]; +export type GetV1PayrollCalendarsResponse = + GetV1PayrollCalendarsResponses[keyof GetV1PayrollCalendarsResponses]; -export type PatchV1SandboxEmploymentsEmploymentIdData = { - /** - * Employment params - */ - body?: EmploymentUpdateParams; - headers: { +export type GetV1WdGphPayDetailData = { + body?: never; + headers?: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * The preferred language of the inquiring user in Workday */ - Authorization: string; + accept_language?: string; }; - path: { + path?: never; + query: { /** - * Employment ID + * The pay group ID for identifying the pay group at the vendor system + */ + payGroupExternalId: string; + /** + * The run type id provided in the paySummary API + */ + runTypeId: string; + /** + * The cycle type id, defaults to the main run if not provided + */ + cycleTypeId?: string; + /** + * The period end date in question, defaults to current period if not provided */ - employment_id: string; + periodEndDate?: Date; }; - query?: never; - url: '/v1/sandbox/employments/{employment_id}'; + url: '/v1/wd/gph/payDetail'; }; -export type PatchV1SandboxEmploymentsEmploymentIdErrors = { +export type GetV1WdGphPayDetailErrors = { /** * Bad Request */ @@ -20334,34 +20790,22 @@ export type PatchV1SandboxEmploymentsEmploymentIdErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PatchV1SandboxEmploymentsEmploymentIdError = - PatchV1SandboxEmploymentsEmploymentIdErrors[keyof PatchV1SandboxEmploymentsEmploymentIdErrors]; +export type GetV1WdGphPayDetailError = + GetV1WdGphPayDetailErrors[keyof GetV1WdGphPayDetailErrors]; -export type PatchV1SandboxEmploymentsEmploymentIdResponses = { +export type GetV1WdGphPayDetailResponses = { /** * Success */ - 200: EmploymentResponse; + 200: PayDetailResponse; }; -export type PatchV1SandboxEmploymentsEmploymentIdResponse = - PatchV1SandboxEmploymentsEmploymentIdResponses[keyof PatchV1SandboxEmploymentsEmploymentIdResponses]; +export type GetV1WdGphPayDetailResponse = + GetV1WdGphPayDetailResponses[keyof GetV1WdGphPayDetailResponses]; -export type GetV1EmploymentContractsEmploymentIdPendingChangesData = { +export type GetV1ContractAmendmentsSchemaData = { body?: never; headers: { /** @@ -20372,25 +20816,33 @@ export type GetV1EmploymentContractsEmploymentIdPendingChangesData = { */ Authorization: string; }; - path: { + path?: never; + query: { /** - * Employment ID + * The ID of the employment concerned by the contract amendment request. */ employment_id: string; + /** + * Country code according to ISO 3-digit alphabetic codes. + */ + country_code: string; + /** + * Name of the desired form + */ + form?: 'contract_amendment'; + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; }; - query?: never; - url: '/v1/employment-contracts/{employment_id}/pending-changes'; + url: '/v1/contract-amendments/schema'; }; -export type GetV1EmploymentContractsEmploymentIdPendingChangesErrors = { +export type GetV1ContractAmendmentsSchemaErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -20401,32 +20853,57 @@ export type GetV1EmploymentContractsEmploymentIdPendingChangesErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1EmploymentContractsEmploymentIdPendingChangesError = - GetV1EmploymentContractsEmploymentIdPendingChangesErrors[keyof GetV1EmploymentContractsEmploymentIdPendingChangesErrors]; +export type GetV1ContractAmendmentsSchemaError = + GetV1ContractAmendmentsSchemaErrors[keyof GetV1ContractAmendmentsSchemaErrors]; -export type GetV1EmploymentContractsEmploymentIdPendingChangesResponses = { +export type GetV1ContractAmendmentsSchemaResponses = { /** * Success */ - 200: EmploymentContractPendingChangesResponse; + 200: ContractAmendmentFormResponse; }; -export type GetV1EmploymentContractsEmploymentIdPendingChangesResponse = - GetV1EmploymentContractsEmploymentIdPendingChangesResponses[keyof GetV1EmploymentContractsEmploymentIdPendingChangesResponses]; +export type GetV1ContractAmendmentsSchemaResponse = + GetV1ContractAmendmentsSchemaResponses[keyof GetV1ContractAmendmentsSchemaResponses]; -export type GetV1ResignationsOffboardingRequestIdData = { +export type GetV1TestSchemaData = { body?: never; + path?: never; + query?: { + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; + }; + url: '/v1/test-schema'; +}; + +export type GetV1TestSchemaResponses = { + /** + * Success + */ + 200: CompanyFormResponse; +}; + +export type GetV1TestSchemaResponse = + GetV1TestSchemaResponses[keyof GetV1TestSchemaResponses]; + +export type PatchV1EmployeeTimeoffId2Data = { + /** + * UpdateTimeoff + */ + body: UpdateEmployeeTimeoffParams; path: { /** - * Offboarding request ID + * Timeoff ID */ - offboarding_request_id: string; + id: string; }; query?: never; - url: '/v1/resignations/{offboarding_request_id}'; + url: '/v1/employee/timeoff/{id}'; }; -export type GetV1ResignationsOffboardingRequestIdErrors = { +export type PatchV1EmployeeTimeoffId2Errors = { /** * Bad Request */ @@ -20449,38 +20926,39 @@ export type GetV1ResignationsOffboardingRequestIdErrors = { 429: TooManyRequestsResponse; }; -export type GetV1ResignationsOffboardingRequestIdError = - GetV1ResignationsOffboardingRequestIdErrors[keyof GetV1ResignationsOffboardingRequestIdErrors]; +export type PatchV1EmployeeTimeoffId2Error = + PatchV1EmployeeTimeoffId2Errors[keyof PatchV1EmployeeTimeoffId2Errors]; -export type GetV1ResignationsOffboardingRequestIdResponses = { +export type PatchV1EmployeeTimeoffId2Responses = { /** * Success */ - 200: ResignationResponse; + 200: TimeoffResponse; }; -export type GetV1ResignationsOffboardingRequestIdResponse = - GetV1ResignationsOffboardingRequestIdResponses[keyof GetV1ResignationsOffboardingRequestIdResponses]; +export type PatchV1EmployeeTimeoffId2Response = + PatchV1EmployeeTimeoffId2Responses[keyof PatchV1EmployeeTimeoffId2Responses]; -export type PostV1DocumentsData = { +export type PatchV1EmployeeTimeoffIdData = { /** - * File + * UpdateTimeoff */ - body: FileParams; - headers: { + body: UpdateEmployeeTimeoffParams; + path: { /** - * This endpoint works with any of the access tokens provided. You can use an access - * token obtained through the Client Credentials flow, the Authorization Code flow, or the Refresh Token flow. - * + * Timeoff ID */ - Authorization: string; + id: string; }; - path?: never; query?: never; - url: '/v1/documents'; + url: '/v1/employee/timeoff/{id}'; }; -export type PostV1DocumentsErrors = { +export type PatchV1EmployeeTimeoffIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -20493,96 +20971,95 @@ export type PostV1DocumentsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type PostV1DocumentsError = - PostV1DocumentsErrors[keyof PostV1DocumentsErrors]; +export type PatchV1EmployeeTimeoffIdError = + PatchV1EmployeeTimeoffIdErrors[keyof PatchV1EmployeeTimeoffIdErrors]; -export type PostV1DocumentsResponses = { +export type PatchV1EmployeeTimeoffIdResponses = { /** * Success */ - 200: UploadFileResponse; + 200: TimeoffResponse; }; -export type PostV1DocumentsResponse = - PostV1DocumentsResponses[keyof PostV1DocumentsResponses]; +export type PatchV1EmployeeTimeoffIdResponse = + PatchV1EmployeeTimeoffIdResponses[keyof PatchV1EmployeeTimeoffIdResponses]; -export type PostV1EmploymentsEmploymentIdInviteData = { +export type GetV1ScimV2GroupsIdData = { body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; path: { /** - * Employment ID + * Group ID (slug) */ - employment_id: string; + id: string; }; query?: never; - url: '/v1/employments/{employment_id}/invite'; + url: '/v1/scim/v2/Groups/{id}'; }; -export type PostV1EmploymentsEmploymentIdInviteErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1ScimV2GroupsIdErrors = { /** - * Conflict + * Unauthorized */ - 409: ConflictResponse; + 401: IntegrationsScimErrorResponse; /** - * Unprocessable Entity + * Forbidden */ - 422: UnprocessableEntityResponse; + 403: IntegrationsScimErrorResponse; /** - * Unprocessable Entity + * Not Found */ - 429: TooManyRequestsResponse; + 404: IntegrationsScimErrorResponse; }; -export type PostV1EmploymentsEmploymentIdInviteError = - PostV1EmploymentsEmploymentIdInviteErrors[keyof PostV1EmploymentsEmploymentIdInviteErrors]; +export type GetV1ScimV2GroupsIdError = + GetV1ScimV2GroupsIdErrors[keyof GetV1ScimV2GroupsIdErrors]; -export type PostV1EmploymentsEmploymentIdInviteResponses = { +export type GetV1ScimV2GroupsIdResponses = { /** * Success */ - 200: SuccessResponse; + 200: IntegrationsScimGroup; }; -export type PostV1EmploymentsEmploymentIdInviteResponse = - PostV1EmploymentsEmploymentIdInviteResponses[keyof PostV1EmploymentsEmploymentIdInviteResponses]; +export type GetV1ScimV2GroupsIdResponse = + GetV1ScimV2GroupsIdResponses[keyof GetV1ScimV2GroupsIdResponses]; -export type GetV1ExpensesIdData = { +export type GetV1CountriesCountryCodeLegalEntityFormsFormData = { body?: never; - headers: { + path: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Country code according to ISO 3-digit alphabetic codes */ - Authorization: string; + country_code: string; + /** + * Name of the desired form + */ + form: string; }; - path: { + query?: { /** - * Expense ID + * Product type. Default value is global_payroll. */ - id: string; + product_type?: 'peo' | 'global_payroll' | 'e2e_payroll'; + /** + * Legal entity id for admistrative_details of e2e payroll products in GBR + */ + legal_entity_id?: UuidSlug; + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; }; - query?: never; - url: '/v1/expenses/{id}'; + url: '/v1/countries/{country_code}/legal_entity_forms/{form}'; }; -export type GetV1ExpensesIdErrors = { +export type GetV1CountriesCountryCodeLegalEntityFormsFormErrors = { /** * Bad Request */ @@ -20600,135 +21077,149 @@ export type GetV1ExpensesIdErrors = { */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV1ExpensesIdError = - GetV1ExpensesIdErrors[keyof GetV1ExpensesIdErrors]; +export type GetV1CountriesCountryCodeLegalEntityFormsFormError = + GetV1CountriesCountryCodeLegalEntityFormsFormErrors[keyof GetV1CountriesCountryCodeLegalEntityFormsFormErrors]; -export type GetV1ExpensesIdResponses = { +export type GetV1CountriesCountryCodeLegalEntityFormsFormResponses = { /** * Success */ - 200: ExpenseResponse; + 200: CountryFormResponse; }; -export type GetV1ExpensesIdResponse = - GetV1ExpensesIdResponses[keyof GetV1ExpensesIdResponses]; +export type GetV1CountriesCountryCodeLegalEntityFormsFormResponse = + GetV1CountriesCountryCodeLegalEntityFormsFormResponses[keyof GetV1CountriesCountryCodeLegalEntityFormsFormResponses]; -export type PatchV1ExpensesId2Data = { - /** - * Expenses - */ - body?: UpdateExpenseParams; +export type GetV1EmploymentContractsEmploymentIdPendingChangesData = { + body?: never; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * Expense ID + * Employment ID */ - id: string; + employment_id: string; }; query?: never; - url: '/v1/expenses/{id}'; + url: '/v1/employment-contracts/{employment_id}/pending-changes'; }; -export type PatchV1ExpensesId2Errors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmploymentContractsEmploymentIdPendingChangesErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PatchV1ExpensesId2Error = - PatchV1ExpensesId2Errors[keyof PatchV1ExpensesId2Errors]; +export type GetV1EmploymentContractsEmploymentIdPendingChangesError = + GetV1EmploymentContractsEmploymentIdPendingChangesErrors[keyof GetV1EmploymentContractsEmploymentIdPendingChangesErrors]; -export type PatchV1ExpensesId2Responses = { +export type GetV1EmploymentContractsEmploymentIdPendingChangesResponses = { /** * Success */ - 200: ExpenseResponse; + 200: EmploymentContractPendingChangesResponse; }; -export type PatchV1ExpensesId2Response = - PatchV1ExpensesId2Responses[keyof PatchV1ExpensesId2Responses]; +export type GetV1EmploymentContractsEmploymentIdPendingChangesResponse = + GetV1EmploymentContractsEmploymentIdPendingChangesResponses[keyof GetV1EmploymentContractsEmploymentIdPendingChangesResponses]; -export type PatchV1ExpensesIdData = { +export type PostV1SdkTelemetryErrorsData = { /** - * Expenses + * SDK Error Report */ - body?: UpdateExpenseParams; - path: { - /** - * Expense ID - */ - id: string; - }; + body: SdkErrorPayload; + path?: never; query?: never; - url: '/v1/expenses/{id}'; + url: '/v1/sdk/telemetry-errors'; }; -export type PatchV1ExpensesIdErrors = { +export type PostV1SdkTelemetryErrorsErrors = { /** * Bad Request */ - 400: BadRequestResponse; + 400: ErrorResponse; /** - * Unauthorized + * Too Many Requests */ - 401: UnauthorizedResponse; + 429: RateLimitResponse; +}; + +export type PostV1SdkTelemetryErrorsError = + PostV1SdkTelemetryErrorsErrors[keyof PostV1SdkTelemetryErrorsErrors]; + +export type PostV1SdkTelemetryErrorsResponses = { /** - * Not Found + * No Content */ - 404: NotFoundResponse; + 204: unknown; +}; + +export type GetV1CompaniesCompanyIdComplianceProfileData = { + body?: never; + path: { + /** + * Company ID + */ + company_id: UuidSlug; + }; + query?: never; + url: '/v1/companies/{company_id}/compliance-profile'; +}; + +export type GetV1CompaniesCompanyIdComplianceProfileErrors = { /** - * Conflict + * Unauthorized */ - 409: ConflictResponse; + 401: UnauthorizedResponse; /** - * Unprocessable Entity + * Forbidden */ - 422: UnprocessableEntityResponse; + 403: ForbiddenResponse; /** - * Too many requests + * Not Found */ - 429: TooManyRequestsResponse; + 404: NotFoundResponse; }; -export type PatchV1ExpensesIdError = - PatchV1ExpensesIdErrors[keyof PatchV1ExpensesIdErrors]; +export type GetV1CompaniesCompanyIdComplianceProfileError = + GetV1CompaniesCompanyIdComplianceProfileErrors[keyof GetV1CompaniesCompanyIdComplianceProfileErrors]; -export type PatchV1ExpensesIdResponses = { +export type GetV1CompaniesCompanyIdComplianceProfileResponses = { /** * Success */ - 200: ExpenseResponse; + 200: CompanyComplianceProfileResponse; }; -export type PatchV1ExpensesIdResponse = - PatchV1ExpensesIdResponses[keyof PatchV1ExpensesIdResponses]; +export type GetV1CompaniesCompanyIdComplianceProfileResponse = + GetV1CompaniesCompanyIdComplianceProfileResponses[keyof GetV1CompaniesCompanyIdComplianceProfileResponses]; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdData = { +export type GetV1PayslipsIdData = { body?: never; headers: { /** @@ -20741,15 +21232,19 @@ export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdData = { }; path: { /** - * Benefit Renewal Request Id + * Payslip ID */ - benefit_renewal_request_id: UuidSlug; + id: string; }; query?: never; - url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}'; + url: '/v1/payslips/{id}'; }; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors = { +export type GetV1PayslipsIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -20762,51 +21257,38 @@ export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdError = - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors]; +export type GetV1PayslipsIdError = + GetV1PayslipsIdErrors[keyof GetV1PayslipsIdErrors]; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses = { +export type GetV1PayslipsIdResponses = { /** * Success */ - 200: BenefitRenewalRequestsBenefitRenewalRequestResponse; + 200: PayslipResponse; }; -export type GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponse = - GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses[keyof GetV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses]; +export type GetV1PayslipsIdResponse = + GetV1PayslipsIdResponses[keyof GetV1PayslipsIdResponses]; -export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdData = { - /** - * Benefit Renewal Request Response - */ - body?: BenefitRenewalRequestsUpdateBenefitRenewalRequest; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; +export type PostV1TimeoffTimeoffIdCancelRequestApproveData = { + body?: never; path: { /** - * Benefit Renewal Request Id - */ - benefit_renewal_request_id: UuidSlug; - }; - query?: { - /** - * Version of the form schema + * Time Off ID */ - json_schema_version?: number | 'latest'; + timeoff_id: string; }; - url: '/v1/benefit-renewal-requests/{benefit_renewal_request_id}'; + query?: never; + url: '/v1/timeoff/{timeoff_id}/cancel-request/approve'; }; -export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors = { +export type PostV1TimeoffTimeoffIdCancelRequestApproveErrors = { /** * Unauthorized */ @@ -20821,32 +21303,64 @@ export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors = { 429: TooManyRequestsResponse; }; -export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdError = - PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors[keyof PostV1BenefitRenewalRequestsBenefitRenewalRequestIdErrors]; +export type PostV1TimeoffTimeoffIdCancelRequestApproveError = + PostV1TimeoffTimeoffIdCancelRequestApproveErrors[keyof PostV1TimeoffTimeoffIdCancelRequestApproveErrors]; -export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses = { +export type PostV1TimeoffTimeoffIdCancelRequestApproveResponses = { /** * Success */ 200: SuccessResponse; }; -export type PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponse = - PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses[keyof PostV1BenefitRenewalRequestsBenefitRenewalRequestIdResponses]; +export type PostV1TimeoffTimeoffIdCancelRequestApproveResponse = + PostV1TimeoffTimeoffIdCancelRequestApproveResponses[keyof PostV1TimeoffTimeoffIdCancelRequestApproveResponses]; -export type GetV1EmploymentsEmploymentIdOnboardingStepsData = { +export type GetV1WebhookEventsData = { body?: never; - path: { + path?: never; + query?: { /** - * Employment ID + * Filter by webhook event type */ - employment_id: UuidSlug; + event_type?: string; + /** + * Filter by delivery status (true = 200, false = 4xx/5xx) + */ + successfully_delivered?: boolean; + /** + * Filter by company ID + */ + company_id?: string; + /** + * Filter by date before (ISO 8601 format) + */ + before?: string; + /** + * Filter by date after (ISO 8601 format) + */ + after?: string; + /** + * Sort order + */ + order?: 'asc' | 'desc'; + /** + * Field to sort by + */ + sort_by?: 'first_triggered_at'; + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; }; - query?: never; - url: '/v1/employments/{employment_id}/onboarding-steps'; + url: '/v1/webhook-events'; }; -export type GetV1EmploymentsEmploymentIdOnboardingStepsErrors = { +export type GetV1WebhookEventsErrors = { /** * Unauthorized */ @@ -20855,34 +21369,51 @@ export type GetV1EmploymentsEmploymentIdOnboardingStepsErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; }; -export type GetV1EmploymentsEmploymentIdOnboardingStepsError = - GetV1EmploymentsEmploymentIdOnboardingStepsErrors[keyof GetV1EmploymentsEmploymentIdOnboardingStepsErrors]; +export type GetV1WebhookEventsError = + GetV1WebhookEventsErrors[keyof GetV1WebhookEventsErrors]; -export type GetV1EmploymentsEmploymentIdOnboardingStepsResponses = { +export type GetV1WebhookEventsResponses = { /** * Success */ - 200: EmploymentOnboardingStepsResponse; + 200: ListWebhookEventsResponse; }; -export type GetV1EmploymentsEmploymentIdOnboardingStepsResponse = - GetV1EmploymentsEmploymentIdOnboardingStepsResponses[keyof GetV1EmploymentsEmploymentIdOnboardingStepsResponses]; +export type GetV1WebhookEventsResponse = + GetV1WebhookEventsResponses[keyof GetV1WebhookEventsResponses]; -export type GetV1EmploymentsEmploymentIdCompanyStructureNodesData = { +export type GetV1TimeoffTypesData = { body?: never; - path: { + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; + path?: never; + query?: { /** - * Employment ID + * Optional. Employment type to list time off types for: `contractor` or `full_time`. Omit for backward-compatible behavior (full-time types). */ - employment_id: string; + type?: TimeoffTypesEmploymentType; }; - query?: never; - url: '/v1/employments/{employment_id}/company-structure-nodes'; + url: '/v1/timeoff/types'; }; -export type GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors = { +export type GetV1TimeoffTypesErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -20895,28 +21426,32 @@ export type GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1EmploymentsEmploymentIdCompanyStructureNodesError = - GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors[keyof GetV1EmploymentsEmploymentIdCompanyStructureNodesErrors]; +export type GetV1TimeoffTypesError = + GetV1TimeoffTypesErrors[keyof GetV1TimeoffTypesErrors]; -export type GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses = { +export type GetV1TimeoffTypesResponses = { /** * Success */ - 200: CompanyStructureNodesResponse; + 200: ListTimeoffTypesResponse; }; -export type GetV1EmploymentsEmploymentIdCompanyStructureNodesResponse = - GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses[keyof GetV1EmploymentsEmploymentIdCompanyStructureNodesResponses]; +export type GetV1TimeoffTypesResponse = + GetV1TimeoffTypesResponses[keyof GetV1TimeoffTypesResponses]; -export type GetV1EmploymentsEmploymentIdCustomFieldsData = { +export type GetV1CompaniesCompanyIdLegalEntitiesData = { body?: never; path: { /** - * Employment ID + * Company ID */ - employment_id: string; + company_id: UuidSlug; }; query?: { /** @@ -20928,10 +21463,10 @@ export type GetV1EmploymentsEmploymentIdCustomFieldsData = { */ page_size?: number; }; - url: '/v1/employments/{employment_id}/custom-fields'; + url: '/v1/companies/{company_id}/legal-entities'; }; -export type GetV1EmploymentsEmploymentIdCustomFieldsErrors = { +export type GetV1CompaniesCompanyIdLegalEntitiesErrors = { /** * Unauthorized */ @@ -20940,53 +21475,41 @@ export type GetV1EmploymentsEmploymentIdCustomFieldsErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; }; -export type GetV1EmploymentsEmploymentIdCustomFieldsError = - GetV1EmploymentsEmploymentIdCustomFieldsErrors[keyof GetV1EmploymentsEmploymentIdCustomFieldsErrors]; +export type GetV1CompaniesCompanyIdLegalEntitiesError = + GetV1CompaniesCompanyIdLegalEntitiesErrors[keyof GetV1CompaniesCompanyIdLegalEntitiesErrors]; -export type GetV1EmploymentsEmploymentIdCustomFieldsResponses = { +export type GetV1CompaniesCompanyIdLegalEntitiesResponses = { /** * Success */ - 200: ListEmploymentCustomFieldValuePaginatedResponse; + 200: ListCompanyLegalEntitiesResponse; }; -export type GetV1EmploymentsEmploymentIdCustomFieldsResponse = - GetV1EmploymentsEmploymentIdCustomFieldsResponses[keyof GetV1EmploymentsEmploymentIdCustomFieldsResponses]; +export type GetV1CompaniesCompanyIdLegalEntitiesResponse = + GetV1CompaniesCompanyIdLegalEntitiesResponses[keyof GetV1CompaniesCompanyIdLegalEntitiesResponses]; -export type PutV1ResignationsOffboardingRequestIdValidateData = { +export type PostV1EmploymentsEmploymentIdContractEligibilityData = { /** - * ValidateResignation + * Contract Eligibility Create Parameters */ - body: ValidateResignationRequestParams; + body: CreateContractEligibilityParams; path: { /** - * Offboarding request ID + * Employment ID */ - offboarding_request_id: string; + employment_id: string; }; query?: never; - url: '/v1/resignations/{offboarding_request_id}/validate'; + url: '/v1/employments/{employment_id}/contract-eligibility'; }; -export type PutV1ResignationsOffboardingRequestIdValidateErrors = { +export type PostV1EmploymentsEmploymentIdContractEligibilityErrors = { /** * Bad Request */ 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; /** * Unprocessable Entity */ @@ -20997,179 +21520,111 @@ export type PutV1ResignationsOffboardingRequestIdValidateErrors = { 429: TooManyRequestsResponse; }; -export type PutV1ResignationsOffboardingRequestIdValidateError = - PutV1ResignationsOffboardingRequestIdValidateErrors[keyof PutV1ResignationsOffboardingRequestIdValidateErrors]; +export type PostV1EmploymentsEmploymentIdContractEligibilityError = + PostV1EmploymentsEmploymentIdContractEligibilityErrors[keyof PostV1EmploymentsEmploymentIdContractEligibilityErrors]; -export type PutV1ResignationsOffboardingRequestIdValidateResponses = { +export type PostV1EmploymentsEmploymentIdContractEligibilityResponses = { /** * Success */ 200: SuccessResponse; }; -export type PutV1ResignationsOffboardingRequestIdValidateResponse = - PutV1ResignationsOffboardingRequestIdValidateResponses[keyof PutV1ResignationsOffboardingRequestIdValidateResponses]; +export type PostV1EmploymentsEmploymentIdContractEligibilityResponse = + PostV1EmploymentsEmploymentIdContractEligibilityResponses[keyof PostV1EmploymentsEmploymentIdContractEligibilityResponses]; -export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdData = - { - body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; - path: { - /** - * Company ID - */ - company_id: string; - /** - * Legal Entity ID to set as the new default - */ - legal_entity_id: string; - }; - query?: never; - url: '/v1/sandbox/companies/{company_id}/default-legal-entity/{legal_entity_id}'; +export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesData = { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; }; - -export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors = - { + query?: { /** - * Bad Request + * Restrict to currencies which payout is guaranteed (default: true) */ - 400: BadRequestResponse; + restrict_to_guaranteed_pay_out_currencies?: boolean; + }; + url: '/v1/contractors/employments/{employment_id}/contractor-currencies'; +}; + +export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors = + { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: NotFoundResponse; /** - * Too many requests + * Internal Server Error */ - 429: TooManyRequestsResponse; + 500: InternalServerErrorResponse; }; -export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdError = - PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors[keyof PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdErrors]; +export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesError = + GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors[keyof GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesErrors]; -export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses = +export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses = { /** * Success */ - 200: SuccessResponse; + 200: ContractorCurrencyResponse; }; -export type PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponse = - PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses[keyof PutV1SandboxCompaniesCompanyIdDefaultLegalEntityLegalEntityIdResponses]; +export type GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponse = + GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses[keyof GetV1ContractorsEmploymentsEmploymentIdContractorCurrenciesResponses]; -export type GetV1CompaniesCompanyIdWebhookCallbacksData = { +export type GetV1PayslipsData = { body?: never; - path: { + path?: never; + query?: { /** - * Company ID + * Employment ID */ - company_id: string; - }; - query?: never; - url: '/v1/companies/{company_id}/webhook-callbacks'; -}; - -export type GetV1CompaniesCompanyIdWebhookCallbacksErrors = { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; -}; - -export type GetV1CompaniesCompanyIdWebhookCallbacksError = - GetV1CompaniesCompanyIdWebhookCallbacksErrors[keyof GetV1CompaniesCompanyIdWebhookCallbacksErrors]; - -export type GetV1CompaniesCompanyIdWebhookCallbacksResponses = { - /** - * Success - */ - 200: ListWebhookCallbacksResponse; -}; - -export type GetV1CompaniesCompanyIdWebhookCallbacksResponse = - GetV1CompaniesCompanyIdWebhookCallbacksResponses[keyof GetV1CompaniesCompanyIdWebhookCallbacksResponses]; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityData = - { - body?: never; - path: { - /** - * Company ID - */ - company_id: UuidSlug; - /** - * Legal entity ID - */ - legal_entity_id: UuidSlug; - }; - query?: never; - url: '/v1/companies/{company_id}/legal-entities/{legal_entity_id}/contractor-eligibility'; - }; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors = - { + employment_id?: string; /** - * Unauthorized + * Filters by payslips `issued_at` field, after or on the same day than the given date */ - 401: UnauthorizedResponse; + start_date?: string; /** - * Not Found + * Filters by payslips `issued_at` field, before or or the same day than the given date */ - 404: NotFoundResponse; - }; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityError = - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityErrors]; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses = - { + end_date?: string; /** - * Success + * Filters by payslips `expected_payout_date` field, after or on the same day than the given date */ - 200: ContractorEligibilityResponse; - }; - -export type GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponse = - GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses[keyof GetV1CompaniesCompanyIdLegalEntitiesLegalEntityIdContractorEligibilityResponses]; - -export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdData = { - body?: never; - path: { + expected_payout_start_date?: string; /** - * Custom field ID + * Filters by payslips `expected_payout_date` field, before or or the same day than the given date */ - custom_field_id: string; + expected_payout_end_date?: string; /** - * Employment ID + * Starts fetching records after the given page */ - employment_id: string; + page?: number; + /** + * Change the amount of records returned per page, defaults to 20, limited to 100 + */ + page_size?: number; }; - query?: never; - url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}'; + url: '/v1/payslips'; }; -export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors = { +export type GetV1PayslipsErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -21182,49 +21637,52 @@ export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdError = - GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors[keyof GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors]; +export type GetV1PayslipsError = GetV1PayslipsErrors[keyof GetV1PayslipsErrors]; -export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses = { +export type GetV1PayslipsResponses = { /** * Success */ - 200: EmploymentCustomFieldValueResponse; + 200: ListPayslipsResponse; }; -export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponse = - GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses[keyof GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses]; +export type GetV1PayslipsResponse = + GetV1PayslipsResponses[keyof GetV1PayslipsResponses]; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Data = { +export type PostV1SandboxEmploymentsData = { /** - * Custom Field Value Update Parameters + * Employment params */ - body: UpdateEmploymentCustomFieldValueParams; - path: { - /** - * Custom field ID - */ - custom_field_id: string; + body?: EmploymentCreateParams; + headers: { /** - * Employment ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - employment_id: string; + Authorization: string; }; + path?: never; query?: never; - url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}'; + url: '/v1/sandbox/employments'; }; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors = { +export type PostV1SandboxEmploymentsErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ @@ -21233,49 +21691,42 @@ export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Error = - PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors]; +export type PostV1SandboxEmploymentsError = + PostV1SandboxEmploymentsErrors[keyof PostV1SandboxEmploymentsErrors]; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses = { +export type PostV1SandboxEmploymentsResponses = { /** * Success */ - 200: EmploymentCustomFieldValueResponse; + 201: EmploymentCreationResponse; }; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Response = - PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses]; +export type PostV1SandboxEmploymentsResponse = + PostV1SandboxEmploymentsResponses[keyof PostV1SandboxEmploymentsResponses]; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdData = { - /** - * Custom Field Value Update Parameters - */ - body: UpdateEmploymentCustomFieldValueParams; +export type GetV1PayrollRunsPayrollRunIdData = { + body?: never; path: { /** - * Custom field ID - */ - custom_field_id: string; - /** - * Employment ID + * Payroll run ID */ - employment_id: string; + payroll_run_id: string; }; query?: never; - url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}'; + url: '/v1/payroll-runs/{payroll_run_id}'; }; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors = { +export type GetV1PayrollRunsPayrollRunIdErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -21286,20 +21737,20 @@ export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors = { 422: UnprocessableEntityResponse; }; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdError = - PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors]; +export type GetV1PayrollRunsPayrollRunIdError = + GetV1PayrollRunsPayrollRunIdErrors[keyof GetV1PayrollRunsPayrollRunIdErrors]; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses = { +export type GetV1PayrollRunsPayrollRunIdResponses = { /** * Success */ - 200: EmploymentCustomFieldValueResponse; + 200: PayrollRunResponse; }; -export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponse = - PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses]; +export type GetV1PayrollRunsPayrollRunIdResponse = + GetV1PayrollRunsPayrollRunIdResponses[keyof GetV1PayrollRunsPayrollRunIdResponses]; -export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdData = +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsData = { body?: never; path: { @@ -21307,17 +21758,17 @@ export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTermina * Employment ID */ employment_id: string; - /** - * Termination Request ID - */ - termination_request_id: string; }; query?: never; - url: '/v1/contractors/employments/{employment_id}/cor-termination-requests/{termination_request_id}'; + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents/requirements'; }; -export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors = +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; /** * Forbidden */ @@ -21328,129 +21779,148 @@ export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTermina 404: NotFoundResponse; }; -export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdError = - GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors[keyof GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdErrors]; +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsError = + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsErrors[keyof GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsErrors]; -export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses = +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponses = { /** * Success */ - 200: CorTerminationRequestResponse; + 200: IndexPreOnboardingDocumentRequirementsResponse; }; -export type GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponse = - GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses[keyof GetV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsTerminationRequestIdResponses]; - -export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentData = - { - body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; - query?: never; - url: '/v1/contractors/employments/{employment_id}/terminate-cor-employment'; - }; +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponse = + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponses[keyof GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirementsResponses]; -export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors = - { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; +export type GetV1OffboardingsIdData = { + body?: never; + path: { /** - * Unprocessable Entity + * Offboarding request ID */ - 422: UnprocessableEntityResponse; + id: string; }; + query?: never; + url: '/v1/offboardings/{id}'; +}; -export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentError = - PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors[keyof PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentErrors]; +export type GetV1OffboardingsIdErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; +}; -export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses = - { - /** - * Success - */ - 200: SuccessResponse; - }; +export type GetV1OffboardingsIdError = + GetV1OffboardingsIdErrors[keyof GetV1OffboardingsIdErrors]; -export type PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponse = - PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses[keyof PostV1ContractorsEmploymentsEmploymentIdTerminateCorEmploymentResponses]; +export type GetV1OffboardingsIdResponses = { + /** + * Success + */ + 200: OffboardingResponse; +}; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignData = - { +export type GetV1OffboardingsIdResponse = + GetV1OffboardingsIdResponses[keyof GetV1OffboardingsIdResponses]; + +export type GetV1ExpensesData = { + body?: never; + headers: { /** - * SignContractDocument + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - body: SignContractDocument; - path: { - /** - * Employment ID - */ - employment_id: string; - /** - * Document ID - */ - contract_document_id: string; - }; - query?: never; - url: '/v1/contractors/employments/{employment_id}/contract-documents/{contract_document_id}/sign'; + Authorization: string; }; - -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors = - { + path?: never; + query?: { /** - * Bad Request + * Starts fetching records after the given page */ - 400: BadRequestResponse; + page?: number; /** - * Forbidden + * Change the amount of records returned per page, defaults to 20, limited to 100 */ - 403: ForbiddenResponse; + page_size?: number; }; + url: '/v1/expenses'; +}; + +export type GetV1ExpensesErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; +}; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignError = - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignErrors]; +export type GetV1ExpensesError = GetV1ExpensesErrors[keyof GetV1ExpensesErrors]; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses = - { - /** - * Success - */ - 200: SuccessResponse; - }; +export type GetV1ExpensesResponses = { + /** + * Success + */ + 201: ListExpenseResponse; +}; -export type PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponse = - PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractDocumentsContractDocumentIdSignResponses]; +export type GetV1ExpensesResponse = + GetV1ExpensesResponses[keyof GetV1ExpensesResponses]; -export type GetV1IdentityCurrentData = { - body?: never; +export type PostV1ExpensesData = { + /** + * Expenses + */ + body?: ParamsToCreateExpense; headers: { /** - * This endpoint works with any of the access tokens provided. You can use an access - * token obtained through the Client Credentials flow, the Authorization Code flow, or the Refresh Token flow. + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. * */ Authorization: string; }; path?: never; query?: never; - url: '/v1/identity/current'; + url: '/v1/expenses'; }; -export type GetV1IdentityCurrentErrors = { +export type PostV1ExpensesErrors = { /** * Bad Request */ @@ -21473,20 +21943,64 @@ export type GetV1IdentityCurrentErrors = { 429: TooManyRequestsResponse; }; -export type GetV1IdentityCurrentError = - GetV1IdentityCurrentErrors[keyof GetV1IdentityCurrentErrors]; +export type PostV1ExpensesError = + PostV1ExpensesErrors[keyof PostV1ExpensesErrors]; -export type GetV1IdentityCurrentResponses = { +export type PostV1ExpensesResponses = { /** * Success */ - 201: IdentityCurrentResponse; + 201: ExpenseResponse; }; -export type GetV1IdentityCurrentResponse = - GetV1IdentityCurrentResponses[keyof GetV1IdentityCurrentResponses]; +export type PostV1ExpensesResponse = + PostV1ExpensesResponses[keyof PostV1ExpensesResponses]; -export type DeleteV1IncentivesIdData = { +export type GetV1EmployeePayslipFilesData = { + body?: never; + path?: never; + query?: { + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/employee/payslip-files'; +}; + +export type GetV1EmployeePayslipFilesErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; +}; + +export type GetV1EmployeePayslipFilesError = + GetV1EmployeePayslipFilesErrors[keyof GetV1EmployeePayslipFilesErrors]; + +export type GetV1EmployeePayslipFilesResponses = { + /** + * Success + */ + 200: ListPayslipFilesResponse; +}; + +export type GetV1EmployeePayslipFilesResponse = + GetV1EmployeePayslipFilesResponses[keyof GetV1EmployeePayslipFilesResponses]; + +export type PostV1EmploymentsEmploymentIdInviteData = { body?: never; headers: { /** @@ -21499,27 +22013,19 @@ export type DeleteV1IncentivesIdData = { }; path: { /** - * Incentive ID + * Employment ID */ - id: string; + employment_id: string; }; query?: never; - url: '/v1/incentives/{id}'; + url: '/v1/employments/{employment_id}/invite'; }; -export type DeleteV1IncentivesIdErrors = { +export type PostV1EmploymentsEmploymentIdInviteErrors = { /** * Bad Request */ 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; /** * Conflict */ @@ -21529,170 +22035,216 @@ export type DeleteV1IncentivesIdErrors = { */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type DeleteV1IncentivesIdError = - DeleteV1IncentivesIdErrors[keyof DeleteV1IncentivesIdErrors]; +export type PostV1EmploymentsEmploymentIdInviteError = + PostV1EmploymentsEmploymentIdInviteErrors[keyof PostV1EmploymentsEmploymentIdInviteErrors]; -export type DeleteV1IncentivesIdResponses = { +export type PostV1EmploymentsEmploymentIdInviteResponses = { /** * Success */ 200: SuccessResponse; }; -export type DeleteV1IncentivesIdResponse = - DeleteV1IncentivesIdResponses[keyof DeleteV1IncentivesIdResponses]; +export type PostV1EmploymentsEmploymentIdInviteResponse = + PostV1EmploymentsEmploymentIdInviteResponses[keyof PostV1EmploymentsEmploymentIdInviteResponses]; -export type GetV1IncentivesIdData = { - body?: never; - headers: { +export type PostV1ProbationExtensionsData = { + /** + * ProbationExtension + */ + body: CreateProbationExtensionParams; + path?: never; + query?: never; + url: '/v1/probation-extensions'; +}; + +export type PostV1ProbationExtensionsErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type PostV1ProbationExtensionsError = + PostV1ProbationExtensionsErrors[keyof PostV1ProbationExtensionsErrors]; + +export type PostV1ProbationExtensionsResponses = { + /** + * Success + */ + 200: ProbationExtensionResponse; +}; + +export type PostV1ProbationExtensionsResponse = + PostV1ProbationExtensionsResponses[keyof PostV1ProbationExtensionsResponses]; + +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveData = + { + body?: never; + path: { + /** + * Contract amendment request ID + */ + contract_amendment_request_id: string; + }; + query?: never; + url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/approve'; + }; + +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors = + { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Bad Request */ - Authorization: string; + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; - path: { + +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveError = + PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveErrors]; + +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses = + { + /** + * Success + */ + 200: ContractAmendmentResponse; + }; + +export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponse = + PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdApproveResponses]; + +export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusData = + { + body?: never; + path: { + /** + * Company ID + */ + company_id: UuidSlug; + /** + * Employment ID + */ + employment_id: UuidSlug; + }; + query?: never; + url: '/v1/companies/{company_id}/employments/{employment_id}/onboarding-reserves-status'; + }; + +export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors = + { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** - * Incentive ID + * Not Found */ - id: string; + 404: NotFoundResponse; }; - query?: never; - url: '/v1/incentives/{id}'; -}; - -export type GetV1IncentivesIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; -}; - -export type GetV1IncentivesIdError = - GetV1IncentivesIdErrors[keyof GetV1IncentivesIdErrors]; - -export type GetV1IncentivesIdResponses = { - /** - * Success - */ - 200: IncentiveResponse; -}; -export type GetV1IncentivesIdResponse = - GetV1IncentivesIdResponses[keyof GetV1IncentivesIdResponses]; +export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusError = + GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors[keyof GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusErrors]; -export type PatchV1IncentivesId2Data = { - /** - * Incentive - */ - body?: UpdateIncentiveParams; - headers: { +export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses = + { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Success */ - Authorization: string; + 200: OnboardingReservesStatusResponse; }; + +export type GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponse = + GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses[keyof GetV1CompaniesCompanyIdEmploymentsEmploymentIdOnboardingReservesStatusResponses]; + +export type GetV1ContractorInvoicesIdData = { + body?: never; path: { /** - * Incentive ID + * Resource unique identifier */ - id: string; + id: UuidSlug; }; query?: never; - url: '/v1/incentives/{id}'; + url: '/v1/contractor-invoices/{id}'; }; -export type PatchV1IncentivesId2Errors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1ContractorInvoicesIdErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PatchV1IncentivesId2Error = - PatchV1IncentivesId2Errors[keyof PatchV1IncentivesId2Errors]; +export type GetV1ContractorInvoicesIdError = + GetV1ContractorInvoicesIdErrors[keyof GetV1ContractorInvoicesIdErrors]; -export type PatchV1IncentivesId2Responses = { +export type GetV1ContractorInvoicesIdResponses = { /** * Success */ - 200: IncentiveResponse; + 200: ContractorInvoiceResponse; }; -export type PatchV1IncentivesId2Response = - PatchV1IncentivesId2Responses[keyof PatchV1IncentivesId2Responses]; +export type GetV1ContractorInvoicesIdResponse = + GetV1ContractorInvoicesIdResponses[keyof GetV1ContractorInvoicesIdResponses]; -export type PatchV1IncentivesIdData = { - /** - * Incentive - */ - body?: UpdateIncentiveParams; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; - path: { - /** - * Incentive ID - */ - id: string; - }; +export type GetV1WdGphPayProcessingFeatureData = { + body?: never; + path?: never; query?: never; - url: '/v1/incentives/{id}'; + url: '/v1/wd/gph/payProcessingFeature'; }; -export type PatchV1IncentivesIdErrors = { +export type GetV1WdGphPayProcessingFeatureErrors = { /** * Bad Request */ @@ -21705,160 +22257,124 @@ export type PatchV1IncentivesIdErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PatchV1IncentivesIdError = - PatchV1IncentivesIdErrors[keyof PatchV1IncentivesIdErrors]; +export type GetV1WdGphPayProcessingFeatureError = + GetV1WdGphPayProcessingFeatureErrors[keyof GetV1WdGphPayProcessingFeatureErrors]; -export type PatchV1IncentivesIdResponses = { +export type GetV1WdGphPayProcessingFeatureResponses = { /** * Success */ - 200: IncentiveResponse; + 200: PayProcessingFeatureResponse; }; -export type PatchV1IncentivesIdResponse = - PatchV1IncentivesIdResponses[keyof PatchV1IncentivesIdResponses]; +export type GetV1WdGphPayProcessingFeatureResponse = + GetV1WdGphPayProcessingFeatureResponses[keyof GetV1WdGphPayProcessingFeatureResponses]; -export type GetV1ContractorsSchemasEligibilityQuestionnaireData = { +export type GetV1WdGphPayProgressData = { body?: never; + headers?: { + /** + * The preferred language of the inquiring user in Workday + */ + accept_language?: string; + }; path?: never; query: { /** - * Type of eligibility questionnaire + * The pay group ID for identifying the pay group at the vendor system */ - type: 'contractor_of_record'; + payGroupExternalId: string; /** - * Version of the form schema + * The run type id provided in the paySummary API */ - json_schema_version?: number | 'latest'; + runTypeId: string; + /** + * The cycle type id, defaults to the main run if not provided + */ + cycleTypeId?: string; + /** + * The period end date in question, defaults to current period if not provided + */ + periodEndDate?: Date; }; - url: '/v1/contractors/schemas/eligibility-questionnaire'; + url: '/v1/wd/gph/payProgress'; }; -export type GetV1ContractorsSchemasEligibilityQuestionnaireErrors = { +export type GetV1WdGphPayProgressErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: NotFoundResponse; }; -export type GetV1ContractorsSchemasEligibilityQuestionnaireError = - GetV1ContractorsSchemasEligibilityQuestionnaireErrors[keyof GetV1ContractorsSchemasEligibilityQuestionnaireErrors]; +export type GetV1WdGphPayProgressError = + GetV1WdGphPayProgressErrors[keyof GetV1WdGphPayProgressErrors]; -export type GetV1ContractorsSchemasEligibilityQuestionnaireResponses = { +export type GetV1WdGphPayProgressResponses = { /** * Success */ - 200: EligibilityQuestionnaireJsonSchemaResponse; + 200: PayProgressResponse; }; -export type GetV1ContractorsSchemasEligibilityQuestionnaireResponse = - GetV1ContractorsSchemasEligibilityQuestionnaireResponses[keyof GetV1ContractorsSchemasEligibilityQuestionnaireResponses]; +export type GetV1WdGphPayProgressResponse = + GetV1WdGphPayProgressResponses[keyof GetV1WdGphPayProgressResponses]; -export type GetV1WorkAuthorizationRequestsData = { +export type GetV1CompanyCurrenciesData = { body?: never; path?: never; - query?: { - /** - * Filter results on the given status - */ - status?: - | 'pending' - | 'cancelled' - | 'declined_by_manager' - | 'declined_by_remote' - | 'approved_by_manager' - | 'approved_by_remote'; - /** - * Filter results on the given employment slug - */ - employment_id?: string; - /** - * Filter results on the given employee name - */ - employee_name?: string; - /** - * Sort order - */ - order?: 'asc' | 'desc'; - /** - * Field to sort by - */ - sort_by?: 'submitted_at'; - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page - */ - page_size?: number; - }; - url: '/v1/work-authorization-requests'; + query?: never; + url: '/v1/company-currencies'; }; -export type GetV1WorkAuthorizationRequestsErrors = { +export type GetV1CompanyCurrenciesErrors = { /** * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; }; -export type GetV1WorkAuthorizationRequestsError = - GetV1WorkAuthorizationRequestsErrors[keyof GetV1WorkAuthorizationRequestsErrors]; +export type GetV1CompanyCurrenciesError = + GetV1CompanyCurrenciesErrors[keyof GetV1CompanyCurrenciesErrors]; -export type GetV1WorkAuthorizationRequestsResponses = { +export type GetV1CompanyCurrenciesResponses = { /** * Success */ - 200: ListWorkAuthorizationRequestsResponse; + 200: CompanyCurrenciesResponse; }; -export type GetV1WorkAuthorizationRequestsResponse = - GetV1WorkAuthorizationRequestsResponses[keyof GetV1WorkAuthorizationRequestsResponses]; +export type GetV1CompanyCurrenciesResponse = + GetV1CompanyCurrenciesResponses[keyof GetV1CompanyCurrenciesResponses]; -export type GetV1BulkEmploymentJobsJobIdData = { +export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaData = { body?: never; path: { /** - * Bulk employment job id + * Unique identifier of the employment */ - job_id: string; + employment_id: UuidSlug; }; - query?: never; - url: '/v1/bulk-employment-jobs/{job_id}'; + query?: { + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; + }; + url: '/v1/employments/{employment_id}/benefit-offers/schema'; }; -export type GetV1BulkEmploymentJobsJobIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors = { /** * Forbidden */ @@ -21870,38 +22386,71 @@ export type GetV1BulkEmploymentJobsJobIdErrors = { /** * Unprocessable Entity */ - 429: TooManyRequestsResponse; + 422: UnprocessableEntityResponse; }; -export type GetV1BulkEmploymentJobsJobIdError = - GetV1BulkEmploymentJobsJobIdErrors[keyof GetV1BulkEmploymentJobsJobIdErrors]; +export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaError = + GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors[keyof GetV1EmploymentsEmploymentIdBenefitOffersSchemaErrors]; -export type GetV1BulkEmploymentJobsJobIdResponses = { +export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses = { /** * Success */ - 200: BulkEmploymentImportJobResponse; + 200: UnifiedEmploymentsBenefitOffersJsonSchemaResponse; }; -export type GetV1BulkEmploymentJobsJobIdResponse = - GetV1BulkEmploymentJobsJobIdResponses[keyof GetV1BulkEmploymentJobsJobIdResponses]; +export type GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponse = + GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses[keyof GetV1EmploymentsEmploymentIdBenefitOffersSchemaResponses]; -export type GetV1PayItemsData = { +export type GetV1ContractorInvoiceSchedulesData = { body?: never; path?: never; query?: { /** - * Filter by employment slug + * Filters contractor invoice schedules by start date greater than or equal to the value. */ - employment_slug?: UuidSlug; + start_date_from?: Date; /** - * Filter pay items with effective_date >= given date (YYYY-MM-DD) + * Filters contractor invoice schedules by start date less than or equal to the value. */ - effective_from?: Date; + start_date_to?: Date; /** - * Filter pay items with effective_date <= given date (YYYY-MM-DD) + * Filters contractor invoice schedules by next invoice date greater than or equal to the value. */ - effective_to?: Date; + next_invoice_date_from?: Date; + /** + * Filters contractor invoice schedules by next invoice date less than or equal to the value. + */ + next_invoice_date_to?: Date; + /** + * Filters contractor invoice schedules by status matching the value. + */ + status?: ContractorInvoiceScheduleStatus; + /** + * Filters contractor invoice schedules by employment id matching the value. + */ + employment_id?: UuidSlug; + /** + * Filters contractor invoice schedules by periodicity matching the value. + */ + periodicity?: ContractorInvoiceSchedulePeriodicity; + /** + * Filters contractor invoice schedules by currency matching the value. + */ + currency?: string; + /** + * Field to sort by + */ + sort_by?: + | 'number' + | 'total_amount' + | 'next_invoice_at' + | 'start_date' + | 'nr_occurrences'; + /** + * Sort order + */ + order?: 'asc' | 'desc'; /** * Starts fetching records after the given page */ @@ -21911,10 +22460,10 @@ export type GetV1PayItemsData = { */ page_size?: number; }; - url: '/v1/pay-items'; + url: '/v1/contractor-invoice-schedules'; }; -export type GetV1PayItemsErrors = { +export type GetV1ContractorInvoiceSchedulesErrors = { /** * Unauthorized */ @@ -21927,172 +22476,136 @@ export type GetV1PayItemsErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; }; -export type GetV1PayItemsError = GetV1PayItemsErrors[keyof GetV1PayItemsErrors]; +export type GetV1ContractorInvoiceSchedulesError = + GetV1ContractorInvoiceSchedulesErrors[keyof GetV1ContractorInvoiceSchedulesErrors]; -export type GetV1PayItemsResponses = { +export type GetV1ContractorInvoiceSchedulesResponses = { /** * Success */ - 200: ListPayItemsResponse; + 200: ListContractorInvoiceSchedulesResponse; }; -export type GetV1PayItemsResponse = - GetV1PayItemsResponses[keyof GetV1PayItemsResponses]; +export type GetV1ContractorInvoiceSchedulesResponse = + GetV1ContractorInvoiceSchedulesResponses[keyof GetV1ContractorInvoiceSchedulesResponses]; -export type GetV1BenefitOffersCountrySummariesData = { - body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; +export type PostV1ContractorInvoiceSchedulesData = { + /** + * Bulk creation payload + */ + body: BulkContractorInvoiceScheduleCreateParams; path?: never; query?: never; - url: '/v1/benefit-offers/country-summaries'; + url: '/v1/contractor-invoice-schedules'; }; -export type GetV1BenefitOffersCountrySummariesErrors = { +export type PostV1ContractorInvoiceSchedulesErrors = { + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; /** - * Unprocessable Entity + * BulkContractorInvoiceScheduleCreateResponse + * + * Response containing the lists of succeeded and failed schedules. */ - 422: UnprocessableEntityResponse; + 422: { + data: { + failures: Array; + successes: Array; + }; + }; }; -export type GetV1BenefitOffersCountrySummariesError = - GetV1BenefitOffersCountrySummariesErrors[keyof GetV1BenefitOffersCountrySummariesErrors]; +export type PostV1ContractorInvoiceSchedulesError = + PostV1ContractorInvoiceSchedulesErrors[keyof PostV1ContractorInvoiceSchedulesErrors]; -export type GetV1BenefitOffersCountrySummariesResponses = { +export type PostV1ContractorInvoiceSchedulesResponses = { /** - * Success + * BulkContractorInvoiceScheduleCreateResponse + * + * Response containing the lists of succeeded and failed schedules. */ - 200: CountrySummariesResponse; + 201: { + data: { + failures: Array; + successes: Array; + }; + }; + /** + * BulkContractorInvoiceScheduleCreateResponse + * + * Response containing the lists of succeeded and failed schedules. + */ + 207: { + data: { + failures: Array; + successes: Array; + }; + }; }; -export type GetV1BenefitOffersCountrySummariesResponse = - GetV1BenefitOffersCountrySummariesResponses[keyof GetV1BenefitOffersCountrySummariesResponses]; +export type PostV1ContractorInvoiceSchedulesResponse = + PostV1ContractorInvoiceSchedulesResponses[keyof PostV1ContractorInvoiceSchedulesResponses]; -export type GetV1BenefitOffersData = { +export type GetV1WorkAuthorizationRequestsIdData = { body?: never; - headers: { + path: { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * work authorization request ID */ - Authorization: string; + id: string; }; - path?: never; query?: never; - url: '/v1/benefit-offers'; + url: '/v1/work-authorization-requests/{id}'; }; -export type GetV1BenefitOffersErrors = { +export type GetV1WorkAuthorizationRequestsIdErrors = { /** * Not Found */ 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; }; -export type GetV1BenefitOffersError = - GetV1BenefitOffersErrors[keyof GetV1BenefitOffersErrors]; +export type GetV1WorkAuthorizationRequestsIdError = + GetV1WorkAuthorizationRequestsIdErrors[keyof GetV1WorkAuthorizationRequestsIdErrors]; -export type GetV1BenefitOffersResponses = { +export type GetV1WorkAuthorizationRequestsIdResponses = { /** * Success */ - 200: BenefitOfferByEmploymentResponse; + 200: WorkAuthorizationRequestResponse; }; -export type GetV1BenefitOffersResponse = - GetV1BenefitOffersResponses[keyof GetV1BenefitOffersResponses]; - -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelData = - { - body?: never; - path: { - /** - * Contract amendment request ID - */ - contract_amendment_request_id: string; - }; - query?: never; - url: '/v1/sandbox/contract-amendments/{contract_amendment_request_id}/cancel'; - }; - -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors = - { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; - }; - -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelError = - PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelErrors]; - -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses = - { - /** - * Success - */ - 200: SuccessResponse; - }; - -export type PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponse = - PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses[keyof PutV1SandboxContractAmendmentsContractAmendmentRequestIdCancelResponses]; +export type GetV1WorkAuthorizationRequestsIdResponse = + GetV1WorkAuthorizationRequestsIdResponses[keyof GetV1WorkAuthorizationRequestsIdResponses]; -export type GetV1EmployeeTimeoffData = { - body?: never; - path?: never; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; +export type PatchV1WorkAuthorizationRequestsId2Data = { + /** + * Work Authorization Request + */ + body: UpdateWorkAuthorizationRequestParams; + path: { /** - * Number of items per page + * work authorization request ID */ - page_size?: number; + id: string; }; - url: '/v1/employee/timeoff'; -}; - -export type GetV1EmployeeTimeoffErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; + query?: never; + url: '/v1/work-authorization-requests/{id}'; +}; + +export type PatchV1WorkAuthorizationRequestsId2Errors = { /** * Unauthorized */ @@ -22104,37 +22617,38 @@ export type GetV1EmployeeTimeoffErrors = { /** * Unprocessable Entity */ - 429: TooManyRequestsResponse; + 422: UnprocessableEntityResponse; }; -export type GetV1EmployeeTimeoffError = - GetV1EmployeeTimeoffErrors[keyof GetV1EmployeeTimeoffErrors]; +export type PatchV1WorkAuthorizationRequestsId2Error = + PatchV1WorkAuthorizationRequestsId2Errors[keyof PatchV1WorkAuthorizationRequestsId2Errors]; -export type GetV1EmployeeTimeoffResponses = { +export type PatchV1WorkAuthorizationRequestsId2Responses = { /** * Success */ - 200: ListTimeoffResponse; + 200: WorkAuthorizationRequestResponse; }; -export type GetV1EmployeeTimeoffResponse = - GetV1EmployeeTimeoffResponses[keyof GetV1EmployeeTimeoffResponses]; +export type PatchV1WorkAuthorizationRequestsId2Response = + PatchV1WorkAuthorizationRequestsId2Responses[keyof PatchV1WorkAuthorizationRequestsId2Responses]; -export type PostV1EmployeeTimeoffData = { +export type PatchV1WorkAuthorizationRequestsIdData = { /** - * Timeoff + * Work Authorization Request */ - body: CreateEmployeeTimeoffParams; - path?: never; + body: UpdateWorkAuthorizationRequestParams; + path: { + /** + * work authorization request ID + */ + id: string; + }; query?: never; - url: '/v1/employee/timeoff'; + url: '/v1/work-authorization-requests/{id}'; }; -export type PostV1EmployeeTimeoffErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PatchV1WorkAuthorizationRequestsIdErrors = { /** * Unauthorized */ @@ -22147,53 +22661,49 @@ export type PostV1EmployeeTimeoffErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PostV1EmployeeTimeoffError = - PostV1EmployeeTimeoffErrors[keyof PostV1EmployeeTimeoffErrors]; +export type PatchV1WorkAuthorizationRequestsIdError = + PatchV1WorkAuthorizationRequestsIdErrors[keyof PatchV1WorkAuthorizationRequestsIdErrors]; -export type PostV1EmployeeTimeoffResponses = { +export type PatchV1WorkAuthorizationRequestsIdResponses = { /** - * Created + * Success */ - 201: TimeoffResponse; + 200: WorkAuthorizationRequestResponse; }; -export type PostV1EmployeeTimeoffResponse = - PostV1EmployeeTimeoffResponses[keyof PostV1EmployeeTimeoffResponses]; +export type PatchV1WorkAuthorizationRequestsIdResponse = + PatchV1WorkAuthorizationRequestsIdResponses[keyof PatchV1WorkAuthorizationRequestsIdResponses]; -export type PatchV2EmploymentsEmploymentId2Data = { +export type PostV1TimeoffTimeoffIdDeclineData = { /** - * Employment params + * DeclineTimeoff */ - body?: EmploymentV2UpdateParams; + body: DeclineTimeoffParams; path: { /** - * Employment ID + * Time Off ID */ - employment_id: string; + timeoff_id: string; }; query?: never; - url: '/v2/employments/{employment_id}'; + url: '/v1/timeoff/{timeoff_id}/decline'; }; -export type PatchV2EmploymentsEmploymentId2Errors = { +export type PostV1TimeoffTimeoffIdDeclineErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** - * Conflict + * Not Found */ - 409: ConflictResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ @@ -22204,83 +22714,78 @@ export type PatchV2EmploymentsEmploymentId2Errors = { 429: TooManyRequestsResponse; }; -export type PatchV2EmploymentsEmploymentId2Error = - PatchV2EmploymentsEmploymentId2Errors[keyof PatchV2EmploymentsEmploymentId2Errors]; +export type PostV1TimeoffTimeoffIdDeclineError = + PostV1TimeoffTimeoffIdDeclineErrors[keyof PostV1TimeoffTimeoffIdDeclineErrors]; -export type PatchV2EmploymentsEmploymentId2Responses = { +export type PostV1TimeoffTimeoffIdDeclineResponses = { /** * Success */ - 200: EmploymentResponse; + 200: TimeoffResponse; }; -export type PatchV2EmploymentsEmploymentId2Response = - PatchV2EmploymentsEmploymentId2Responses[keyof PatchV2EmploymentsEmploymentId2Responses]; +export type PostV1TimeoffTimeoffIdDeclineResponse = + PostV1TimeoffTimeoffIdDeclineResponses[keyof PostV1TimeoffTimeoffIdDeclineResponses]; -export type PatchV2EmploymentsEmploymentIdData = { - /** - * Employment params - */ - body?: EmploymentV2UpdateParams; - path: { +export type GetV1ContractorsSchemasEligibilityQuestionnaireData = { + body?: never; + path?: never; + query: { /** - * Employment ID + * Type of eligibility questionnaire */ - employment_id: string; + type: 'contractor_of_record'; + /** + * Version of the form schema + */ + json_schema_version?: number | 'latest'; }; - query?: never; - url: '/v2/employments/{employment_id}'; + url: '/v1/contractors/schemas/eligibility-questionnaire'; }; -export type PatchV2EmploymentsEmploymentIdErrors = { +export type GetV1ContractorsSchemasEligibilityQuestionnaireErrors = { /** - * Bad Request + * Unauthorized */ - 400: BadRequestResponse; + 401: UnauthorizedResponse; /** * Forbidden */ 403: ForbiddenResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PatchV2EmploymentsEmploymentIdError = - PatchV2EmploymentsEmploymentIdErrors[keyof PatchV2EmploymentsEmploymentIdErrors]; +export type GetV1ContractorsSchemasEligibilityQuestionnaireError = + GetV1ContractorsSchemasEligibilityQuestionnaireErrors[keyof GetV1ContractorsSchemasEligibilityQuestionnaireErrors]; -export type PatchV2EmploymentsEmploymentIdResponses = { +export type GetV1ContractorsSchemasEligibilityQuestionnaireResponses = { /** * Success */ - 200: EmploymentResponse; + 200: EligibilityQuestionnaireJsonSchemaResponse; }; -export type PatchV2EmploymentsEmploymentIdResponse = - PatchV2EmploymentsEmploymentIdResponses[keyof PatchV2EmploymentsEmploymentIdResponses]; +export type GetV1ContractorsSchemasEligibilityQuestionnaireResponse = + GetV1ContractorsSchemasEligibilityQuestionnaireResponses[keyof GetV1ContractorsSchemasEligibilityQuestionnaireResponses]; -export type GetV1ProbationExtensionsIdData = { - body?: never; - path: { - /** - * Probation Extension Request ID - */ - id: string; - }; +export type PostAuthOauth2TokenData = { + /** + * OAuth2Token + */ + body?: OAuth2TokenParams; + path?: never; query?: never; - url: '/v1/probation-extensions/{id}'; + url: '/api/eor/oauth2/token'; }; -export type GetV1ProbationExtensionsIdErrors = { +export type PostAuthOauth2TokenErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -22293,58 +22798,132 @@ export type GetV1ProbationExtensionsIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Too many requests + */ + 429: TooManyRequestsResponse; }; -export type GetV1ProbationExtensionsIdError = - GetV1ProbationExtensionsIdErrors[keyof GetV1ProbationExtensionsIdErrors]; +export type PostAuthOauth2TokenError = + PostAuthOauth2TokenErrors[keyof PostAuthOauth2TokenErrors]; -export type GetV1ProbationExtensionsIdResponses = { +export type PostAuthOauth2TokenResponses = { /** * Success */ - 200: ProbationExtensionResponse; + 200: OAuth2Tokens; }; -export type GetV1ProbationExtensionsIdResponse = - GetV1ProbationExtensionsIdResponses[keyof GetV1ProbationExtensionsIdResponses]; +export type PostAuthOauth2TokenResponse = + PostAuthOauth2TokenResponses[keyof PostAuthOauth2TokenResponses]; -export type GetV1PayslipsData = { - body?: never; - path?: never; - query?: { +export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData = + { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription'; + }; + +export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors = + { /** - * Employment ID + * Unauthorized */ - employment_id?: string; + 401: UnauthorizedResponse; /** - * Filters by payslips `issued_at` field, after or on the same day than the given date + * Forbidden */ - start_date?: string; + 403: ForbiddenResponse; /** - * Filters by payslips `issued_at` field, before or or the same day than the given date + * Not Found */ - end_date?: string; + 404: NotFoundResponse; /** - * Filters by payslips `expected_payout_date` field, after or on the same day than the given date + * Unprocessable Entity */ - expected_payout_start_date?: string; + 422: UnprocessableEntityResponse; + }; + +export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionError = + DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors[keyof DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors]; + +export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses = + { /** - * Filters by payslips `expected_payout_date` field, before or or the same day than the given date + * No Content */ - expected_payout_end_date?: string; + 204: unknown; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData = + { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription'; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors = + { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionError = + PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors]; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses = + { /** - * Starts fetching records after the given page + * Created */ - page?: number; + 201: SuccessResponse; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponse = + PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses]; + +export type PutV2EmploymentsEmploymentIdPersonalDetailsData = { + /** + * Employment personal details params + */ + body?: EmploymentPersonalDetailsParams; + path: { /** - * Change the amount of records returned per page, defaults to 20, limited to 100 + * Employment ID */ - page_size?: number; + employment_id: string; }; - url: '/v1/payslips'; + query?: never; + url: '/v2/employments/{employment_id}/personal_details'; }; -export type GetV1PayslipsErrors = { +export type PutV2EmploymentsEmploymentIdPersonalDetailsErrors = { /** * Bad Request */ @@ -22353,61 +22932,117 @@ export type GetV1PayslipsErrors = { * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV1PayslipsError = GetV1PayslipsErrors[keyof GetV1PayslipsErrors]; +export type PutV2EmploymentsEmploymentIdPersonalDetailsError = + PutV2EmploymentsEmploymentIdPersonalDetailsErrors[keyof PutV2EmploymentsEmploymentIdPersonalDetailsErrors]; -export type GetV1PayslipsResponses = { +export type PutV2EmploymentsEmploymentIdPersonalDetailsResponses = { /** * Success */ - 200: ListPayslipsResponse; + 200: EmploymentResponse; }; -export type GetV1PayslipsResponse = - GetV1PayslipsResponses[keyof GetV1PayslipsResponses]; +export type PutV2EmploymentsEmploymentIdPersonalDetailsResponse = + PutV2EmploymentsEmploymentIdPersonalDetailsResponses[keyof PutV2EmploymentsEmploymentIdPersonalDetailsResponses]; -export type GetV1ExpensesExpenseIdReceiptsReceiptIdData = { +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsData = + { + /** + * FindOrCreatePreOnboardingDocumentParams + */ + body: FindOrCreatePreOnboardingDocumentParams; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents'; + }; + +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsErrors = + { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; + }; + +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsError = + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsErrors[keyof PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsErrors]; + +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponses = + { + /** + * Success + */ + 200: CreatePreOnboardingDocumentResponse; + }; + +export type PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponse = + PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponses[keyof PostV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsResponses]; + +export type GetV1ContractAmendmentsIdData = { body?: never; - path: { + headers: { /** - * The expense ID + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * */ - expense_id: string; + Authorization: string; + }; + path: { /** - * The receipt ID + * Contract amendment request ID */ - receipt_id: string; + id: string; }; query?: never; - url: '/v1/expenses/{expense_id}/receipts/{receipt_id}'; + url: '/v1/contract-amendments/{id}'; }; -export type GetV1ExpensesExpenseIdReceiptsReceiptIdErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1ContractAmendmentsIdErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; /** * Not Found */ @@ -22416,40 +23051,34 @@ export type GetV1ExpensesExpenseIdReceiptsReceiptIdErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type GetV1ExpensesExpenseIdReceiptsReceiptIdError = - GetV1ExpensesExpenseIdReceiptsReceiptIdErrors[keyof GetV1ExpensesExpenseIdReceiptsReceiptIdErrors]; +export type GetV1ContractAmendmentsIdError = + GetV1ContractAmendmentsIdErrors[keyof GetV1ContractAmendmentsIdErrors]; -export type GetV1ExpensesExpenseIdReceiptsReceiptIdResponses = { +export type GetV1ContractAmendmentsIdResponses = { /** * Success */ - 200: GenericFile; + 200: ContractAmendmentResponse; }; -export type GetV1ExpensesExpenseIdReceiptsReceiptIdResponse = - GetV1ExpensesExpenseIdReceiptsReceiptIdResponses[keyof GetV1ExpensesExpenseIdReceiptsReceiptIdResponses]; +export type GetV1ContractAmendmentsIdResponse = + GetV1ContractAmendmentsIdResponses[keyof GetV1ContractAmendmentsIdResponses]; -export type PostAuthOauth2TokenData = { - /** - * OAuth2Token - */ - body?: OAuth2TokenParams; - path?: never; +export type PostV1IdentityVerificationEmploymentIdDeclineData = { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; query?: never; - url: '/auth/oauth2/token'; + url: '/v1/identity-verification/{employment_id}/decline'; }; -export type PostAuthOauth2TokenErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PostV1IdentityVerificationEmploymentIdDeclineErrors = { /** * Unauthorized */ @@ -22462,45 +23091,38 @@ export type PostAuthOauth2TokenErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Too many requests - */ - 429: TooManyRequestsResponse; }; -export type PostAuthOauth2TokenError = - PostAuthOauth2TokenErrors[keyof PostAuthOauth2TokenErrors]; +export type PostV1IdentityVerificationEmploymentIdDeclineError = + PostV1IdentityVerificationEmploymentIdDeclineErrors[keyof PostV1IdentityVerificationEmploymentIdDeclineErrors]; -export type PostAuthOauth2TokenResponses = { +export type PostV1IdentityVerificationEmploymentIdDeclineResponses = { /** * Success */ - 200: OAuth2Tokens; + 200: SuccessResponse; }; -export type PostAuthOauth2TokenResponse = - PostAuthOauth2TokenResponses[keyof PostAuthOauth2TokenResponses]; +export type PostV1IdentityVerificationEmploymentIdDeclineResponse = + PostV1IdentityVerificationEmploymentIdDeclineResponses[keyof PostV1IdentityVerificationEmploymentIdDeclineResponses]; -export type PutV2EmploymentsEmploymentIdPricingPlanDetailsData = { - /** - * Employment pricing plan details params - */ - body?: EmploymentPricingPlanDetailsParams; - path: { +export type GetV1EmployeeExpenseCategoriesData = { + body?: never; + path?: never; + query?: { /** - * Employment ID + * Include parent (non-selectable) categories in addition to selectable leaves */ - employment_id: string; + include_parents?: boolean; + /** + * Expense ID (slug) whose category should be included in the result, even if it is not selectable by default + */ + expense_id?: string; }; - query?: never; - url: '/v2/employments/{employment_id}/pricing_plan_details'; + url: '/v1/employee/expense-categories'; }; -export type PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmployeeExpenseCategoriesErrors = { /** * Unauthorized */ @@ -22513,71 +23135,32 @@ export type PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdPricingPlanDetailsError = - PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors[keyof PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors]; +export type GetV1EmployeeExpenseCategoriesError = + GetV1EmployeeExpenseCategoriesErrors[keyof GetV1EmployeeExpenseCategoriesErrors]; -export type PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses = { +export type GetV1EmployeeExpenseCategoriesResponses = { /** * Success */ - 200: EmploymentResponse; -}; - -export type PutV2EmploymentsEmploymentIdPricingPlanDetailsResponse = - PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses[keyof PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses]; - -export type GetV1CountriesCountryCodeLegalEntityFormsFormData = { - body?: never; - path: { - /** - * Country code according to ISO 3-digit alphabetic codes - */ - country_code: string; - /** - * Name of the desired form - */ - form: string; - }; - query?: { - /** - * Product type. Default value is global_payroll. - */ - product_type?: 'peo' | 'global_payroll' | 'e2e_payroll'; - /** - * Legal entity id for admistrative_details of e2e payroll products in GBR - */ - legal_entity_id?: UuidSlug; - /** - * Version of the form schema - */ - json_schema_version?: number | 'latest'; - }; - url: '/v1/countries/{country_code}/legal_entity_forms/{form}'; + 200: ListExpenseCategoriesResponse; }; -export type GetV1CountriesCountryCodeLegalEntityFormsFormErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1EmployeeExpenseCategoriesResponse = + GetV1EmployeeExpenseCategoriesResponses[keyof GetV1EmployeeExpenseCategoriesResponses]; + +export type PostV1CostCalculatorEstimationCsvData = { /** - * Unauthorized + * Estimate params */ - 401: UnauthorizedResponse; + body?: CostCalculatorEstimateParams; + path?: never; + query?: never; + url: '/v1/cost-calculator/estimation-csv'; +}; + +export type PostV1CostCalculatorEstimationCsvErrors = { /** * Not Found */ @@ -22586,68 +23169,69 @@ export type GetV1CountriesCountryCodeLegalEntityFormsFormErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type GetV1CountriesCountryCodeLegalEntityFormsFormError = - GetV1CountriesCountryCodeLegalEntityFormsFormErrors[keyof GetV1CountriesCountryCodeLegalEntityFormsFormErrors]; +export type PostV1CostCalculatorEstimationCsvError = + PostV1CostCalculatorEstimationCsvErrors[keyof PostV1CostCalculatorEstimationCsvErrors]; -export type GetV1CountriesCountryCodeLegalEntityFormsFormResponses = { +export type PostV1CostCalculatorEstimationCsvResponses = { /** * Success */ - 200: CountryFormResponse; + 200: CostCalculatorEstimateCsvResponse; }; -export type GetV1CountriesCountryCodeLegalEntityFormsFormResponse = - GetV1CountriesCountryCodeLegalEntityFormsFormResponses[keyof GetV1CountriesCountryCodeLegalEntityFormsFormResponses]; +export type PostV1CostCalculatorEstimationCsvResponse = + PostV1CostCalculatorEstimationCsvResponses[keyof PostV1CostCalculatorEstimationCsvResponses]; -export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionData = +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdData = { - /** - * Manage Contractor Plus subscription params - */ - body: ManageContractorPlusSubscriptionOperationsParams; + body?: never; path: { /** * Employment ID */ employment_id: string; + /** + * Pre-onboarding document ID + */ + id: string; }; query?: never; - url: '/v1/contractors/employments/{employment_id}/contractor-plus-subscription'; + url: '/v1/onboarding/employments/{employment_id}/pre-onboarding-documents/{id}'; }; -export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors = +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdErrors = { /** - * Bad Request + * Unauthorized */ - 400: BadRequestResponse; + 401: UnauthorizedResponse; /** * Forbidden */ 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; }; -export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionError = - PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionErrors]; +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdError = + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdErrors[keyof GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdErrors]; -export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses = +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponses = { /** * Success */ - 200: SuccessResponse; + 200: ShowPreOnboardingDocumentResponse; }; -export type PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponse = - PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractorPlusSubscriptionResponses]; +export type GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponse = + GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponses[keyof GetV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsIdResponses]; -export type GetV1TimeoffData = { +export type GetV1BillingDocumentsData = { body?: never; headers: { /** @@ -22661,25 +23245,9 @@ export type GetV1TimeoffData = { path?: never; query?: { /** - * Only show time off for a specific employment - */ - employment_id?: string; - /** - * Filter time off by its type - */ - timeoff_type?: TimeoffType; - /** - * Filter time off by its status - */ - status?: TimeoffStatus; - /** - * Sort order - */ - order?: 'asc' | 'desc'; - /** - * Field to sort by + * The month for the billing documents (in ISO-8601 format) */ - sort_by?: 'timeoff_type' | 'status'; + period?: string; /** * Starts fetching records after the given page */ @@ -22689,14 +23257,10 @@ export type GetV1TimeoffData = { */ page_size?: number; }; - url: '/v1/timeoff'; + url: '/v1/billing-documents'; }; -export type GetV1TimeoffErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1BillingDocumentsErrors = { /** * Unauthorized */ @@ -22709,29 +23273,23 @@ export type GetV1TimeoffErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type GetV1TimeoffError = GetV1TimeoffErrors[keyof GetV1TimeoffErrors]; +export type GetV1BillingDocumentsError = + GetV1BillingDocumentsErrors[keyof GetV1BillingDocumentsErrors]; -export type GetV1TimeoffResponses = { +export type GetV1BillingDocumentsResponses = { /** * Success */ - 200: ListTimeoffResponse; + 200: BillingDocumentsResponse; }; -export type GetV1TimeoffResponse = - GetV1TimeoffResponses[keyof GetV1TimeoffResponses]; +export type GetV1BillingDocumentsResponse = + GetV1BillingDocumentsResponses[keyof GetV1BillingDocumentsResponses]; -export type PostV1TimeoffData = { - /** - * Timeoff - */ - body: CreateApprovedTimeoffParams; +export type GetV1BillingDocumentsBillingDocumentIdData = { + body?: never; headers: { /** * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. @@ -22741,12 +23299,22 @@ export type PostV1TimeoffData = { */ Authorization: string; }; - path?: never; - query?: never; - url: '/v1/timeoff'; + path: { + /** + * The billing document's ID + */ + billing_document_id: string; + }; + query?: { + /** + * When true, includes billing document items whose type is not part of the standard set for the invoice type. + */ + include_unrecognized_types?: boolean; + }; + url: '/v1/billing-documents/{billing_document_id}'; }; -export type PostV1TimeoffErrors = { +export type GetV1BillingDocumentsBillingDocumentIdErrors = { /** * Bad Request */ @@ -22769,26 +23337,92 @@ export type PostV1TimeoffErrors = { 429: TooManyRequestsResponse; }; -export type PostV1TimeoffError = PostV1TimeoffErrors[keyof PostV1TimeoffErrors]; +export type GetV1BillingDocumentsBillingDocumentIdError = + GetV1BillingDocumentsBillingDocumentIdErrors[keyof GetV1BillingDocumentsBillingDocumentIdErrors]; -export type PostV1TimeoffResponses = { +export type GetV1BillingDocumentsBillingDocumentIdResponses = { /** - * Created + * Success */ - 201: TimeoffResponse; + 200: BillingDocumentResponse; }; -export type PostV1TimeoffResponse = - PostV1TimeoffResponses[keyof PostV1TimeoffResponses]; +export type GetV1BillingDocumentsBillingDocumentIdResponse = + GetV1BillingDocumentsBillingDocumentIdResponses[keyof GetV1BillingDocumentsBillingDocumentIdResponses]; -export type GetV1PayrollRunsData = { +export type GetV1EmployeeDocumentsData = { body?: never; path?: never; query?: { /** - * Filters payroll runs where period_start or period_end match the given date + * Starts fetching records after the given page */ - payroll_period?: Date; + page?: number; + /** + * Number of items per page + */ + page_size?: number; + /** + * Filter documents by their description or file name, accepts full and partial case insensitive matches + */ + name?: string; + /** + * Filters the results that were uploaded on or after a given date + */ + inserted_after?: Date; + /** + * Filters the results that were uploaded before a given date + */ + inserted_before?: Date; + /** + * Field to sort by + */ + sort_by?: + | 'description' + | 'document_source' + | 'inserted_at' + | 'name' + | 'type' + | 'uploaded_by_role' + | 'related_to' + | 'sub_type' + | 'uploaded_by'; + /** + * Sort order + */ + order?: 'asc' | 'desc'; + }; + url: '/v1/employee/documents'; +}; + +export type GetV1EmployeeDocumentsErrors = { + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; +}; + +export type GetV1EmployeeDocumentsError = + GetV1EmployeeDocumentsErrors[keyof GetV1EmployeeDocumentsErrors]; + +export type GetV1EmployeeDocumentsResponses = { + /** + * Success + */ + 200: ListDocumentsResponse; +}; + +export type GetV1EmployeeDocumentsResponse = + GetV1EmployeeDocumentsResponses[keyof GetV1EmployeeDocumentsResponses]; + +export type GetV1EmployeeTimeoffData = { + body?: never; + path?: never; + query?: { /** * Starts fetching records after the given page */ @@ -22798,10 +23432,56 @@ export type GetV1PayrollRunsData = { */ page_size?: number; }; - url: '/v1/payroll-runs'; + url: '/v1/employee/timeoff'; }; -export type GetV1PayrollRunsErrors = { +export type GetV1EmployeeTimeoffErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; +}; + +export type GetV1EmployeeTimeoffError = + GetV1EmployeeTimeoffErrors[keyof GetV1EmployeeTimeoffErrors]; + +export type GetV1EmployeeTimeoffResponses = { + /** + * Success + */ + 200: ListTimeoffResponse; +}; + +export type GetV1EmployeeTimeoffResponse = + GetV1EmployeeTimeoffResponses[keyof GetV1EmployeeTimeoffResponses]; + +export type PostV1EmployeeTimeoffData = { + /** + * Timeoff + */ + body: CreateEmployeeTimeoffParams; + path?: never; + query?: never; + url: '/v1/employee/timeoff'; +}; + +export type PostV1EmployeeTimeoffErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ @@ -22814,129 +23494,89 @@ export type GetV1PayrollRunsErrors = { * Unprocessable Entity */ 422: UnprocessableEntityResponse; -}; - -export type GetV1PayrollRunsError = - GetV1PayrollRunsErrors[keyof GetV1PayrollRunsErrors]; - -export type GetV1PayrollRunsResponses = { /** - * Success + * Unprocessable Entity */ - 200: ListPayrollRunResponse; + 429: TooManyRequestsResponse; }; -export type GetV1PayrollRunsResponse = - GetV1PayrollRunsResponses[keyof GetV1PayrollRunsResponses]; - -export type GetV1ScimV2GroupsIdData = { - body?: never; - path: { - /** - * Group ID (slug) - */ - id: string; - }; - query?: never; - url: '/v1/scim/v2/Groups/{id}'; -}; +export type PostV1EmployeeTimeoffError = + PostV1EmployeeTimeoffErrors[keyof PostV1EmployeeTimeoffErrors]; -export type GetV1ScimV2GroupsIdErrors = { - /** - * Unauthorized - */ - 401: IntegrationsScimErrorResponse; - /** - * Forbidden - */ - 403: IntegrationsScimErrorResponse; +export type PostV1EmployeeTimeoffResponses = { /** - * Not Found + * Created */ - 404: IntegrationsScimErrorResponse; + 201: TimeoffResponse; }; -export type GetV1ScimV2GroupsIdError = - GetV1ScimV2GroupsIdErrors[keyof GetV1ScimV2GroupsIdErrors]; +export type PostV1EmployeeTimeoffResponse = + PostV1EmployeeTimeoffResponses[keyof PostV1EmployeeTimeoffResponses]; -export type GetV1ScimV2GroupsIdResponses = { +export type PutV1EmploymentsEmploymentIdPersonalDetailsData = { /** - * Success + * Employment personal details params */ - 200: IntegrationsScimGroup; -}; - -export type GetV1ScimV2GroupsIdResponse = - GetV1ScimV2GroupsIdResponses[keyof GetV1ScimV2GroupsIdResponses]; - -export type GetV1EmploymentContractsData = { - body?: never; - headers: { - /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * - */ - Authorization: string; - }; - path?: never; - query: { + body?: EmploymentPersonalDetailsParams; + path: { /** * Employment ID */ employment_id: string; - /** - * Only Active - */ - only_active?: boolean; }; - url: '/v1/employment-contracts'; + query?: never; + url: '/v1/employments/{employment_id}/personal_details'; }; -export type GetV1EmploymentContractsErrors = { +export type PutV1EmploymentsEmploymentIdPersonalDetailsErrors = { /** - * Unauthorized + * Bad Request */ - 401: UnauthorizedResponse; + 400: BadRequestResponse; /** * Forbidden */ 403: ForbiddenResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type GetV1EmploymentContractsError = - GetV1EmploymentContractsErrors[keyof GetV1EmploymentContractsErrors]; +export type PutV1EmploymentsEmploymentIdPersonalDetailsError = + PutV1EmploymentsEmploymentIdPersonalDetailsErrors[keyof PutV1EmploymentsEmploymentIdPersonalDetailsErrors]; -export type GetV1EmploymentContractsResponses = { +export type PutV1EmploymentsEmploymentIdPersonalDetailsResponses = { /** * Success */ - 200: ListEmploymentContractResponse; + 200: EmploymentResponse; }; -export type GetV1EmploymentContractsResponse = - GetV1EmploymentContractsResponses[keyof GetV1EmploymentContractsResponses]; +export type PutV1EmploymentsEmploymentIdPersonalDetailsResponse = + PutV1EmploymentsEmploymentIdPersonalDetailsResponses[keyof PutV1EmploymentsEmploymentIdPersonalDetailsResponses]; -export type PostV1CurrencyConverterEffective2Data = { - /** - * Convert currency parameters - */ - body: ConvertCurrencyParams; - path?: never; +export type GetV1ProbationExtensionsIdData = { + body?: never; + path: { + /** + * Probation Extension Request ID + */ + id: string; + }; query?: never; - url: '/v1/currency-converter'; + url: '/v1/probation-extensions/{id}'; }; -export type PostV1CurrencyConverterEffective2Errors = { +export type GetV1ProbationExtensionsIdErrors = { /** * Unauthorized */ @@ -22951,41 +23591,32 @@ export type PostV1CurrencyConverterEffective2Errors = { 422: UnprocessableEntityResponse; }; -export type PostV1CurrencyConverterEffective2Error = - PostV1CurrencyConverterEffective2Errors[keyof PostV1CurrencyConverterEffective2Errors]; +export type GetV1ProbationExtensionsIdError = + GetV1ProbationExtensionsIdErrors[keyof GetV1ProbationExtensionsIdErrors]; -export type PostV1CurrencyConverterEffective2Responses = { +export type GetV1ProbationExtensionsIdResponses = { /** * Success */ - 200: ConvertCurrencyResponse; + 200: ProbationExtensionResponse; }; -export type PostV1CurrencyConverterEffective2Response = - PostV1CurrencyConverterEffective2Responses[keyof PostV1CurrencyConverterEffective2Responses]; +export type GetV1ProbationExtensionsIdResponse = + GetV1ProbationExtensionsIdResponses[keyof GetV1ProbationExtensionsIdResponses]; -export type GetV1CompaniesData = { +export type GetV1FilesIdData = { body?: never; - headers: { - /** - * Requires a client credentials access token obtained through the Client Credentials flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Client Credentials flow. - * - */ - Authorization: string; - }; - path?: never; - query?: { + path: { /** - * External ID + * File ID */ - external_id?: string; + id: string; }; - url: '/v1/companies'; + query?: never; + url: '/v1/files/{id}'; }; -export type GetV1CompaniesErrors = { +export type GetV1FilesIdErrors = { /** * Unauthorized */ @@ -23000,161 +23631,122 @@ export type GetV1CompaniesErrors = { 422: UnprocessableEntityResponse; }; -export type GetV1CompaniesError = - GetV1CompaniesErrors[keyof GetV1CompaniesErrors]; +export type GetV1FilesIdError = GetV1FilesIdErrors[keyof GetV1FilesIdErrors]; -export type GetV1CompaniesResponses = { +export type GetV1FilesIdResponses = { /** * Success */ - 200: CompaniesResponse; + 200: DownloadFileResponse; }; -export type GetV1CompaniesResponse = - GetV1CompaniesResponses[keyof GetV1CompaniesResponses]; +export type GetV1FilesIdResponse = + GetV1FilesIdResponses[keyof GetV1FilesIdResponses]; -export type PostV1CompaniesData = { - /** - * Create Company params - */ - body?: CreateCompanyParams; - headers: { - /** - * Requires a client credentials access token obtained through the Client Credentials flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Client Credentials flow. - * - */ - Authorization: string; - }; +export type GetV1CompanyDepartmentsData = { + body?: never; path?: never; - query?: { - /** - * Version of the address_details form schema - */ - address_details_json_schema_version?: number | 'latest'; + query: { /** - * Version of the bank_account_details form schema + * Company ID */ - bank_account_details_json_schema_version?: number | 'latest'; + company_id: string; /** - * Complementary action(s) to perform when creating a company: - * - * - `get_oauth_access_tokens` returns the user's access and refresh tokens - * - `send_create_password_email ` sends a reset password token to the company owner's email so they can log in using Remote UI (not needed if integration plans to use SSO only) - * - * If `action` contains `send_create_password_email` you can redirect the user to [https://employ.remote.com/api-integration-new-password-send](https://employ.remote.com/api-integration-new-password-send) - * + * Paginate option. Default: true. When true, paginates response; otherwise, does not. */ - action?: string; + paginate?: boolean; /** - * Whether the request should be performed async - * + * Starts fetching records after the given page */ - async?: boolean; + page?: number; /** - * Scope of the access token - * + * Number of items per page */ - scope?: string; + page_size?: number; }; - url: '/v1/companies'; + url: '/v1/company-departments'; }; -export type PostV1CompaniesErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; +export type GetV1CompanyDepartmentsErrors = { /** - * Conflict + * Not Found */ - 409: CompanyCreationConflictErrorResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PostV1CompaniesError = - PostV1CompaniesErrors[keyof PostV1CompaniesErrors]; +export type GetV1CompanyDepartmentsError = + GetV1CompanyDepartmentsErrors[keyof GetV1CompanyDepartmentsErrors]; -export type PostV1CompaniesResponses = { +export type GetV1CompanyDepartmentsResponses = { /** - * Created + * Success */ - 201: CompanyCreationResponse; + 200: ListCompanyDepartmentsPaginatedResponse; }; -export type PostV1CompaniesResponse = - PostV1CompaniesResponses[keyof PostV1CompaniesResponses]; +export type GetV1CompanyDepartmentsResponse = + GetV1CompanyDepartmentsResponses[keyof GetV1CompanyDepartmentsResponses]; -export type PostV1BulkEmploymentJobsData = { +export type PostV1CompanyDepartmentsData = { /** - * Bulk employment params + * Create Company Department request params */ - body?: BulkEmploymentCreateParams; + body: CreateCompanyDepartmentParams; path?: never; query?: never; - url: '/v1/bulk-employment-jobs'; + url: '/v1/company-departments'; }; -export type PostV1BulkEmploymentJobsErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type PostV1CompanyDepartmentsErrors = { /** - * Forbidden + * Not Found */ - 403: ForbiddenResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PostV1BulkEmploymentJobsError = - PostV1BulkEmploymentJobsErrors[keyof PostV1BulkEmploymentJobsErrors]; +export type PostV1CompanyDepartmentsError = + PostV1CompanyDepartmentsErrors[keyof PostV1CompanyDepartmentsErrors]; -export type PostV1BulkEmploymentJobsResponses = { +export type PostV1CompanyDepartmentsResponses = { /** - * Accepted + * Created */ - 202: BulkEmploymentImportJobResponse; + 201: CompanyDepartmentCreatedResponse; }; -export type PostV1BulkEmploymentJobsResponse = - PostV1BulkEmploymentJobsResponses[keyof PostV1BulkEmploymentJobsResponses]; +export type PostV1CompanyDepartmentsResponse = + PostV1CompanyDepartmentsResponses[keyof PostV1CompanyDepartmentsResponses]; -export type PostV1TimesheetsTimesheetIdSendBackData = { - /** - * SendBackTimesheetParams - */ - body?: SendBackTimesheetParams; +export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsData = { + body?: never; path: { /** - * Timesheet ID + * Payroll run ID */ - timesheet_id: string; + payroll_run_id: string; }; - query?: never; - url: '/v1/timesheets/{timesheet_id}/send-back'; + query?: { + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/payroll-runs/{payroll_run_id}/employee-details'; }; -export type PostV1TimesheetsTimesheetIdSendBackErrors = { +export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors = { /** * Unauthorized */ @@ -23169,20 +23761,20 @@ export type PostV1TimesheetsTimesheetIdSendBackErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1TimesheetsTimesheetIdSendBackError = - PostV1TimesheetsTimesheetIdSendBackErrors[keyof PostV1TimesheetsTimesheetIdSendBackErrors]; +export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsError = + GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors[keyof GetV1PayrollRunsPayrollRunIdEmployeeDetailsErrors]; -export type PostV1TimesheetsTimesheetIdSendBackResponses = { +export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses = { /** * Success */ - 200: SentBackTimesheetResponse; + 200: EmployeeDetailsResponse; }; -export type PostV1TimesheetsTimesheetIdSendBackResponse = - PostV1TimesheetsTimesheetIdSendBackResponses[keyof PostV1TimesheetsTimesheetIdSendBackResponses]; +export type GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponse = + GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses[keyof GetV1PayrollRunsPayrollRunIdEmployeeDetailsResponses]; -export type DeleteV1CompanyManagersUserIdData = { +export type GetV1EmploymentsEmploymentIdData = { body?: never; headers: { /** @@ -23195,103 +23787,174 @@ export type DeleteV1CompanyManagersUserIdData = { }; path: { /** - * User ID + * Employment ID */ - user_id: string; + employment_id: string; }; - query?: never; - url: '/v1/company-managers/{user_id}'; + query?: { + /** + * Wether files should be excluded + */ + exclude_files?: boolean; + }; + url: '/v1/employments/{employment_id}'; }; -export type DeleteV1CompanyManagersUserIdErrors = { +export type GetV1EmploymentsEmploymentIdErrors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type DeleteV1CompanyManagersUserIdError = - DeleteV1CompanyManagersUserIdErrors[keyof DeleteV1CompanyManagersUserIdErrors]; +export type GetV1EmploymentsEmploymentIdError = + GetV1EmploymentsEmploymentIdErrors[keyof GetV1EmploymentsEmploymentIdErrors]; -export type DeleteV1CompanyManagersUserIdResponses = { +export type GetV1EmploymentsEmploymentIdResponses = { /** * Success */ - 200: SuccessResponse; + 200: EmploymentShowResponse; }; -export type DeleteV1CompanyManagersUserIdResponse = - DeleteV1CompanyManagersUserIdResponses[keyof DeleteV1CompanyManagersUserIdResponses]; +export type GetV1EmploymentsEmploymentIdResponse = + GetV1EmploymentsEmploymentIdResponses[keyof GetV1EmploymentsEmploymentIdResponses]; -export type GetV1CompanyManagersUserIdData = { - body?: never; +export type PatchV1EmploymentsEmploymentId2Data = { + /** + * Employment params + */ + body?: EmploymentFullParams; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** - * User ID + * Employment ID */ - user_id: string; + employment_id: string; }; - query?: never; - url: '/v1/company-managers/{user_id}'; + query?: { + /** + * Version of the address_details form schema + */ + address_details_json_schema_version?: number | 'latest'; + /** + * Version of the administrative_details form schema + */ + administrative_details_json_schema_version?: number | 'latest'; + /** + * Version of the bank_account_details form schema + */ + bank_account_details_json_schema_version?: number | 'latest'; + /** + * Version of the employment_basic_information form schema + */ + employment_basic_information_json_schema_version?: number | 'latest'; + /** + * Version of the billing_address_details form schema + */ + billing_address_details_json_schema_version?: number | 'latest'; + /** + * Version of the contract_details form schema + */ + contract_details_json_schema_version?: number | 'latest'; + /** + * Version of the emergency_contact_details form schema + */ + emergency_contact_details_json_schema_version?: number | 'latest'; + /** + * Version of the personal_details form schema + */ + personal_details_json_schema_version?: number | 'latest'; + /** + * Version of the pricing_plan_details form schema + */ + pricing_plan_details_json_schema_version?: number | 'latest'; + /** + * Skips the dynamic benefits part of the schema if set. To be used when benefits are set via its own API. + */ + skip_benefits?: boolean; + /** + * Complementary action(s) to perform when creating an employment. + */ + actions?: string; + }; + url: '/v1/employments/{employment_id}'; }; -export type GetV1CompanyManagersUserIdErrors = { +export type PatchV1EmploymentsEmploymentId2Errors = { /** * Bad Request */ 400: BadRequestResponse; /** - * Unauthorized + * Forbidden */ - 401: UnauthorizedResponse; + 403: ForbiddenResponse; /** - * Not Found + * Conflict */ - 404: NotFoundResponse; + 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; /** - * Too many requests + * Unprocessable Entity */ 429: TooManyRequestsResponse; }; -export type GetV1CompanyManagersUserIdError = - GetV1CompanyManagersUserIdErrors[keyof GetV1CompanyManagersUserIdErrors]; +export type PatchV1EmploymentsEmploymentId2Error = + PatchV1EmploymentsEmploymentId2Errors[keyof PatchV1EmploymentsEmploymentId2Errors]; -export type GetV1CompanyManagersUserIdResponses = { +export type PatchV1EmploymentsEmploymentId2Responses = { /** * Success */ - 200: CompanyManagerResponse; + 200: EmploymentResponse; }; -export type GetV1CompanyManagersUserIdResponse = - GetV1CompanyManagersUserIdResponses[keyof GetV1CompanyManagersUserIdResponses]; +export type PatchV1EmploymentsEmploymentId2Response = + PatchV1EmploymentsEmploymentId2Responses[keyof PatchV1EmploymentsEmploymentId2Responses]; -export type PutV2EmploymentsEmploymentIdEmergencyContactData = { +export type PatchV1EmploymentsEmploymentIdData = { /** - * Employment emergency contact params + * Employment params */ - body?: EmploymentEmergencyContactParams; + body?: EmploymentFullParams; + headers: { + /** + * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. + * + * The refresh token needs to have been obtained through the Authorization Code flow. + * + */ + Authorization: string; + }; path: { /** * Employment ID @@ -23299,31 +23962,63 @@ export type PutV2EmploymentsEmploymentIdEmergencyContactData = { employment_id: string; }; query?: { + /** + * Version of the address_details form schema + */ + address_details_json_schema_version?: number | 'latest'; + /** + * Version of the administrative_details form schema + */ + administrative_details_json_schema_version?: number | 'latest'; + /** + * Version of the bank_account_details form schema + */ + bank_account_details_json_schema_version?: number | 'latest'; + /** + * Version of the employment_basic_information form schema + */ + employment_basic_information_json_schema_version?: number | 'latest'; + /** + * Version of the billing_address_details form schema + */ + billing_address_details_json_schema_version?: number | 'latest'; + /** + * Version of the contract_details form schema + */ + contract_details_json_schema_version?: number | 'latest'; /** * Version of the emergency_contact_details form schema */ emergency_contact_details_json_schema_version?: number | 'latest'; + /** + * Version of the personal_details form schema + */ + personal_details_json_schema_version?: number | 'latest'; + /** + * Version of the pricing_plan_details form schema + */ + pricing_plan_details_json_schema_version?: number | 'latest'; + /** + * Skips the dynamic benefits part of the schema if set. To be used when benefits are set via its own API. + */ + skip_benefits?: boolean; + /** + * Complementary action(s) to perform when creating an employment. + */ + actions?: string; }; - url: '/v2/employments/{employment_id}/emergency_contact'; + url: '/v1/employments/{employment_id}'; }; -export type PutV2EmploymentsEmploymentIdEmergencyContactErrors = { +export type PatchV1EmploymentsEmploymentIdErrors = { /** * Bad Request */ 400: BadRequestResponse; - /** - * Unauthorized - */ - 401: UnauthorizedResponse; /** * Forbidden */ 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; /** * Conflict */ @@ -23338,27 +24033,36 @@ export type PutV2EmploymentsEmploymentIdEmergencyContactErrors = { 429: TooManyRequestsResponse; }; -export type PutV2EmploymentsEmploymentIdEmergencyContactError = - PutV2EmploymentsEmploymentIdEmergencyContactErrors[keyof PutV2EmploymentsEmploymentIdEmergencyContactErrors]; +export type PatchV1EmploymentsEmploymentIdError = + PatchV1EmploymentsEmploymentIdErrors[keyof PatchV1EmploymentsEmploymentIdErrors]; -export type PutV2EmploymentsEmploymentIdEmergencyContactResponses = { +export type PatchV1EmploymentsEmploymentIdResponses = { /** * Success */ 200: EmploymentResponse; }; -export type PutV2EmploymentsEmploymentIdEmergencyContactResponse = - PutV2EmploymentsEmploymentIdEmergencyContactResponses[keyof PutV2EmploymentsEmploymentIdEmergencyContactResponses]; +export type PatchV1EmploymentsEmploymentIdResponse = + PatchV1EmploymentsEmploymentIdResponses[keyof PatchV1EmploymentsEmploymentIdResponses]; -export type GetV1EmployeeExpensesData = { +export type GetV1EmployeeTimesheetsData = { body?: never; path?: never; - query?: never; - url: '/v1/employee/expenses'; + query?: { + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/employee/timesheets'; }; -export type GetV1EmployeeExpensesErrors = { +export type GetV1EmployeeTimesheetsErrors = { /** * Unauthorized */ @@ -23373,214 +24077,134 @@ export type GetV1EmployeeExpensesErrors = { 404: NotFoundResponse; }; -export type GetV1EmployeeExpensesError = - GetV1EmployeeExpensesErrors[keyof GetV1EmployeeExpensesErrors]; +export type GetV1EmployeeTimesheetsError = + GetV1EmployeeTimesheetsErrors[keyof GetV1EmployeeTimesheetsErrors]; -export type GetV1EmployeeExpensesResponses = { +export type GetV1EmployeeTimesheetsResponses = { /** * Success */ 200: SuccessResponse; }; -export type GetV1EmployeeExpensesResponse = - GetV1EmployeeExpensesResponses[keyof GetV1EmployeeExpensesResponses]; +export type GetV1EmployeeTimesheetsResponse = + GetV1EmployeeTimesheetsResponses[keyof GetV1EmployeeTimesheetsResponses]; -export type PostV1EmployeeExpensesData = { - /** - * Expense params - */ - body?: ParamsToCreateEmployeeExpense; - path?: never; +export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdData = { + body?: never; + path: { + /** + * Custom field ID + */ + custom_field_id: string; + /** + * Employment ID + */ + employment_id: string; + }; query?: never; - url: '/v1/employee/expenses'; + url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}'; }; -export type PostV1EmployeeExpensesErrors = { - /** - * Bad Request - */ - 400: BadRequestResponse; +export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Forbidden + * Not Found */ - 403: ForbiddenResponse; + 404: NotFoundResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; }; -export type PostV1EmployeeExpensesError = - PostV1EmployeeExpensesErrors[keyof PostV1EmployeeExpensesErrors]; +export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdError = + GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors[keyof GetV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors]; -export type PostV1EmployeeExpensesResponses = { +export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses = { /** - * Created + * Success */ - 201: SuccessResponse; + 200: EmploymentCustomFieldValueResponse; }; -export type PostV1EmployeeExpensesResponse = - PostV1EmployeeExpensesResponses[keyof PostV1EmployeeExpensesResponses]; - -export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData = - { - body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; - query?: never; - url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription'; - }; - -export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors = - { - /** - * Unauthorized - */ - 401: UnauthorizedResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; - /** - * Unprocessable Entity - */ - 422: UnprocessableEntityResponse; - }; - -export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionError = - DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors[keyof DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors]; - -export type DeleteV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses = - { - /** - * No Content - */ - 204: unknown; - }; - -export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionData = - { - body?: never; - path: { - /** - * Employment ID - */ - employment_id: string; - }; - query?: never; - url: '/v1/contractors/employments/{employment_id}/contractor-cor-subscription'; - }; +export type GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponse = + GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses[keyof GetV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses]; -export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors = - { - /** - * Bad Request - */ - 400: BadRequestResponse; - /** - * Forbidden - */ - 403: ForbiddenResponse; - /** - * Not Found - */ - 404: NotFoundResponse; +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Data = { + /** + * Custom Field Value Update Parameters + */ + body: UpdateEmploymentCustomFieldValueParams; + path: { /** - * Unprocessable Entity + * Custom field ID */ - 422: UnprocessableEntityResponse; - }; - -export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionError = - PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors[keyof PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionErrors]; - -export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses = - { + custom_field_id: string; /** - * Created + * Employment ID */ - 201: SuccessResponse; + employment_id: string; }; + query?: never; + url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}'; +}; -export type PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponse = - PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses[keyof PostV1ContractorsEmploymentsEmploymentIdContractorCorSubscriptionResponses]; - -export type GetV1ContractorInvoiceSchedulesData = { - body?: never; - path?: never; - query?: { - /** - * Filters contractor invoice schedules by start date greater than or equal to the value. - */ - start_date_from?: Date; - /** - * Filters contractor invoice schedules by start date less than or equal to the value. - */ - start_date_to?: Date; - /** - * Filters contractor invoice schedules by next invoice date greater than or equal to the value. - */ - next_invoice_date_from?: Date; - /** - * Filters contractor invoice schedules by next invoice date less than or equal to the value. - */ - next_invoice_date_to?: Date; - /** - * Filters contractor invoice schedules by status matching the value. - */ - status?: ContractorInvoiceScheduleStatus; - /** - * Filters contractor invoice schedules by employment id matching the value. - */ - employment_id?: UuidSlug; - /** - * Filters contractor invoice schedules by periodicity matching the value. - */ - periodicity?: ContractorInvoiceSchedulePeriodicity; - /** - * Filters contractor invoice schedules by currency matching the value. - */ - currency?: string; - /** - * Field to sort by - */ - sort_by?: - | 'number' - | 'total_amount' - | 'next_invoice_at' - | 'start_date' - | 'nr_occurrences'; - /** - * Sort order - */ - order?: 'asc' | 'desc'; +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Error = + PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Errors]; + +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses = { + /** + * Success + */ + 200: EmploymentCustomFieldValueResponse; +}; + +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Response = + PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentId2Responses]; + +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdData = { + /** + * Custom Field Value Update Parameters + */ + body: UpdateEmploymentCustomFieldValueParams; + path: { /** - * Starts fetching records after the given page + * Custom field ID */ - page?: number; + custom_field_id: string; /** - * Number of items per page + * Employment ID */ - page_size?: number; + employment_id: string; }; - url: '/v1/contractor-invoice-schedules'; + query?: never; + url: '/v1/custom-fields/{custom_field_id}/values/{employment_id}'; }; -export type GetV1ContractorInvoiceSchedulesErrors = { +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors = { /** * Unauthorized */ @@ -23593,101 +24217,97 @@ export type GetV1ContractorInvoiceSchedulesErrors = { * Not Found */ 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; }; -export type GetV1ContractorInvoiceSchedulesError = - GetV1ContractorInvoiceSchedulesErrors[keyof GetV1ContractorInvoiceSchedulesErrors]; +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdError = + PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdErrors]; -export type GetV1ContractorInvoiceSchedulesResponses = { +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses = { /** * Success */ - 200: ListContractorInvoiceSchedulesResponse; + 200: EmploymentCustomFieldValueResponse; }; -export type GetV1ContractorInvoiceSchedulesResponse = - GetV1ContractorInvoiceSchedulesResponses[keyof GetV1ContractorInvoiceSchedulesResponses]; +export type PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponse = + PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses[keyof PatchV1CustomFieldsCustomFieldIdValuesEmploymentIdResponses]; -export type PostV1ContractorInvoiceSchedulesData = { +export type PutV1ResignationsOffboardingRequestIdValidateData = { /** - * Bulk creation payload + * ValidateResignation */ - body: BulkContractorInvoiceScheduleCreateParams; - path?: never; + body: ValidateResignationRequestParams; + path: { + /** + * Offboarding request ID + */ + offboarding_request_id: string; + }; query?: never; - url: '/v1/contractor-invoice-schedules'; + url: '/v1/resignations/{offboarding_request_id}/validate'; }; -export type PostV1ContractorInvoiceSchedulesErrors = { +export type PutV1ResignationsOffboardingRequestIdValidateErrors = { /** - * Forbidden + * Bad Request */ - 403: ForbiddenResponse; + 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; /** * Not Found */ 404: NotFoundResponse; /** - * BulkContractorInvoiceScheduleCreateResponse - * - * Response containing the lists of succeeded and failed schedules. + * Unprocessable Entity */ - 422: { - data: { - failures: Array; - successes: Array; - }; - }; + 422: UnprocessableEntityResponse; + /** + * Unprocessable Entity + */ + 429: TooManyRequestsResponse; }; -export type PostV1ContractorInvoiceSchedulesError = - PostV1ContractorInvoiceSchedulesErrors[keyof PostV1ContractorInvoiceSchedulesErrors]; +export type PutV1ResignationsOffboardingRequestIdValidateError = + PutV1ResignationsOffboardingRequestIdValidateErrors[keyof PutV1ResignationsOffboardingRequestIdValidateErrors]; -export type PostV1ContractorInvoiceSchedulesResponses = { - /** - * BulkContractorInvoiceScheduleCreateResponse - * - * Response containing the lists of succeeded and failed schedules. - */ - 201: { - data: { - failures: Array; - successes: Array; - }; - }; +export type PutV1ResignationsOffboardingRequestIdValidateResponses = { /** - * BulkContractorInvoiceScheduleCreateResponse - * - * Response containing the lists of succeeded and failed schedules. + * Success */ - 207: { - data: { - failures: Array; - successes: Array; - }; - }; + 200: SuccessResponse; }; -export type PostV1ContractorInvoiceSchedulesResponse = - PostV1ContractorInvoiceSchedulesResponses[keyof PostV1ContractorInvoiceSchedulesResponses]; +export type PutV1ResignationsOffboardingRequestIdValidateResponse = + PutV1ResignationsOffboardingRequestIdValidateResponses[keyof PutV1ResignationsOffboardingRequestIdValidateResponses]; -export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsData = { +export type GetV1ContractorInvoiceSchedulesIdData = { body?: never; path: { /** - * Employment ID + * Resource unique identifier */ - employment_id: string; + id: UuidSlug; }; query?: never; - url: '/v1/employments/{employment_id}/engagement-agreement-details'; + url: '/v1/contractor-invoice-schedules/{id}'; }; -export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { +export type GetV1ContractorInvoiceSchedulesIdErrors = { /** * Bad Request */ 400: BadRequestResponse; + /** + * Unauthorized + */ + 401: UnauthorizedResponse; /** * Forbidden */ @@ -23706,39 +24326,39 @@ export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { 429: TooManyRequestsResponse; }; -export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsError = - GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof GetV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; +export type GetV1ContractorInvoiceSchedulesIdError = + GetV1ContractorInvoiceSchedulesIdErrors[keyof GetV1ContractorInvoiceSchedulesIdErrors]; -export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { +export type GetV1ContractorInvoiceSchedulesIdResponses = { /** * Success */ - 200: EmploymentEngagementAgreementDetailsResponse; + 200: ContractorInvoiceScheduleResponse; }; -export type GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponse = - GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof GetV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; +export type GetV1ContractorInvoiceSchedulesIdResponse = + GetV1ContractorInvoiceSchedulesIdResponses[keyof GetV1ContractorInvoiceSchedulesIdResponses]; -export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsData = { +export type PatchV1ContractorInvoiceSchedulesId2Data = { /** - * Employment engagement agreement details params + * Update parameters */ - body?: EmploymentEngagementAgreementDetailsParams; + body: UpdateScheduleContractorInvoiceParams; path: { /** - * Employment ID + * Resource unique identifier */ - employment_id: string; + id: UuidSlug; }; query?: never; - url: '/v1/employments/{employment_id}/engagement-agreement-details'; + url: '/v1/contractor-invoice-schedules/{id}'; }; -export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { +export type PatchV1ContractorInvoiceSchedulesId2Errors = { /** - * Bad Request + * Unauthorized */ - 400: BadRequestResponse; + 401: UnauthorizedResponse; /** * Forbidden */ @@ -23747,51 +24367,88 @@ export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors = { * Not Found */ 404: NotFoundResponse; - /** - * Conflict - */ - 409: ConflictResponse; /** * Unprocessable Entity */ 422: UnprocessableEntityResponse; - /** - * Unprocessable Entity - */ - 429: TooManyRequestsResponse; }; -export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsError = - PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors[keyof PostV1EmploymentsEmploymentIdEngagementAgreementDetailsErrors]; +export type PatchV1ContractorInvoiceSchedulesId2Error = + PatchV1ContractorInvoiceSchedulesId2Errors[keyof PatchV1ContractorInvoiceSchedulesId2Errors]; -export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses = { +export type PatchV1ContractorInvoiceSchedulesId2Responses = { /** * Success */ - 200: SuccessResponse; + 200: ContractorInvoiceScheduleResponse; }; -export type PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponse = - PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses[keyof PostV1EmploymentsEmploymentIdEngagementAgreementDetailsResponses]; +export type PatchV1ContractorInvoiceSchedulesId2Response = + PatchV1ContractorInvoiceSchedulesId2Responses[keyof PatchV1ContractorInvoiceSchedulesId2Responses]; -export type GetV1BillingDocumentsBillingDocumentIdBreakdownData = { - body?: never; +export type PatchV1ContractorInvoiceSchedulesIdData = { + /** + * Update parameters + */ + body: UpdateScheduleContractorInvoiceParams; path: { /** - * The billing document's ID + * Resource unique identifier */ - billing_document_id: string; + id: UuidSlug; }; - query?: { + query?: never; + url: '/v1/contractor-invoice-schedules/{id}'; +}; + +export type PatchV1ContractorInvoiceSchedulesIdErrors = { + /** + * Unauthorized + */ + 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; +}; + +export type PatchV1ContractorInvoiceSchedulesIdError = + PatchV1ContractorInvoiceSchedulesIdErrors[keyof PatchV1ContractorInvoiceSchedulesIdErrors]; + +export type PatchV1ContractorInvoiceSchedulesIdResponses = { + /** + * Success + */ + 200: ContractorInvoiceScheduleResponse; +}; + +export type PatchV1ContractorInvoiceSchedulesIdResponse = + PatchV1ContractorInvoiceSchedulesIdResponses[keyof PatchV1ContractorInvoiceSchedulesIdResponses]; + +export type PutV2EmploymentsEmploymentIdPricingPlanDetailsData = { + /** + * Employment pricing plan details params + */ + body?: EmploymentPricingPlanDetailsParams; + path: { /** - * Filters the results by the type of the billing breakdown item. + * Employment ID */ - type?: string; + employment_id: string; }; - url: '/v1/billing-documents/{billing_document_id}/breakdown'; + query?: never; + url: '/v2/employments/{employment_id}/pricing_plan_details'; }; -export type GetV1BillingDocumentsBillingDocumentIdBreakdownErrors = { +export type PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors = { /** * Bad Request */ @@ -23800,10 +24457,18 @@ export type GetV1BillingDocumentsBillingDocumentIdBreakdownErrors = { * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; /** * Not Found */ - 404: NotFoundResponse; + 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ @@ -23814,105 +24479,98 @@ export type GetV1BillingDocumentsBillingDocumentIdBreakdownErrors = { 429: TooManyRequestsResponse; }; -export type GetV1BillingDocumentsBillingDocumentIdBreakdownError = - GetV1BillingDocumentsBillingDocumentIdBreakdownErrors[keyof GetV1BillingDocumentsBillingDocumentIdBreakdownErrors]; +export type PutV2EmploymentsEmploymentIdPricingPlanDetailsError = + PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors[keyof PutV2EmploymentsEmploymentIdPricingPlanDetailsErrors]; -export type GetV1BillingDocumentsBillingDocumentIdBreakdownResponses = { +export type PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses = { /** * Success */ - 200: BillingDocumentBreakdownResponse; + 200: EmploymentResponse; }; -export type GetV1BillingDocumentsBillingDocumentIdBreakdownResponse = - GetV1BillingDocumentsBillingDocumentIdBreakdownResponses[keyof GetV1BillingDocumentsBillingDocumentIdBreakdownResponses]; +export type PutV2EmploymentsEmploymentIdPricingPlanDetailsResponse = + PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses[keyof PutV2EmploymentsEmploymentIdPricingPlanDetailsResponses]; -export type GetV1EmployeeDocumentsData = { - body?: never; +export type PostV1RiskReserveData = { + /** + * Risk Reserve + */ + body: CreateRiskReserveParams; path?: never; - query?: { - /** - * Starts fetching records after the given page - */ - page?: number; - /** - * Number of items per page - */ - page_size?: number; - /** - * Filter documents by their description or file name, accepts full and partial case insensitive matches - */ - name?: string; - /** - * Filters the results that were uploaded on or after a given date - */ - inserted_after?: Date; - /** - * Filters the results that were uploaded before a given date - */ - inserted_before?: Date; - /** - * Field to sort by - */ - sort_by?: - | 'description' - | 'document_source' - | 'inserted_at' - | 'name' - | 'type' - | 'uploaded_by_role' - | 'related_to' - | 'sub_type' - | 'uploaded_by'; - /** - * Sort order - */ - order?: 'asc' | 'desc'; - }; - url: '/v1/employee/documents'; + query?: never; + url: '/v1/risk-reserve'; }; -export type GetV1EmployeeDocumentsErrors = { +export type PostV1RiskReserveErrors = { /** - * Forbidden + * Unauthorized */ - 403: ForbiddenResponse; + 401: UnauthorizedResponse; /** * Not Found */ 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; }; -export type GetV1EmployeeDocumentsError = - GetV1EmployeeDocumentsErrors[keyof GetV1EmployeeDocumentsErrors]; +export type PostV1RiskReserveError = + PostV1RiskReserveErrors[keyof PostV1RiskReserveErrors]; -export type GetV1EmployeeDocumentsResponses = { +export type PostV1RiskReserveResponses = { /** * Success */ - 200: ListDocumentsResponse; + 200: SuccessResponse; }; -export type GetV1EmployeeDocumentsResponse = - GetV1EmployeeDocumentsResponses[keyof GetV1EmployeeDocumentsResponses]; +export type PostV1RiskReserveResponse = + PostV1RiskReserveResponses[keyof PostV1RiskReserveResponses]; -export type PostV1TimeoffTimeoffIdCancelRequestApproveData = { - body?: never; +export type PutV2EmploymentsEmploymentIdAddressDetailsData = { + /** + * Employment address details params + */ + body?: EmploymentAddressDetailsParams; path: { /** - * Time Off ID + * Employment ID */ - timeoff_id: string; + employment_id: string; }; - query?: never; - url: '/v1/timeoff/{timeoff_id}/cancel-request/approve'; + query?: { + /** + * Version of the address_details form schema + */ + address_details_json_schema_version?: number | 'latest'; + }; + url: '/v2/employments/{employment_id}/address_details'; }; -export type PostV1TimeoffTimeoffIdCancelRequestApproveErrors = { +export type PutV2EmploymentsEmploymentIdAddressDetailsErrors = { + /** + * Bad Request + */ + 400: BadRequestResponse; /** * Unauthorized */ 401: UnauthorizedResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Conflict + */ + 409: ConflictResponse; /** * Unprocessable Entity */ @@ -23923,32 +24581,36 @@ export type PostV1TimeoffTimeoffIdCancelRequestApproveErrors = { 429: TooManyRequestsResponse; }; -export type PostV1TimeoffTimeoffIdCancelRequestApproveError = - PostV1TimeoffTimeoffIdCancelRequestApproveErrors[keyof PostV1TimeoffTimeoffIdCancelRequestApproveErrors]; +export type PutV2EmploymentsEmploymentIdAddressDetailsError = + PutV2EmploymentsEmploymentIdAddressDetailsErrors[keyof PutV2EmploymentsEmploymentIdAddressDetailsErrors]; -export type PostV1TimeoffTimeoffIdCancelRequestApproveResponses = { +export type PutV2EmploymentsEmploymentIdAddressDetailsResponses = { /** * Success */ - 200: SuccessResponse; + 200: EmploymentResponse; }; -export type PostV1TimeoffTimeoffIdCancelRequestApproveResponse = - PostV1TimeoffTimeoffIdCancelRequestApproveResponses[keyof PostV1TimeoffTimeoffIdCancelRequestApproveResponses]; +export type PutV2EmploymentsEmploymentIdAddressDetailsResponse = + PutV2EmploymentsEmploymentIdAddressDetailsResponses[keyof PutV2EmploymentsEmploymentIdAddressDetailsResponses]; -export type PostV1IdentityVerificationEmploymentIdVerifyData = { +export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdData = { body?: never; path: { /** * Employment ID */ employment_id: string; + /** + * Document ID + */ + id: string; }; query?: never; - url: '/v1/identity-verification/{employment_id}/verify'; + url: '/v1/contractors/employments/{employment_id}/contract-documents/{id}'; }; -export type PostV1IdentityVerificationEmploymentIdVerifyErrors = { +export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors = { /** * Unauthorized */ @@ -23963,64 +24625,107 @@ export type PostV1IdentityVerificationEmploymentIdVerifyErrors = { 422: UnprocessableEntityResponse; }; -export type PostV1IdentityVerificationEmploymentIdVerifyError = - PostV1IdentityVerificationEmploymentIdVerifyErrors[keyof PostV1IdentityVerificationEmploymentIdVerifyErrors]; +export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdError = + GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors[keyof GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdErrors]; -export type PostV1IdentityVerificationEmploymentIdVerifyResponses = { - /** - * Success - */ - 200: SuccessResponse; -}; +export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses = + { + /** + * Success + */ + 200: ContractDocumentResponse; + }; -export type PostV1IdentityVerificationEmploymentIdVerifyResponse = - PostV1IdentityVerificationEmploymentIdVerifyResponses[keyof PostV1IdentityVerificationEmploymentIdVerifyResponses]; +export type GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponse = + GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses[keyof GetV1ContractorsEmploymentsEmploymentIdContractDocumentsIdResponses]; -export type GetV1BillingDocumentsBillingDocumentIdPdfData = { - body?: never; - headers: { +export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsData = + { + body?: never; + path: { + /** + * Employment ID + */ + employment_id: string; + }; + query?: never; + url: '/v1/contractors/employments/{employment_id}/cor-termination-requests'; + }; + +export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors = + { /** - * Requires a Company-scoped access token obtained through the Authorization Code flow or the Refresh Token flow. - * - * The refresh token needs to have been obtained through the Authorization Code flow. - * + * Bad Request */ - Authorization: string; + 400: BadRequestResponse; + /** + * Forbidden + */ + 403: ForbiddenResponse; + /** + * Not Found + */ + 404: NotFoundResponse; + /** + * Unprocessable Entity + */ + 422: UnprocessableEntityResponse; }; - path: { + +export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsError = + PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors[keyof PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsErrors]; + +export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses = + { /** - * The billing document's ID + * Created */ - billing_document_id: string; + 201: CorTerminationRequestCreatedResponse; }; - query?: never; - url: '/v1/billing-documents/{billing_document_id}/pdf'; + +export type PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponse = + PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses[keyof PostV1ContractorsEmploymentsEmploymentIdCorTerminationRequestsResponses]; + +export type GetV1EmployeePayslipsData = { + body?: never; + path?: never; + query?: { + /** + * Starts fetching records after the given page + */ + page?: number; + /** + * Number of items per page + */ + page_size?: number; + }; + url: '/v1/employee/payslips'; }; -export type GetV1BillingDocumentsBillingDocumentIdPdfErrors = { +export type GetV1EmployeePayslipsErrors = { /** * Unauthorized */ 401: UnauthorizedResponse; /** - * Not Found + * Forbidden */ - 404: NotFoundResponse; + 403: ForbiddenResponse; /** - * Unprocessable Entity + * Not Found */ - 422: UnprocessableEntityResponse; + 404: NotFoundResponse; }; -export type GetV1BillingDocumentsBillingDocumentIdPdfError = - GetV1BillingDocumentsBillingDocumentIdPdfErrors[keyof GetV1BillingDocumentsBillingDocumentIdPdfErrors]; +export type GetV1EmployeePayslipsError = + GetV1EmployeePayslipsErrors[keyof GetV1EmployeePayslipsErrors]; -export type GetV1BillingDocumentsBillingDocumentIdPdfResponses = { +export type GetV1EmployeePayslipsResponses = { /** * Success */ - 200: GenericFile; + 200: ListEmployeePayslipsResponse; }; -export type GetV1BillingDocumentsBillingDocumentIdPdfResponse = - GetV1BillingDocumentsBillingDocumentIdPdfResponses[keyof GetV1BillingDocumentsBillingDocumentIdPdfResponses]; +export type GetV1EmployeePayslipsResponse = + GetV1EmployeePayslipsResponses[keyof GetV1EmployeePayslipsResponses]; diff --git a/src/common/api/fixtures/pre-onboarding.ts b/src/common/api/fixtures/pre-onboarding.ts new file mode 100644 index 000000000..eb40e80b2 --- /dev/null +++ b/src/common/api/fixtures/pre-onboarding.ts @@ -0,0 +1,50 @@ +// TODO: Provisional, we'll modify later +export const mockPreOnboardingRequirements = { + data: [ + { + name: 'Individual Labor Agreement', + status: 'awaiting_signatures', + description: + 'Individual Labor Agreement required for each German AUG employment', + slug: '5e39159e-96ef-40ea-82bc-b054917fc82f', + needs_constraints_ack: true, + document_constraints_ack_at: null, + freeze_employment_data: false, + redlining_help_email: null, + supports_redlining: false, + depends_on_requirement: null, + }, + { + name: 'Master Service Agreement', + status: 'awaiting_signatures', + description: + 'Master Service Agreement required for the first hire on this German legal entity', + slug: 'dc3b954c-9d6c-4ddd-b8dc-531f9be773fb', + needs_constraints_ack: true, + document_constraints_ack_at: '2026-05-08T17:17:47Z', + freeze_employment_data: false, + redlining_help_email: null, + supports_redlining: false, + depends_on_requirement: null, + }, + ], +}; + +export const mockCreatedDocument = { + data: { + id: 'doc_123', + employment_id: 'emp_456', + document_type: 'employment_agreement', + status: 'draft', + pdf_url: 'https://example.com/document.pdf', + created_at: '2026-05-13T12:00:00Z', + }, +}; + +export const mockSignedDocument = { + data: { + id: 'doc_123', + status: 'signed', + signed_at: '2026-05-13T14:00:00Z', + }, +}; diff --git a/src/components/form/validationResolver.ts b/src/components/form/validationResolver.ts index 843bb7ed3..33b1a48c5 100644 --- a/src/components/form/validationResolver.ts +++ b/src/components/form/validationResolver.ts @@ -74,6 +74,7 @@ export const useJsonSchemasValidationFormResolver = < ): Resolver => { return async (data: T) => { const result = await handleValidation(data); + console.log('result', result); // Handle null case - return no errors if (!result) { diff --git a/src/flows/Onboarding/OnboardingFlow.tsx b/src/flows/Onboarding/OnboardingFlow.tsx index 597a129f4..fdcfab949 100644 --- a/src/flows/Onboarding/OnboardingFlow.tsx +++ b/src/flows/Onboarding/OnboardingFlow.tsx @@ -12,6 +12,7 @@ import { SelectCountryStep } from '@/src/flows/Onboarding/components/SelectCount import { ReviewStep } from '@/src/flows/Onboarding/components/ReviewStep'; import { SaveDraftButton } from '@/src/flows/Onboarding/components/SaveDraftButton'; import { EngagementAgreementDetailsStep } from '@/src/flows/Onboarding/components/EngagementAgreementDetailsStep'; +import { PreOnboardingRequirements } from '@/src/flows/Onboarding/components/PreOnboardingRequirements'; export const OnboardingFlow = ({ employmentId, @@ -66,6 +67,7 @@ export const OnboardingFlow = ({ OnboardingInvite: OnboardingInvite, SelectCountryStep: SelectCountryStep, ReviewStep: ReviewStep, + PreOnboardingRequirements: PreOnboardingRequirements, }, })} diff --git a/src/flows/Onboarding/api.ts b/src/flows/Onboarding/api.ts index 43ac46705..234345073 100644 --- a/src/flows/Onboarding/api.ts +++ b/src/flows/Onboarding/api.ts @@ -14,6 +14,7 @@ import { getV1EmploymentsEmploymentIdBenefitOffers, getV1EmploymentsEmploymentIdBenefitOffersSchema, getV1EmploymentsEmploymentIdEngagementAgreementDetails, + getV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirements, patchV1EmploymentsEmploymentId2, postV1CurrencyConverterEffective, postV1CurrencyConverterRaw, @@ -561,3 +562,84 @@ export const useEngagementAgreementDetailsSchema = ( }, }); }; + +/** + * Get pre-onboarding requirements for an employment + */ +export const useGetPreOnboardingRequirements = ( + employmentId: string, + options?: { queryOptions?: { enabled?: boolean } }, +) => { + const { client } = useClient(); + + return useQuery({ + queryKey: ['pre-onboarding-requirements', employmentId], + queryFn: () => + getV1OnboardingEmploymentsEmploymentIdPreOnboardingDocumentsRequirements({ + client: client as Client, + path: { + employment_id: employmentId, + }, + }), + enabled: options?.queryOptions?.enabled ?? true, + select: (response) => response.data?.data, + }); +}; + +/** + * Create a pre-onboarding document + */ +export const useCreatePreOnboardingDocument = () => { + return useMutation({ + mutationFn: async ({ + employmentId: _employmentId, + }: { + employmentId: string; + }) => { + const { mockCreatedDocument } = + await import('@/src/common/api/fixtures/pre-onboarding'); + await new Promise((resolve) => setTimeout(resolve, 800)); + return mockCreatedDocument; + }, + }); +}; + +/** + * Get pre-onboarding document preview + */ +export const useGetPreOnboardingDocument = ( + documentId: string | undefined, + options?: { queryOptions?: { enabled?: boolean } }, +) => { + return useQuery({ + queryKey: ['pre-onboarding-document', documentId], + queryFn: async () => { + const { mockCreatedDocument } = + await import('@/src/common/api/fixtures/pre-onboarding'); + await new Promise((resolve) => setTimeout(resolve, 300)); + return mockCreatedDocument; + }, + enabled: options?.queryOptions?.enabled && !!documentId, + select: (data) => data.data, + }); +}; + +/** + * Sign a pre-onboarding document + */ +export const useSignPreOnboardingDocument = () => { + return useMutation({ + mutationFn: async ({ + documentId: _documentId, + signature: _signature, + }: { + documentId: string; + signature: string; + }) => { + const { mockSignedDocument } = + await import('@/src/common/api/fixtures/pre-onboarding'); + await new Promise((resolve) => setTimeout(resolve, 1000)); + return mockSignedDocument; + }, + }); +}; diff --git a/src/flows/Onboarding/components/PreOnboardingRequirements.tsx b/src/flows/Onboarding/components/PreOnboardingRequirements.tsx new file mode 100644 index 000000000..52a06d24e --- /dev/null +++ b/src/flows/Onboarding/components/PreOnboardingRequirements.tsx @@ -0,0 +1,74 @@ +import { useState } from 'react'; +import { useOnboardingContext } from '@/src/flows/Onboarding/context'; +import { + useGetPreOnboardingRequirements, + useCreatePreOnboardingDocument, + useGetPreOnboardingDocument, + useSignPreOnboardingDocument, +} from '@/src/flows/Onboarding/api'; + +const usePreOnboardingRequirements = ({ + employmentId, +}: { + employmentId: string; +}) => { + const [documentId, setDocumentId] = useState(); + + const { data: requirements, isLoading: isLoadingRequirements } = + useGetPreOnboardingRequirements(employmentId, { + queryOptions: { enabled: !!employmentId }, + }); + + const { data: documentPreview, isLoading: isLoadingDocumentPreview } = + useGetPreOnboardingDocument(documentId, { + queryOptions: { enabled: !!documentId }, + }); + + const createDocumentMutation = useCreatePreOnboardingDocument(); + const signDocumentMutation = useSignPreOnboardingDocument(); + + const onCreateDocument = async () => { + const result = await createDocumentMutation.mutateAsync({ + employmentId, + }); + setDocumentId(result.data.id); + return result; + }; + + const onSignDocument = async (signature: string) => { + if (!documentId) { + throw new Error('No document to sign'); + } + return await signDocumentMutation.mutateAsync({ + documentId, + signature, + }); + }; + + return { + requirements, + isLoadingRequirements, + documentPreview, + isLoadingDocumentPreview, + isCreatingDocument: createDocumentMutation.isPending, + isSigning: signDocumentMutation.isPending, + onCreateDocument, + onSignDocument, + }; +}; + +export const PreOnboardingRequirements = ({ + render, +}: { + render: ( + bag: ReturnType, + ) => React.ReactNode; +}) => { + const { onboardingBag } = useOnboardingContext(); + + const bag = usePreOnboardingRequirements({ + employmentId: onboardingBag.employmentId as string, + }); + + return render(bag); +}; diff --git a/src/flows/Onboarding/types.ts b/src/flows/Onboarding/types.ts index b4a80dbc6..c61fc3aec 100644 --- a/src/flows/Onboarding/types.ts +++ b/src/flows/Onboarding/types.ts @@ -15,6 +15,7 @@ import { SelectCountryStep } from '@/src/flows/Onboarding/components/SelectCount import { ReviewStep } from '@/src/flows/Onboarding/components/ReviewStep'; import { SaveDraftButton } from '@/src/flows/Onboarding/components/SaveDraftButton'; import { EngagementAgreementDetailsStep } from '@/src/flows/Onboarding/components/EngagementAgreementDetailsStep'; +import { PreOnboardingRequirements } from '@/src/flows/Onboarding/components/PreOnboardingRequirements'; export type OnboardingRenderProps = { /** @@ -38,6 +39,7 @@ export type OnboardingRenderProps = { * @see {@link SelectCountryStep} * @see {@link ReviewStep} * @see {@link SaveDraftButton} + * @see {@link PreOnboardingRequirements} */ components: { SubmitButton: typeof OnboardingSubmit; @@ -50,6 +52,7 @@ export type OnboardingRenderProps = { SelectCountryStep: typeof SelectCountryStep; ReviewStep: typeof ReviewStep; SaveDraftButton: typeof SaveDraftButton; + PreOnboardingRequirements: typeof PreOnboardingRequirements; }; }; @@ -225,3 +228,26 @@ export type CreditRiskState = | 'invite_successful' | 'referred' | null; + +// TODO: Provisional, we'll modify later +export type PreOnboardingRequirement = { + id: string; + title: string; + description: string; + status: 'pending' | 'completed'; + required: boolean; +}; + +export type PreOnboardingDocument = { + id: string; + employment_id: string; + document_type: string; + status: 'draft' | 'pending_signature' | 'signed'; + pdf_url?: string; + created_at: string; +}; + +export type SignDocumentPayload = { + signature: string; + signed_at?: string; +};