diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 96754d23..dda05dd9 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,21 +1,21 @@ -speakeasyVersion: 1.563.0 +speakeasyVersion: 1.582.0 sources: GustoEmbedded-OAS: sourceNamespace: gusto-embedded-oas - sourceRevisionDigest: sha256:a1aeea076843567753316650f2d29983013f880f47f820724bd2875d8e771c6c - sourceBlobDigest: sha256:3dd94a0621318c2b09c9944b0debb1f17a6a4c61cb98e4674415872348146240 + sourceRevisionDigest: sha256:c494230f0bcad1f73093031bf8d093aff47d372b1379cf6adb312d366737e088 + sourceBlobDigest: sha256:e22d751e83af131bc1b55381e3845594478ee4c2342ef94e708e8cede6882245 tags: - latest - - speakeasy-sdk-regen-1749833190 + - speakeasy-sdk-regen-1749860068 - "2024-04-01" targets: gusto-embedded: source: GustoEmbedded-OAS sourceNamespace: gusto-embedded-oas - sourceRevisionDigest: sha256:a1aeea076843567753316650f2d29983013f880f47f820724bd2875d8e771c6c - sourceBlobDigest: sha256:3dd94a0621318c2b09c9944b0debb1f17a6a4c61cb98e4674415872348146240 + sourceRevisionDigest: sha256:c494230f0bcad1f73093031bf8d093aff47d372b1379cf6adb312d366737e088 + sourceBlobDigest: sha256:e22d751e83af131bc1b55381e3845594478ee4c2342ef94e708e8cede6882245 codeSamplesNamespace: gusto-embedded-oas-typescript-code-samples - codeSamplesRevisionDigest: sha256:1882e9f8d7078d53fb801492504e3b910634021e4f5aac99663f9b0361cecb9f + codeSamplesRevisionDigest: sha256:42abf4454ecbaadfa2d96d41e1a12fa0cf6db809443a5de524b9cf3ee83bf1ea workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/gusto_embedded/.gitignore b/gusto_embedded/.gitignore index 6b625958..34ee8d81 100644 --- a/gusto_embedded/.gitignore +++ b/gusto_embedded/.gitignore @@ -1,3 +1,7 @@ +/examples/node_modules +.env +.env.local +.env.*.local .DS_Store **/.speakeasy/temp/ **/.speakeasy/logs/ diff --git a/gusto_embedded/.speakeasy/gen.lock b/gusto_embedded/.speakeasy/gen.lock index 30f7e31f..93da5ab8 100644 --- a/gusto_embedded/.speakeasy/gen.lock +++ b/gusto_embedded/.speakeasy/gen.lock @@ -1,12 +1,12 @@ lockVersion: 2.0.0 id: f0264e24-cbe2-4074-b157-7a6ba8979508 management: - docChecksum: 3f7e9e9f0e0d4044b9c4bd0dfb3fe67f + docChecksum: 9897439106079b55448df7137b324ff8 docVersion: "2024-04-01" - speakeasyVersion: 1.563.0 - generationVersion: 2.629.1 - releaseVersion: 0.6.4 - configChecksum: 28d56ca03d52d52794e3985f3941e5f1 + speakeasyVersion: 1.582.0 + generationVersion: 2.657.1 + releaseVersion: 0.6.5 + configChecksum: 57c4a5de50d4bc0327415bcc9d41585b repoURL: https://github.com/Gusto/gusto-typescript-client.git repoSubDirectory: gusto_embedded installationURL: https://gitpkg.now.sh/Gusto/gusto-typescript-client/gusto_embedded @@ -15,8 +15,8 @@ features: typescript: additionalDependencies: 0.1.0 additionalProperties: 0.1.1 - constsAndDefaults: 0.1.11 - core: 3.21.11 + constsAndDefaults: 0.1.12 + core: 3.21.14 defaultEnabledRetries: 0.1.0 deprecations: 2.81.1 devContainers: 2.90.0 @@ -37,7 +37,7 @@ features: retries: 2.83.0 sdkHooks: 0.3.0 serverIDs: 2.81.2 - unions: 2.85.9 + unions: 2.85.11 uploadStreams: 0.1.0 generatedFiles: - .devcontainer/README.md @@ -80,6 +80,7 @@ generatedFiles: - docs/models/components/benefittyperequirementsdeductaspercentagedefaultvalue.md - docs/models/components/benefittyperequirementsdefaultvalue.md - docs/models/components/benefittyperequirementslimitoptiondefaultvalue.md + - docs/models/components/blockertype.md - docs/models/components/catchup.md - docs/models/components/category.md - docs/models/components/childsupportdata.md @@ -125,6 +126,9 @@ generatedFiles: - docs/models/components/contractorpaymentgroupminimal.md - docs/models/components/contractorpaymentgroupminimalstatus.md - docs/models/components/contractorpaymentgroupminimaltotals.md + - docs/models/components/contractorpaymentgrouppartnerdisbursements.md + - docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentmethod.md + - docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentstatus.md - docs/models/components/contractorpaymentgroupstatus.md - docs/models/components/contractorpaymentgrouptotals.md - docs/models/components/contractorpaymentmethod.md @@ -160,14 +164,17 @@ generatedFiles: - docs/models/components/departmentemployees.md - docs/models/components/departments.md - docs/models/components/detailedpaymentaccountsplit.md + - docs/models/components/disbursements.md - docs/models/components/document.md - docs/models/components/documentpdf.md - docs/models/components/documentsigned.md - docs/models/components/documentsignedrecipienttype.md - docs/models/components/documenttype.md + - docs/models/components/earnedfastachblockers.md - docs/models/components/earnings.md - docs/models/components/earningtype.md - docs/models/components/earningtypelist.md + - docs/models/components/einverification.md - docs/models/components/employee.md - docs/models/components/employeeaddress.md - docs/models/components/employeebankaccount.md @@ -181,15 +188,20 @@ generatedFiles: - docs/models/components/employeebenefitvalue.md - docs/models/components/employeechecknumbermapping.md - docs/models/components/employeecompensations.md + - docs/models/components/employeecurrentemploymentstatus.md - docs/models/components/employeecustomfield.md - docs/models/components/employeededuction.md - docs/models/components/employeefederaltax.md + - docs/models/components/employeehomeaddress.md - docs/models/components/employeeonboardingdocument.md + - docs/models/components/employeeonboardingdocumentsconfig.md - docs/models/components/employeeonboardingstatus.md + - docs/models/components/employeeonboardingstatus1.md - docs/models/components/employeeonboardingstatusonboardingstep.md - docs/models/components/employeepaymentdetail.md - docs/models/components/employeepaymentdetailpaymentmethod.md - docs/models/components/employeepaymentmethod.md + - docs/models/components/employeepaymentmethod1.md - docs/models/components/employeepaymentmethodsplitby.md - docs/models/components/employeepaymentmethodtype.md - docs/models/components/employeepaystubslist.md @@ -220,6 +232,7 @@ generatedFiles: - docs/models/components/fastpaymentlimitrequiredbody.md - docs/models/components/federalholidays.md - docs/models/components/federaltaxdetails.md + - docs/models/components/federaltaxdetailsstatus.md - docs/models/components/fields.md - docs/models/components/fipscodes.md - docs/models/components/fixed.md @@ -258,6 +271,7 @@ generatedFiles: - docs/models/components/informationrequest.md - docs/models/components/informationrequeststatus.md - docs/models/components/informationrequesttype.md + - docs/models/components/integrationtype.md - docs/models/components/invoicedata.md - docs/models/components/job.md - docs/models/components/juneteenth.md @@ -311,6 +325,10 @@ generatedFiles: - docs/models/components/payrollemployeecompensationstypepaidtimeoff.md - docs/models/components/payrollemployeecompensationstypepaymentmethod.md - docs/models/components/payrollfixedcompensationtypestype.md + - docs/models/components/payrollpartnerdisbursements.md + - docs/models/components/payrollpartnerdisbursementsdisbursements.md + - docs/models/components/payrollpartnerdisbursementspaymentmethod.md + - docs/models/components/payrollpartnerdisbursementspaymentstatus.md - docs/models/components/payrollpaymentspeedchangedtype.md - docs/models/components/payrollpayperiodtype.md - docs/models/components/payrollpayrollstatusmetatype.md @@ -318,6 +336,7 @@ generatedFiles: - docs/models/components/payrollprocessingrequest.md - docs/models/components/payrollprocessingrequeststatus.md - docs/models/components/payrollreceipt.md + - docs/models/components/payrollreceiptemployeecompensations.md - docs/models/components/payrollreceiptpaymentmethod.md - docs/models/components/payrollreceipttaxes.md - docs/models/components/payrollreversal.md @@ -326,6 +345,11 @@ generatedFiles: - docs/models/components/payrollsubmissionblockerstypestatus.md - docs/models/components/payrolltotalstype.md - docs/models/components/payrolltype.md + - docs/models/components/payrollupdate.md + - docs/models/components/payrollupdatefixedcompensations.md + - docs/models/components/payrollupdatehourlycompensations.md + - docs/models/components/payrollupdatepaidtimeoff.md + - docs/models/components/payrollupdatepaymentmethod.md - docs/models/components/payrollwithholdingpayperiodtype.md - docs/models/components/payscheduleassignment.md - docs/models/components/payscheduleassignmentbody.md @@ -367,6 +391,7 @@ generatedFiles: - docs/models/components/resourcetype.md - docs/models/components/section.md - docs/models/components/security.md + - docs/models/components/showemployees.md - docs/models/components/signatory.md - docs/models/components/sortorder.md - docs/models/components/source.md @@ -418,6 +443,7 @@ generatedFiles: - docs/models/components/webhooksubscriptionstatus.md - docs/models/components/wireinrequest.md - docs/models/components/wireinrequeststatus.md + - docs/models/components/withholdingpayperiod.md - docs/models/components/workaddress.md - docs/models/components/ytdbenefitamountsfromdifferentcompany.md - docs/models/errors/base.md @@ -454,6 +480,7 @@ generatedFiles: - docs/models/operations/deletev1companiescompanyidcontractorpaymentcontractorpaymentresponse.md - docs/models/operations/deletev1companiescompanyidearningtypesearningtypeuuidrequest.md - docs/models/operations/deletev1companiescompanyidearningtypesearningtypeuuidresponse.md + - docs/models/operations/deletev1companiescompanyidpayrollsheaderxgustoapiversion.md - docs/models/operations/deletev1companiescompanyidpayrollsrequest.md - docs/models/operations/deletev1companiescompanyidpayrollsresponse.md - docs/models/operations/deletev1companiescompanyuuidsignatoriessignatoryuuidrequest.md @@ -492,12 +519,12 @@ generatedFiles: - docs/models/operations/deletev1workaddressesworkaddressuuidheaderxgustoapiversion.md - docs/models/operations/deletev1workaddressesworkaddressuuidrequest.md - docs/models/operations/deletev1workaddressesworkaddressuuidresponse.md + - docs/models/operations/disbursements.md - docs/models/operations/document.md - docs/models/operations/documents.md - docs/models/operations/documenttype.md - docs/models/operations/earnings.md - docs/models/operations/earningtype.md - - docs/models/operations/employeecompensations.md - docs/models/operations/employees.md - docs/models/operations/employeestatetaxes.md - docs/models/operations/employmentstatus.md @@ -508,7 +535,6 @@ generatedFiles: - docs/models/operations/fields.md - docs/models/operations/filetype.md - docs/models/operations/filingform.md - - docs/models/operations/fixedcompensations.md - docs/models/operations/frequency.md - docs/models/operations/garnishmenttype.md - docs/models/operations/getachtransactionsrequest.md @@ -597,6 +623,10 @@ generatedFiles: - docs/models/operations/getv1companiescompanyidpayrollreversalsrequest.md - docs/models/operations/getv1companiescompanyidpayrollreversalsresponse.md - docs/models/operations/getv1companiescompanyidpayrollsheaderxgustoapiversion.md + - docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md + - docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md + - docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md + - docs/models/operations/getv1companiescompanyidpayrollspayrollidheaderxgustoapiversion.md - docs/models/operations/getv1companiescompanyidpayrollspayrollidqueryparaminclude.md - docs/models/operations/getv1companiescompanyidpayrollspayrollidrequest.md - docs/models/operations/getv1companiescompanyidpayrollspayrollidresponse.md @@ -662,6 +692,9 @@ generatedFiles: - docs/models/operations/getv1contractorformsresponse.md - docs/models/operations/getv1contractorpaymentgroupscontractorpaymentgroupidrequest.md - docs/models/operations/getv1contractorpaymentgroupscontractorpaymentgroupidresponse.md + - docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md + - docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsrequest.md + - docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsresponse.md - docs/models/operations/getv1contractorpaymentscontractorpaymentuuidfundrequest.md - docs/models/operations/getv1contractorpaymentscontractorpaymentuuidfundresponse.md - docs/models/operations/getv1contractorpaymentscontractorpaymentuuidreceiptrequest.md @@ -786,9 +819,9 @@ generatedFiles: - docs/models/operations/groupings.md - docs/models/operations/headerxgustoapiversion.md - docs/models/operations/homeaddress.md - - docs/models/operations/hourlycompensations.md - docs/models/operations/include.md - docs/models/operations/independenceday.md + - docs/models/operations/integrationtype.md - docs/models/operations/job.md - docs/models/operations/juneteenth.md - docs/models/operations/laborday.md @@ -803,8 +836,20 @@ generatedFiles: - docs/models/operations/offcyclereason.md - docs/models/operations/onboardingstatus.md - docs/models/operations/ownertype.md - - docs/models/operations/paidtimeoff.md + - docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsdisbursements.md + - docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md + - docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentmethod.md + - docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentstatus.md + - docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md + - docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequestbody.md + - docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md + - docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md + - docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementspaymentmethod.md + - docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequest.md + - docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequestbody.md + - docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsresponse.md - docs/models/operations/paymentmethod.md + - docs/models/operations/paymentstatus.md - docs/models/operations/paymentunit.md - docs/models/operations/payperiods.md - docs/models/operations/payrolltype.md @@ -867,7 +912,6 @@ generatedFiles: - docs/models/operations/postv1companiescompanyidcontractorpaymentgroupsrequest.md - docs/models/operations/postv1companiescompanyidcontractorpaymentgroupsrequestbody.md - docs/models/operations/postv1companiescompanyidcontractorpaymentgroupsresponse.md - - docs/models/operations/postv1companiescompanyidcontractorpaymentspaymentmethod.md - docs/models/operations/postv1companiescompanyidcontractorpaymentsrequest.md - docs/models/operations/postv1companiescompanyidcontractorpaymentsrequestbody.md - docs/models/operations/postv1companiescompanyidcontractorpaymentsresponse.md @@ -1021,6 +1065,7 @@ generatedFiles: - docs/models/operations/putv1companiescompanyidfederaltaxdetailsrequest.md - docs/models/operations/putv1companiescompanyidfederaltaxdetailsrequestbody.md - docs/models/operations/putv1companiescompanyidfederaltaxdetailsresponse.md + - docs/models/operations/putv1companiescompanyidpayrollsheaderxgustoapiversion.md - docs/models/operations/putv1companiescompanyidpayrollspayrollidcalculaterequest.md - docs/models/operations/putv1companiescompanyidpayrollspayrollidcalculateresponse.md - docs/models/operations/putv1companiescompanyidpayrollspayrollidpreparerequest.md @@ -1030,9 +1075,7 @@ generatedFiles: - docs/models/operations/putv1companiescompanyidpayrollspayrollidsubmitrequestbody.md - docs/models/operations/putv1companiescompanyidpayrollspayrollidsubmitresponse.md - docs/models/operations/putv1companiescompanyidpayrollsrequest.md - - docs/models/operations/putv1companiescompanyidpayrollsrequestbody.md - docs/models/operations/putv1companiescompanyidpayrollsresponse.md - - docs/models/operations/putv1companiescompanyidpayrollswithholdingpayperiod.md - docs/models/operations/putv1companiescompanyidpayschedulespayscheduleidfrequency.md - docs/models/operations/putv1companiescompanyidpayschedulespayscheduleidrequest.md - docs/models/operations/putv1companiescompanyidpayschedulespayscheduleidrequestbody.md @@ -1131,6 +1174,7 @@ generatedFiles: - docs/models/operations/putv1employeesemployeeidstatetaxesheaderxgustoapiversion.md - docs/models/operations/putv1employeesemployeeidstatetaxesrequest.md - docs/models/operations/putv1employeesemployeeidstatetaxesresponse.md + - docs/models/operations/putv1employeesheaderxgustoapiversion.md - docs/models/operations/putv1employeesrequest.md - docs/models/operations/putv1employeesrequestbody.md - docs/models/operations/putv1employeesresponse.md @@ -1284,6 +1328,10 @@ generatedFiles: - docs/sdks/wireinrequests/README.md - docs/types/rfcdate.md - eslint.config.mjs + - examples/.env.template + - examples/README.md + - examples/introspectionGetInfo.example.ts + - examples/package.json - jsr.json - package.json - src/core.ts @@ -1337,6 +1385,8 @@ generatedFiles: - src/funcs/contractorPaymentGroupsFund.ts - src/funcs/contractorPaymentGroupsGet.ts - src/funcs/contractorPaymentGroupsGetList.ts + - src/funcs/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts + - src/funcs/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts - src/funcs/contractorPaymentGroupsPreview.ts - src/funcs/contractorPaymentMethodGet.ts - src/funcs/contractorPaymentMethodGetBankAccounts.ts @@ -1502,7 +1552,9 @@ generatedFiles: - src/funcs/payrollsGetPayStub.ts - src/funcs/payrollsGetPayStubs.ts - src/funcs/payrollsGetReceipt.ts + - src/funcs/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts - src/funcs/payrollsList.ts + - src/funcs/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts - src/funcs/payrollsPrepare.ts - src/funcs/payrollsSkip.ts - src/funcs/payrollsSubmit.ts @@ -1587,6 +1639,7 @@ generatedFiles: - src/models/components/contractorpaymentforgroup.ts - src/models/components/contractorpaymentgroup.ts - src/models/components/contractorpaymentgroupminimal.ts + - src/models/components/contractorpaymentgrouppartnerdisbursements.ts - src/models/components/contractorpaymentmethod.ts - src/models/components/contractorpaymentreceipt.ts - src/models/components/contractorpaymentsummary.ts @@ -1608,6 +1661,7 @@ generatedFiles: - src/models/components/employeebenefitforcompanybenefit.ts - src/models/components/employeecustomfield.ts - src/models/components/employeefederaltax.ts + - src/models/components/employeehomeaddress.ts - src/models/components/employeeonboardingdocument.ts - src/models/components/employeeonboardingstatus.ts - src/models/components/employeepaymentdetail.ts @@ -1666,6 +1720,7 @@ generatedFiles: - src/models/components/payrollcreditblockerstype.ts - src/models/components/payrollemployeecompensationstype.ts - src/models/components/payrollfixedcompensationtypestype.ts + - src/models/components/payrollpartnerdisbursements.ts - src/models/components/payrollpaymentspeedchangedtype.ts - src/models/components/payrollpayperiodtype.ts - src/models/components/payrollpayrollstatusmetatype.ts @@ -1675,6 +1730,7 @@ generatedFiles: - src/models/components/payrollreversal.ts - src/models/components/payrollsubmissionblockerstype.ts - src/models/components/payrolltotalstype.ts + - src/models/components/payrollupdate.ts - src/models/components/payrollwithholdingpayperiodtype.ts - src/models/components/payscheduleassignment.ts - src/models/components/payscheduleassignmentbody.ts @@ -1696,6 +1752,7 @@ generatedFiles: - src/models/components/report.ts - src/models/components/reporttemplate.ts - src/models/components/security.ts + - src/models/components/showemployees.ts - src/models/components/signatory.ts - src/models/components/sortorder.ts - src/models/components/supportedbenefit.ts @@ -1787,6 +1844,7 @@ generatedFiles: - src/models/operations/getv1companiescompanyidpayperiods.ts - src/models/operations/getv1companiescompanyidpayrollreversals.ts - src/models/operations/getv1companiescompanyidpayrolls.ts + - src/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.ts - src/models/operations/getv1companiescompanyidpayrollspayrollid.ts - src/models/operations/getv1companiescompanyidpayschedules.ts - src/models/operations/getv1companiescompanyidpayschedulesassignments.ts @@ -1816,6 +1874,7 @@ generatedFiles: - src/models/operations/getv1contractorformpdf.ts - src/models/operations/getv1contractorforms.ts - src/models/operations/getv1contractorpaymentgroupscontractorpaymentgroupid.ts + - src/models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.ts - src/models/operations/getv1contractorpaymentscontractorpaymentuuidfund.ts - src/models/operations/getv1contractorpaymentscontractorpaymentuuidreceipt.ts - src/models/operations/getv1contractorscontractoruuid.ts @@ -1866,6 +1925,8 @@ generatedFiles: - src/models/operations/getv1workaddressesworkaddressuuid.ts - src/models/operations/getversionemployeestimeoffactivities.ts - src/models/operations/getwireinrequestswireinrequestuuid.ts + - src/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.ts + - src/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.ts - src/models/operations/postcompaniescompanyuuidholidaypaypolicy.ts - src/models/operations/postcompaniescompanyuuidreports.ts - src/models/operations/postcompaniescompanyuuidsuspensions.ts @@ -2030,6 +2091,8 @@ generatedFiles: - src/react-query/contractorPaymentGroupsFund.ts - src/react-query/contractorPaymentGroupsGet.ts - src/react-query/contractorPaymentGroupsGetList.ts + - src/react-query/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts + - src/react-query/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts - src/react-query/contractorPaymentGroupsPreview.ts - src/react-query/contractorPaymentMethodGet.ts - src/react-query/contractorPaymentMethodGetBankAccounts.ts @@ -2196,7 +2259,9 @@ generatedFiles: - src/react-query/payrollsGetPayStub.ts - src/react-query/payrollsGetPayStubs.ts - src/react-query/payrollsGetReceipt.ts + - src/react-query/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts - src/react-query/payrollsList.ts + - src/react-query/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts - src/react-query/payrollsPrepare.ts - src/react-query/payrollsSkip.ts - src/react-query/payrollsSubmit.ts @@ -2871,7 +2936,7 @@ examples: X-Gusto-API-Version: "2024-04-01" responses: "200": - application/json: {"version": "5521489cc7c93732300805dcf87a5fd3", "tax_payer_type": "S-Corporation", "taxable_as_scorp": true, "filing_form": "941", "has_ein": true, "ein_verified": true, "legal_name": "Company Name LLC", "effective_date": "2024-01-01", "deposit_schedule": "Semiweekly"} + application/json: {"version": "5521489cc7c93732300805dcf87a5fd3", "tax_payer_type": "S-Corporation", "taxable_as_scorp": true, "filing_form": "941", "has_ein": true, "ein_verified": true, "ein_verification": {"status": "verified"}, "legal_name": "Company Name LLC", "effective_date": "2024-01-01", "deposit_schedule": "Semiweekly"} put-v1-companies-company_id-federal_tax_details: Example: parameters: @@ -2883,7 +2948,7 @@ examples: application/json: {"legal_name": "Acme Corp.", "tax_payer_type": "LLP", "filing_form": "944", "taxable_as_scorp": false, "version": "6cb95e00540706ca48d4577b3c839fbe"} responses: "200": - application/json: {"version": "5521489cc7c93732300805dcf87a5fd3", "tax_payer_type": "S-Corporation", "taxable_as_scorp": true, "filing_form": "941", "has_ein": true, "ein_verified": true, "legal_name": "Company Name LLC", "effective_date": "2024-01-01", "deposit_schedule": "Semiweekly"} + application/json: {"version": "5521489cc7c93732300805dcf87a5fd3", "tax_payer_type": "S-Corporation", "taxable_as_scorp": true, "filing_form": "941", "has_ein": true, "ein_verified": true, "ein_verification": {"status": "verified"}, "legal_name": "Company Name LLC", "effective_date": "2024-01-01", "deposit_schedule": "Semiweekly"} Basic: parameters: path: @@ -3279,6 +3344,19 @@ examples: application/json: {"uuid": "6b1351a2-de35-4499-b948-43abab274634", "version": "e1bdd845a493c74908f8e15d6114169b", "company_uuid": "10593a6a-505b-4aa6-bf31-15dcdceedbe3", "phone_number": "8009360383", "street_1": "300 3rd Street", "street_2": "Apartment 318", "city": "San Francisco", "state": "CO", "zip": "94107", "country": "USA", "mailing_address": true, "filing_address": true, "created_at": "2025-06-09T13:43:49.000-07:00", "updated_at": "2025-06-09T13:43:50.000-07:00", "active": true} "404": application/json: {"errors": [{"error_key": "state", "category": "invalid_attribute_value", "message": "State is in the wrong format"}]} + speakeasy-default-put-v1-locations-location-id: + parameters: + path: + location_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "phone_number": "8009360383", "street_1": "300 3rd Street", "street_2": "Apartment 318", "city": "San Francisco", "zip": "94107"} + responses: + "200": + application/json: {"uuid": "ced517c9-1c22-4468-88f7-bea752987d03", "country": "USA"} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} get-v1-locations-location_uuid-minimum_wages: "": parameters: @@ -3697,7 +3775,7 @@ examples: X-Gusto-API-Version: "2024-04-01" responses: "200": - application/json: {"company_uuid": "423dd616-6dbc-4724-938a-403f6217a933", "partner_uuid": "556f05d0-48e0-4c47-bce5-db9aea923043", "fast_payment_limit": "5000", "payment_speed": "2-day"} + application/json: {"company_uuid": "423dd616-6dbc-4724-938a-403f6217a933", "partner_uuid": "556f05d0-48e0-4c47-bce5-db9aea923043", "fast_payment_limit": "5000", "payment_speed": "2-day", "earned_fast_ach_blockers": [{"blocker_type": "minimum_days", "threshold": 15}, {"blocker_type": "minimum_funded_payments", "threshold": 1}]} put-v1-company-payment-configs: Example: parameters: @@ -3709,7 +3787,7 @@ examples: application/json: {"fast_payment_limit": "5000", "payment_speed": "2-day"} responses: "200": - application/json: {"company_uuid": "423dd616-6dbc-4724-938a-403f6217a933", "partner_uuid": "556f05d0-48e0-4c47-bce5-db9aea923043", "fast_payment_limit": "5000", "payment_speed": "2-day"} + application/json: {"company_uuid": "423dd616-6dbc-4724-938a-403f6217a933", "partner_uuid": "556f05d0-48e0-4c47-bce5-db9aea923043", "fast_payment_limit": "5000", "payment_speed": "2-day", "earned_fast_ach_blockers": [{"blocker_type": "minimum_days", "threshold": 15}, {"blocker_type": "minimum_funded_payments", "threshold": 1}]} Basic: parameters: path: @@ -4056,6 +4134,17 @@ examples: application/json: {"uuid": "1c4fba51-b867-49a7-9d75-54572badcc7e", "first_name": "Karl", "middle_initial": null, "last_name": "The Fog", "email": null, "company_uuid": "81191cf6-8bd3-4dad-836a-5e7cfdad5182", "manager_uuid": null, "version": "5211ee9bb08e51634431a18eff0afc64", "department": null, "terminated": false, "two_percent_shareholder": null, "work_email": null, "onboarded": false, "onboarding_status": "admin_onboarding_incomplete", "onboarding_documents_config": {"uuid": null, "i9_document": false}, "jobs": [], "eligible_paid_time_off": [], "terminations": [], "garnishments": [], "date_of_birth": null, "has_ssn": false, "ssn": "", "phone": null, "preferred_first_name": null, "payment_method": "Check", "current_employment_status": null, "historical": false, "employee_code": "b9f87c", "department_uuid": null} "404": application/json: {"errors": [{"error_key": "request", "category": "not_found", "message": "The requested resource was not found."}]} + speakeasy-default-post-v1-employees: + parameters: + path: + company_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + responses: + "201": + application/json: {"uuid": "9f634ba6-53c8-4290-8751-3ec38c369860", "first_name": "Lela", "last_name": "Graham", "eligible_paid_time_off": [{"accrual_unit": "Hour", "accrual_method": "unlimited", "accrual_period": "Year"}], "payment_method": "Check"} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} post-v1-historical_employees: Example: parameters: @@ -4158,6 +4247,19 @@ examples: application/json: {"uuid": "1abe1569-9d13-4046-be56-5873f95bba18", "first_name": "Weezy", "middle_initial": "F", "last_name": "Baby", "email": "tunechi@cashmoneyrecords.com", "company_uuid": "84e0b59a-b28c-4247-a64b-c690352374e1", "version": "4eff5441d8f8ecc08f53a88ded36f13e", "department": null, "onboarding_status": "onboarding_completed", "onboarding_documents_config": {"uuid": null, "i9_document": false}, "jobs": [{"uuid": "b642ef6b-5f2c-4972-a7b1-e492f16e66d8", "employee_uuid": "1abe1569-9d13-4046-be56-5873f95bba18", "hire_date": "2024-06-09", "title": "", "primary": true, "two_percent_shareholder": false, "location_uuid": "6f844e75-de46-420d-9680-b670022f21ce", "location": {"uuid": "6f844e75-de46-420d-9680-b670022f21ce", "street_1": "3121 Milky Way", "street_2": "", "city": "San Francisco", "state": "CA", "zip": "94107", "country": "USA", "inactive": false}}], "date_of_birth": "1991-01-31", "has_ssn": true, "preferred_first_name": null, "payment_method": "Check", "employee_code": "20961c", "department_uuid": null, "title": "", "hired_at": "2024-06-09", "hidden_ssn": "", "flsa_status": "Exempt", "applicable_tax_ids": [3, 7, 6, 2, 1, 4, 5, 109, 107, 108, 106]} "404": application/json: {"errors": [{"error_key": "base", "category": "invalid_resource_version", "message": "You are attempting to update a resource using an out-of-date version."}]} + speakeasy-default-put-v1-employees: + parameters: + path: + employee_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "first_name": "Weezy", "middle_initial": "F", "last_name": "Baby", "email": "tunechi@cashmoneyrecords.com", "date_of_birth": "1991-01-31", "ssn": "824920233", "work_email": "new.partner.work@example.com"} + responses: + "200": + application/json: {"uuid": "2953c680-3178-4466-8441-8947dce42145", "first_name": "Pearl", "last_name": "Volkman", "eligible_paid_time_off": [{"accrual_unit": "Hour", "accrual_method": "unlimited", "accrual_period": "Year"}], "payment_method": "Check"} + "404": + application/json: {"errors": []} delete-v1-employee: speakeasy-default-delete-v1-employee: parameters: @@ -4244,6 +4346,19 @@ examples: application/json: {"uuid": "049dbf20-0e2a-4232-854b-ac888cef3f0c", "onboarding_status": "admin_onboarding_incomplete", "onboarding_steps": [{"title": "Personal details", "id": "personal_details", "required": true, "completed": false, "requirements": []}, {"title": "Enter compensation details", "id": "compensation_details", "required": true, "completed": true, "requirements": []}, {"title": "Add work address", "id": "add_work_address", "required": true, "completed": false, "requirements": []}, {"title": "Add home address", "id": "add_home_address", "required": true, "completed": false, "requirements": []}, {"title": "Enter federal tax withholdings", "id": "federal_tax_setup", "required": true, "completed": false, "requirements": []}, {"title": "Enter state tax information", "id": "state_tax_setup", "required": true, "completed": false, "requirements": ["add_work_address", "add_home_address"]}, {"title": "Direct deposit setup", "id": "direct_deposit_setup", "required": false, "completed": false, "requirements": []}, {"title": "Employee form signing", "id": "employee_form_signing", "required": true, "completed": false, "requirements": ["federal_tax_setup", "state_tax_setup"]}, {"title": "File new hire report", "id": "file_new_hire_report", "required": true, "completed": false, "requirements": ["add_work_address"]}]} "404": application/json: {"errors": [{"error_key": "request", "category": "not_found", "message": "The requested resource was not found."}]} + speakeasy-default-put-v1-employees-employee-id-onboarding-status: + parameters: + path: + employee_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"onboarding_status": "admin_onboarding_incomplete"} + responses: + "200": + application/json: {"uuid": "66aca799-a6b4-44d8-9d21-a3c9f6ca4c66"} + "404": + application/json: {"errors": []} get-version-employees-time_off_activities: example: parameters: @@ -4277,7 +4392,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "first_name": "Leanna", "last_name": "Swaniawski", "date_of_birth": "1977-07-17", "ssn": "", "work_address": {}, "home_address": {"street_1": "", "city": "Port Mitchell", "state": "Kentucky", "zip": "85765"}, "termination": {}, "job": {}} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "first_name": "Leanna", "last_name": "Swaniawski", "date_of_birth": "1977-07-17", "ssn": "", "work_address": {}, "home_address": {"street_1": "", "city": "Port Mitchell", "state": "Kentucky", "zip": "85765"}, "termination": {}, "job": {}} responses: "200": application/json: {"uuid": "ad85459f-8bf5-4a8f-9079-3b3fa790799e", "first_name": "Karl", "middle_initial": null, "last_name": "Jaskolski", "email": null, "company_uuid": "3c69d228-a250-49b4-9946-24e4e4294da4", "manager_uuid": null, "version": "dedac972dd28945fcd6cd941723cc71a", "department": null, "terminated": true, "two_percent_shareholder": false, "work_email": null, "onboarded": true, "onboarding_status": "onboarding_completed", "onboarding_documents_config": {"uuid": null, "i9_document": false}, "jobs": [{"uuid": "f0be5480-7a15-4583-b0d0-789c02a1afe4", "version": "1c0722f3e090713b6a0db7c39904693e", "employee_uuid": "ad85459f-8bf5-4a8f-9079-3b3fa790799e", "hire_date": "2023-11-01", "title": "Client Support Director", "primary": true, "rate": "70000.00", "payment_unit": "Year", "current_compensation_uuid": "1a1faa42-274b-4440-b200-a5d81df14af2", "compensations": [{"uuid": "145660ed-6fcc-4211-8915-18e2786290a2", "version": "2cd4b18662395eb53bcf80d5b5447f36", "job_uuid": "857feae3-414e-445d-b28b-2eb3ef50155e", "rate": "70000.00", "payment_unit": "Year", "flsa_status": "Exempt", "effective_date": "2023-11-01", "adjust_for_minimum_wage": false, "minimum_wages": []}]}], "eligible_paid_time_off": [], "terminations": [{"uuid": "ad85459f-8bf5-4a8f-9079-3b3fa790799e", "version": "e6c865df784842196d411c1466b01686", "employee_uuid": "ad85459f-8bf5-4a8f-9079-3b3fa790799e", "active": false, "cancelable": true, "effective_date": "2023-12-31", "run_termination_payroll": false}], "garnishments": [], "date_of_birth": "1986-06-25", "has_ssn": false, "ssn": "", "phone": null, "preferred_first_name": null, "payment_method": "Check", "historical": true, "employee_code": "eh3st1", "department_uuid": null} @@ -4527,7 +4642,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "effective_date": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "effective_date": ""} responses: "404": application/json: {"errors": [{"error_key": "base", "category": "payroll_blocker", "message": "Company must complete all onboarding requirements in order to run payroll.", "metadata": {"key": "needs_onboarding"}}]} @@ -4538,7 +4653,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "effective_date": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "effective_date": ""} responses: "404": application/json: {"errors": [{"error_key": "first_name", "category": "invalid_attribute_value", "message": "First name is required"}, {"error_key": "date_of_birth", "category": "invalid_attribute_value", "message": "Date of birth is not a valid date"}]} @@ -4549,7 +4664,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "effective_date": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "effective_date": ""} responses: "404": application/json: {"errors": [{"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "72ae4617-daa9-4ed7-85e0-18ed5d0ee835"}, "errors": [{"error_key": "hours", "category": "invalid_attribute_value", "message": "Ella Fitzgerald is paid fixed wage and hours cannot be set on a contractor payment"}]}, {"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "2d7bf62c-babf-4a12-8292-340e2d9cab28"}, "errors": [{"error_key": "wage", "category": "invalid_attribute_value", "message": "Isaiah Berlin is paid hourly and wage cannot be set on a contractor payment"}]}]} @@ -4617,7 +4732,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "effective_date": "", "file_new_hire_report": true, "work_location_uuid": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "effective_date": "", "file_new_hire_report": true, "work_location_uuid": ""} responses: "404": application/json: {"errors": [{"error_key": "base", "category": "payroll_blocker", "message": "Company must complete all onboarding requirements in order to run payroll.", "metadata": {"key": "needs_onboarding"}}]} @@ -4628,7 +4743,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "effective_date": "", "file_new_hire_report": true, "work_location_uuid": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "effective_date": "", "file_new_hire_report": true, "work_location_uuid": ""} responses: "404": application/json: {"errors": [{"error_key": "first_name", "category": "invalid_attribute_value", "message": "First name is required"}, {"error_key": "date_of_birth", "category": "invalid_attribute_value", "message": "Date of birth is not a valid date"}]} @@ -4639,7 +4754,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "effective_date": "", "file_new_hire_report": true, "work_location_uuid": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "effective_date": "", "file_new_hire_report": true, "work_location_uuid": ""} responses: "404": application/json: {"errors": [{"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "72ae4617-daa9-4ed7-85e0-18ed5d0ee835"}, "errors": [{"error_key": "hours", "category": "invalid_attribute_value", "message": "Ella Fitzgerald is paid fixed wage and hours cannot be set on a contractor payment"}]}, {"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "2d7bf62c-babf-4a12-8292-340e2d9cab28"}, "errors": [{"error_key": "wage", "category": "invalid_attribute_value", "message": "Isaiah Berlin is paid hourly and wage cannot be set on a contractor payment"}]}]} @@ -4791,6 +4906,19 @@ examples: application/json: {"uuid": "4fb52ba1-c50a-413c-a4cd-1166044fee89", "employee_uuid": "c5d6fa56-3aa4-4d0c-9315-14b197cf7401", "effective_date": "2025-04-09", "courtesy_withholding": false, "street_1": "500 3rd Street", "street_2": "", "city": "San Francisco", "state": "CA", "zip": "94107", "country": "USA", "active": true, "version": "e4a88d91321dad0d3918c4efaeb433a2"} "404": application/json: {"errors": [{"error_key": "street_1", "category": "invalid_attribute_value", "message": "Must include a street address"}]} + speakeasy-default-post-v1-employees-employee-id-home-addresses: + parameters: + path: + employee_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"street_1": "300 3rd Street", "city": "San Francisco", "state": "CA", "zip": "94107", "effective_date": "2022-01-31"} + responses: + "201": + application/json: {"uuid": "b552472e-2d5c-4e19-bf31-49aeeb888b6e", "country": "USA", "version": ""} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} get-v1-home_addresses-home_address_uuid: Example: parameters: @@ -4894,6 +5022,19 @@ examples: application/json: {"uuid": "fb763fae-9dae-4307-9070-282b75ba4028", "employee_uuid": "549bfb85-03c7-4eb0-9d18-3bb85d9d3aae", "effective_date": "1970-01-01", "courtesy_withholding": false, "street_1": "600 4th Street", "street_2": "", "city": "Miami", "state": "FL", "zip": "33173", "country": "USA", "active": true, "version": "92676c3c5a3c0f26911388a55633b31a"} "404": application/json: {"errors": [{"error_key": "request", "category": "not_found", "message": "The requested resource was not found."}]} + speakeasy-default-put-v1-home-addresses-home-address-uuid: + parameters: + path: + home_address_uuid: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4"} + responses: + "200": + application/json: {"uuid": "d9fd058f-e693-4c4a-905f-3b5654a55589", "country": "USA", "version": ""} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} delete-v1-home_addresses-home_address_uuid: Basic: parameters: @@ -4978,6 +5119,19 @@ examples: application/json: {"uuid": "64ee5fd7-3eb2-4083-883c-95e93e181cc8", "effective_date": "2020-01-31", "active": true, "location_uuid": "733ab2af-9510-408f-8d20-09196967174f", "employee_uuid": "d773461f-848a-40a1-8f09-b2ee4249d5c7", "version": "3879823d440f3a3215d129ac73c58966", "street_1": "977 Marks Viaduct", "street_2": "Apt. 958", "city": "Pink Hill", "state": "NC", "zip": "28572", "country": "USA"} "404": application/json: {"errors": [{"error_key": "request", "category": "not_found", "message": "The requested resource was not found."}]} + speakeasy-default-post-v1-employees-employee-id-work-addresses: + parameters: + path: + employee_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"location_uuid": "6a119be7-b4b0-4e27-aaa0-89d5f2524635", "effective_date": "2023-05-15"} + responses: + "201": + application/json: {"uuid": "e02ec014-1e6b-41a8-ba57-7e102baa2d06", "version": "", "country": "USA"} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} get-v1-work_addresses-work_address_uuid: test_example: parameters: @@ -5028,6 +5182,19 @@ examples: application/json: {"uuid": "11b87d8e-c2dc-44f6-abc0-ccc58cd3ea5b", "effective_date": "2022-01-01", "active": false, "location_uuid": "24446253-8c6b-421d-a291-6667343e0f27", "employee_uuid": "eec0c9db-693e-419e-a928-d88b8010206f", "version": "e671435712a401b4b3fa7cfc1e240678", "street_1": "5467 Ward Radial", "street_2": "Suite 251", "city": "Holualoa", "state": "HI", "zip": "96725", "country": "USA"} "404": application/json: {"errors": [{"error_key": "request", "category": "not_found", "message": "The requested resource was not found."}]} + speakeasy-default-put-v1-work-addresses-work-address-uuid: + parameters: + path: + work_address_uuid: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "location_uuid": "6a119be7-b4b0-4e27-aaa0-89d5f2524635", "effective_date": "2023-05-15"} + responses: + "200": + application/json: {"uuid": "27c58f85-7f90-4597-bc74-193b0a8d024d", "version": "", "country": "USA"} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} delete-v1-work_addresses-work_address_uuid: test_example: parameters: @@ -5196,6 +5363,19 @@ examples: application/json: [{"employee_uuid": "c963cb99-fe1c-4aa8-9d48-1ad211ad396f", "state": "CA", "file_new_hire_report": false, "is_work_state": true, "questions": [{"label": "Filing Status", "description": "The Head of Household status applies to unmarried individuals who have a relative living with them in their home. If unsure, read the CA Filing Status explanation.\n", "key": "filing_status", "is_question_for_admin_only": false, "input_question_format": {"type": "Select", "options": [{"value": "S", "label": "Single"}, {"value": "M", "label": "Married one income"}, {"value": "MD", "label": "Married dual income"}, {"value": "H", "label": "Head of Household"}, {"value": "E", "label": "Do Not Withhold"}]}, "answers": [{"value": "M", "valid_from": "2010-01-01", "valid_up_to": null}]}, {"label": "Withholding Allowance", "description": "This value is needed to calculate the employee's CA income tax withholding. If unsure, use the CA DE-4 form to calculate the value manually.\n", "key": "withholding_allowance", "is_question_for_admin_only": false, "input_question_format": {"type": "Number"}, "answers": [{"value": 1, "valid_from": "2010-01-01", "valid_up_to": null}]}, {"label": "Additional Withholding", "description": "You can withhold an additional amount of California income taxes here.", "key": "additional_withholding", "is_question_for_admin_only": false, "input_question_format": {"type": "Currency"}, "answers": [{"value": "0.0", "valid_from": "2010-01-01", "valid_up_to": null}]}, {"label": "File a New Hire Report?", "description": "State law requires you to file a new hire report within 20 days of hiring or re-hiring an employee.", "key": "file_new_hire_report", "is_question_for_admin_only": true, "input_question_format": {"type": "Select", "options": [{"value": true, "label": "Yes, file the state new hire report for me."}, {"value": false, "label": "No, I have already filed."}]}, "answers": [{"value": false, "valid_from": "2010-01-01", "valid_up_to": null}]}]}] "404": application/json: {"errors": [{"error_key": "request", "category": "not_found", "message": "The requested resource was not found."}]} + speakeasy-default-put-v1-employees-employee-id-state-taxes: + parameters: + path: + employee_uuid: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"states": []} + responses: + "200": + application/json: [{}] + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} post-v1-employees-employee_id-bank_accounts: Example: parameters: @@ -5924,7 +6104,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} responses: "200": application/json: {"uuid": "c9fc1ad3-c107-4e7b-aa21-2dd4b00a7a07", "company_uuid": "b7457fec-3b76-43bb-9c6e-69cca4688942", "wage_type": "Hourly", "is_active": false, "version": "63859768485e218ccf8a449bb60f14ed", "type": "Individual", "first_name": "Kory", "last_name": "Gottlieb", "middle_initial": "P", "business_name": null, "ein": null, "has_ein": false, "email": "keira.west@mckenzie.org", "start_date": "2022-01-01", "address": {"street_1": "621 Jast Row", "street_2": "Apt. 281", "city": "Coral Springs", "state": "FL", "zip": "33065", "country": "USA"}, "hourly_rate": "60.00", "file_new_hire_report": true, "work_state": "FL", "onboarded": true, "onboarding_status": "onboarding_completed", "payment_method": "Direct Deposit", "has_ssn": true, "department_uuid": "56260b3d-c375-415c-b77a-75d99f717193"} @@ -5935,7 +6115,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} responses: "200": application/json: {"uuid": "c7c0659c-21a6-4b4e-b74c-9252576fc68c", "company_uuid": "0ec4ae6e-e436-460d-b63c-94a14503d16f", "wage_type": "Fixed", "is_active": true, "version": "8aab307f1e8ed788697f8986346af559", "type": "Business", "first_name": null, "last_name": null, "middle_initial": null, "business_name": "Labadie-Stroman", "ein": "XX-XXX0001", "has_ein": true, "email": "jonatan@kerluke.info", "start_date": "2022-01-01", "address": null, "hourly_rate": "0.00", "file_new_hire_report": false, "work_state": null, "onboarded": false, "onboarding_status": "admin_onboarding_incomplete", "payment_method": "Direct Deposit", "has_ssn": false} @@ -5946,7 +6126,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} responses: "422": application/json: {"errors": [{"error_key": "base", "category": "payroll_blocker", "message": "Company must complete all onboarding requirements in order to run payroll.", "metadata": {"key": "needs_onboarding"}}]} @@ -5957,7 +6137,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} responses: "422": application/json: {"errors": [{"error_key": "first_name", "category": "invalid_attribute_value", "message": "First name is required"}, {"error_key": "date_of_birth", "category": "invalid_attribute_value", "message": "Date of birth is not a valid date"}]} @@ -5968,7 +6148,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Individual", "start_date": "2020-01-11", "hourly_rate": "40.0", "self_onboarding": false, "file_new_hire_report": false} responses: "422": application/json: {"errors": [{"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "72ae4617-daa9-4ed7-85e0-18ed5d0ee835"}, "errors": [{"error_key": "hours", "category": "invalid_attribute_value", "message": "Ella Fitzgerald is paid fixed wage and hours cannot be set on a contractor payment"}]}, {"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "2d7bf62c-babf-4a12-8292-340e2d9cab28"}, "errors": [{"error_key": "wage", "category": "invalid_attribute_value", "message": "Isaiah Berlin is paid hourly and wage cannot be set on a contractor payment"}]}]} @@ -6063,7 +6243,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4"} responses: "422": application/json: {"errors": [{"error_key": "base", "category": "payroll_blocker", "message": "Company must complete all onboarding requirements in order to run payroll.", "metadata": {"key": "needs_onboarding"}}]} @@ -6074,7 +6254,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4"} responses: "422": application/json: {"errors": [{"error_key": "first_name", "category": "invalid_attribute_value", "message": "First name is required"}, {"error_key": "date_of_birth", "category": "invalid_attribute_value", "message": "Date of birth is not a valid date"}]} @@ -6085,7 +6265,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": ""} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4"} responses: "422": application/json: {"errors": [{"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "72ae4617-daa9-4ed7-85e0-18ed5d0ee835"}, "errors": [{"error_key": "hours", "category": "invalid_attribute_value", "message": "Ella Fitzgerald is paid fixed wage and hours cannot be set on a contractor payment"}]}, {"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "2d7bf62c-babf-4a12-8292-340e2d9cab28"}, "errors": [{"error_key": "wage", "category": "invalid_attribute_value", "message": "Isaiah Berlin is paid hourly and wage cannot be set on a contractor payment"}]}]} @@ -6188,7 +6368,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Direct Deposit"} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Direct Deposit"} responses: "200": application/json: {"version": "63859768485e218ccf8a449bb60f14ed", "type": "Direct Deposit", "split_by": "Percentage", "splits": [{"uuid": "e88f9436-b74e-49a8-87e9-777b9bfe715e", "name": "BoA Checking Account", "hidden_account_number": "XXXX0992", "priority": 1, "split_amount": 100}]} @@ -6199,7 +6379,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Direct Deposit"} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Direct Deposit"} responses: "422": application/json: {"errors": [{"error_key": "base", "category": "payroll_blocker", "message": "Company must complete all onboarding requirements in order to run payroll.", "metadata": {"key": "needs_onboarding"}}]} @@ -6210,7 +6390,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Direct Deposit"} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Direct Deposit"} responses: "422": application/json: {"errors": [{"error_key": "first_name", "category": "invalid_attribute_value", "message": "First name is required"}, {"error_key": "date_of_birth", "category": "invalid_attribute_value", "message": "Date of birth is not a valid date"}]} @@ -6221,7 +6401,7 @@ examples: header: X-Gusto-API-Version: "2024-04-01" requestBody: - application/json: {"version": "", "type": "Direct Deposit"} + application/json: {"version": "56d00c178bc7393b2a206ed6a86afcb4", "type": "Direct Deposit"} responses: "422": application/json: {"errors": [{"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "72ae4617-daa9-4ed7-85e0-18ed5d0ee835"}, "errors": [{"error_key": "hours", "category": "invalid_attribute_value", "message": "Ella Fitzgerald is paid fixed wage and hours cannot be set on a contractor payment"}]}, {"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "2d7bf62c-babf-4a12-8292-340e2d9cab28"}, "errors": [{"error_key": "wage", "category": "invalid_attribute_value", "message": "Isaiah Berlin is paid hourly and wage cannot be set on a contractor payment"}]}]} @@ -6750,6 +6930,17 @@ examples: application/json: {} "404": application/json: {"errors": [{"error_key": "", "category": ""}]} + speakeasy-default-post-v1-companies-company-id-payrolls: + parameters: + path: + company_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + responses: + "200": + application/json: {} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} get-v1-companies-company_id-payrolls: Example: parameters: @@ -6808,6 +6999,18 @@ examples: responses: "200": application/json: {"payroll_deadline": "2021-02-18T22:00:00Z", "check_date": "2021-02-22", "processed": true, "processed_date": "2021-02-18", "calculated_at": "2021-02-18T12:00:00Z", "payroll_uuid": "b50e611d-8f3d-4f24-b001-46675f7b5777", "company_uuid": "6bf7807c-a5a0-4f4d-b2e7-3fbb4b2299fb", "off_cycle": false, "auto_pilot": true, "external": false, "pay_period": {"start_date": "2021-02-01", "end_date": "2021-02-15", "pay_schedule_uuid": "00ebc4a4-ec88-4435-8f45-c505bb63e501"}, "payroll_status_meta": {"cancellable": false, "expected_check_date": "2021-02-22", "initial_check_date": "2021-02-22", "expected_debit_time": "2021-02-18T22:00:00Z", "payroll_late": false, "initial_debit_cutoff_time": "2021-02-18T22:00:00Z"}, "totals": {"company_debit": "121747.71", "net_pay_debit": "79283.80", "tax_debit": "42463.91", "reimbursement_debit": "0.00", "child_support_debit": "0.00", "reimbursements": "0.00", "net_pay": "81752.94", "gross_pay": "130635.89", "employee_bonuses": "0.00", "employee_commissions": "18536.37", "employee_cash_tips": "0.00", "employee_paycheck_tips": "0.00", "additional_earnings": "0.00", "owners_draw": "0.00", "check_amount": "2469.14", "employer_taxes": "6917.19", "employee_taxes": "35546.72", "benefits": "0.00", "employee_benefits_deductions": "13336.23", "imputed_pay": "0.00", "deferred_payroll_taxes": "0.00", "other_deductions": "240.00"}, "employee_compensations": [{"employee_uuid": "187412e1-3dbe-491a-bb2f-2f40323a7067", "excluded": false, "gross_pay": 2791.25, "net_pay": 1953.31, "check_amount": 1953.31, "payment_method": "Direct Deposit", "fixed_compensations": [{"name": "Bonus", "amount": "100.00", "job_uuid": "94e0d15e-9ed2-4077-98f6-64554f242ba5"}, {"name": "Reimbursement", "amount": "100.00", "job_uuid": "91bc3b43-ded0-4ee7-98fe-215499e909ba"}], "hourly_compensations": [{"name": "Regular Hours", "hours": "40.000", "job_uuid": "bd378298-3e0c-4145-904a-baadf8a91fa3", "compensation_multiplier": 1, "flsa_status": "Nonexempt"}, {"name": "Overtime", "hours": "15.000", "job_uuid": "9d3760f0-d1f9-4700-8817-0fe2dce5cf23", "compensation_multiplier": 1.5, "flsa_status": "Nonexempt"}, {"name": "Double overtime", "hours": "0.000", "job_uuid": "b5eef9a9-4a87-4649-a80d-14878c05f44e", "compensation_multiplier": 2, "flsa_status": "Nonexempt"}, {"name": "Regular Hours", "hours": "40.000", "job_uuid": "332bd171-9efc-432b-abbb-a75c9dba706a", "compensation_multiplier": 1, "flsa_status": "Nonexempt"}, {"name": "Overtime", "hours": "5.000", "job_uuid": "ca9b3dc1-57ac-4736-901a-9b1c9634b9d5", "compensation_multiplier": 1.5, "flsa_status": "Nonexempt"}, {"name": "Double overtime", "hours": "0.000", "job_uuid": "1bad01e2-140c-49ed-9542-2388ce4a19b3", "compensation_multiplier": 2, "flsa_status": "Nonexempt"}], "paid_time_off": [{"name": "Vacation Hours", "hours": "20.000"}, {"name": "Sick Hours", "hours": "0.000"}, {"name": "Holiday Hours", "hours": "0.000"}], "benefits": [{"name": "Group Term Life", "employee_deduction": 100, "company_contribution": 50, "imputed": true}, {"name": "401K", "employee_deduction": 100, "company_contribution": 50, "imputed": false}], "deductions": [{"name": "Child Support", "amount": 80}], "taxes": [{"name": "Federal Income Tax", "employer": false, "amount": 646.69}, {"name": "Social Security", "employer": true, "amount": 191.25}]}, {"employee_uuid": "187412e1-3dbe-491a-bb2f-2f40323a7012", "excluded": false, "gross_pay": 2791.25, "net_pay": 1953.31, "check_amount": 1953.31, "payment_method": "Direct Deposit", "fixed_compensations": [{"name": "Bonus", "amount": "100.00", "job_uuid": "94e0d15e-9ed2-4077-98f6-64554f242b34"}, {"name": "Reimbursement", "amount": "100.00", "job_uuid": "91bc3b43-ded0-4ee7-98fe-215499e90955"}], "hourly_compensations": [{"name": "Regular Hours", "hours": "40.000", "job_uuid": "bd378298-3e0c-4145-904a-baadf8a91fa3", "compensation_multiplier": 1, "flsa_status": "Commission Only Exempt"}], "paid_time_off": [{"name": "Vacation Hours", "hours": "20.000"}, {"name": "Sick Hours", "hours": "0.000"}, {"name": "Holiday Hours", "hours": "0.000"}], "benefits": [{"name": "Group Term Life", "employee_deduction": 100, "company_contribution": 50, "imputed": true}, {"name": "401K", "employee_deduction": 100, "company_contribution": 50, "imputed": false}], "deductions": [{"name": "Child Support", "amount": 80}], "taxes": [{"name": "Federal Income Tax", "employer": false, "amount": 646.69}, {"name": "Social Security", "employer": true, "amount": 191.25}]}, {"employee_uuid": "187412e1-3dbe-491a-bb2f-2f40323a7781", "excluded": false, "gross_pay": 2791.25, "net_pay": 1953.31, "check_amount": 1953.31, "payment_method": "Direct Deposit", "fixed_compensations": [{"name": "Bonus", "amount": "100.00", "job_uuid": "94e0d15e-9ed2-4077-98f6-64554f242bab"}, {"name": "Reimbursement", "amount": "100.00", "job_uuid": "91bc3b43-ded0-4ee7-98fe-215499e909cd"}], "hourly_compensations": [{"name": "Regular Hours", "hours": "40.000", "job_uuid": "bd378298-3e0c-4145-904a-baadf8a91fa3", "compensation_multiplier": 1, "flsa_status": "Exempt"}], "paid_time_off": [{"name": "Vacation Hours", "hours": "20.000"}, {"name": "Sick Hours", "hours": "0.000"}, {"name": "Holiday Hours", "hours": "0.000"}], "benefits": [{"name": "Group Term Life", "employee_deduction": 100, "company_contribution": 50, "imputed": true}, {"name": "401K", "employee_deduction": 100, "company_contribution": 50, "imputed": false}], "deductions": [{"name": "Child Support", "amount": 80}], "taxes": [{"name": "Federal Income Tax", "employer": false, "amount": 646.69}, {"name": "Social Security", "employer": true, "amount": 191.25}]}], "company_taxes": [{"name": "MO Compensation Deduction", "employer": true, "amount": "-0.92"}, {"name": "NY MCTMT", "employer": true, "amount": "5.00"}], "created_at": "2022-02-01T22:00:00Z", "credit_blockers": [{"blocker_type": "waiting_for_wire_in", "blocker_name": "Waiting for Wire In", "unblock_options": [{"unblock_type": "submit_wire", "check_date": "2024-06-10", "metadata": {}}], "selected_option": "submit_wire", "status": "unresolved"}], "processing_request": {"status": "submit_success", "errors": []}} + speakeasy-default-get-v1-companies-company-id-payrolls-payroll-id: + parameters: + path: + company_id: "" + payroll_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + responses: + "200": + application/json: {} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} put-v1-companies-company_id-payrolls: Example: parameters: @@ -6857,6 +7060,20 @@ examples: responses: "422": application/json: {"errors": [{"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "72ae4617-daa9-4ed7-85e0-18ed5d0ee835"}, "errors": [{"error_key": "hours", "category": "invalid_attribute_value", "message": "Ella Fitzgerald is paid fixed wage and hours cannot be set on a contractor payment"}]}, {"error_key": "contractor_payments", "category": "nested_errors", "metadata": {"contractor_uuid": "2d7bf62c-babf-4a12-8292-340e2d9cab28"}, "errors": [{"error_key": "wage", "category": "invalid_attribute_value", "message": "Isaiah Berlin is paid hourly and wage cannot be set on a contractor payment"}]}]} + speakeasy-default-put-v1-companies-company-id-payrolls: + parameters: + path: + company_id: "" + payroll_id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"employee_compensations": [{}]} + responses: + "200": + application/json: {} + "404": + application/json: {"errors": []} delete-v1-companies-company_id-payrolls: speakeasy-default-delete-v1-companies-company-id-payrolls: parameters: @@ -6865,6 +7082,9 @@ examples: payroll_id: "" header: X-Gusto-API-Version: "2024-04-01" + responses: + "404": + application/json: {"errors": []} put-v1-companies-company_id-payrolls-payroll_id-prepare: Example: parameters: @@ -8025,7 +8245,7 @@ examples: application/json: {"aggregation": "default"} responses: "200": - application/json: {"payroll_uuid": "a83d0bd8-7d20-43b9-834c-6d514ef6cb20", "aggregation": "default", "request_uuid": "p83d0ca8-7d41-42a9-834y-7d218ef6cb20"} + application/json: {"payroll_uuid": "a83d0bd8-7d20-43b9-834c-6d514ef6cb20", "aggregation": "integration", "integration_type": "xero", "request_uuid": "p83d0ca8-7d41-42a9-834y-7d218ef6cb20"} Basic: parameters: path: @@ -9372,5 +9592,59 @@ examples: responses: "200": application/json: [{"uuid": "8ad92898-591b-4d89-a22e-81f1cfdbf03e", "company_uuid": "", "title": "", "message": "", "status": "resolved", "category": "", "actionable": false, "can_block_payroll": false, "published_at": "", "due_at": null, "resources": []}] + get-v1-companies-company_id-payrolls-id-partner_disbursements: + speakeasy-default-get-v1-companies-company-id-payrolls-id-partner-disbursements: + parameters: + path: + company_id: "" + id: "" + header: + X-Gusto-API-Version: "2024-04-01" + responses: + "200": + application/json: {} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} + patch-v1-companies-company_id-payrolls-id-partner_disbursements: + speakeasy-default-patch-v1-companies-company-id-payrolls-id-partner-disbursements: + parameters: + path: + company_id: "" + id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"disbursements": [{"employee_uuid": "1a2b3c4d-5e6f-7890-abcd-ef1234567890"}]} + responses: + "200": + application/json: {} + "404": + application/json: {"errors": []} + get-v1-contractor_payment_groups-id-partner_disbursements: + speakeasy-default-get-v1-contractor-payment-groups-id-partner-disbursements: + parameters: + path: + id: "" + header: + X-Gusto-API-Version: "2024-04-01" + responses: + "200": + application/json: {} + "404": + application/json: {"errors": []} + patch-v1-contractor_payment_groups-id-partner_disbursements: + speakeasy-default-patch-v1-contractor-payment-groups-id-partner-disbursements: + parameters: + path: + id: "" + header: + X-Gusto-API-Version: "2024-04-01" + requestBody: + application/json: {"disbursements": [{"contractor_payment_uuid": "9f8e7d6c-5b4a-3928-1c2d-3e4f5a6b7c8d"}]} + responses: + "200": + application/json: {} + "404": + application/json: {"errors": [{"error_key": "", "category": ""}]} examplesVersion: 1.0.2 generatedTests: {} diff --git a/gusto_embedded/.speakeasy/gen.yaml b/gusto_embedded/.speakeasy/gen.yaml index bfa7539c..c64713f6 100644 --- a/gusto_embedded/.speakeasy/gen.yaml +++ b/gusto_embedded/.speakeasy/gen.yaml @@ -19,8 +19,12 @@ generation: auth: oAuth2ClientCredentialsEnabled: true oAuth2PasswordEnabled: true + tests: + generateTests: true + generateNewTests: false + skipResponseBodyAssertions: false typescript: - version: 0.6.4 + version: 0.6.5 additionalDependencies: dependencies: {} devDependencies: {} @@ -29,6 +33,7 @@ typescript: author: Speakeasy baseErrorName: GustoEmbeddedError clientServerStatusCodesAsErrors: true + constFieldsAlwaysOptional: true defaultErrorName: APIError enableCustomCodeRegions: false enableMCPServer: true @@ -37,6 +42,7 @@ typescript: envVarPrefix: GUSTOEMBEDDED flattenGlobalSecurity: true flatteningOrder: parameters-first + generateExamples: true imports: option: openapi paths: diff --git a/gusto_embedded/README.md b/gusto_embedded/README.md index 256c9535..66d344eb 100644 --- a/gusto_embedded/README.md +++ b/gusto_embedded/README.md @@ -271,6 +271,8 @@ run(); * [get](docs/sdks/contractorpaymentgroups/README.md#get) - Fetch a contractor payment group * [delete](docs/sdks/contractorpaymentgroups/README.md#delete) - Cancel a contractor payment group * [fund](docs/sdks/contractorpaymentgroups/README.md#fund) - Fund a contractor payment group [DEMO] +* [getV1ContractorPaymentGroupsIdPartnerDisbursements](docs/sdks/contractorpaymentgroups/README.md#getv1contractorpaymentgroupsidpartnerdisbursements) - Get partner disbursements for a contractor payment group +* [patchV1ContractorPaymentGroupsIdPartnerDisbursements](docs/sdks/contractorpaymentgroups/README.md#patchv1contractorpaymentgroupsidpartnerdisbursements) - Update partner disbursements for a contractor payment group ### [contractorPaymentMethod](docs/sdks/contractorpaymentmethod/README.md) @@ -527,6 +529,8 @@ run(); * [getPayStub](docs/sdks/payrolls/README.md#getpaystub) - Get an employee pay stub (pdf) * [getPayStubs](docs/sdks/payrolls/README.md#getpaystubs) - Get an employee's pay stubs * [generatePrintableChecks](docs/sdks/payrolls/README.md#generateprintablechecks) - Generate printable payroll checks (pdf) +* [getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements](docs/sdks/payrolls/README.md#getv1companiescompanyidpayrollsidpartnerdisbursements) - Get partner disbursements for a payroll +* [patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements](docs/sdks/payrolls/README.md#patchv1companiescompanyidpayrollsidpartnerdisbursements) - Update partner disbursements for a payroll ### [paySchedules](docs/sdks/payschedules/README.md) @@ -663,6 +667,8 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md). - [`contractorPaymentGroupsFund`](docs/sdks/contractorpaymentgroups/README.md#fund) - Fund a contractor payment group [DEMO] - [`contractorPaymentGroupsGet`](docs/sdks/contractorpaymentgroups/README.md#get) - Fetch a contractor payment group - [`contractorPaymentGroupsGetList`](docs/sdks/contractorpaymentgroups/README.md#getlist) - Get contractor payment groups for a company +- [`contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements`](docs/sdks/contractorpaymentgroups/README.md#getv1contractorpaymentgroupsidpartnerdisbursements) - Get partner disbursements for a contractor payment group +- [`contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements`](docs/sdks/contractorpaymentgroups/README.md#patchv1contractorpaymentgroupsidpartnerdisbursements) - Update partner disbursements for a contractor payment group - [`contractorPaymentGroupsPreview`](docs/sdks/contractorpaymentgroups/README.md#preview) - Preview a contractor payment group - [`contractorPaymentMethodGet`](docs/sdks/contractorpaymentmethod/README.md#get) - Get a contractor's payment method - [`contractorPaymentMethodGetBankAccounts`](docs/sdks/contractorpaymentmethod/README.md#getbankaccounts) - Get all contractor bank accounts @@ -818,7 +824,9 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md). - [`payrollsGetPayStub`](docs/sdks/payrolls/README.md#getpaystub) - Get an employee pay stub (pdf) - [`payrollsGetPayStubs`](docs/sdks/payrolls/README.md#getpaystubs) - Get an employee's pay stubs - [`payrollsGetReceipt`](docs/sdks/payrolls/README.md#getreceipt) - Get a single payroll receipt +- [`payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements`](docs/sdks/payrolls/README.md#getv1companiescompanyidpayrollsidpartnerdisbursements) - Get partner disbursements for a payroll - [`payrollsList`](docs/sdks/payrolls/README.md#list) - Get all payrolls for a company +- [`payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements`](docs/sdks/payrolls/README.md#patchv1companiescompanyidpayrollsidpartnerdisbursements) - Update partner disbursements for a payroll - [`payrollsPrepare`](docs/sdks/payrolls/README.md#prepare) - Prepare a payroll for update - [`payrollsSkip`](docs/sdks/payrolls/README.md#skip) - Skip a payroll - [`payrollsSubmit`](docs/sdks/payrolls/README.md#submit) - Submit payroll @@ -942,6 +950,8 @@ To learn about this feature and how to get started, check - [`useContractorPaymentGroupsFundMutation`](docs/sdks/contractorpaymentgroups/README.md#fund) - Fund a contractor payment group [DEMO] - [`useContractorPaymentGroupsGet`](docs/sdks/contractorpaymentgroups/README.md#get) - Fetch a contractor payment group - [`useContractorPaymentGroupsGetList`](docs/sdks/contractorpaymentgroups/README.md#getlist) - Get contractor payment groups for a company +- [`useContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements`](docs/sdks/contractorpaymentgroups/README.md#getv1contractorpaymentgroupsidpartnerdisbursements) - Get partner disbursements for a contractor payment group +- [`useContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutation`](docs/sdks/contractorpaymentgroups/README.md#patchv1contractorpaymentgroupsidpartnerdisbursements) - Update partner disbursements for a contractor payment group - [`useContractorPaymentGroupsPreviewMutation`](docs/sdks/contractorpaymentgroups/README.md#preview) - Preview a contractor payment group - [`useContractorPaymentMethodGet`](docs/sdks/contractorpaymentmethod/README.md#get) - Get a contractor's payment method - [`useContractorPaymentMethodGetBankAccounts`](docs/sdks/contractorpaymentmethod/README.md#getbankaccounts) - Get all contractor bank accounts @@ -1097,7 +1107,9 @@ To learn about this feature and how to get started, check - [`usePayrollsGetPayStub`](docs/sdks/payrolls/README.md#getpaystub) - Get an employee pay stub (pdf) - [`usePayrollsGetPayStubs`](docs/sdks/payrolls/README.md#getpaystubs) - Get an employee's pay stubs - [`usePayrollsGetReceipt`](docs/sdks/payrolls/README.md#getreceipt) - Get a single payroll receipt +- [`usePayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements`](docs/sdks/payrolls/README.md#getv1companiescompanyidpayrollsidpartnerdisbursements) - Get partner disbursements for a payroll - [`usePayrollsList`](docs/sdks/payrolls/README.md#list) - Get all payrolls for a company +- [`usePayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutation`](docs/sdks/payrolls/README.md#patchv1companiescompanyidpayrollsidpartnerdisbursements) - Update partner disbursements for a payroll - [`usePayrollsPrepareMutation`](docs/sdks/payrolls/README.md#prepare) - Prepare a payroll for update - [`usePayrollsSkipMutation`](docs/sdks/payrolls/README.md#skip) - Skip a payroll - [`usePayrollsSubmitMutation`](docs/sdks/payrolls/README.md#submit) - Submit payroll @@ -1330,10 +1342,10 @@ run(); **Inherit from [`GustoEmbeddedError`](./src/models/errors/gustoembeddederror.ts)**: -* [`UnprocessableEntityErrorObject`](docs/models/errors/unprocessableentityerrorobject.md): Unprocessable Entity This may happen when the body of your request contains errors such as `invalid_attribute_value`, or the request fails due to an `invalid_operation`. See the [Errors Categories](https://docs.gusto.com/embedded-payroll/docs/error-categories) guide for more details. Applicable to 129 of 253 methods.* -* [`UnprocessableEntityErrorObject1`](docs/models/errors/unprocessableentityerrorobject1.md): Unprocessable Entity This may happen when the body of your request contains errors such as `invalid_attribute_value`, or the request fails due to an `invalid_operation`. See the [Errors Categories](https://docs.gusto.com/embedded-payroll/docs/error-categories) guide for more details. Status code `422`. Applicable to 4 of 253 methods.* -* [`PayrollBlockersError`](docs/models/errors/payrollblockerserror.md): Payroll Blockers Error For detailed information, see the [Payroll Blockers guide](https://docs.gusto.com/embedded-payroll/docs/payroll-blockers). Status code `422`. Applicable to 4 of 253 methods.* -* [`DeleteV1CompanyBenefitsCompanyBenefitIdResponseBody`](docs/models/errors/deletev1companybenefitscompanybenefitidresponsebody.md): Unprocessable Entity. Status code `422`. Applicable to 1 of 253 methods.* +* [`UnprocessableEntityErrorObject`](./src/models/errors/unprocessableentityerrorobject.ts): Unprocessable Entity This may happen when the body of your request contains errors such as `invalid_attribute_value`, or the request fails due to an `invalid_operation`. See the [Errors Categories](https://docs.gusto.com/embedded-payroll/docs/error-categories) guide for more details. Applicable to 135 of 257 methods.* +* [`UnprocessableEntityErrorObject1`](./src/models/errors/unprocessableentityerrorobject1.ts): Unprocessable Entity This may happen when the body of your request contains errors such as `invalid_attribute_value`, or the request fails due to an `invalid_operation`. See the [Errors Categories](https://docs.gusto.com/embedded-payroll/docs/error-categories) guide for more details. Status code `422`. Applicable to 4 of 257 methods.* +* [`PayrollBlockersError`](./src/models/errors/payrollblockerserror.ts): Payroll Blockers Error For detailed information, see the [Payroll Blockers guide](https://docs.gusto.com/embedded-payroll/docs/payroll-blockers). Status code `422`. Applicable to 4 of 257 methods.* +* [`DeleteV1CompanyBenefitsCompanyBenefitIdResponseBody`](./src/models/errors/deletev1companybenefitscompanybenefitidresponsebody.ts): Unprocessable Entity. Status code `422`. Applicable to 1 of 257 methods.* * [`ResponseValidationError`](./src/models/errors/responsevalidationerror.ts): Type mismatch between the data returned from the server and the structure expected by the SDK. See `error.rawValue` for the raw value and `error.pretty()` for a nicely formatted multi-line string. diff --git a/gusto_embedded/RELEASES.md b/gusto_embedded/RELEASES.md index fba06cfe..c04f98c4 100644 --- a/gusto_embedded/RELEASES.md +++ b/gusto_embedded/RELEASES.md @@ -288,4 +288,14 @@ Based on: ### Generated - [typescript v0.6.4] gusto_embedded ### Releases -- [NPM v0.6.4] https://www.npmjs.com/package/@gusto/embedded-api/v/0.6.4 - gusto_embedded \ No newline at end of file +- [NPM v0.6.4] https://www.npmjs.com/package/@gusto/embedded-api/v/0.6.4 - gusto_embedded + +## 2025-07-15 17:19:57 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.582.0 (2.657.1) https://github.com/speakeasy-api/speakeasy +### Generated +- [typescript v0.6.5] gusto_embedded +### Releases +- [NPM v0.6.5] https://www.npmjs.com/package/@gusto/embedded-api/v/0.6.5 - gusto_embedded \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/aggregation.md b/gusto_embedded/docs/models/components/aggregation.md index 35724167..b50d27a1 100644 --- a/gusto_embedded/docs/models/components/aggregation.md +++ b/gusto_embedded/docs/models/components/aggregation.md @@ -7,11 +7,11 @@ The breakdown level used for the report ```typescript import { Aggregation } from "@gusto/embedded-api/models/components/generalledgerreport.js"; -let value: Aggregation = "job"; +let value: Aggregation = "department"; ``` ## Values ```typescript -"default" | "job" | "department" +"default" | "job" | "department" | "integration" ``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/blockertype.md b/gusto_embedded/docs/models/components/blockertype.md new file mode 100644 index 00000000..1dfbe3c0 --- /dev/null +++ b/gusto_embedded/docs/models/components/blockertype.md @@ -0,0 +1,17 @@ +# BlockerType + +The type of blocker + +## Example Usage + +```typescript +import { BlockerType } from "@gusto/embedded-api/models/components/paymentconfigs.js"; + +let value: BlockerType = "minimum_funded_payments"; +``` + +## Values + +```typescript +"minimum_days" | "minimum_funded_payments" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/companybenefitwithemployeebenefitsvaluetiers.md b/gusto_embedded/docs/models/components/companybenefitwithemployeebenefitsvaluetiers.md index 37e0ec68..6c9aae61 100644 --- a/gusto_embedded/docs/models/components/companybenefitwithemployeebenefitsvaluetiers.md +++ b/gusto_embedded/docs/models/components/companybenefitwithemployeebenefitsvaluetiers.md @@ -12,8 +12,8 @@ let value: CompanyBenefitWithEmployeeBenefitsValueTiers = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | -| `threshold` | *string* | :heavy_minus_sign: | The percentage threshold at which this tier ends (inclusive).

For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll.

If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. | -| `thresholdDelta` | *string* | :heavy_minus_sign: | The step up difference between this tier's threshold and the previous tier's threshold. In the first tier, this is equivalent to threshold. | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | +| `threshold` | *string* | :heavy_minus_sign: | Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to.

Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards.

For example:

If the first tier has a threshold of "3", and `rate` of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll.

If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. | +| `thresholdDelta` | *string* | :heavy_minus_sign: | The step up difference between this tier's threshold and the previous tier's threshold. In the first tier, this is equivalent to threshold. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursements.md b/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursements.md new file mode 100644 index 00000000..c5eae906 --- /dev/null +++ b/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursements.md @@ -0,0 +1,18 @@ +# ContractorPaymentGroupPartnerDisbursements + +Partner disbursements for a contractor payment group + +## Example Usage + +```typescript +import { ContractorPaymentGroupPartnerDisbursements } from "@gusto/embedded-api/models/components/contractorpaymentgrouppartnerdisbursements.js"; + +let value: ContractorPaymentGroupPartnerDisbursements = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | +| `contractorPaymentGroupUuid` | *string* | :heavy_minus_sign: | The UUID of the contractor payment group | +| `disbursements` | [components.Disbursements](../../models/components/disbursements.md)[] | :heavy_minus_sign: | List of disbursements for the contractor payment group | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentmethod.md b/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentmethod.md new file mode 100644 index 00000000..0527dfaa --- /dev/null +++ b/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentmethod.md @@ -0,0 +1,18 @@ +# ContractorPaymentGroupPartnerDisbursementsPaymentMethod + +The payment method for the disbursement + +## Example Usage + +```typescript +import { ContractorPaymentGroupPartnerDisbursementsPaymentMethod } from "@gusto/embedded-api/models/components/contractorpaymentgrouppartnerdisbursements.js"; + +let value: ContractorPaymentGroupPartnerDisbursementsPaymentMethod = + "Direct Deposit"; +``` + +## Values + +```typescript +"Direct Deposit" | "Check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentstatus.md b/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentstatus.md new file mode 100644 index 00000000..745694bc --- /dev/null +++ b/gusto_embedded/docs/models/components/contractorpaymentgrouppartnerdisbursementspaymentstatus.md @@ -0,0 +1,17 @@ +# ContractorPaymentGroupPartnerDisbursementsPaymentStatus + +The status of the payment + +## Example Usage + +```typescript +import { ContractorPaymentGroupPartnerDisbursementsPaymentStatus } from "@gusto/embedded-api/models/components/contractorpaymentgrouppartnerdisbursements.js"; + +let value: ContractorPaymentGroupPartnerDisbursementsPaymentStatus = "Paid"; +``` + +## Values + +```typescript +"Pending" | "Paid" | "Not partner managed" | "Converted to check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/currentemploymentstatus.md b/gusto_embedded/docs/models/components/currentemploymentstatus.md index 86554f62..6f4f3a98 100644 --- a/gusto_embedded/docs/models/components/currentemploymentstatus.md +++ b/gusto_embedded/docs/models/components/currentemploymentstatus.md @@ -5,7 +5,7 @@ The current employment status of the employee. Full-time employees work 30+ hour ## Example Usage ```typescript -import { CurrentEmploymentStatus } from "@gusto/embedded-api/models/components/employee.js"; +import { CurrentEmploymentStatus } from "@gusto/embedded-api/models/components/showemployees.js"; let value: CurrentEmploymentStatus = "part_time_twenty_plus_hours"; ``` diff --git a/gusto_embedded/docs/models/components/disbursements.md b/gusto_embedded/docs/models/components/disbursements.md new file mode 100644 index 00000000..4e6022df --- /dev/null +++ b/gusto_embedded/docs/models/components/disbursements.md @@ -0,0 +1,18 @@ +# Disbursements + +## Example Usage + +```typescript +import { Disbursements } from "@gusto/embedded-api/models/components/contractorpaymentgrouppartnerdisbursements.js"; + +let value: Disbursements = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `contractorPaymentUuid` | *string* | :heavy_minus_sign: | The UUID of the contractor payment | +| `contractorUuid` | *string* | :heavy_minus_sign: | The UUID of the contractor | +| `paymentMethod` | [components.ContractorPaymentGroupPartnerDisbursementsPaymentMethod](../../models/components/contractorpaymentgrouppartnerdisbursementspaymentmethod.md) | :heavy_minus_sign: | The payment method for the disbursement | +| `paymentStatus` | [components.ContractorPaymentGroupPartnerDisbursementsPaymentStatus](../../models/components/contractorpaymentgrouppartnerdisbursementspaymentstatus.md) | :heavy_minus_sign: | The status of the payment | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/earnedfastachblockers.md b/gusto_embedded/docs/models/components/earnedfastachblockers.md new file mode 100644 index 00000000..08b7db89 --- /dev/null +++ b/gusto_embedded/docs/models/components/earnedfastachblockers.md @@ -0,0 +1,16 @@ +# EarnedFastAchBlockers + +## Example Usage + +```typescript +import { EarnedFastAchBlockers } from "@gusto/embedded-api/models/components/paymentconfigs.js"; + +let value: EarnedFastAchBlockers = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | +| `blockerType` | [components.BlockerType](../../models/components/blockertype.md) | :heavy_minus_sign: | The type of blocker | +| `threshold` | *number* | :heavy_minus_sign: | The threshold needed to unblock | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/einverification.md b/gusto_embedded/docs/models/components/einverification.md new file mode 100644 index 00000000..bc520174 --- /dev/null +++ b/gusto_embedded/docs/models/components/einverification.md @@ -0,0 +1,17 @@ +# EinVerification + +Information about the status of verifying the company's Employer Identification Number (EIN) + +## Example Usage + +```typescript +import { EinVerification } from "@gusto/embedded-api/models/components/federaltaxdetails.js"; + +let value: EinVerification = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `status` | [components.FederalTaxDetailsStatus](../../models/components/federaltaxdetailsstatus.md) | :heavy_minus_sign: | The status of EIN verification:
- `pending`: The EIN verification process has not completed (or the company does not yet have an EIN).
- `verified`: The EIN has been successfully verified as a valid EIN with the IRS.
- `failed`: The company's EIN did not pass verification. Common issues are being entered incorrectly or not matching the company's legal name. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/employee.md b/gusto_embedded/docs/models/components/employee.md index ea851028..073bfc93 100644 --- a/gusto_embedded/docs/models/components/employee.md +++ b/gusto_embedded/docs/models/components/employee.md @@ -38,8 +38,8 @@ let value: Employee = { | `twoPercentShareholder` | *boolean* | :heavy_minus_sign: | Whether the employee is a two percent shareholder of the company. This field only applies to companies with an S-Corp entity type. | | `workEmail` | *string* | :heavy_minus_sign: | The work email address of the employee. This is provided to support syncing users between our system and yours. You may not use this email address for any other purpose (e.g. marketing). | | `onboarded` | *boolean* | :heavy_minus_sign: | Whether the employee has completed onboarding. | -| `onboardingStatus` | [components.OnboardingStatus](../../models/components/onboardingstatus.md) | :heavy_minus_sign: | The current onboarding status of the employee | -| `onboardingDocumentsConfig` | [components.OnboardingDocumentsConfig](../../models/components/onboardingdocumentsconfig.md) | :heavy_minus_sign: | Configuration for an employee onboarding documents during onboarding | +| `onboardingStatus` | [components.EmployeeOnboardingStatus1](../../models/components/employeeonboardingstatus1.md) | :heavy_minus_sign: | The current onboarding status of the employee | +| `onboardingDocumentsConfig` | [components.EmployeeOnboardingDocumentsConfig](../../models/components/employeeonboardingdocumentsconfig.md) | :heavy_minus_sign: | Configuration for an employee onboarding documents during onboarding | | `jobs` | [components.Job](../../models/components/job.md)[] | :heavy_minus_sign: | N/A | | `eligiblePaidTimeOff` | [components.PaidTimeOff](../../models/components/paidtimeoff.md)[] | :heavy_minus_sign: | N/A | | `terminations` | [components.Termination](../../models/components/termination.md)[] | :heavy_minus_sign: | N/A | @@ -50,8 +50,8 @@ let value: Employee = { | `ssn` | *string* | :heavy_minus_sign: | Deprecated. This field always returns an empty string. | | `phone` | *string* | :heavy_minus_sign: | N/A | | `preferredFirstName` | *string* | :heavy_minus_sign: | N/A | -| `paymentMethod` | [components.PaymentMethod](../../models/components/paymentmethod.md) | :heavy_minus_sign: | The employee's payment method | -| `currentEmploymentStatus` | [components.CurrentEmploymentStatus](../../models/components/currentemploymentstatus.md) | :heavy_minus_sign: | The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. | +| `paymentMethod` | [components.EmployeePaymentMethod1](../../models/components/employeepaymentmethod1.md) | :heavy_minus_sign: | The employee's payment method | +| `currentEmploymentStatus` | [components.EmployeeCurrentEmploymentStatus](../../models/components/employeecurrentemploymentstatus.md) | :heavy_minus_sign: | The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. | | `historical` | *boolean* | :heavy_minus_sign: | N/A | | `employeeCode` | *string* | :heavy_minus_sign: | The short format code of the employee | | `departmentUuid` | *string* | :heavy_minus_sign: | The UUID of the department the employee is under | diff --git a/gusto_embedded/docs/models/components/employeecompensations.md b/gusto_embedded/docs/models/components/employeecompensations.md index 89acd293..ba0dae26 100644 --- a/gusto_embedded/docs/models/components/employeecompensations.md +++ b/gusto_embedded/docs/models/components/employeecompensations.md @@ -3,21 +3,20 @@ ## Example Usage ```typescript -import { EmployeeCompensations } from "@gusto/embedded-api/models/components/payrollreceipt.js"; +import { EmployeeCompensations } from "@gusto/embedded-api/models/components/payrollupdate.js"; let value: EmployeeCompensations = {}; ``` ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | -| `employeeUuid` | *string* | :heavy_minus_sign: | The UUID of the employee. | -| `employeeFirstName` | *string* | :heavy_minus_sign: | The first name of the employee. | -| `employeeLastName` | *string* | :heavy_minus_sign: | The last name of the employee. | -| `paymentMethod` | [components.PayrollReceiptPaymentMethod](../../models/components/payrollreceiptpaymentmethod.md) | :heavy_minus_sign: | The employee's compensation payment method. | -| `netPay` | *string* | :heavy_minus_sign: | The employee's net pay. Net pay paid by check is available for reference but is not included in the `["totals"]["net_pay_debit"]` amount. | -| `totalTax` | *string* | :heavy_minus_sign: | The total of employer and employee taxes for the pay period. | -| `totalGarnishments` | *string* | :heavy_minus_sign: | The total garnishments for the pay period. | -| `childSupportGarnishment` | *string* | :heavy_minus_sign: | The total child support garnishment for the pay period. | -| `totalReimbursement` | *string* | :heavy_minus_sign: | The total reimbursement for the pay period. | \ No newline at end of file +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `employeeUuid` | *string* | :heavy_minus_sign: | The UUID of the employee. | +| `version` | *string* | :heavy_minus_sign: | The current version of this employee compensation from the prepared payroll. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | +| `excluded` | *boolean* | :heavy_minus_sign: | This employee will be excluded from payroll calculation and will not be paid for the payroll. | +| `paymentMethod` | [components.PayrollUpdatePaymentMethod](../../models/components/payrollupdatepaymentmethod.md) | :heavy_minus_sign: | The employee's compensation payment method. Invalid values will be ignored. | +| `memo` | *string* | :heavy_minus_sign: | Custom text that will be printed as a personal note to the employee on a paystub. | +| `fixedCompensations` | [components.PayrollUpdateFixedCompensations](../../models/components/payrollupdatefixedcompensations.md)[] | :heavy_minus_sign: | N/A | +| `hourlyCompensations` | [components.PayrollUpdateHourlyCompensations](../../models/components/payrollupdatehourlycompensations.md)[] | :heavy_minus_sign: | N/A | +| `paidTimeOff` | [components.PayrollUpdatePaidTimeOff](../../models/components/payrollupdatepaidtimeoff.md)[] | :heavy_minus_sign: | An array of all paid time off the employee is eligible for this pay period. Each paid time off object can be the name or the specific policy_uuid. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/employeecurrentemploymentstatus.md b/gusto_embedded/docs/models/components/employeecurrentemploymentstatus.md new file mode 100644 index 00000000..6d3067fa --- /dev/null +++ b/gusto_embedded/docs/models/components/employeecurrentemploymentstatus.md @@ -0,0 +1,17 @@ +# EmployeeCurrentEmploymentStatus + +The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. + +## Example Usage + +```typescript +import { EmployeeCurrentEmploymentStatus } from "@gusto/embedded-api/models/components/employee.js"; + +let value: EmployeeCurrentEmploymentStatus = "seasonal"; +``` + +## Values + +```typescript +"full_time" | "part_time_under_twenty_hours" | "part_time_twenty_plus_hours" | "variable" | "seasonal" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/employeehomeaddress.md b/gusto_embedded/docs/models/components/employeehomeaddress.md new file mode 100644 index 00000000..5494cda3 --- /dev/null +++ b/gusto_embedded/docs/models/components/employeehomeaddress.md @@ -0,0 +1,29 @@ +# EmployeeHomeAddress + +## Example Usage + +```typescript +import { EmployeeHomeAddress } from "@gusto/embedded-api/models/components/employeehomeaddress.js"; + +let value: EmployeeHomeAddress = { + street1: "412 Kiera Stravenue", + street2: "Suite 391", + city: "San Francisco", + state: "CA", + zip: "94107", + active: true, +}; +``` + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | +| `street1` | *string* | :heavy_minus_sign: | N/A | +| `street2` | *string* | :heavy_minus_sign: | N/A | +| `city` | *string* | :heavy_minus_sign: | N/A | +| `state` | *string* | :heavy_minus_sign: | N/A | +| `zip` | *string* | :heavy_minus_sign: | N/A | +| `country` | *string* | :heavy_minus_sign: | N/A | +| `active` | *boolean* | :heavy_minus_sign: | The status of the location. Inactive locations have been deleted, but may still have historical data associated with them. | +| `uuid` | *string* | :heavy_minus_sign: | Unique identifier for this address. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/employeeonboardingdocumentsconfig.md b/gusto_embedded/docs/models/components/employeeonboardingdocumentsconfig.md new file mode 100644 index 00000000..029d6c55 --- /dev/null +++ b/gusto_embedded/docs/models/components/employeeonboardingdocumentsconfig.md @@ -0,0 +1,18 @@ +# EmployeeOnboardingDocumentsConfig + +Configuration for an employee onboarding documents during onboarding + +## Example Usage + +```typescript +import { EmployeeOnboardingDocumentsConfig } from "@gusto/embedded-api/models/components/employee.js"; + +let value: EmployeeOnboardingDocumentsConfig = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------- | ------------------------------------------------------------- | ------------------------------------------------------------- | ------------------------------------------------------------- | +| `uuid` | *string* | :heavy_minus_sign: | The UUID of the onboarding documents config | +| `i9Document` | *boolean* | :heavy_minus_sign: | Whether to include Form I-9 for an employee during onboarding | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/employeeonboardingstatus1.md b/gusto_embedded/docs/models/components/employeeonboardingstatus1.md new file mode 100644 index 00000000..47665f71 --- /dev/null +++ b/gusto_embedded/docs/models/components/employeeonboardingstatus1.md @@ -0,0 +1,17 @@ +# EmployeeOnboardingStatus1 + +The current onboarding status of the employee + +## Example Usage + +```typescript +import { EmployeeOnboardingStatus1 } from "@gusto/embedded-api/models/components/employee.js"; + +let value: EmployeeOnboardingStatus1 = "self_onboarding_completed_by_employee"; +``` + +## Values + +```typescript +"onboarding_completed" | "admin_onboarding_incomplete" | "self_onboarding_pending_invite" | "self_onboarding_invited" | "self_onboarding_invited_started" | "self_onboarding_invited_overdue" | "self_onboarding_completed_by_employee" | "self_onboarding_awaiting_admin_review" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/employeepaymentmethod1.md b/gusto_embedded/docs/models/components/employeepaymentmethod1.md new file mode 100644 index 00000000..bdd7d4ed --- /dev/null +++ b/gusto_embedded/docs/models/components/employeepaymentmethod1.md @@ -0,0 +1,17 @@ +# EmployeePaymentMethod1 + +The employee's payment method + +## Example Usage + +```typescript +import { EmployeePaymentMethod1 } from "@gusto/embedded-api/models/components/employee.js"; + +let value: EmployeePaymentMethod1 = "Check"; +``` + +## Values + +```typescript +"Direct Deposit" | "Check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/federaltaxdetails.md b/gusto_embedded/docs/models/components/federaltaxdetails.md index ace88ade..dd9184bc 100644 --- a/gusto_embedded/docs/models/components/federaltaxdetails.md +++ b/gusto_embedded/docs/models/components/federaltaxdetails.md @@ -19,7 +19,8 @@ let value: FederalTaxDetails = {}; | `taxableAsScorp` | *boolean* | :heavy_minus_sign: | Whether the company is taxed as an S-Corporation. Tax payer types that may be taxed as an S-Corporation include:
- S-Corporation
- C-Corporation
- LLC | | `filingForm` | *string* | :heavy_minus_sign: | The form used by the company for federal tax filing. One of:
- 941 (Quarterly federal tax return form)
- 944 (Annual federal tax return form) | | `hasEin` | *boolean* | :heavy_minus_sign: | Whether company's Employer Identification Number (EIN) is present | -| `einVerified` | *boolean* | :heavy_minus_sign: | Whether the EIN was able to be verified as a valid EIN with the IRS. | +| `einVerified` | *boolean* | :heavy_minus_sign: | Whether the EIN has been successfully verified as a valid EIN with the IRS. | +| `einVerification` | [components.EinVerification](../../models/components/einverification.md) | :heavy_minus_sign: | Information about the status of verifying the company's Employer Identification Number (EIN) | | `legalName` | *string* | :heavy_minus_sign: | The legal name of the company | | `effectiveDate` | *string* | :heavy_minus_sign: | The date that these details took effect. | | `depositSchedule` | *string* | :heavy_minus_sign: | How often the company sends money to the IRS. One of:
- Semiweekly
- Monthly | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/federaltaxdetailsstatus.md b/gusto_embedded/docs/models/components/federaltaxdetailsstatus.md new file mode 100644 index 00000000..575f1bff --- /dev/null +++ b/gusto_embedded/docs/models/components/federaltaxdetailsstatus.md @@ -0,0 +1,20 @@ +# FederalTaxDetailsStatus + +The status of EIN verification: +- `pending`: The EIN verification process has not completed (or the company does not yet have an EIN). +- `verified`: The EIN has been successfully verified as a valid EIN with the IRS. +- `failed`: The company's EIN did not pass verification. Common issues are being entered incorrectly or not matching the company's legal name. + +## Example Usage + +```typescript +import { FederalTaxDetailsStatus } from "@gusto/embedded-api/models/components/federaltaxdetails.js"; + +let value: FederalTaxDetailsStatus = "pending"; +``` + +## Values + +```typescript +"pending" | "verified" | "failed" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/generalledgerreport.md b/gusto_embedded/docs/models/components/generalledgerreport.md index 9bd8cbf8..7c0388a3 100644 --- a/gusto_embedded/docs/models/components/generalledgerreport.md +++ b/gusto_embedded/docs/models/components/generalledgerreport.md @@ -12,8 +12,9 @@ let value: GeneralLedgerReport = {}; ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------- | ----------------------------------------------------------------- | ----------------------------------------------------------------- | ----------------------------------------------------------------- | -| `payrollUuid` | *string* | :heavy_minus_sign: | The UUID of the payroll record for which the report was generated | -| `aggregation` | [components.Aggregation](../../models/components/aggregation.md) | :heavy_minus_sign: | The breakdown level used for the report | -| `requestUuid` | *string* | :heavy_minus_sign: | UUID to use for polling the report status | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------- | +| `payrollUuid` | *string* | :heavy_minus_sign: | The UUID of the payroll record for which the report was generated | +| `aggregation` | [components.Aggregation](../../models/components/aggregation.md) | :heavy_minus_sign: | The breakdown level used for the report | +| `integrationType` | [components.IntegrationType](../../models/components/integrationtype.md) | :heavy_minus_sign: | The `integration_type` used for the report, if `aggregation` was 'integration.' Otherwise, this will be null. | +| `requestUuid` | *string* | :heavy_minus_sign: | UUID to use for polling the report status | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/integrationtype.md b/gusto_embedded/docs/models/components/integrationtype.md new file mode 100644 index 00000000..8fabb0a4 --- /dev/null +++ b/gusto_embedded/docs/models/components/integrationtype.md @@ -0,0 +1,17 @@ +# IntegrationType + +The `integration_type` used for the report, if `aggregation` was 'integration.' Otherwise, this will be null. + +## Example Usage + +```typescript +import { IntegrationType } from "@gusto/embedded-api/models/components/generalledgerreport.js"; + +let value: IntegrationType = "qbo"; +``` + +## Values + +```typescript +"xero" | "qbo" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/onboardingdocumentsconfig.md b/gusto_embedded/docs/models/components/onboardingdocumentsconfig.md index 7f8a29ff..55e0fc9d 100644 --- a/gusto_embedded/docs/models/components/onboardingdocumentsconfig.md +++ b/gusto_embedded/docs/models/components/onboardingdocumentsconfig.md @@ -5,7 +5,7 @@ Configuration for an employee onboarding documents during onboarding ## Example Usage ```typescript -import { OnboardingDocumentsConfig } from "@gusto/embedded-api/models/components/employee.js"; +import { OnboardingDocumentsConfig } from "@gusto/embedded-api/models/components/showemployees.js"; let value: OnboardingDocumentsConfig = {}; ``` diff --git a/gusto_embedded/docs/models/components/onboardingstatus.md b/gusto_embedded/docs/models/components/onboardingstatus.md index 9bbfe436..14260048 100644 --- a/gusto_embedded/docs/models/components/onboardingstatus.md +++ b/gusto_embedded/docs/models/components/onboardingstatus.md @@ -5,7 +5,7 @@ The current onboarding status of the employee ## Example Usage ```typescript -import { OnboardingStatus } from "@gusto/embedded-api/models/components/employee.js"; +import { OnboardingStatus } from "@gusto/embedded-api/models/components/showemployees.js"; let value: OnboardingStatus = "admin_onboarding_incomplete"; ``` diff --git a/gusto_embedded/docs/models/components/paymentconfigs.md b/gusto_embedded/docs/models/components/paymentconfigs.md index f69f550e..e3c09360 100644 --- a/gusto_embedded/docs/models/components/paymentconfigs.md +++ b/gusto_embedded/docs/models/components/paymentconfigs.md @@ -12,9 +12,10 @@ let value: PaymentConfigs = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- | ---------------------------------------- | -| `companyUuid` | *string* | :heavy_minus_sign: | Company uuid | -| `partnerUuid` | *string* | :heavy_minus_sign: | Partner uuid | -| `fastPaymentLimit` | *string* | :heavy_minus_sign: | Payment limit for 1-day or 2-day payroll | -| `paymentSpeed` | *string* | :heavy_minus_sign: | Payment speed for 1-day, 2-day, 4-day | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `companyUuid` | *string* | :heavy_minus_sign: | Company uuid | +| `partnerUuid` | *string* | :heavy_minus_sign: | Partner uuid | +| `fastPaymentLimit` | *string* | :heavy_minus_sign: | Payment limit for 1-day or 2-day payroll | +| `paymentSpeed` | *string* | :heavy_minus_sign: | Payment speed for 1-day, 2-day, 4-day | +| `earnedFastAchBlockers` | [components.EarnedFastAchBlockers](../../models/components/earnedfastachblockers.md)[] | :heavy_minus_sign: | Blockers preventing the company from earning fast ACH payments | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/paymentmethod.md b/gusto_embedded/docs/models/components/paymentmethod.md index 77c117bf..cae8e8b6 100644 --- a/gusto_embedded/docs/models/components/paymentmethod.md +++ b/gusto_embedded/docs/models/components/paymentmethod.md @@ -5,7 +5,7 @@ The employee's payment method ## Example Usage ```typescript -import { PaymentMethod } from "@gusto/embedded-api/models/components/employee.js"; +import { PaymentMethod } from "@gusto/embedded-api/models/components/showemployees.js"; let value: PaymentMethod = "Check"; ``` diff --git a/gusto_embedded/docs/models/components/payroll.md b/gusto_embedded/docs/models/components/payroll.md index 0f706b96..a3aec7c3 100644 --- a/gusto_embedded/docs/models/components/payroll.md +++ b/gusto_embedded/docs/models/components/payroll.md @@ -37,4 +37,5 @@ let value: Payroll = {}; | `createdAt` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | Datetime for when the resource was created. | | `submissionBlockers` | [components.PayrollSubmissionBlockersType](../../models/components/payrollsubmissionblockerstype.md)[] | :heavy_minus_sign: | Only included for processed or calculated payrolls | | `creditBlockers` | [components.PayrollCreditBlockersType](../../models/components/payrollcreditblockerstype.md)[] | :heavy_minus_sign: | Only included for processed payrolls | -| `processingRequest` | [components.PayrollProcessingRequest](../../models/components/payrollprocessingrequest.md) | :heavy_minus_sign: | N/A | \ No newline at end of file +| `processingRequest` | [components.PayrollProcessingRequest](../../models/components/payrollprocessingrequest.md) | :heavy_minus_sign: | N/A | +| `partnerOwnedDisbursement` | *boolean* | :heavy_minus_sign: | Will money movement for the payroll be performed by the partner rather than by Gusto? | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollemployeecompensationstype.md b/gusto_embedded/docs/models/components/payrollemployeecompensationstype.md index c67af164..1f531e46 100644 --- a/gusto_embedded/docs/models/components/payrollemployeecompensationstype.md +++ b/gusto_embedded/docs/models/components/payrollemployeecompensationstype.md @@ -18,7 +18,7 @@ let value: PayrollEmployeeCompensationsType = {}; | `grossPay` | *number* | :heavy_minus_sign: | The employee's gross pay, equal to regular wages + cash tips + payroll tips + any other additional earnings, excluding imputed income. This value is only available for processed payrolls. | | `netPay` | *number* | :heavy_minus_sign: | The employee's net pay, equal to gross_pay - employee taxes - employee deductions or garnishments - cash tips. This value is only available for processed payrolls. | | `checkAmount` | *number* | :heavy_minus_sign: | The employee's check amount, equal to net_pay + reimbursements. This value is only available for processed payrolls. | -| `paymentMethod` | [components.PayrollEmployeeCompensationsTypePaymentMethod](../../models/components/payrollemployeecompensationstypepaymentmethod.md) | :heavy_minus_sign: | The employee's compensation payment method. | +| `paymentMethod` | [components.PayrollEmployeeCompensationsTypePaymentMethod](../../models/components/payrollemployeecompensationstypepaymentmethod.md) | :heavy_minus_sign: | The employee's compensation payment method. Is *only* `Historical` when retrieving external payrolls initially run outside of Gusto, then put into Gusto. | | `memo` | *string* | :heavy_minus_sign: | Custom text that will be printed as a personal note to the employee on a paystub. | | `fixedCompensations` | [components.FixedCompensations](../../models/components/fixedcompensations.md)[] | :heavy_minus_sign: | An array of fixed compensations for the employee. Fixed compensations include tips, bonuses, and one time reimbursements. If this payroll has been processed, only fixed compensations with a value greater than 0.00 are returned. For an unprocessed payroll, all active fixed compensations are returned. | | `hourlyCompensations` | [components.HourlyCompensations](../../models/components/hourlycompensations.md)[] | :heavy_minus_sign: | An array of hourly compensations for the employee. Hourly compensations include regular, overtime, and double overtime hours. If this payroll has been processed, only hourly compensations with a value greater than 0.00 are returned. For an unprocessed payroll, all active hourly compensations are returned. | diff --git a/gusto_embedded/docs/models/components/payrollemployeecompensationstypepaymentmethod.md b/gusto_embedded/docs/models/components/payrollemployeecompensationstypepaymentmethod.md index 27a6447a..9ff6c7dc 100644 --- a/gusto_embedded/docs/models/components/payrollemployeecompensationstypepaymentmethod.md +++ b/gusto_embedded/docs/models/components/payrollemployeecompensationstypepaymentmethod.md @@ -1,17 +1,17 @@ # PayrollEmployeeCompensationsTypePaymentMethod -The employee's compensation payment method. +The employee's compensation payment method. Is *only* `Historical` when retrieving external payrolls initially run outside of Gusto, then put into Gusto. ## Example Usage ```typescript import { PayrollEmployeeCompensationsTypePaymentMethod } from "@gusto/embedded-api/models/components/payrollemployeecompensationstype.js"; -let value: PayrollEmployeeCompensationsTypePaymentMethod = "Direct Deposit"; +let value: PayrollEmployeeCompensationsTypePaymentMethod = "Check"; ``` ## Values ```typescript -"Direct Deposit" | "Check" +"Direct Deposit" | "Check" | "Historical" ``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollpartnerdisbursements.md b/gusto_embedded/docs/models/components/payrollpartnerdisbursements.md new file mode 100644 index 00000000..ea01388e --- /dev/null +++ b/gusto_embedded/docs/models/components/payrollpartnerdisbursements.md @@ -0,0 +1,18 @@ +# PayrollPartnerDisbursements + +Partner disbursements for a payroll + +## Example Usage + +```typescript +import { PayrollPartnerDisbursements } from "@gusto/embedded-api/models/components/payrollpartnerdisbursements.js"; + +let value: PayrollPartnerDisbursements = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | +| `payrollUuid` | *string* | :heavy_minus_sign: | The UUID of the payroll | +| `disbursements` | [components.PayrollPartnerDisbursementsDisbursements](../../models/components/payrollpartnerdisbursementsdisbursements.md)[] | :heavy_minus_sign: | List of disbursements for the payroll | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollpartnerdisbursementsdisbursements.md b/gusto_embedded/docs/models/components/payrollpartnerdisbursementsdisbursements.md new file mode 100644 index 00000000..89194af5 --- /dev/null +++ b/gusto_embedded/docs/models/components/payrollpartnerdisbursementsdisbursements.md @@ -0,0 +1,17 @@ +# PayrollPartnerDisbursementsDisbursements + +## Example Usage + +```typescript +import { PayrollPartnerDisbursementsDisbursements } from "@gusto/embedded-api/models/components/payrollpartnerdisbursements.js"; + +let value: PayrollPartnerDisbursementsDisbursements = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- | +| `employeeUuid` | *string* | :heavy_minus_sign: | The UUID of the employee | +| `paymentMethod` | [components.PayrollPartnerDisbursementsPaymentMethod](../../models/components/payrollpartnerdisbursementspaymentmethod.md) | :heavy_minus_sign: | The payment method for the disbursement | +| `paymentStatus` | [components.PayrollPartnerDisbursementsPaymentStatus](../../models/components/payrollpartnerdisbursementspaymentstatus.md) | :heavy_minus_sign: | The status of the payment | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollpartnerdisbursementspaymentmethod.md b/gusto_embedded/docs/models/components/payrollpartnerdisbursementspaymentmethod.md new file mode 100644 index 00000000..3aa9ec61 --- /dev/null +++ b/gusto_embedded/docs/models/components/payrollpartnerdisbursementspaymentmethod.md @@ -0,0 +1,17 @@ +# PayrollPartnerDisbursementsPaymentMethod + +The payment method for the disbursement + +## Example Usage + +```typescript +import { PayrollPartnerDisbursementsPaymentMethod } from "@gusto/embedded-api/models/components/payrollpartnerdisbursements.js"; + +let value: PayrollPartnerDisbursementsPaymentMethod = "Direct Deposit"; +``` + +## Values + +```typescript +"Direct Deposit" | "Check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollpartnerdisbursementspaymentstatus.md b/gusto_embedded/docs/models/components/payrollpartnerdisbursementspaymentstatus.md new file mode 100644 index 00000000..d8cdd5cb --- /dev/null +++ b/gusto_embedded/docs/models/components/payrollpartnerdisbursementspaymentstatus.md @@ -0,0 +1,17 @@ +# PayrollPartnerDisbursementsPaymentStatus + +The status of the payment + +## Example Usage + +```typescript +import { PayrollPartnerDisbursementsPaymentStatus } from "@gusto/embedded-api/models/components/payrollpartnerdisbursements.js"; + +let value: PayrollPartnerDisbursementsPaymentStatus = "Converted to check"; +``` + +## Values + +```typescript +"Pending" | "Paid" | "Not partner managed" | "Converted to check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollprepared.md b/gusto_embedded/docs/models/components/payrollprepared.md index cdd70978..0384d21e 100644 --- a/gusto_embedded/docs/models/components/payrollprepared.md +++ b/gusto_embedded/docs/models/components/payrollprepared.md @@ -34,4 +34,5 @@ let value: PayrollPrepared = {}; | `paymentSpeedChanged` | [components.PayrollPaymentSpeedChangedType](../../models/components/payrollpaymentspeedchangedtype.md) | :heavy_minus_sign: | Only applicable when a payroll is moved to four day processing instead of fast ach. | | `createdAt` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | Datetime for when the resource was created. | | `fixedCompensationTypes` | [components.PayrollFixedCompensationTypesType](../../models/components/payrollfixedcompensationtypestype.md)[] | :heavy_minus_sign: | N/A | -| `processingRequest` | [components.PayrollProcessingRequest](../../models/components/payrollprocessingrequest.md) | :heavy_minus_sign: | N/A | \ No newline at end of file +| `processingRequest` | [components.PayrollProcessingRequest](../../models/components/payrollprocessingrequest.md) | :heavy_minus_sign: | N/A | +| `partnerOwnedDisbursement` | *boolean* | :heavy_minus_sign: | Will money movement for the payroll be performed by the partner rather than by Gusto? | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollreceipt.md b/gusto_embedded/docs/models/components/payrollreceipt.md index 0dc6dae6..f3abe0ea 100644 --- a/gusto_embedded/docs/models/components/payrollreceipt.md +++ b/gusto_embedded/docs/models/components/payrollreceipt.md @@ -24,5 +24,5 @@ let value: PayrollReceipt = {}; | `liabilityOfLicensee` | *string* | :heavy_minus_sign: | N/A | | `totals` | [components.Totals](../../models/components/totals.md) | :heavy_minus_sign: | The subtotals for the payroll. | | `taxes` | [components.PayrollReceiptTaxes](../../models/components/payrollreceipttaxes.md)[] | :heavy_minus_sign: | An array of totaled employer and employee taxes for the pay period. | -| `employeeCompensations` | [components.EmployeeCompensations](../../models/components/employeecompensations.md)[] | :heavy_minus_sign: | An array of employee compensations and withholdings for this payroll | +| `employeeCompensations` | [components.PayrollReceiptEmployeeCompensations](../../models/components/payrollreceiptemployeecompensations.md)[] | :heavy_minus_sign: | An array of employee compensations and withholdings for this payroll | | `licensee` | [components.Licensee](../../models/components/licensee.md) | :heavy_minus_sign: | The licensed payroll processor | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payrollreceiptemployeecompensations.md b/gusto_embedded/docs/models/components/payrollreceiptemployeecompensations.md new file mode 100644 index 00000000..22eaa992 --- /dev/null +++ b/gusto_embedded/docs/models/components/payrollreceiptemployeecompensations.md @@ -0,0 +1,23 @@ +# PayrollReceiptEmployeeCompensations + +## Example Usage + +```typescript +import { PayrollReceiptEmployeeCompensations } from "@gusto/embedded-api/models/components/payrollreceipt.js"; + +let value: PayrollReceiptEmployeeCompensations = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | +| `employeeUuid` | *string* | :heavy_minus_sign: | The UUID of the employee. | +| `employeeFirstName` | *string* | :heavy_minus_sign: | The first name of the employee. | +| `employeeLastName` | *string* | :heavy_minus_sign: | The last name of the employee. | +| `paymentMethod` | [components.PayrollReceiptPaymentMethod](../../models/components/payrollreceiptpaymentmethod.md) | :heavy_minus_sign: | The employee's compensation payment method. | +| `netPay` | *string* | :heavy_minus_sign: | The employee's net pay. Net pay paid by check is available for reference but is not included in the `["totals"]["net_pay_debit"]` amount. | +| `totalTax` | *string* | :heavy_minus_sign: | The total of employer and employee taxes for the pay period. | +| `totalGarnishments` | *string* | :heavy_minus_sign: | The total garnishments for the pay period. | +| `childSupportGarnishment` | *string* | :heavy_minus_sign: | The total child support garnishment for the pay period. | +| `totalReimbursement` | *string* | :heavy_minus_sign: | The total reimbursement for the pay period. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsrequestbody.md b/gusto_embedded/docs/models/components/payrollupdate.md similarity index 93% rename from gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsrequestbody.md rename to gusto_embedded/docs/models/components/payrollupdate.md index 8362d30f..ab21c523 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsrequestbody.md +++ b/gusto_embedded/docs/models/components/payrollupdate.md @@ -1,11 +1,11 @@ -# PutV1CompaniesCompanyIdPayrollsRequestBody +# PayrollUpdate ## Example Usage ```typescript -import { PutV1CompaniesCompanyIdPayrollsRequestBody } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; +import { PayrollUpdate } from "@gusto/embedded-api/models/components/payrollupdate.js"; -let value: PutV1CompaniesCompanyIdPayrollsRequestBody = { +let value: PayrollUpdate = { employeeCompensations: [ {}, ], @@ -16,7 +16,7 @@ let value: PutV1CompaniesCompanyIdPayrollsRequestBody = { | Field | Type | Required | Description | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `employeeCompensations` | [operations.EmployeeCompensations](../../models/operations/employeecompensations.md)[] | :heavy_check_mark: | N/A | -| `withholdingPayPeriod` | [operations.PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod](../../models/operations/putv1companiescompanyidpayrollswithholdingpayperiod.md) | :heavy_minus_sign: | The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. | +| `employeeCompensations` | [components.EmployeeCompensations](../../models/components/employeecompensations.md)[] | :heavy_check_mark: | N/A | +| `withholdingPayPeriod` | [components.WithholdingPayPeriod](../../models/components/withholdingpayperiod.md) | :heavy_minus_sign: | The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. | | `skipRegularDeductions` | *boolean* | :heavy_minus_sign: | Block regular deductions and contributions for this payroll. Only relevant for off-cycle payrolls. | | `fixedWithholdingRate` | *boolean* | :heavy_minus_sign: | Enable taxes to be withheld at the IRS's required rate of 22% for federal income taxes. State income taxes will be taxed at the state's supplemental tax rate. Otherwise, we'll sum the entirety of the employee's wages and withhold taxes on the entire amount at the rate for regular wages. Only relevant for off-cycle payrolls. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/fixedcompensations.md b/gusto_embedded/docs/models/components/payrollupdatefixedcompensations.md similarity index 92% rename from gusto_embedded/docs/models/operations/fixedcompensations.md rename to gusto_embedded/docs/models/components/payrollupdatefixedcompensations.md index 2253de82..9e7dd229 100644 --- a/gusto_embedded/docs/models/operations/fixedcompensations.md +++ b/gusto_embedded/docs/models/components/payrollupdatefixedcompensations.md @@ -1,13 +1,13 @@ -# FixedCompensations +# PayrollUpdateFixedCompensations An array of fixed compensations for the employee. Fixed compensations include tips, bonuses, and one time reimbursements. ## Example Usage ```typescript -import { FixedCompensations } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; +import { PayrollUpdateFixedCompensations } from "@gusto/embedded-api/models/components/payrollupdate.js"; -let value: FixedCompensations = {}; +let value: PayrollUpdateFixedCompensations = {}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/hourlycompensations.md b/gusto_embedded/docs/models/components/payrollupdatehourlycompensations.md similarity index 92% rename from gusto_embedded/docs/models/operations/hourlycompensations.md rename to gusto_embedded/docs/models/components/payrollupdatehourlycompensations.md index 0104dc22..35e5cfb0 100644 --- a/gusto_embedded/docs/models/operations/hourlycompensations.md +++ b/gusto_embedded/docs/models/components/payrollupdatehourlycompensations.md @@ -1,13 +1,13 @@ -# HourlyCompensations +# PayrollUpdateHourlyCompensations An array of hourly compensations for the employee. Hourly compensations include regular, overtime, and double overtime hours. ## Example Usage ```typescript -import { HourlyCompensations } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; +import { PayrollUpdateHourlyCompensations } from "@gusto/embedded-api/models/components/payrollupdate.js"; -let value: HourlyCompensations = {}; +let value: PayrollUpdateHourlyCompensations = {}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/paidtimeoff.md b/gusto_embedded/docs/models/components/payrollupdatepaidtimeoff.md similarity index 95% rename from gusto_embedded/docs/models/operations/paidtimeoff.md rename to gusto_embedded/docs/models/components/payrollupdatepaidtimeoff.md index 92099f44..776deb49 100644 --- a/gusto_embedded/docs/models/operations/paidtimeoff.md +++ b/gusto_embedded/docs/models/components/payrollupdatepaidtimeoff.md @@ -1,11 +1,11 @@ -# PaidTimeOff +# PayrollUpdatePaidTimeOff ## Example Usage ```typescript -import { PaidTimeOff } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; +import { PayrollUpdatePaidTimeOff } from "@gusto/embedded-api/models/components/payrollupdate.js"; -let value: PaidTimeOff = {}; +let value: PayrollUpdatePaidTimeOff = {}; ``` ## Fields diff --git a/gusto_embedded/docs/models/components/payrollupdatepaymentmethod.md b/gusto_embedded/docs/models/components/payrollupdatepaymentmethod.md new file mode 100644 index 00000000..b3655dc2 --- /dev/null +++ b/gusto_embedded/docs/models/components/payrollupdatepaymentmethod.md @@ -0,0 +1,17 @@ +# PayrollUpdatePaymentMethod + +The employee's compensation payment method. Invalid values will be ignored. + +## Example Usage + +```typescript +import { PayrollUpdatePaymentMethod } from "@gusto/embedded-api/models/components/payrollupdate.js"; + +let value: PayrollUpdatePaymentMethod = "Check"; +``` + +## Values + +```typescript +"Direct Deposit" | "Check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payschedulelist.md b/gusto_embedded/docs/models/components/payschedulelist.md index 6f6f744d..f66c30b4 100644 --- a/gusto_embedded/docs/models/components/payschedulelist.md +++ b/gusto_embedded/docs/models/components/payschedulelist.md @@ -8,23 +8,23 @@ The representation of a pay schedule. import { PayScheduleList } from "@gusto/embedded-api/models/components/payschedulelist.js"; let value: PayScheduleList = { - uuid: "7b46096a-061f-4508-b4ca-fc903bd2f7f7", - version: "", + uuid: "ea0857cd-d436-4328-b0af-2de988945e91", + version: "56d00c178bc7393b2a206ed6a86afcb4", }; ``` ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `uuid` | *string* | :heavy_check_mark: | The unique identifier of the pay schedule in Gusto. | -| `frequency` | [components.PayScheduleFrequency](../../models/components/payschedulefrequency.md) | :heavy_minus_sign: | The frequency that employees on this pay schedule are paid with Gusto. | -| `anchorPayDate` | *string* | :heavy_minus_sign: | The first date that employees on this pay schedule are paid with Gusto. | -| `anchorEndOfPayPeriod` | *string* | :heavy_minus_sign: | The last date of the first pay period. This can be the same date as the anchor pay date. | -| `day1` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the first day of the month that employees are paid. This field is only relevant for pay schedules with the “Twice per month” and “Monthly” frequencies. It will be null for pay schedules with other frequencies. | -| `day2` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the second day of the month that employees are paid. This field is the second pay date for pay schedules with the "Twice per month" frequency. For semi-monthly pay schedules, this field should be set to 31. For months shorter than 31 days, we will set the second pay date to the last day of the month. It will be null for pay schedules with other frequencies. | -| `name` | *string* | :heavy_minus_sign: | This field will be hourly when the pay schedule is for hourly employees, salaried when the pay schedule is for salaried employees, the department name if pay schedule is by department, and null when the pay schedule is for all employees. | -| `customName` | *string* | :heavy_minus_sign: | A custom name for a pay schedule, defaults to the pay frequency description. | -| `autoPilot` | *boolean* | :heavy_minus_sign: | With Autopilot® enabled, payroll will run automatically one day before your payroll deadlines. | -| `active` | *boolean* | :heavy_minus_sign: | Whether this pay schedule is associated with any employees. A pay schedule is inactive when it's unassigned. | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | \ No newline at end of file +| Field | Type | Required | Description | Example | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `uuid` | *string* | :heavy_check_mark: | The unique identifier of the pay schedule in Gusto. | | +| `frequency` | [components.PayScheduleFrequency](../../models/components/payschedulefrequency.md) | :heavy_minus_sign: | The frequency that employees on this pay schedule are paid with Gusto. | | +| `anchorPayDate` | *string* | :heavy_minus_sign: | The first date that employees on this pay schedule are paid with Gusto. | | +| `anchorEndOfPayPeriod` | *string* | :heavy_minus_sign: | The last date of the first pay period. This can be the same date as the anchor pay date. | | +| `day1` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the first day of the month that employees are paid. This field is only relevant for pay schedules with the “Twice per month” and “Monthly” frequencies. It will be null for pay schedules with other frequencies. | | +| `day2` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the second day of the month that employees are paid. This field is the second pay date for pay schedules with the "Twice per month" frequency. For semi-monthly pay schedules, this field should be set to 31. For months shorter than 31 days, we will set the second pay date to the last day of the month. It will be null for pay schedules with other frequencies. | | +| `name` | *string* | :heavy_minus_sign: | This field will be hourly when the pay schedule is for hourly employees, salaried when the pay schedule is for salaried employees, the department name if pay schedule is by department, and null when the pay schedule is for all employees. | | +| `customName` | *string* | :heavy_minus_sign: | A custom name for a pay schedule, defaults to the pay frequency description. | | +| `autoPilot` | *boolean* | :heavy_minus_sign: | With Autopilot® enabled, payroll will run automatically one day before your payroll deadlines. | | +| `active` | *boolean* | :heavy_minus_sign: | Whether this pay schedule is associated with any employees. A pay schedule is inactive when it's unassigned. | | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/payscheduleobject.md b/gusto_embedded/docs/models/components/payscheduleobject.md index acb43635..baa85419 100644 --- a/gusto_embedded/docs/models/components/payscheduleobject.md +++ b/gusto_embedded/docs/models/components/payscheduleobject.md @@ -8,23 +8,23 @@ The representation of a pay schedule. import { PayScheduleObject } from "@gusto/embedded-api/models/components/payscheduleobject.js"; let value: PayScheduleObject = { - uuid: "70d5a2d4-83b7-472c-9126-9f1adef68cc2", - version: "", + uuid: "35bffac9-552b-4520-bc33-4766373a3eea", + version: "56d00c178bc7393b2a206ed6a86afcb4", }; ``` ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `uuid` | *string* | :heavy_check_mark: | The unique identifier of the pay schedule in Gusto. | -| `frequency` | [components.PayScheduleFrequency](../../models/components/payschedulefrequency.md) | :heavy_minus_sign: | The frequency that employees on this pay schedule are paid with Gusto. | -| `anchorPayDate` | *string* | :heavy_minus_sign: | The first date that employees on this pay schedule are paid with Gusto. | -| `anchorEndOfPayPeriod` | *string* | :heavy_minus_sign: | The last date of the first pay period. This can be the same date as the anchor pay date. | -| `day1` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the first day of the month that employees are paid. This field is only relevant for pay schedules with the “Twice per month” and “Monthly” frequencies. It will be null for pay schedules with other frequencies. | -| `day2` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the second day of the month that employees are paid. This field is the second pay date for pay schedules with the "Twice per month" frequency. For semi-monthly pay schedules, this field should be set to 31. For months shorter than 31 days, we will set the second pay date to the last day of the month. It will be null for pay schedules with other frequencies. | -| `name` | *string* | :heavy_minus_sign: | This field will be hourly when the pay schedule is for hourly employees, salaried when the pay schedule is for salaried employees, the department name if pay schedule is by department, and null when the pay schedule is for all employees. | -| `customName` | *string* | :heavy_minus_sign: | A custom name for a pay schedule, defaults to the pay frequency description. | -| `autoPilot` | *boolean* | :heavy_minus_sign: | With Autopilot® enabled, payroll will run automatically one day before your payroll deadlines. | -| `active` | *boolean* | :heavy_minus_sign: | Whether this pay schedule is associated with any employees. A pay schedule is inactive when it's unassigned. | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | \ No newline at end of file +| Field | Type | Required | Description | Example | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `uuid` | *string* | :heavy_check_mark: | The unique identifier of the pay schedule in Gusto. | | +| `frequency` | [components.PayScheduleFrequency](../../models/components/payschedulefrequency.md) | :heavy_minus_sign: | The frequency that employees on this pay schedule are paid with Gusto. | | +| `anchorPayDate` | *string* | :heavy_minus_sign: | The first date that employees on this pay schedule are paid with Gusto. | | +| `anchorEndOfPayPeriod` | *string* | :heavy_minus_sign: | The last date of the first pay period. This can be the same date as the anchor pay date. | | +| `day1` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the first day of the month that employees are paid. This field is only relevant for pay schedules with the “Twice per month” and “Monthly” frequencies. It will be null for pay schedules with other frequencies. | | +| `day2` | *number* | :heavy_minus_sign: | An integer between 1 and 31 indicating the second day of the month that employees are paid. This field is the second pay date for pay schedules with the "Twice per month" frequency. For semi-monthly pay schedules, this field should be set to 31. For months shorter than 31 days, we will set the second pay date to the last day of the month. It will be null for pay schedules with other frequencies. | | +| `name` | *string* | :heavy_minus_sign: | This field will be hourly when the pay schedule is for hourly employees, salaried when the pay schedule is for salaried employees, the department name if pay schedule is by department, and null when the pay schedule is for all employees. | | +| `customName` | *string* | :heavy_minus_sign: | A custom name for a pay schedule, defaults to the pay frequency description. | | +| `autoPilot` | *boolean* | :heavy_minus_sign: | With Autopilot® enabled, payroll will run automatically one day before your payroll deadlines. | | +| `active` | *boolean* | :heavy_minus_sign: | Whether this pay schedule is associated with any employees. A pay schedule is inactive when it's unassigned. | | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/showemployees.md b/gusto_embedded/docs/models/components/showemployees.md new file mode 100644 index 00000000..0ba01920 --- /dev/null +++ b/gusto_embedded/docs/models/components/showemployees.md @@ -0,0 +1,83 @@ +# ShowEmployees + +The representation of an employee in Gusto. + +## Example Usage + +```typescript +import { ShowEmployees } from "@gusto/embedded-api/models/components/showemployees.js"; + +let value: ShowEmployees = { + uuid: "6cb68c04-1b94-4d92-844c-aea162aa3227", + firstName: "Evert", + lastName: "White", + eligiblePaidTimeOff: [ + { + accrualUnit: "Hour", + accrualMethod: "unlimited", + accrualPeriod: "Year", + }, + ], + currentHomeAddress: { + street1: "412 Kiera Stravenue", + street2: "Suite 391", + city: "San Francisco", + state: "CA", + zip: "94107", + active: true, + }, + allHomeAddresses: [ + { + street1: "412 Kiera Stravenue", + street2: "Suite 391", + city: "San Francisco", + state: "CA", + zip: "94107", + active: true, + }, + ], +}; +``` + +## Fields + +| Field | Type | Required | Description | Example | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `uuid` | *string* | :heavy_check_mark: | The UUID of the employee in Gusto. | | +| `firstName` | *string* | :heavy_check_mark: | N/A | | +| `middleInitial` | *string* | :heavy_minus_sign: | N/A | | +| `lastName` | *string* | :heavy_check_mark: | N/A | | +| `email` | *string* | :heavy_minus_sign: | The personal email address of the employee. This is provided to support syncing users between our system and yours. You may not use this email address for any other purpose (e.g. marketing). | | +| `companyUuid` | *string* | :heavy_minus_sign: | The UUID of the company the employee is employed by. | | +| `managerUuid` | *string* | :heavy_minus_sign: | The UUID of the employee's manager. | | +| `version` | *string* | :heavy_minus_sign: | The current version of the employee. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | | +| `department` | *string* | :heavy_minus_sign: | The employee's department in the company. | | +| `terminated` | *boolean* | :heavy_minus_sign: | Whether the employee is terminated. | | +| `twoPercentShareholder` | *boolean* | :heavy_minus_sign: | Whether the employee is a two percent shareholder of the company. This field only applies to companies with an S-Corp entity type. | | +| `workEmail` | *string* | :heavy_minus_sign: | The work email address of the employee. This is provided to support syncing users between our system and yours. You may not use this email address for any other purpose (e.g. marketing). | | +| `onboarded` | *boolean* | :heavy_minus_sign: | Whether the employee has completed onboarding. | | +| `onboardingStatus` | [components.OnboardingStatus](../../models/components/onboardingstatus.md) | :heavy_minus_sign: | The current onboarding status of the employee | | +| `onboardingDocumentsConfig` | [components.OnboardingDocumentsConfig](../../models/components/onboardingdocumentsconfig.md) | :heavy_minus_sign: | Configuration for an employee onboarding documents during onboarding | | +| `jobs` | [components.Job](../../models/components/job.md)[] | :heavy_minus_sign: | N/A | | +| `eligiblePaidTimeOff` | [components.PaidTimeOff](../../models/components/paidtimeoff.md)[] | :heavy_minus_sign: | N/A | | +| `terminations` | [components.Termination](../../models/components/termination.md)[] | :heavy_minus_sign: | N/A | | +| `garnishments` | [components.Garnishment](../../models/components/garnishment.md)[] | :heavy_minus_sign: | N/A | | +| `customFields` | [components.EmployeeCustomField](../../models/components/employeecustomfield.md)[] | :heavy_minus_sign: | Custom fields are only included for the employee if the include param has the custom_fields value set | | +| `dateOfBirth` | *string* | :heavy_minus_sign: | N/A | | +| `hasSsn` | *boolean* | :heavy_minus_sign: | Indicates whether the employee has an SSN in Gusto. | | +| `ssn` | *string* | :heavy_minus_sign: | Deprecated. This field always returns an empty string. | | +| `phone` | *string* | :heavy_minus_sign: | N/A | | +| `preferredFirstName` | *string* | :heavy_minus_sign: | N/A | | +| `paymentMethod` | [components.PaymentMethod](../../models/components/paymentmethod.md) | :heavy_minus_sign: | The employee's payment method | | +| `currentEmploymentStatus` | [components.CurrentEmploymentStatus](../../models/components/currentemploymentstatus.md) | :heavy_minus_sign: | The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. | | +| `historical` | *boolean* | :heavy_minus_sign: | N/A | | +| `employeeCode` | *string* | :heavy_minus_sign: | The short format code of the employee | | +| `departmentUuid` | *string* | :heavy_minus_sign: | The UUID of the department the employee is under | | +| `title` | *string* | :heavy_minus_sign: | N/A | | +| `hiredAt` | [RFCDate](../../types/rfcdate.md) | :heavy_minus_sign: | The date when the employee was hired to the company | | +| `hiddenSsn` | *string* | :heavy_minus_sign: | N/A | | +| `flsaStatus` | [components.FlsaStatusType](../../models/components/flsastatustype.md) | :heavy_minus_sign: | The FLSA status for this compensation. Salaried ('Exempt') employees are paid a fixed salary every pay period. Salaried with overtime ('Salaried Nonexempt') employees are paid a fixed salary every pay period, and receive overtime pay when applicable. Hourly ('Nonexempt') employees are paid for the hours they work, and receive overtime pay when applicable. Commissioned employees ('Commission Only Exempt') earn wages based only on commission. Commissioned with overtime ('Commission Only Nonexempt') earn wages based on commission, and receive overtime pay when applicable. Owners ('Owner') are employees that own at least twenty percent of the company. | | +| `applicableTaxIds` | *number*[] | :heavy_minus_sign: | N/A | | +| `currentHomeAddress` | [components.EmployeeHomeAddress](../../models/components/employeehomeaddress.md) | :heavy_minus_sign: | N/A | {
"street_1": "412 Kiera Stravenue",
"street_2": "Suite 391",
"city": "San Francisco",
"state": "CA",
"zip": "94107",
"country": "USA",
"active": true,
"uiud": "sample-uuid-123231"
} | +| `allHomeAddresses` | [components.EmployeeHomeAddress](../../models/components/employeehomeaddress.md)[] | :heavy_minus_sign: | N/A | | +| `additionalProperties` | Record | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/tiers.md b/gusto_embedded/docs/models/components/tiers.md index e5ffef95..f341d5e2 100644 --- a/gusto_embedded/docs/models/components/tiers.md +++ b/gusto_embedded/docs/models/components/tiers.md @@ -12,8 +12,8 @@ let value: Tiers = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | -| `threshold` | *string* | :heavy_minus_sign: | The percentage threshold at which this tier ends (inclusive).

For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll.

If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. | -| `thresholdDelta` | *string* | :heavy_minus_sign: | The step up difference between this tier's threshold and the previous tier's threshold. In the first tier, this is equivalent to threshold. | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | +| `threshold` | *string* | :heavy_minus_sign: | Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to.

Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards.

For example:

If the first tier has a threshold of "3", and `rate` of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll.

If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. | +| `thresholdDelta` | *string* | :heavy_minus_sign: | The step up difference between this tier's threshold and the previous tier's threshold. In the first tier, this is equivalent to threshold. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/valuetiers.md b/gusto_embedded/docs/models/components/valuetiers.md index a3085adb..d8e75d79 100644 --- a/gusto_embedded/docs/models/components/valuetiers.md +++ b/gusto_embedded/docs/models/components/valuetiers.md @@ -12,8 +12,8 @@ let value: ValueTiers = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | -| `threshold` | *string* | :heavy_minus_sign: | The percentage threshold at which this tier ends (inclusive).

For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll.

If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. | -| `thresholdDelta` | *string* | :heavy_minus_sign: | The step up difference between this tier's threshold and the previous tier's threshold. In the first tier, this is equivalent to threshold. | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | +| `threshold` | *string* | :heavy_minus_sign: | Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to.

Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards.

For example:

If the first tier has a threshold of "3", and `rate` of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll.

If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. | +| `thresholdDelta` | *string* | :heavy_minus_sign: | The step up difference between this tier's threshold and the previous tier's threshold. In the first tier, this is equivalent to threshold. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/components/withholdingpayperiod.md b/gusto_embedded/docs/models/components/withholdingpayperiod.md new file mode 100644 index 00000000..f50929a0 --- /dev/null +++ b/gusto_embedded/docs/models/components/withholdingpayperiod.md @@ -0,0 +1,17 @@ +# WithholdingPayPeriod + +The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. + +## Example Usage + +```typescript +import { WithholdingPayPeriod } from "@gusto/embedded-api/models/components/payrollupdate.js"; + +let value: WithholdingPayPeriod = "Semiannually"; +``` + +## Values + +```typescript +"Every week" | "Every other week" | "Twice per month" | "Monthly" | "Quarterly" | "Semiannually" | "Annually" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/aggregation.md b/gusto_embedded/docs/models/operations/aggregation.md index 99fca0a2..8a9f4151 100644 --- a/gusto_embedded/docs/models/operations/aggregation.md +++ b/gusto_embedded/docs/models/operations/aggregation.md @@ -7,11 +7,11 @@ The breakdown of the report. Use 'default' for no split. ```typescript import { Aggregation } from "@gusto/embedded-api/models/operations/postpayrollspayrolluuidreportsgeneralledger.js"; -let value: Aggregation = "job"; +let value: Aggregation = "department"; ``` ## Values ```typescript -"default" | "job" | "department" +"default" | "job" | "department" | "integration" ``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/deletev1companiescompanyidpayrollsheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/deletev1companiescompanyidpayrollsheaderxgustoapiversion.md new file mode 100644 index 00000000..cbff2a10 --- /dev/null +++ b/gusto_embedded/docs/models/operations/deletev1companiescompanyidpayrollsheaderxgustoapiversion.md @@ -0,0 +1,18 @@ +# DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/deletev1companiescompanyidpayrolls.js"; + +let value: DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion = + "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/deletev1companiescompanyidpayrollsrequest.md b/gusto_embedded/docs/models/operations/deletev1companiescompanyidpayrollsrequest.md index 8935e5c2..a054ba58 100644 --- a/gusto_embedded/docs/models/operations/deletev1companiescompanyidpayrollsrequest.md +++ b/gusto_embedded/docs/models/operations/deletev1companiescompanyidpayrollsrequest.md @@ -18,4 +18,4 @@ let value: DeleteV1CompaniesCompanyIdPayrollsRequest = { | `companyId` | *string* | :heavy_check_mark: | The UUID of the company | | `payrollId` | *string* | :heavy_check_mark: | The UUID of the payroll | | `async` | *boolean* | :heavy_minus_sign: | When true, request an asynchronous delete of the payroll. | -| `xGustoAPIVersion` | [components.VersionHeader](../../models/components/versionheader.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | \ No newline at end of file +| `xGustoAPIVersion` | [operations.DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion](../../models/operations/deletev1companiescompanyidpayrollsheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/disbursements.md b/gusto_embedded/docs/models/operations/disbursements.md new file mode 100644 index 00000000..933b96bf --- /dev/null +++ b/gusto_embedded/docs/models/operations/disbursements.md @@ -0,0 +1,19 @@ +# Disbursements + +## Example Usage + +```typescript +import { Disbursements } from "@gusto/embedded-api/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: Disbursements = { + contractorPaymentUuid: "9f8e7d6c-5b4a-3928-1c2d-3e4f5a6b7c8d", +}; +``` + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `contractorPaymentUuid` | *string* | :heavy_check_mark: | UUID of the contractor payment | 9f8e7d6c-5b4a-3928-1c2d-3e4f5a6b7c8d | +| `paymentMethod` | [operations.PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod](../../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementspaymentmethod.md) | :heavy_minus_sign: | Payment method for the contractor | | +| `paymentStatus` | [operations.PaymentStatus](../../models/operations/paymentstatus.md) | :heavy_minus_sign: | Status of the payment disbursement | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/employeecompensations.md b/gusto_embedded/docs/models/operations/employeecompensations.md deleted file mode 100644 index 72deeec9..00000000 --- a/gusto_embedded/docs/models/operations/employeecompensations.md +++ /dev/null @@ -1,22 +0,0 @@ -# EmployeeCompensations - -## Example Usage - -```typescript -import { EmployeeCompensations } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; - -let value: EmployeeCompensations = {}; -``` - -## Fields - -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `employeeUuid` | *string* | :heavy_minus_sign: | The UUID of the employee. | -| `version` | *string* | :heavy_minus_sign: | The current version of this employee compensation from the prepared payroll. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `excluded` | *boolean* | :heavy_minus_sign: | This employee will be excluded from payroll calculation and will not be paid for the payroll. | -| `paymentMethod` | [operations.PaymentMethod](../../models/operations/paymentmethod.md) | :heavy_minus_sign: | The employee's compensation payment method. Invalid values will be ignored. | -| `memo` | *string* | :heavy_minus_sign: | Custom text that will be printed as a personal note to the employee on a paystub. | -| `fixedCompensations` | [operations.FixedCompensations](../../models/operations/fixedcompensations.md)[] | :heavy_minus_sign: | N/A | -| `hourlyCompensations` | [operations.HourlyCompensations](../../models/operations/hourlycompensations.md)[] | :heavy_minus_sign: | N/A | -| `paidTimeOff` | [operations.PaidTimeOff](../../models/operations/paidtimeoff.md)[] | :heavy_minus_sign: | An array of all paid time off the employee is eligible for this pay period. Each paid time off object can be the name or the specific policy_uuid. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesrequest.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesrequest.md index 31527902..960062f9 100644 --- a/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesrequest.md +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesrequest.md @@ -19,5 +19,6 @@ let value: GetV1CompaniesCompanyIdEmployeesRequest = { | `searchTerm` | *string* | :heavy_minus_sign: | A string to search for in the object's names | | `include` | [operations.Include](../../models/operations/include.md)[] | :heavy_minus_sign: | Include the requested attribute(s) in each employee response, multiple options are comma separated. Available options:
- all_compensations: Include all effective dated compensations for each job instead of only the current compensation
- custom_fields: Include employees' custom fields
| | `terminated` | *boolean* | :heavy_minus_sign: | Filters employees by the provided boolean | +| `uuids` | *string*[] | :heavy_minus_sign: | Optional subset of employees to fetch. | | `page` | *number* | :heavy_minus_sign: | The page that is requested. When unspecified, will load all objects unless endpoint forces pagination. | | `per` | *number* | :heavy_minus_sign: | Number of objects per page. For majority of endpoints will default to 25 | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesresponse.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesresponse.md index 9c8fc34f..e0b14c9b 100644 --- a/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesresponse.md +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidemployeesresponse.md @@ -10,7 +10,7 @@ let value: GetV1CompaniesCompanyIdEmployeesResponse = {}; ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | -| `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | -| `employees` | [components.Employee](../../models/components/employee.md)[] | :heavy_minus_sign: | successful | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | +| `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | +| `showEmployees` | [components.ShowEmployees](../../models/components/showemployees.md)[] | :heavy_minus_sign: | successful | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md new file mode 100644 index 00000000..ce5c2341 --- /dev/null +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md @@ -0,0 +1,19 @@ +# GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion = + "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md new file mode 100644 index 00000000..db612bff --- /dev/null +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md @@ -0,0 +1,20 @@ +# GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest + +## Example Usage + +```typescript +import { GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest } from "@gusto/embedded-api/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest = { + companyId: "", + id: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `companyId` | *string* | :heavy_check_mark: | The UUID of the company | +| `id` | *string* | :heavy_check_mark: | The UUID of the payroll | +| `xGustoAPIVersion` | [operations.GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion](../../models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md new file mode 100644 index 00000000..a4f80fc9 --- /dev/null +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md @@ -0,0 +1,16 @@ +# GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse + +## Example Usage + +```typescript +import { GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse } from "@gusto/embedded-api/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | +| `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | +| `payrollPartnerDisbursements` | [components.PayrollPartnerDisbursements](../../models/components/payrollpartnerdisbursements.md) | :heavy_minus_sign: | successful | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidheaderxgustoapiversion.md new file mode 100644 index 00000000..b46ceca6 --- /dev/null +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidheaderxgustoapiversion.md @@ -0,0 +1,18 @@ +# GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/getv1companiescompanyidpayrollspayrollid.js"; + +let value: GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion = + "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidqueryparaminclude.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidqueryparaminclude.md index d5acdd46..8970871e 100644 --- a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidqueryparaminclude.md +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidqueryparaminclude.md @@ -12,5 +12,5 @@ let value: GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude = ## Values ```typescript -"benefits" | "deductions" | "taxes" | "payroll_status_meta" +"benefits" | "deductions" | "taxes" | "payroll_status_meta" | "totals" | "risk_blockers" | "reversals" ``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidrequest.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidrequest.md index ab0477eb..4beaa94f 100644 --- a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidrequest.md +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidrequest.md @@ -17,5 +17,5 @@ let value: GetV1CompaniesCompanyIdPayrollsPayrollIdRequest = { | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `companyId` | *string* | :heavy_check_mark: | The UUID of the company | | `payrollId` | *string* | :heavy_check_mark: | The UUID of the payroll | -| `include` | [operations.GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude](../../models/operations/getv1companiescompanyidpayrollspayrollidqueryparaminclude.md)[] | :heavy_minus_sign: | Include the requested attribute in the response, for multiple attributes comma separate the values, i.e. `?include=benefits,deductions,taxes` | -| `xGustoAPIVersion` | [components.VersionHeader](../../models/components/versionheader.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | \ No newline at end of file +| `xGustoAPIVersion` | [operations.GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion](../../models/operations/getv1companiescompanyidpayrollspayrollidheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | +| `include` | [operations.GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude](../../models/operations/getv1companiescompanyidpayrollspayrollidqueryparaminclude.md)[] | :heavy_minus_sign: | Include the requested attribute in the response, for multiple attributes comma separate the values, i.e. `?include=benefits,deductions,taxes` | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidresponse.md b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidresponse.md index 43e561c3..aef9ff24 100644 --- a/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidresponse.md +++ b/gusto_embedded/docs/models/operations/getv1companiescompanyidpayrollspayrollidresponse.md @@ -13,4 +13,4 @@ let value: GetV1CompaniesCompanyIdPayrollsPayrollIdResponse = {}; | Field | Type | Required | Description | | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | | `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | -| `payroll` | [components.Payroll](../../models/components/payroll.md) | :heavy_minus_sign: | Example response | \ No newline at end of file +| `payroll` | [components.Payroll](../../models/components/payroll.md) | :heavy_minus_sign: | successful | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md new file mode 100644 index 00000000..bf31a1f1 --- /dev/null +++ b/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md @@ -0,0 +1,19 @@ +# GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion = + "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsrequest.md b/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsrequest.md new file mode 100644 index 00000000..ecddacf2 --- /dev/null +++ b/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsrequest.md @@ -0,0 +1,18 @@ +# GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest + +## Example Usage + +```typescript +import { GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest } from "@gusto/embedded-api/models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest = { + id: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The UUID of the contractor payment group | +| `xGustoAPIVersion` | [operations.GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion](../../models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsresponse.md b/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsresponse.md new file mode 100644 index 00000000..9f68bbdc --- /dev/null +++ b/gusto_embedded/docs/models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsresponse.md @@ -0,0 +1,16 @@ +# GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse + +## Example Usage + +```typescript +import { GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse } from "@gusto/embedded-api/models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | +| `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | +| `contractorPaymentGroupPartnerDisbursements` | [components.ContractorPaymentGroupPartnerDisbursements](../../models/components/contractorpaymentgrouppartnerdisbursements.md) | :heavy_minus_sign: | successful | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesheaderxgustoapiversion.md index 421b5a9a..1faed170 100644 --- a/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesheaderxgustoapiversion.md +++ b/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesheaderxgustoapiversion.md @@ -1,6 +1,6 @@ # GetV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion -Determines the date-based API version associated with your API call. +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. ## Example Usage diff --git a/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesrequest.md b/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesrequest.md index abe73cd1..184dc9b4 100644 --- a/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesrequest.md +++ b/gusto_embedded/docs/models/operations/getv1employeesemployeeidstatetaxesrequest.md @@ -12,7 +12,7 @@ let value: GetV1EmployeesEmployeeIdStateTaxesRequest = { ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `xGustoAPIVersion` | [operations.GetV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion](../../models/operations/getv1employeesemployeeidstatetaxesheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. | -| `employeeUuid` | *string* | :heavy_check_mark: | The UUID of the employee | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `xGustoAPIVersion` | [operations.GetV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion](../../models/operations/getv1employeesemployeeidstatetaxesheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | +| `employeeUuid` | *string* | :heavy_check_mark: | The UUID of the employee | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/integrationtype.md b/gusto_embedded/docs/models/operations/integrationtype.md new file mode 100644 index 00000000..2a424313 --- /dev/null +++ b/gusto_embedded/docs/models/operations/integrationtype.md @@ -0,0 +1,17 @@ +# IntegrationType + +The kind of integration set up for the company. Required when `aggregation` is 'integration'. Must be null if `aggregation` is not 'integration'. + +## Example Usage + +```typescript +import { IntegrationType } from "@gusto/embedded-api/models/operations/postpayrollspayrolluuidreportsgeneralledger.js"; + +let value: IntegrationType = "qbo"; +``` + +## Values + +```typescript +"xero" | "qbo" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsdisbursements.md b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsdisbursements.md new file mode 100644 index 00000000..e47ad0fc --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsdisbursements.md @@ -0,0 +1,20 @@ +# PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements + +## Example Usage + +```typescript +import { PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements } from "@gusto/embedded-api/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements = { + employeeUuid: "1a2b3c4d-5e6f-7890-abcd-ef1234567890", + }; +``` + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `employeeUuid` | *string* | :heavy_check_mark: | UUID of the employee | 1a2b3c4d-5e6f-7890-abcd-ef1234567890 | +| `paymentMethod` | [operations.PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod](../../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentmethod.md) | :heavy_minus_sign: | Payment method for the employee | | +| `paymentStatus` | [operations.PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus](../../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentstatus.md) | :heavy_minus_sign: | Status of the payment disbursement | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md new file mode 100644 index 00000000..732cdd61 --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md @@ -0,0 +1,19 @@ +# PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion = + "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentmethod.md b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentmethod.md new file mode 100644 index 00000000..d72a3ad9 --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentmethod.md @@ -0,0 +1,19 @@ +# PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod + +Payment method for the employee + +## Example Usage + +```typescript +import { PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod } from "@gusto/embedded-api/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod = + "Direct Deposit"; +``` + +## Values + +```typescript +"Direct Deposit" | "Check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentstatus.md b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentstatus.md new file mode 100644 index 00000000..a405ca76 --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementspaymentstatus.md @@ -0,0 +1,19 @@ +# PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus + +Status of the payment disbursement + +## Example Usage + +```typescript +import { PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus } from "@gusto/embedded-api/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus = + "Pending"; +``` + +## Values + +```typescript +"Pending" | "Paid" | "Not partner managed" | "Converted to check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md new file mode 100644 index 00000000..96ebf1dc --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md @@ -0,0 +1,21 @@ +# PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest + +## Example Usage + +```typescript +import { PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest } from "@gusto/embedded-api/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest = { + companyId: "", + id: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `companyId` | *string* | :heavy_check_mark: | The UUID of the company | +| `id` | *string* | :heavy_check_mark: | The UUID of the payroll | +| `xGustoAPIVersion` | [operations.PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion](../../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | +| `requestBody` | [operations.PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody](../../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequestbody.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequestbody.md b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequestbody.md new file mode 100644 index 00000000..d5472378 --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequestbody.md @@ -0,0 +1,22 @@ +# PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody + +## Example Usage + +```typescript +import { PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody } from "@gusto/embedded-api/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody = + { + disbursements: [ + { + employeeUuid: "1a2b3c4d-5e6f-7890-abcd-ef1234567890", + }, + ], + }; +``` + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `disbursements` | [operations.PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements](../../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsdisbursements.md)[] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md new file mode 100644 index 00000000..22eacb02 --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md @@ -0,0 +1,16 @@ +# PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse + +## Example Usage + +```typescript +import { PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse } from "@gusto/embedded-api/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; + +let value: PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | +| `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | +| `payrollPartnerDisbursements` | [components.PayrollPartnerDisbursements](../../models/components/payrollpartnerdisbursements.md) | :heavy_minus_sign: | successful | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md new file mode 100644 index 00000000..b9cbe4be --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md @@ -0,0 +1,19 @@ +# PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion = + "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementspaymentmethod.md b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementspaymentmethod.md new file mode 100644 index 00000000..788b3f68 --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementspaymentmethod.md @@ -0,0 +1,18 @@ +# PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod + +Payment method for the contractor + +## Example Usage + +```typescript +import { PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod } from "@gusto/embedded-api/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod = + "Check"; +``` + +## Values + +```typescript +"Direct Deposit" | "Check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequest.md b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequest.md new file mode 100644 index 00000000..f58bd425 --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequest.md @@ -0,0 +1,19 @@ +# PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest + +## Example Usage + +```typescript +import { PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest } from "@gusto/embedded-api/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest = { + id: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The UUID of the contractor payment group | +| `xGustoAPIVersion` | [operations.PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion](../../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | +| `requestBody` | [operations.PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody](../../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequestbody.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequestbody.md b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequestbody.md new file mode 100644 index 00000000..46673fed --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequestbody.md @@ -0,0 +1,17 @@ +# PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody + +## Example Usage + +```typescript +import { PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody } from "@gusto/embedded-api/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody = { + disbursements: [], +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | +| `disbursements` | [operations.Disbursements](../../models/operations/disbursements.md)[] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsresponse.md b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsresponse.md new file mode 100644 index 00000000..c272766c --- /dev/null +++ b/gusto_embedded/docs/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsresponse.md @@ -0,0 +1,16 @@ +# PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse + +## Example Usage + +```typescript +import { PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse } from "@gusto/embedded-api/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------ | +| `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | +| `contractorPaymentGroupPartnerDisbursements` | [components.ContractorPaymentGroupPartnerDisbursements](../../models/components/contractorpaymentgrouppartnerdisbursements.md) | :heavy_minus_sign: | successful | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/paymentmethod.md b/gusto_embedded/docs/models/operations/paymentmethod.md index ffceba11..cb1bbfaf 100644 --- a/gusto_embedded/docs/models/operations/paymentmethod.md +++ b/gusto_embedded/docs/models/operations/paymentmethod.md @@ -1,17 +1,15 @@ # PaymentMethod -The employee's compensation payment method. Invalid values will be ignored. - ## Example Usage ```typescript -import { PaymentMethod } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; +import { PaymentMethod } from "@gusto/embedded-api/models/operations/postv1companiescompanyidcontractorpayments.js"; -let value: PaymentMethod = "Check"; +let value: PaymentMethod = "Historical Payment"; ``` ## Values ```typescript -"Direct Deposit" | "Check" +"Direct Deposit" | "Check" | "Historical Payment" ``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/paymentstatus.md b/gusto_embedded/docs/models/operations/paymentstatus.md new file mode 100644 index 00000000..0cbe6801 --- /dev/null +++ b/gusto_embedded/docs/models/operations/paymentstatus.md @@ -0,0 +1,17 @@ +# PaymentStatus + +Status of the payment disbursement + +## Example Usage + +```typescript +import { PaymentStatus } from "@gusto/embedded-api/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; + +let value: PaymentStatus = "Not partner managed"; +``` + +## Values + +```typescript +"Pending" | "Paid" | "Not partner managed" | "Converted to check" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidholidaypaypolicyrequest.md b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidholidaypaypolicyrequest.md index f52466f6..c996cc52 100644 --- a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidholidaypaypolicyrequest.md +++ b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidholidaypaypolicyrequest.md @@ -7,6 +7,7 @@ import { PostCompaniesCompanyUuidHolidayPayPolicyRequest } from "@gusto/embedded let value: PostCompaniesCompanyUuidHolidayPayPolicyRequest = { companyUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidreportsrequest.md b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidreportsrequest.md index 86b411e7..b8109171 100644 --- a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidreportsrequest.md +++ b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidreportsrequest.md @@ -4,9 +4,19 @@ ```typescript import { PostCompaniesCompanyUuidReportsRequest } from "@gusto/embedded-api/models/operations/postcompaniescompanyuuidreports.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PostCompaniesCompanyUuidReportsRequest = { companyUuid: "", + requestBody: { + columns: [], + groupings: [], + fileType: "pdf", + startDate: new RFCDate("2024-01-01"), + endDate: new RFCDate("2024-04-01"), + dismissedStartDate: new RFCDate("2024-01-01"), + dismissedEndDate: new RFCDate("2024-04-01"), + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidsuspensionsrequest.md b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidsuspensionsrequest.md index c8a01bcf..330d0204 100644 --- a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidsuspensionsrequest.md +++ b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidsuspensionsrequest.md @@ -7,6 +7,12 @@ import { PostCompaniesCompanyUuidSuspensionsRequest } from "@gusto/embedded-api/ let value: PostCompaniesCompanyUuidSuspensionsRequest = { companyUuid: "", + requestBody: { + fileQuarterlyForms: true, + fileYearlyForms: false, + reconcileTaxMethod: "pay_taxes", + reason: "shutting_down", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidtimeoffpoliciesrequest.md b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidtimeoffpoliciesrequest.md index 2f12d99b..d088aee4 100644 --- a/gusto_embedded/docs/models/operations/postcompaniescompanyuuidtimeoffpoliciesrequest.md +++ b/gusto_embedded/docs/models/operations/postcompaniescompanyuuidtimeoffpoliciesrequest.md @@ -7,6 +7,11 @@ import { PostCompaniesCompanyUuidTimeOffPoliciesRequest } from "@gusto/embedded- let value: PostCompaniesCompanyUuidTimeOffPoliciesRequest = { companyUuid: "", + requestBody: { + name: "", + policyType: "", + accrualMethod: "per_calendar_year", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postcompaniespayrollskipcompanyuuidrequest.md b/gusto_embedded/docs/models/operations/postcompaniespayrollskipcompanyuuidrequest.md index e57a7a47..e248f337 100644 --- a/gusto_embedded/docs/models/operations/postcompaniespayrollskipcompanyuuidrequest.md +++ b/gusto_embedded/docs/models/operations/postcompaniespayrollskipcompanyuuidrequest.md @@ -7,6 +7,9 @@ import { PostCompaniesPayrollSkipCompanyUuidRequest } from "@gusto/embedded-api/ let value: PostCompaniesPayrollSkipCompanyUuidRequest = { companyUuid: "", + requestBody: { + payrollType: "Regular", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postdepartmentsrequest.md b/gusto_embedded/docs/models/operations/postdepartmentsrequest.md index 3ee7a219..b05ee460 100644 --- a/gusto_embedded/docs/models/operations/postdepartmentsrequest.md +++ b/gusto_embedded/docs/models/operations/postdepartmentsrequest.md @@ -7,6 +7,7 @@ import { PostDepartmentsRequest } from "@gusto/embedded-api/models/operations/po let value: PostDepartmentsRequest = { companyUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/postemployeeytdbenefitamountsfromdifferentcompanyrequest.md b/gusto_embedded/docs/models/operations/postemployeeytdbenefitamountsfromdifferentcompanyrequest.md index 5826cbd5..b4e27177 100644 --- a/gusto_embedded/docs/models/operations/postemployeeytdbenefitamountsfromdifferentcompanyrequest.md +++ b/gusto_embedded/docs/models/operations/postemployeeytdbenefitamountsfromdifferentcompanyrequest.md @@ -7,6 +7,9 @@ import { PostEmployeeYtdBenefitAmountsFromDifferentCompanyRequest } from "@gusto let value: PostEmployeeYtdBenefitAmountsFromDifferentCompanyRequest = { employeeId: "", + postEmployeeYtdBenefitAmountsFromDifferentCompany: { + taxYear: 7695.8, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidaccepttermsofservicerequest.md b/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidaccepttermsofservicerequest.md index 337f830d..1833b47a 100644 --- a/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidaccepttermsofservicerequest.md +++ b/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidaccepttermsofservicerequest.md @@ -7,6 +7,11 @@ import { PostPartnerManagedCompaniesCompanyUuidAcceptTermsOfServiceRequest } fro let value: PostPartnerManagedCompaniesCompanyUuidAcceptTermsOfServiceRequest = { companyUuid: "", + requestBody: { + email: "Selena76@hotmail.com", + ipAddress: "11.124.154.127", + externalUserId: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidretrievetermsofservicerequest.md b/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidretrievetermsofservicerequest.md index 1b50c4b8..77eda9b0 100644 --- a/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidretrievetermsofservicerequest.md +++ b/gusto_embedded/docs/models/operations/postpartnermanagedcompaniescompanyuuidretrievetermsofservicerequest.md @@ -8,6 +8,9 @@ import { PostPartnerManagedCompaniesCompanyUuidRetrieveTermsOfServiceRequest } f let value: PostPartnerManagedCompaniesCompanyUuidRetrieveTermsOfServiceRequest = { companyUuid: "", + requestBody: { + email: "Michael.Wilderman19@gmail.com", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postpayrollsgrossuppayrolluuidrequest.md b/gusto_embedded/docs/models/operations/postpayrollsgrossuppayrolluuidrequest.md index a53e10a6..d69ccb43 100644 --- a/gusto_embedded/docs/models/operations/postpayrollsgrossuppayrolluuidrequest.md +++ b/gusto_embedded/docs/models/operations/postpayrollsgrossuppayrolluuidrequest.md @@ -7,6 +7,10 @@ import { PostPayrollsGrossUpPayrollUuidRequest } from "@gusto/embedded-api/model let value: PostPayrollsGrossUpPayrollUuidRequest = { payrollUuid: "", + requestBody: { + employeeUuid: "", + netPay: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequest.md b/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequest.md index 25d6c144..effe2756 100644 --- a/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequest.md +++ b/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequest.md @@ -7,6 +7,9 @@ import { PostPayrollsPayrollUuidReportsGeneralLedgerRequest } from "@gusto/embed let value: PostPayrollsPayrollUuidReportsGeneralLedgerRequest = { payrollUuid: "", + requestBody: { + aggregation: "default", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequestbody.md b/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequestbody.md index 3319066f..56f761f2 100644 --- a/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequestbody.md +++ b/gusto_embedded/docs/models/operations/postpayrollspayrolluuidreportsgeneralledgerrequestbody.md @@ -12,6 +12,7 @@ let value: PostPayrollsPayrollUuidReportsGeneralLedgerRequestBody = { ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | -| `aggregation` | [operations.Aggregation](../../models/operations/aggregation.md) | :heavy_check_mark: | The breakdown of the report. Use 'default' for no split. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | +| `aggregation` | [operations.Aggregation](../../models/operations/aggregation.md) | :heavy_check_mark: | The breakdown of the report. Use 'default' for no split. | +| `integrationType` | [operations.IntegrationType](../../models/operations/integrationtype.md) | :heavy_minus_sign: | The kind of integration set up for the company. Required when `aggregation` is 'integration'. Must be null if `aggregation` is not 'integration'. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidadminsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidadminsrequest.md index 3bb0e217..cec85c02 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidadminsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidadminsrequest.md @@ -7,6 +7,11 @@ import { PostV1CompaniesCompanyIdAdminsRequest } from "@gusto/embedded-api/model let value: PostV1CompaniesCompanyIdAdminsRequest = { companyId: "", + requestBody: { + firstName: "Gudrun", + lastName: "Fahey", + email: "Vesta_Bogan70@gmail.com", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidbankaccountsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidbankaccountsrequest.md index 94e9ac31..1a1ef53b 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidbankaccountsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidbankaccountsrequest.md @@ -7,6 +7,7 @@ import { PostV1CompaniesCompanyIdBankAccountsRequest } from "@gusto/embedded-api let value: PostV1CompaniesCompanyIdBankAccountsRequest = { companyId: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidcompanybenefitsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidcompanybenefitsrequest.md index 4baad8a7..15551158 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidcompanybenefitsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidcompanybenefitsrequest.md @@ -7,6 +7,9 @@ import { PostV1CompaniesCompanyIdCompanyBenefitsRequest } from "@gusto/embedded- let value: PostV1CompaniesCompanyIdCompanyBenefitsRequest = { companyId: "", + requestBody: { + description: "psst afore although pushy colossal giggle optimistic", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupspreviewrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupspreviewrequest.md index 0dccf41e..6053cbd1 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupspreviewrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupspreviewrequest.md @@ -4,9 +4,15 @@ ```typescript import { PostV1CompaniesCompanyIdContractorPaymentGroupsPreviewRequest } from "@gusto/embedded-api/models/operations/postv1companiescompanyidcontractorpaymentgroupspreview.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PostV1CompaniesCompanyIdContractorPaymentGroupsPreviewRequest = { companyId: "", + requestBody: { + checkDate: new RFCDate("2020-01-01"), + creationToken: "1d532d13-8f61-4a57-ad3c-b5fac1c6e05e", + contractorPayments: [], + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupsrequest.md index e2a70ca3..dc42f596 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentgroupsrequest.md @@ -4,9 +4,15 @@ ```typescript import { PostV1CompaniesCompanyIdContractorPaymentGroupsRequest } from "@gusto/embedded-api/models/operations/postv1companiescompanyidcontractorpaymentgroups.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PostV1CompaniesCompanyIdContractorPaymentGroupsRequest = { companyId: "", + requestBody: { + checkDate: new RFCDate("2020-01-01"), + creationToken: "1d532d13-8f61-4a57-ad3c-b5fac1c6e05e", + contractorPayments: [], + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentspaymentmethod.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentspaymentmethod.md deleted file mode 100644 index b8aff28f..00000000 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentspaymentmethod.md +++ /dev/null @@ -1,15 +0,0 @@ -# PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod - -## Example Usage - -```typescript -import { PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod } from "@gusto/embedded-api/models/operations/postv1companiescompanyidcontractorpayments.js"; - -let value: PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod = "Check"; -``` - -## Values - -```typescript -"Direct Deposit" | "Check" | "Historical Payment" -``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequest.md index 5b1107f3..df3b04c9 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequest.md @@ -4,9 +4,18 @@ ```typescript import { PostV1CompaniesCompanyIdContractorPaymentsRequest } from "@gusto/embedded-api/models/operations/postv1companiescompanyidcontractorpayments.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PostV1CompaniesCompanyIdContractorPaymentsRequest = { companyId: "", + requestBody: { + contractorUuid: "", + date: new RFCDate("2020-01-01"), + wage: 5000, + hours: 40, + bonus: 500, + reimbursement: 20, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequestbody.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequestbody.md index 5a75c767..079abf81 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequestbody.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidcontractorpaymentsrequestbody.md @@ -18,12 +18,12 @@ let value: PostV1CompaniesCompanyIdContractorPaymentsRequestBody = { ## Fields -| Field | Type | Required | Description | Example | -| -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `contractorUuid` | *string* | :heavy_check_mark: | The contractor receiving the payment | | -| `date` | [RFCDate](../../types/rfcdate.md) | :heavy_check_mark: | Date of contractor payment | 2020-01-01 | -| `paymentMethod` | [operations.PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod](../../models/operations/postv1companiescompanyidcontractorpaymentspaymentmethod.md) | :heavy_minus_sign: | N/A | | -| `wage` | *number* | :heavy_minus_sign: | If the contractor is on a fixed wage, this is the fixed wage payment for the contractor, regardless of hours worked | 5000 | -| `hours` | *number* | :heavy_minus_sign: | If the contractor is on an hourly wage, this is the number of hours that the contractor worked for the payment | 40 | -| `bonus` | *number* | :heavy_minus_sign: | If the contractor is on an hourly wage, this is the bonus the contractor earned | 500 | -| `reimbursement` | *number* | :heavy_minus_sign: | Reimbursed wages for the contractor | 20 | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------- | +| `contractorUuid` | *string* | :heavy_check_mark: | The contractor receiving the payment | | +| `date` | [RFCDate](../../types/rfcdate.md) | :heavy_check_mark: | Date of contractor payment | 2020-01-01 | +| `paymentMethod` | [operations.PaymentMethod](../../models/operations/paymentmethod.md) | :heavy_minus_sign: | N/A | | +| `wage` | *number* | :heavy_minus_sign: | If the contractor is on a fixed wage, this is the fixed wage payment for the contractor, regardless of hours worked | 5000 | +| `hours` | *number* | :heavy_minus_sign: | If the contractor is on an hourly wage, this is the number of hours that the contractor worked for the payment | 40 | +| `bonus` | *number* | :heavy_minus_sign: | If the contractor is on an hourly wage, this is the bonus the contractor earned | 500 | +| `reimbursement` | *number* | :heavy_minus_sign: | Reimbursed wages for the contractor | 20 | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidearningtypesrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidearningtypesrequest.md index a938cfdd..d72c6d8c 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidearningtypesrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidearningtypesrequest.md @@ -7,6 +7,9 @@ import { PostV1CompaniesCompanyIdEarningTypesRequest } from "@gusto/embedded-api let value: PostV1CompaniesCompanyIdEarningTypesRequest = { companyId: "", + requestBody: { + name: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidlocationsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidlocationsrequest.md index c298081b..140c7e25 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidlocationsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidlocationsrequest.md @@ -7,6 +7,13 @@ import { PostV1CompaniesCompanyIdLocationsRequest } from "@gusto/embedded-api/mo let value: PostV1CompaniesCompanyIdLocationsRequest = { companyId: "", + requestBody: { + phoneNumber: "(584) 699-1419 x64119", + street1: "", + city: "Brianstad", + state: "Missouri", + zip: "44022-3912", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayrollsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayrollsrequest.md index 14f3b948..e45d61a4 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayrollsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayrollsrequest.md @@ -14,6 +14,6 @@ let value: PostV1CompaniesCompanyIdPayrollsRequest = { | Field | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `companyId` | *string* | :heavy_check_mark: | The UUID of the company | | `xGustoAPIVersion` | [operations.PostV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion](../../models/operations/postv1companiescompanyidpayrollsheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | +| `companyId` | *string* | :heavy_check_mark: | The UUID of the company | | `requestBody` | [operations.PostV1CompaniesCompanyIdPayrollsRequestBody](../../models/operations/postv1companiescompanyidpayrollsrequestbody.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignmentpreviewrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignmentpreviewrequest.md index 412133af..930e9329 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignmentpreviewrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignmentpreviewrequest.md @@ -7,6 +7,9 @@ import { PostV1CompaniesCompanyIdPaySchedulesAssignmentPreviewRequest } from "@g let value: PostV1CompaniesCompanyIdPaySchedulesAssignmentPreviewRequest = { companyId: "", + payScheduleAssignmentBody: { + type: "by_employee", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignrequest.md index d8e9c91e..7a79b507 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesassignrequest.md @@ -7,6 +7,9 @@ import { PostV1CompaniesCompanyIdPaySchedulesAssignRequest } from "@gusto/embedd let value: PostV1CompaniesCompanyIdPaySchedulesAssignRequest = { companyId: "", + payScheduleAssignmentBody: { + type: "by_employee", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesrequest.md index 17c1992a..87f5e072 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyidpayschedulesrequest.md @@ -7,6 +7,11 @@ import { PostV1CompaniesCompanyIdPaySchedulesRequest } from "@gusto/embedded-api let value: PostV1CompaniesCompanyIdPaySchedulesRequest = { companyId: "", + requestBody: { + frequency: "Every week", + anchorPayDate: "2020-05-15", + anchorEndOfPayPeriod: "2020-05-08", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyuuidcontractorsrequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyuuidcontractorsrequest.md index 40590447..965ba1ec 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyuuidcontractorsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyuuidcontractorsrequest.md @@ -7,6 +7,11 @@ import { PostV1CompaniesCompanyUuidContractorsRequest } from "@gusto/embedded-ap let value: PostV1CompaniesCompanyUuidContractorsRequest = { companyUuid: "", + requestBody: { + wageType: "Fixed", + startDate: "2020-01-11", + hourlyRate: "40.0", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companiescompanyuuidsignatoriesinviterequest.md b/gusto_embedded/docs/models/operations/postv1companiescompanyuuidsignatoriesinviterequest.md index 8ab536d2..92e5e6b7 100644 --- a/gusto_embedded/docs/models/operations/postv1companiescompanyuuidsignatoriesinviterequest.md +++ b/gusto_embedded/docs/models/operations/postv1companiescompanyuuidsignatoriesinviterequest.md @@ -7,6 +7,9 @@ import { PostV1CompaniesCompanyUuidSignatoriesInviteRequest } from "@gusto/embed let value: PostV1CompaniesCompanyUuidSignatoriesInviteRequest = { companyUuid: "", + requestBody: { + email: "Kiara_Fritsch31@hotmail.com", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companyflowsrequest.md b/gusto_embedded/docs/models/operations/postv1companyflowsrequest.md index 82a50052..548c5db3 100644 --- a/gusto_embedded/docs/models/operations/postv1companyflowsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companyflowsrequest.md @@ -7,6 +7,9 @@ import { PostV1CompanyFlowsRequest } from "@gusto/embedded-api/models/operations let value: PostV1CompanyFlowsRequest = { companyUuid: "", + requestBody: { + flowType: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1companysignatoriesrequest.md b/gusto_embedded/docs/models/operations/postv1companysignatoriesrequest.md index 2f4da824..9b4c797c 100644 --- a/gusto_embedded/docs/models/operations/postv1companysignatoriesrequest.md +++ b/gusto_embedded/docs/models/operations/postv1companysignatoriesrequest.md @@ -7,6 +7,21 @@ import { PostV1CompanySignatoriesRequest } from "@gusto/embedded-api/models/oper let value: PostV1CompanySignatoriesRequest = { companyUuid: "", + requestBody: { + ssn: "", + firstName: "Bridget", + lastName: "Parker", + email: "Flavio.Rippin42@yahoo.com", + title: "", + phone: "534.780.0624 x537", + birthday: "", + homeAddress: { + street1: "", + city: "Haleyport", + state: "Idaho", + zip: "25196", + }, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1compensationscompensationidrequest.md b/gusto_embedded/docs/models/operations/postv1compensationscompensationidrequest.md index ff39f711..fb56b84f 100644 --- a/gusto_embedded/docs/models/operations/postv1compensationscompensationidrequest.md +++ b/gusto_embedded/docs/models/operations/postv1compensationscompensationidrequest.md @@ -7,6 +7,10 @@ import { PostV1CompensationsCompensationIdRequest } from "@gusto/embedded-api/mo let value: PostV1CompensationsCompensationIdRequest = { jobId: "", + requestBody: { + paymentUnit: "Week", + flsaStatus: "Commission Only Exempt", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1contractorscontractoruuidbankaccountsrequest.md b/gusto_embedded/docs/models/operations/postv1contractorscontractoruuidbankaccountsrequest.md index 6c6cde0c..423c43aa 100644 --- a/gusto_embedded/docs/models/operations/postv1contractorscontractoruuidbankaccountsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1contractorscontractoruuidbankaccountsrequest.md @@ -7,6 +7,12 @@ import { PostV1ContractorsContractorUuidBankAccountsRequest } from "@gusto/embed let value: PostV1ContractorsContractorUuidBankAccountsRequest = { contractorUuid: "", + requestBody: { + name: "", + routingNumber: "", + accountNumber: "", + accountType: "Checking", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1employeesemployeeidbankaccountsrequest.md b/gusto_embedded/docs/models/operations/postv1employeesemployeeidbankaccountsrequest.md index c645a6b0..e12cfbab 100644 --- a/gusto_embedded/docs/models/operations/postv1employeesemployeeidbankaccountsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1employeesemployeeidbankaccountsrequest.md @@ -7,6 +7,12 @@ import { PostV1EmployeesEmployeeIdBankAccountsRequest } from "@gusto/embedded-ap let value: PostV1EmployeesEmployeeIdBankAccountsRequest = { employeeId: "", + requestBody: { + name: "", + routingNumber: "", + accountNumber: "", + accountType: "Savings", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1employeesemployeeidemployeebenefitsrequest.md b/gusto_embedded/docs/models/operations/postv1employeesemployeeidemployeebenefitsrequest.md index 90bfd42c..3cf42b64 100644 --- a/gusto_embedded/docs/models/operations/postv1employeesemployeeidemployeebenefitsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1employeesemployeeidemployeebenefitsrequest.md @@ -7,6 +7,9 @@ import { PostV1EmployeesEmployeeIdEmployeeBenefitsRequest } from "@gusto/embedde let value: PostV1EmployeesEmployeeIdEmployeeBenefitsRequest = { employeeId: "", + requestBody: { + companyBenefitUuid: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1employeesemployeeidgarnishmentsrequest.md b/gusto_embedded/docs/models/operations/postv1employeesemployeeidgarnishmentsrequest.md index 26f0db6a..04d4de9a 100644 --- a/gusto_embedded/docs/models/operations/postv1employeesemployeeidgarnishmentsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1employeesemployeeidgarnishmentsrequest.md @@ -7,6 +7,10 @@ import { PostV1EmployeesEmployeeIdGarnishmentsRequest } from "@gusto/embedded-ap let value: PostV1EmployeesEmployeeIdGarnishmentsRequest = { employeeId: "", + requestBody: { + amount: "", + courtOrdered: true, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1employeesemployeeidhomeaddressesrequest.md b/gusto_embedded/docs/models/operations/postv1employeesemployeeidhomeaddressesrequest.md index 0e31225e..16acd6c1 100644 --- a/gusto_embedded/docs/models/operations/postv1employeesemployeeidhomeaddressesrequest.md +++ b/gusto_embedded/docs/models/operations/postv1employeesemployeeidhomeaddressesrequest.md @@ -4,9 +4,17 @@ ```typescript import { PostV1EmployeesEmployeeIdHomeAddressesRequest } from "@gusto/embedded-api/models/operations/postv1employeesemployeeidhomeaddresses.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PostV1EmployeesEmployeeIdHomeAddressesRequest = { employeeId: "", + requestBody: { + street1: "300 3rd Street", + city: "San Francisco", + state: "CA", + zip: "94107", + effectiveDate: new RFCDate("2022-01-31"), + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1employeesemployeeidrehirerequest.md b/gusto_embedded/docs/models/operations/postv1employeesemployeeidrehirerequest.md index 531a475d..178d317b 100644 --- a/gusto_embedded/docs/models/operations/postv1employeesemployeeidrehirerequest.md +++ b/gusto_embedded/docs/models/operations/postv1employeesemployeeidrehirerequest.md @@ -7,6 +7,11 @@ import { PostV1EmployeesEmployeeIdRehireRequest } from "@gusto/embedded-api/mode let value: PostV1EmployeesEmployeeIdRehireRequest = { employeeId: "", + rehireBody: { + effectiveDate: "", + fileNewHireReport: false, + workLocationUuid: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1employeesemployeeidterminationsrequest.md b/gusto_embedded/docs/models/operations/postv1employeesemployeeidterminationsrequest.md index 39fef98e..ac302269 100644 --- a/gusto_embedded/docs/models/operations/postv1employeesemployeeidterminationsrequest.md +++ b/gusto_embedded/docs/models/operations/postv1employeesemployeeidterminationsrequest.md @@ -7,6 +7,9 @@ import { PostV1EmployeesEmployeeIdTerminationsRequest } from "@gusto/embedded-ap let value: PostV1EmployeesEmployeeIdTerminationsRequest = { employeeId: "", + requestBody: { + effectiveDate: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1employeesemployeeidworkaddressesrequest.md b/gusto_embedded/docs/models/operations/postv1employeesemployeeidworkaddressesrequest.md index ca4df09c..5df6a5b1 100644 --- a/gusto_embedded/docs/models/operations/postv1employeesemployeeidworkaddressesrequest.md +++ b/gusto_embedded/docs/models/operations/postv1employeesemployeeidworkaddressesrequest.md @@ -4,9 +4,14 @@ ```typescript import { PostV1EmployeesEmployeeIdWorkAddressesRequest } from "@gusto/embedded-api/models/operations/postv1employeesemployeeidworkaddresses.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PostV1EmployeesEmployeeIdWorkAddressesRequest = { employeeId: "", + requestBody: { + locationUuid: "6a119be7-b4b0-4e27-aaa0-89d5f2524635", + effectiveDate: new RFCDate("2023-05-15"), + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1externalpayrollrequest.md b/gusto_embedded/docs/models/operations/postv1externalpayrollrequest.md index 3fabed87..92c5a6a9 100644 --- a/gusto_embedded/docs/models/operations/postv1externalpayrollrequest.md +++ b/gusto_embedded/docs/models/operations/postv1externalpayrollrequest.md @@ -7,6 +7,11 @@ import { PostV1ExternalPayrollRequest } from "@gusto/embedded-api/models/operati let value: PostV1ExternalPayrollRequest = { companyUuid: "", + requestBody: { + checkDate: "", + paymentPeriodStartDate: "", + paymentPeriodEndDate: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1historicalemployeesrequest.md b/gusto_embedded/docs/models/operations/postv1historicalemployeesrequest.md index fe4a5020..278f0bb5 100644 --- a/gusto_embedded/docs/models/operations/postv1historicalemployeesrequest.md +++ b/gusto_embedded/docs/models/operations/postv1historicalemployeesrequest.md @@ -7,6 +7,21 @@ import { PostV1HistoricalEmployeesRequest } from "@gusto/embedded-api/models/ope let value: PostV1HistoricalEmployeesRequest = { companyUuid: "", + historicalEmployeeBody: { + firstName: "Baylee", + lastName: "Stamm", + dateOfBirth: "1955-10-22", + ssn: "", + workAddress: {}, + homeAddress: { + street1: "", + city: "West Heatherville", + state: "North Dakota", + zip: "12580", + }, + termination: {}, + job: {}, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1jobsjobidrequest.md b/gusto_embedded/docs/models/operations/postv1jobsjobidrequest.md index 329255f9..feeb079c 100644 --- a/gusto_embedded/docs/models/operations/postv1jobsjobidrequest.md +++ b/gusto_embedded/docs/models/operations/postv1jobsjobidrequest.md @@ -7,6 +7,10 @@ import { PostV1JobsJobIdRequest } from "@gusto/embedded-api/models/operations/po let value: PostV1JobsJobIdRequest = { employeeId: "", + requestBody: { + title: "", + hireDate: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1partnermanagedcompaniesrequest.md b/gusto_embedded/docs/models/operations/postv1partnermanagedcompaniesrequest.md index f100ca25..00240569 100644 --- a/gusto_embedded/docs/models/operations/postv1partnermanagedcompaniesrequest.md +++ b/gusto_embedded/docs/models/operations/postv1partnermanagedcompaniesrequest.md @@ -5,7 +5,18 @@ ```typescript import { PostV1PartnerManagedCompaniesRequest } from "@gusto/embedded-api/models/operations/postv1partnermanagedcompanies.js"; -let value: PostV1PartnerManagedCompaniesRequest = {}; +let value: PostV1PartnerManagedCompaniesRequest = { + requestBody: { + user: { + firstName: "Zakary", + lastName: "Block", + email: "Jaylen96@yahoo.com", + }, + company: { + name: "", + }, + }, +}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/postv1payrollspayrollidcalculateaccruingtimeoffhoursrequest.md b/gusto_embedded/docs/models/operations/postv1payrollspayrollidcalculateaccruingtimeoffhoursrequest.md index 00b64e68..fe1baeaa 100644 --- a/gusto_embedded/docs/models/operations/postv1payrollspayrollidcalculateaccruingtimeoffhoursrequest.md +++ b/gusto_embedded/docs/models/operations/postv1payrollspayrollidcalculateaccruingtimeoffhoursrequest.md @@ -8,6 +8,7 @@ import { PostV1PayrollsPayrollIdCalculateAccruingTimeOffHoursRequest } from "@gu let value: PostV1PayrollsPayrollIdCalculateAccruingTimeOffHoursRequest = { payrollId: "", employeeId: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1payrollspayrolluuidgenerateddocumentsprintablepayrollchecksrequest.md b/gusto_embedded/docs/models/operations/postv1payrollspayrolluuidgenerateddocumentsprintablepayrollchecksrequest.md index f61df642..fc6eeeb7 100644 --- a/gusto_embedded/docs/models/operations/postv1payrollspayrolluuidgenerateddocumentsprintablepayrollchecksrequest.md +++ b/gusto_embedded/docs/models/operations/postv1payrollspayrolluuidgenerateddocumentsprintablepayrollchecksrequest.md @@ -8,6 +8,9 @@ import { PostV1PayrollsPayrollUuidGeneratedDocumentsPrintablePayrollChecksReques let value: PostV1PayrollsPayrollUuidGeneratedDocumentsPrintablePayrollChecksRequest = { payrollUuid: "", + requestBody: { + printingFormat: "top", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/postv1plaidprocessortokenrequest.md b/gusto_embedded/docs/models/operations/postv1plaidprocessortokenrequest.md index 93a04c8a..b6987cdd 100644 --- a/gusto_embedded/docs/models/operations/postv1plaidprocessortokenrequest.md +++ b/gusto_embedded/docs/models/operations/postv1plaidprocessortokenrequest.md @@ -5,7 +5,13 @@ ```typescript import { PostV1PlaidProcessorTokenRequest } from "@gusto/embedded-api/models/operations/postv1plaidprocessortoken.js"; -let value: PostV1PlaidProcessorTokenRequest = {}; +let value: PostV1PlaidProcessorTokenRequest = { + requestBody: { + ownerType: "Company", + ownerId: "", + processorToken: "", + }, +}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/postv1sandboxgenerate1099request.md b/gusto_embedded/docs/models/operations/postv1sandboxgenerate1099request.md index 1a58994a..1c231a7a 100644 --- a/gusto_embedded/docs/models/operations/postv1sandboxgenerate1099request.md +++ b/gusto_embedded/docs/models/operations/postv1sandboxgenerate1099request.md @@ -5,7 +5,11 @@ ```typescript import { PostV1SandboxGenerate1099Request } from "@gusto/embedded-api/models/operations/postv1sandboxgenerate1099.js"; -let value: PostV1SandboxGenerate1099Request = {}; +let value: PostV1SandboxGenerate1099Request = { + requestBody: { + contractorId: "", + }, +}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/postv1sandboxgeneratew2request.md b/gusto_embedded/docs/models/operations/postv1sandboxgeneratew2request.md index da318e15..0099f347 100644 --- a/gusto_embedded/docs/models/operations/postv1sandboxgeneratew2request.md +++ b/gusto_embedded/docs/models/operations/postv1sandboxgeneratew2request.md @@ -5,7 +5,11 @@ ```typescript import { PostV1SandboxGenerateW2Request } from "@gusto/embedded-api/models/operations/postv1sandboxgeneratew2.js"; -let value: PostV1SandboxGenerateW2Request = {}; +let value: PostV1SandboxGenerateW2Request = { + requestBody: { + employeeId: "", + }, +}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/postv1webhooksubscriptionrequest.md b/gusto_embedded/docs/models/operations/postv1webhooksubscriptionrequest.md index 09600665..55255a36 100644 --- a/gusto_embedded/docs/models/operations/postv1webhooksubscriptionrequest.md +++ b/gusto_embedded/docs/models/operations/postv1webhooksubscriptionrequest.md @@ -5,7 +5,14 @@ ```typescript import { PostV1WebhookSubscriptionRequest } from "@gusto/embedded-api/models/operations/postv1webhooksubscription.js"; -let value: PostV1WebhookSubscriptionRequest = {}; +let value: PostV1WebhookSubscriptionRequest = { + requestBody: { + url: "https://tight-allocation.name/", + subscriptionTypes: [ + "Payroll", + ], + }, +}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/putaddpeopletodepartmentrequest.md b/gusto_embedded/docs/models/operations/putaddpeopletodepartmentrequest.md index dfdc2917..bc1e0033 100644 --- a/gusto_embedded/docs/models/operations/putaddpeopletodepartmentrequest.md +++ b/gusto_embedded/docs/models/operations/putaddpeopletodepartmentrequest.md @@ -7,6 +7,7 @@ import { PutAddPeopleToDepartmentRequest } from "@gusto/embedded-api/models/oper let value: PutAddPeopleToDepartmentRequest = { departmentUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyaddrequest.md b/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyaddrequest.md index 5bb13e57..74fc8805 100644 --- a/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyaddrequest.md +++ b/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyaddrequest.md @@ -7,6 +7,9 @@ import { PutCompaniesCompanyUuidHolidayPayPolicyAddRequest } from "@gusto/embedd let value: PutCompaniesCompanyUuidHolidayPayPolicyAddRequest = { companyUuid: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyremoverequest.md b/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyremoverequest.md index b8053b48..47610452 100644 --- a/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyremoverequest.md +++ b/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyremoverequest.md @@ -7,6 +7,9 @@ import { PutCompaniesCompanyUuidHolidayPayPolicyRemoveRequest } from "@gusto/emb let value: PutCompaniesCompanyUuidHolidayPayPolicyRemoveRequest = { companyUuid: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyrequest.md b/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyrequest.md index 2da7e40e..c699109b 100644 --- a/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyrequest.md +++ b/gusto_embedded/docs/models/operations/putcompaniescompanyuuidholidaypaypolicyrequest.md @@ -7,6 +7,9 @@ import { PutCompaniesCompanyUuidHolidayPayPolicyRequest } from "@gusto/embedded- let value: PutCompaniesCompanyUuidHolidayPayPolicyRequest = { companyUuid: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putdepartmentsrequest.md b/gusto_embedded/docs/models/operations/putdepartmentsrequest.md index b7208382..a868a514 100644 --- a/gusto_embedded/docs/models/operations/putdepartmentsrequest.md +++ b/gusto_embedded/docs/models/operations/putdepartmentsrequest.md @@ -7,6 +7,9 @@ import { PutDepartmentsRequest } from "@gusto/embedded-api/models/operations/put let value: PutDepartmentsRequest = { departmentUuid: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putremovepeoplefromdepartmentrequest.md b/gusto_embedded/docs/models/operations/putremovepeoplefromdepartmentrequest.md index 2e6b0d02..1ee814b9 100644 --- a/gusto_embedded/docs/models/operations/putremovepeoplefromdepartmentrequest.md +++ b/gusto_embedded/docs/models/operations/putremovepeoplefromdepartmentrequest.md @@ -7,6 +7,7 @@ import { PutRemovePeopleFromDepartmentRequest } from "@gusto/embedded-api/models let value: PutRemovePeopleFromDepartmentRequest = { departmentUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/puttimeoffpoliciestimeoffpolicyuuidrequest.md b/gusto_embedded/docs/models/operations/puttimeoffpoliciestimeoffpolicyuuidrequest.md index 1a88fd0a..f584501b 100644 --- a/gusto_embedded/docs/models/operations/puttimeoffpoliciestimeoffpolicyuuidrequest.md +++ b/gusto_embedded/docs/models/operations/puttimeoffpoliciestimeoffpolicyuuidrequest.md @@ -7,6 +7,7 @@ import { PutTimeOffPoliciesTimeOffPolicyUuidRequest } from "@gusto/embedded-api/ let value: PutTimeOffPoliciesTimeOffPolicyUuidRequest = { timeOffPolicyUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidbankaccountsverifyrequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidbankaccountsverifyrequest.md index 49365419..1590b988 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidbankaccountsverifyrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidbankaccountsverifyrequest.md @@ -8,6 +8,10 @@ import { PutV1CompaniesCompanyIdBankAccountsVerifyRequest } from "@gusto/embedde let value: PutV1CompaniesCompanyIdBankAccountsVerifyRequest = { bankAccountUuid: "", companyId: "", + requestBody: { + deposit1: 6176.75, + deposit2: 1725.74, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidearningtypesearningtypeuuidrequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidearningtypesearningtypeuuidrequest.md index b1a0df3a..d32eeeb0 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidearningtypesearningtypeuuidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidearningtypesearningtypeuuidrequest.md @@ -8,6 +8,7 @@ import { PutV1CompaniesCompanyIdEarningTypesEarningTypeUuidRequest } from "@gust let value: PutV1CompaniesCompanyIdEarningTypesEarningTypeUuidRequest = { companyId: "", earningTypeUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidfederaltaxdetailsrequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidfederaltaxdetailsrequest.md index 4153715d..c4c0c06d 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidfederaltaxdetailsrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidfederaltaxdetailsrequest.md @@ -7,6 +7,9 @@ import { PutV1CompaniesCompanyIdFederalTaxDetailsRequest } from "@gusto/embedded let value: PutV1CompaniesCompanyIdFederalTaxDetailsRequest = { companyId: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsheaderxgustoapiversion.md new file mode 100644 index 00000000..e86a6ba3 --- /dev/null +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsheaderxgustoapiversion.md @@ -0,0 +1,17 @@ +# PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; + +let value: PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion = "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollspayrollidsubmitrequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollspayrollidsubmitrequest.md index 2f9a57c2..9d8c574f 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollspayrollidsubmitrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollspayrollidsubmitrequest.md @@ -8,6 +8,7 @@ import { PutV1CompaniesCompanyIdPayrollsPayrollIdSubmitRequest } from "@gusto/em let value: PutV1CompaniesCompanyIdPayrollsPayrollIdSubmitRequest = { companyId: "", payrollId: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsrequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsrequest.md index e0b8f994..29a45e9c 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsrequest.md @@ -8,6 +8,9 @@ import { PutV1CompaniesCompanyIdPayrollsRequest } from "@gusto/embedded-api/mode let value: PutV1CompaniesCompanyIdPayrollsRequest = { companyId: "", payrollId: "", + payrollUpdate: { + employeeCompensations: [], + }, }; ``` @@ -15,7 +18,7 @@ let value: PutV1CompaniesCompanyIdPayrollsRequest = { | Field | Type | Required | Description | | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `xGustoAPIVersion` | [operations.PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion](../../models/operations/putv1companiescompanyidpayrollsheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | | `companyId` | *string* | :heavy_check_mark: | The UUID of the company | | `payrollId` | *string* | :heavy_check_mark: | The UUID of the payroll | -| `xGustoAPIVersion` | [components.VersionHeader](../../models/components/versionheader.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | -| `requestBody` | [operations.PutV1CompaniesCompanyIdPayrollsRequestBody](../../models/operations/putv1companiescompanyidpayrollsrequestbody.md) | :heavy_check_mark: | N/A | \ No newline at end of file +| `payrollUpdate` | [components.PayrollUpdate](../../models/components/payrollupdate.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsresponse.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsresponse.md index caa6d048..44c91b7c 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsresponse.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollsresponse.md @@ -13,4 +13,4 @@ let value: PutV1CompaniesCompanyIdPayrollsResponse = {}; | Field | Type | Required | Description | | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | | `httpMeta` | [components.HTTPMetadata](../../models/components/httpmetadata.md) | :heavy_check_mark: | N/A | -| `payrollPrepared` | [components.PayrollPrepared](../../models/components/payrollprepared.md) | :heavy_minus_sign: | A prepared payroll | \ No newline at end of file +| `payrollPrepared` | [components.PayrollPrepared](../../models/components/payrollprepared.md) | :heavy_minus_sign: | successful | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollswithholdingpayperiod.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollswithholdingpayperiod.md deleted file mode 100644 index f374b473..00000000 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayrollswithholdingpayperiod.md +++ /dev/null @@ -1,17 +0,0 @@ -# PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod - -The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. - -## Example Usage - -```typescript -import { PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod } from "@gusto/embedded-api/models/operations/putv1companiescompanyidpayrolls.js"; - -let value: PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod = "Monthly"; -``` - -## Values - -```typescript -"Every week" | "Every other week" | "Twice per month" | "Monthly" | "Quarterly" | "Semiannually" | "Annually" -``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayschedulespayscheduleidrequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayschedulespayscheduleidrequest.md index 63826ee7..42ff6de8 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyidpayschedulespayscheduleidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyidpayschedulespayscheduleidrequest.md @@ -8,6 +8,11 @@ import { PutV1CompaniesCompanyIdPaySchedulesPayScheduleIdRequest } from "@gusto/ let value: PutV1CompaniesCompanyIdPaySchedulesPayScheduleIdRequest = { companyId: "", payScheduleId: "", + requestBody: { + version: "", + anchorPayDate: "2020-05-15", + anchorEndOfPayPeriod: "2020-05-08", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyuuidsignatoriessignatoryuuidrequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyuuidsignatoriessignatoryuuidrequest.md index 70001237..e715e83b 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyuuidsignatoriessignatoryuuidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyuuidsignatoriessignatoryuuidrequest.md @@ -8,6 +8,7 @@ import { PutV1CompaniesCompanyUuidSignatoriesSignatoryUuidRequest } from "@gusto let value: PutV1CompaniesCompanyUuidSignatoriesSignatoryUuidRequest = { companyUuid: "", signatoryUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiescompanyuuidtaxrequirementsstaterequest.md b/gusto_embedded/docs/models/operations/putv1companiescompanyuuidtaxrequirementsstaterequest.md index 5d307f7c..766988b8 100644 --- a/gusto_embedded/docs/models/operations/putv1companiescompanyuuidtaxrequirementsstaterequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiescompanyuuidtaxrequirementsstaterequest.md @@ -8,6 +8,7 @@ import { PutV1CompaniesCompanyUuidTaxRequirementsStateRequest } from "@gusto/emb let value: PutV1CompaniesCompanyUuidTaxRequirementsStateRequest = { companyUuid: "", state: "Connecticut", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companiesrequest.md b/gusto_embedded/docs/models/operations/putv1companiesrequest.md index c492c180..a80f183b 100644 --- a/gusto_embedded/docs/models/operations/putv1companiesrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companiesrequest.md @@ -7,6 +7,9 @@ import { PutV1CompaniesRequest } from "@gusto/embedded-api/models/operations/put let value: PutV1CompaniesRequest = { companyId: "", + requestBody: { + contractorOnly: false, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidemployeebenefitsrequest.md b/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidemployeebenefitsrequest.md index 413e8269..6a8fad37 100644 --- a/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidemployeebenefitsrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidemployeebenefitsrequest.md @@ -7,6 +7,13 @@ import { PutV1CompanyBenefitsCompanyBenefitIdEmployeeBenefitsRequest } from "@gu let value: PutV1CompanyBenefitsCompanyBenefitIdEmployeeBenefitsRequest = { companyBenefitId: "", + requestBody: { + employeeBenefits: [ + { + employeeUuid: "", + }, + ], + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidrequest.md b/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidrequest.md index 308defc5..3cc17ae6 100644 --- a/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companybenefitscompanybenefitidrequest.md @@ -7,6 +7,9 @@ import { PutV1CompanyBenefitsCompanyBenefitIdRequest } from "@gusto/embedded-api let value: PutV1CompanyBenefitsCompanyBenefitIdRequest = { companyBenefitId: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companyformsignrequest.md b/gusto_embedded/docs/models/operations/putv1companyformsignrequest.md index 81fc9a30..b9ba25f8 100644 --- a/gusto_embedded/docs/models/operations/putv1companyformsignrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companyformsignrequest.md @@ -7,6 +7,10 @@ import { PutV1CompanyFormSignRequest } from "@gusto/embedded-api/models/operatio let value: PutV1CompanyFormSignRequest = { formId: "", + requestBody: { + signatureText: "", + agree: true, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companyindustryrequest.md b/gusto_embedded/docs/models/operations/putv1companyindustryrequest.md index e5758fee..775dec47 100644 --- a/gusto_embedded/docs/models/operations/putv1companyindustryrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companyindustryrequest.md @@ -7,6 +7,9 @@ import { PutV1CompanyIndustryRequest } from "@gusto/embedded-api/models/operatio let value: PutV1CompanyIndustryRequest = { companyId: "", + requestBody: { + naicsCode: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1companypaymentconfigsrequest.md b/gusto_embedded/docs/models/operations/putv1companypaymentconfigsrequest.md index d8180117..56cc7a0e 100644 --- a/gusto_embedded/docs/models/operations/putv1companypaymentconfigsrequest.md +++ b/gusto_embedded/docs/models/operations/putv1companypaymentconfigsrequest.md @@ -7,6 +7,9 @@ import { PutV1CompanyPaymentConfigsRequest } from "@gusto/embedded-api/models/op let value: PutV1CompanyPaymentConfigsRequest = { companyUuid: "", + requestBody: { + paymentSpeed: "1-day", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1compensationscompensationidrequest.md b/gusto_embedded/docs/models/operations/putv1compensationscompensationidrequest.md index 36c2cbf9..1d7e01af 100644 --- a/gusto_embedded/docs/models/operations/putv1compensationscompensationidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1compensationscompensationidrequest.md @@ -7,6 +7,9 @@ import { PutV1CompensationsCompensationIdRequest } from "@gusto/embedded-api/mod let value: PutV1CompensationsCompensationIdRequest = { compensationId: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1contractordocumentsignrequest.md b/gusto_embedded/docs/models/operations/putv1contractordocumentsignrequest.md index bd7125b8..3f679fc3 100644 --- a/gusto_embedded/docs/models/operations/putv1contractordocumentsignrequest.md +++ b/gusto_embedded/docs/models/operations/putv1contractordocumentsignrequest.md @@ -7,6 +7,12 @@ import { PutV1ContractorDocumentSignRequest } from "@gusto/embedded-api/models/o let value: PutV1ContractorDocumentSignRequest = { documentUuid: "", + requestBody: { + fields: [ + {}, + ], + agree: true, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequest.md b/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequest.md index 070f331b..91a4f3a4 100644 --- a/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequest.md +++ b/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequest.md @@ -7,6 +7,10 @@ import { PutV1ContractorsContractorIdPaymentMethodRequest } from "@gusto/embedde let value: PutV1ContractorsContractorIdPaymentMethodRequest = { contractorUuid: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + type: "Check", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequestbody.md b/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequestbody.md index 873f78f1..2ad5c63e 100644 --- a/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1contractorscontractoridpaymentmethodrequestbody.md @@ -6,14 +6,14 @@ import { PutV1ContractorsContractorIdPaymentMethodRequestBody } from "@gusto/embedded-api/models/operations/putv1contractorscontractoridpaymentmethod.js"; let value: PutV1ContractorsContractorIdPaymentMethodRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", type: "Direct Deposit", }; ``` ## Fields -| Field | Type | Required | Description | -| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `type` | [operations.PutV1ContractorsContractorIdPaymentMethodType](../../models/operations/putv1contractorscontractoridpaymentmethodtype.md) | :heavy_check_mark: | The payment method type. If type is Direct Deposit, the contractor is required to have a bank account.
see [Bank account endpoint](./post-v1-contractors-contractor_uuid-bank_accounts) | \ No newline at end of file +| Field | Type | Required | Description | Example | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `type` | [operations.PutV1ContractorsContractorIdPaymentMethodType](../../models/operations/putv1contractorscontractoridpaymentmethodtype.md) | :heavy_check_mark: | The payment method type. If type is Direct Deposit, the contractor is required to have a bank account.
see [Bank account endpoint](./post-v1-contractors-contractor_uuid-bank_accounts) | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequest.md b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequest.md index f959ae1c..cdd237b5 100644 --- a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequest.md +++ b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequest.md @@ -7,6 +7,9 @@ import { PutV1ContractorsContractorUuidAddressRequest } from "@gusto/embedded-ap let value: PutV1ContractorsContractorUuidAddressRequest = { contractorUuid: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequestbody.md b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequestbody.md index 0c0bba57..58578987 100644 --- a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidaddressrequestbody.md @@ -6,17 +6,17 @@ import { PutV1ContractorsContractorUuidAddressRequestBody } from "@gusto/embedded-api/models/operations/putv1contractorscontractoruuidaddress.js"; let value: PutV1ContractorsContractorUuidAddressRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", }; ``` ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `street1` | *string* | :heavy_minus_sign: | N/A | -| `street2` | *string* | :heavy_minus_sign: | N/A | -| `city` | *string* | :heavy_minus_sign: | N/A | -| `state` | *string* | :heavy_minus_sign: | N/A | -| `zip` | *string* | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `street1` | *string* | :heavy_minus_sign: | N/A | | +| `street2` | *string* | :heavy_minus_sign: | N/A | | +| `city` | *string* | :heavy_minus_sign: | N/A | | +| `state` | *string* | :heavy_minus_sign: | N/A | | +| `zip` | *string* | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidonboardingstatusrequest.md b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidonboardingstatusrequest.md index e0d75a79..d93a4e54 100644 --- a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidonboardingstatusrequest.md +++ b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidonboardingstatusrequest.md @@ -7,6 +7,7 @@ import { PutV1ContractorsContractorUuidOnboardingStatusRequest } from "@gusto/em let value: PutV1ContractorsContractorUuidOnboardingStatusRequest = { contractorUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequest.md b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequest.md index 0bb953a5..7b52bd1f 100644 --- a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequest.md @@ -7,6 +7,11 @@ import { PutV1ContractorsContractorUuidRequest } from "@gusto/embedded-api/model let value: PutV1ContractorsContractorUuidRequest = { contractorUuid: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + startDate: "2020-01-11", + hourlyRate: "40.0", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequestbody.md b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequestbody.md index f3331ada..039b27c8 100644 --- a/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1contractorscontractoruuidrequestbody.md @@ -6,7 +6,7 @@ import { PutV1ContractorsContractorUuidRequestBody } from "@gusto/embedded-api/models/operations/putv1contractorscontractoruuid.js"; let value: PutV1ContractorsContractorUuidRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", startDate: "2020-01-11", hourlyRate: "40.0", }; @@ -16,7 +16,7 @@ let value: PutV1ContractorsContractorUuidRequestBody = { | Field | Type | Required | Description | Example | | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | | `type` | [operations.PutV1ContractorsContractorUuidType](../../models/operations/putv1contractorscontractoruuidtype.md) | :heavy_minus_sign: | The contractor type. | | | `wageType` | [operations.PutV1ContractorsContractorUuidWageType](../../models/operations/putv1contractorscontractoruuidwagetype.md) | :heavy_minus_sign: | The contractor’s wage type.
| | | `startDate` | *string* | :heavy_minus_sign: | The day when the contractor will start working for the company.
| 2020-01-11 | diff --git a/gusto_embedded/docs/models/operations/putv1employeebenefitsemployeebenefitidrequest.md b/gusto_embedded/docs/models/operations/putv1employeebenefitsemployeebenefitidrequest.md index cb614f6b..083650ef 100644 --- a/gusto_embedded/docs/models/operations/putv1employeebenefitsemployeebenefitidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeebenefitsemployeebenefitidrequest.md @@ -7,6 +7,9 @@ import { PutV1EmployeeBenefitsEmployeeBenefitIdRequest } from "@gusto/embedded-a let value: PutV1EmployeeBenefitsEmployeeBenefitIdRequest = { employeeBenefitId: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeeformsignrequest.md b/gusto_embedded/docs/models/operations/putv1employeeformsignrequest.md index a1e9098c..99c5f5a8 100644 --- a/gusto_embedded/docs/models/operations/putv1employeeformsignrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeeformsignrequest.md @@ -8,6 +8,10 @@ import { PutV1EmployeeFormSignRequest } from "@gusto/embedded-api/models/operati let value: PutV1EmployeeFormSignRequest = { employeeId: "", formId: "", + requestBody: { + signatureText: "", + agree: false, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidbankaccountsrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidbankaccountsrequest.md index f0673a9f..37122e89 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidbankaccountsrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidbankaccountsrequest.md @@ -8,6 +8,12 @@ import { PutV1EmployeesEmployeeIdBankAccountsRequest } from "@gusto/embedded-api let value: PutV1EmployeesEmployeeIdBankAccountsRequest = { employeeId: "", bankAccountUuid: "", + requestBody: { + name: "", + routingNumber: "", + accountNumber: "", + accountType: "Checking", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidfederaltaxesrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidfederaltaxesrequest.md index 1fc97621..988fbf2e 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidfederaltaxesrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidfederaltaxesrequest.md @@ -7,6 +7,9 @@ import { PutV1EmployeesEmployeeIdFederalTaxesRequest } from "@gusto/embedded-api let value: PutV1EmployeesEmployeeIdFederalTaxesRequest = { employeeUuid: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationdocumentsrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationdocumentsrequest.md index ce80e6a9..e47e8ccd 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationdocumentsrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationdocumentsrequest.md @@ -7,6 +7,15 @@ import { PutV1EmployeesEmployeeIdI9AuthorizationDocumentsRequest } from "@gusto/ let value: PutV1EmployeesEmployeeIdI9AuthorizationDocumentsRequest = { employeeId: "", + requestBody: { + documents: [ + { + documentType: "", + documentTitle: "", + issuingAuthority: "", + }, + ], + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationemployersignrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationemployersignrequest.md index 304ee8d3..18827d3d 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationemployersignrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationemployersignrequest.md @@ -7,6 +7,11 @@ import { PutV1EmployeesEmployeeIdI9AuthorizationEmployerSignRequest } from "@gus let value: PutV1EmployeesEmployeeIdI9AuthorizationEmployerSignRequest = { employeeId: "", + requestBody: { + signatureText: "", + signerTitle: "", + agree: false, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationrequest.md index c9c18b74..a6bf4e3c 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidi9authorizationrequest.md @@ -7,6 +7,9 @@ import { PutV1EmployeesEmployeeIdI9AuthorizationRequest } from "@gusto/embedded- let value: PutV1EmployeesEmployeeIdI9AuthorizationRequest = { employeeId: "", + requestBody: { + authorizationStatus: "permanent_resident", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingdocumentsconfigrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingdocumentsconfigrequest.md index 3e838960..33ed93ea 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingdocumentsconfigrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingdocumentsconfigrequest.md @@ -7,6 +7,7 @@ import { PutV1EmployeesEmployeeIdOnboardingDocumentsConfigRequest } from "@gusto let value: PutV1EmployeesEmployeeIdOnboardingDocumentsConfigRequest = { employeeId: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingstatusrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingstatusrequest.md index 00244040..175c789f 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingstatusrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidonboardingstatusrequest.md @@ -7,6 +7,9 @@ import { PutV1EmployeesEmployeeIdOnboardingStatusRequest } from "@gusto/embedded let value: PutV1EmployeesEmployeeIdOnboardingStatusRequest = { employeeId: "", + requestBody: { + onboardingStatus: "self_onboarding_pending_invite", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidpaymentmethodrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidpaymentmethodrequest.md index 6f48824b..cfbabd5d 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidpaymentmethodrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidpaymentmethodrequest.md @@ -7,6 +7,10 @@ import { PutV1EmployeesEmployeeIdPaymentMethodRequest } from "@gusto/embedded-ap let value: PutV1EmployeesEmployeeIdPaymentMethodRequest = { employeeId: "", + requestBody: { + version: "", + type: "Check", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequest.md index 63dcc94a..5cc5c654 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequest.md @@ -7,6 +7,12 @@ import { PutV1EmployeesEmployeeIdRehireRequest } from "@gusto/embedded-api/model let value: PutV1EmployeesEmployeeIdRehireRequest = { employeeId: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + effectiveDate: "", + fileNewHireReport: true, + workLocationUuid: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequestbody.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequestbody.md index d7783809..68b74034 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidrehirerequestbody.md @@ -6,7 +6,7 @@ import { PutV1EmployeesEmployeeIdRehireRequestBody } from "@gusto/embedded-api/models/operations/putv1employeesemployeeidrehire.js"; let value: PutV1EmployeesEmployeeIdRehireRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", effectiveDate: "", fileNewHireReport: true, workLocationUuid: "", @@ -15,11 +15,11 @@ let value: PutV1EmployeesEmployeeIdRehireRequestBody = { ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `effectiveDate` | *string* | :heavy_check_mark: | The day when the employee returns to work. | -| `fileNewHireReport` | *boolean* | :heavy_check_mark: | The boolean flag indicating whether Gusto will file a new hire report for the employee. | -| `workLocationUuid` | *string* | :heavy_check_mark: | The uuid of the employee's work location. | -| `employmentStatus` | [operations.EmploymentStatus](../../models/operations/employmentstatus.md) | :heavy_minus_sign: | The employee's employment status. Supplying an invalid option will set the employment_status to *not_set*. | -| `twoPercentShareholder` | *boolean* | :heavy_minus_sign: | Whether the employee is a two percent shareholder of the company. This field only applies to companies with an S-Corp entity type. | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `effectiveDate` | *string* | :heavy_check_mark: | The day when the employee returns to work. | | +| `fileNewHireReport` | *boolean* | :heavy_check_mark: | The boolean flag indicating whether Gusto will file a new hire report for the employee. | | +| `workLocationUuid` | *string* | :heavy_check_mark: | The uuid of the employee's work location. | | +| `employmentStatus` | [operations.EmploymentStatus](../../models/operations/employmentstatus.md) | :heavy_minus_sign: | The employee's employment status. Supplying an invalid option will set the employment_status to *not_set*. | | +| `twoPercentShareholder` | *boolean* | :heavy_minus_sign: | Whether the employee is a two percent shareholder of the company. This field only applies to companies with an S-Corp entity type. | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesheaderxgustoapiversion.md index 088041a6..8b193378 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesheaderxgustoapiversion.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesheaderxgustoapiversion.md @@ -1,6 +1,6 @@ # PutV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion -Determines the date-based API version associated with your API call. +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. ## Example Usage diff --git a/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesrequest.md b/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesrequest.md index 5f37b7d1..5a38510d 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesemployeeidstatetaxesrequest.md @@ -7,13 +7,16 @@ import { PutV1EmployeesEmployeeIdStateTaxesRequest } from "@gusto/embedded-api/m let value: PutV1EmployeesEmployeeIdStateTaxesRequest = { employeeUuid: "", + employeeStateTaxesRequest: { + states: [], + }, }; ``` ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `xGustoAPIVersion` | [operations.PutV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion](../../models/operations/putv1employeesemployeeidstatetaxesheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. | -| `employeeUuid` | *string* | :heavy_check_mark: | The UUID of the employee | -| `employeeStateTaxesRequest` | [components.EmployeeStateTaxesRequest](../../models/components/employeestatetaxesrequest.md) | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `xGustoAPIVersion` | [operations.PutV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion](../../models/operations/putv1employeesemployeeidstatetaxesheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | +| `employeeUuid` | *string* | :heavy_check_mark: | The UUID of the employee | +| `employeeStateTaxesRequest` | [components.EmployeeStateTaxesRequest](../../models/components/employeestatetaxesrequest.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1employeesheaderxgustoapiversion.md b/gusto_embedded/docs/models/operations/putv1employeesheaderxgustoapiversion.md new file mode 100644 index 00000000..3c898833 --- /dev/null +++ b/gusto_embedded/docs/models/operations/putv1employeesheaderxgustoapiversion.md @@ -0,0 +1,17 @@ +# PutV1EmployeesHeaderXGustoAPIVersion + +Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + +## Example Usage + +```typescript +import { PutV1EmployeesHeaderXGustoAPIVersion } from "@gusto/embedded-api/models/operations/putv1employees.js"; + +let value: PutV1EmployeesHeaderXGustoAPIVersion = "2024-04-01"; +``` + +## Values + +```typescript +"2024-04-01" +``` \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1employeesrequest.md b/gusto_embedded/docs/models/operations/putv1employeesrequest.md index 4d744927..24e704fa 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesrequest.md +++ b/gusto_embedded/docs/models/operations/putv1employeesrequest.md @@ -7,13 +7,23 @@ import { PutV1EmployeesRequest } from "@gusto/embedded-api/models/operations/put let value: PutV1EmployeesRequest = { employeeId: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + firstName: "Weezy", + middleInitial: "F", + lastName: "Baby", + email: "tunechi@cashmoneyrecords.com", + dateOfBirth: "1991-01-31", + ssn: "824920233", + workEmail: "new.partner.work@example.com", + }, }; ``` ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -| `xGustoAPIVersion` | *string* | :heavy_minus_sign: | N/A | -| `employeeId` | *string* | :heavy_check_mark: | The UUID of the employee | -| `requestBody` | [operations.PutV1EmployeesRequestBody](../../models/operations/putv1employeesrequestbody.md) | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `xGustoAPIVersion` | [operations.PutV1EmployeesHeaderXGustoAPIVersion](../../models/operations/putv1employeesheaderxgustoapiversion.md) | :heavy_minus_sign: | Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. | +| `employeeId` | *string* | :heavy_check_mark: | The UUID of the employee | +| `requestBody` | [operations.PutV1EmployeesRequestBody](../../models/operations/putv1employeesrequestbody.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1employeesrequestbody.md b/gusto_embedded/docs/models/operations/putv1employeesrequestbody.md index b5f2d565..7261dade 100644 --- a/gusto_embedded/docs/models/operations/putv1employeesrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1employeesrequestbody.md @@ -6,21 +6,28 @@ import { PutV1EmployeesRequestBody } from "@gusto/embedded-api/models/operations/putv1employees.js"; let value: PutV1EmployeesRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", + firstName: "Weezy", + middleInitial: "F", + lastName: "Baby", + email: "tunechi@cashmoneyrecords.com", + dateOfBirth: "1991-01-31", + ssn: "824920233", + workEmail: "new.partner.work@example.com", }; ``` ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `firstName` | *string* | :heavy_minus_sign: | N/A | -| `middleInitial` | *string* | :heavy_minus_sign: | N/A | -| `lastName` | *string* | :heavy_minus_sign: | N/A | -| `email` | *string* | :heavy_minus_sign: | N/A | -| `dateOfBirth` | *string* | :heavy_minus_sign: | N/A | -| `ssn` | *string* | :heavy_minus_sign: | N/A | -| `preferredFirstName` | *string* | :heavy_minus_sign: | N/A | -| `twoPercentShareholder` | *boolean* | :heavy_minus_sign: | Whether the employee is a two percent shareholder of the company. This field only applies to companies with an S-Corp entity type. | -| `workEmail` | *string* | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `firstName` | *string* | :heavy_minus_sign: | N/A | Weezy | +| `middleInitial` | *string* | :heavy_minus_sign: | N/A | F | +| `lastName` | *string* | :heavy_minus_sign: | N/A | Baby | +| `email` | *string* | :heavy_minus_sign: | N/A | tunechi@cashmoneyrecords.com | +| `dateOfBirth` | *string* | :heavy_minus_sign: | N/A | 1991-01-31 | +| `ssn` | *string* | :heavy_minus_sign: | N/A | 824920233 | +| `preferredFirstName` | *string* | :heavy_minus_sign: | N/A | | +| `twoPercentShareholder` | *boolean* | :heavy_minus_sign: | Whether the employee is a two percent shareholder of the company. This field only applies to companies with an S-Corp entity type. | | +| `workEmail` | *string* | :heavy_minus_sign: | N/A | new.partner.work@example.com | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1externalpayrollrequest.md b/gusto_embedded/docs/models/operations/putv1externalpayrollrequest.md index f3fe86e1..2dd540a9 100644 --- a/gusto_embedded/docs/models/operations/putv1externalpayrollrequest.md +++ b/gusto_embedded/docs/models/operations/putv1externalpayrollrequest.md @@ -8,6 +8,7 @@ import { PutV1ExternalPayrollRequest } from "@gusto/embedded-api/models/operatio let value: PutV1ExternalPayrollRequest = { companyUuid: "", externalPayrollId: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1garnishmentsgarnishmentidrequest.md b/gusto_embedded/docs/models/operations/putv1garnishmentsgarnishmentidrequest.md index ca6442ad..91d5cf90 100644 --- a/gusto_embedded/docs/models/operations/putv1garnishmentsgarnishmentidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1garnishmentsgarnishmentidrequest.md @@ -7,6 +7,9 @@ import { PutV1GarnishmentsGarnishmentIdRequest } from "@gusto/embedded-api/model let value: PutV1GarnishmentsGarnishmentIdRequest = { garnishmentId: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1historicalemployeesrequest.md b/gusto_embedded/docs/models/operations/putv1historicalemployeesrequest.md index 9f90028a..2664476e 100644 --- a/gusto_embedded/docs/models/operations/putv1historicalemployeesrequest.md +++ b/gusto_embedded/docs/models/operations/putv1historicalemployeesrequest.md @@ -8,6 +8,22 @@ import { PutV1HistoricalEmployeesRequest } from "@gusto/embedded-api/models/oper let value: PutV1HistoricalEmployeesRequest = { companyUuid: "", historicalEmployeeUuid: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + firstName: "Mellie", + lastName: "Stroman-Bergstrom", + dateOfBirth: "1987-03-01", + ssn: "", + workAddress: {}, + homeAddress: { + street1: "", + city: "South Alessia", + state: "Arizona", + zip: "43501-5370", + }, + termination: {}, + job: {}, + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1historicalemployeesrequestbody.md b/gusto_embedded/docs/models/operations/putv1historicalemployeesrequestbody.md index c2900649..6c7a1434 100644 --- a/gusto_embedded/docs/models/operations/putv1historicalemployeesrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1historicalemployeesrequestbody.md @@ -8,7 +8,7 @@ Update a historical employee. import { PutV1HistoricalEmployeesRequestBody } from "@gusto/embedded-api/models/operations/putv1historicalemployees.js"; let value: PutV1HistoricalEmployeesRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", firstName: "Domingo", lastName: "Abshire", dateOfBirth: "1973-08-20", @@ -27,18 +27,18 @@ let value: PutV1HistoricalEmployeesRequestBody = { ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `firstName` | *string* | :heavy_check_mark: | N/A | -| `middleInitial` | *string* | :heavy_minus_sign: | N/A | -| `lastName` | *string* | :heavy_check_mark: | N/A | -| `preferredFirstName` | *string* | :heavy_minus_sign: | N/A | -| `dateOfBirth` | *string* | :heavy_check_mark: | N/A | -| `ssn` | *string* | :heavy_check_mark: | N/A | -| `workAddress` | [operations.WorkAddress](../../models/operations/workaddress.md) | :heavy_check_mark: | N/A | -| `homeAddress` | [operations.PutV1HistoricalEmployeesHomeAddress](../../models/operations/putv1historicalemployeeshomeaddress.md) | :heavy_check_mark: | N/A | -| `termination` | [operations.Termination](../../models/operations/termination.md) | :heavy_check_mark: | N/A | -| `email` | *string* | :heavy_minus_sign: | Optional. If provided, the email address will be saved to the employee. | -| `job` | [operations.Job](../../models/operations/job.md) | :heavy_check_mark: | N/A | -| `employeeStateTaxes` | [operations.EmployeeStateTaxes](../../models/operations/employeestatetaxes.md) | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `firstName` | *string* | :heavy_check_mark: | N/A | | +| `middleInitial` | *string* | :heavy_minus_sign: | N/A | | +| `lastName` | *string* | :heavy_check_mark: | N/A | | +| `preferredFirstName` | *string* | :heavy_minus_sign: | N/A | | +| `dateOfBirth` | *string* | :heavy_check_mark: | N/A | | +| `ssn` | *string* | :heavy_check_mark: | N/A | | +| `workAddress` | [operations.WorkAddress](../../models/operations/workaddress.md) | :heavy_check_mark: | N/A | | +| `homeAddress` | [operations.PutV1HistoricalEmployeesHomeAddress](../../models/operations/putv1historicalemployeeshomeaddress.md) | :heavy_check_mark: | N/A | | +| `termination` | [operations.Termination](../../models/operations/termination.md) | :heavy_check_mark: | N/A | | +| `email` | *string* | :heavy_minus_sign: | Optional. If provided, the email address will be saved to the employee. | | +| `job` | [operations.Job](../../models/operations/job.md) | :heavy_check_mark: | N/A | | +| `employeeStateTaxes` | [operations.EmployeeStateTaxes](../../models/operations/employeestatetaxes.md) | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequest.md b/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequest.md index b72c3f1f..5896a579 100644 --- a/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequest.md @@ -7,6 +7,9 @@ import { PutV1HomeAddressesHomeAddressUuidRequest } from "@gusto/embedded-api/mo let value: PutV1HomeAddressesHomeAddressUuidRequest = { homeAddressUuid: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequestbody.md b/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequestbody.md index da2ec381..a0150625 100644 --- a/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1homeaddresseshomeaddressuuidrequestbody.md @@ -6,19 +6,19 @@ import { PutV1HomeAddressesHomeAddressUuidRequestBody } from "@gusto/embedded-api/models/operations/putv1homeaddresseshomeaddressuuid.js"; let value: PutV1HomeAddressesHomeAddressUuidRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", }; ``` ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `street1` | *string* | :heavy_minus_sign: | N/A | -| `street2` | *string* | :heavy_minus_sign: | N/A | -| `city` | *string* | :heavy_minus_sign: | N/A | -| `state` | *string* | :heavy_minus_sign: | N/A | -| `zip` | *string* | :heavy_minus_sign: | N/A | -| `effectiveDate` | [RFCDate](../../types/rfcdate.md) | :heavy_minus_sign: | N/A | -| `courtesyWithholding` | *boolean* | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `street1` | *string* | :heavy_minus_sign: | N/A | | +| `street2` | *string* | :heavy_minus_sign: | N/A | | +| `city` | *string* | :heavy_minus_sign: | N/A | | +| `state` | *string* | :heavy_minus_sign: | N/A | | +| `zip` | *string* | :heavy_minus_sign: | N/A | | +| `effectiveDate` | [RFCDate](../../types/rfcdate.md) | :heavy_minus_sign: | N/A | | +| `courtesyWithholding` | *boolean* | :heavy_minus_sign: | N/A | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1jobsjobidrequest.md b/gusto_embedded/docs/models/operations/putv1jobsjobidrequest.md index 2f7312a0..88bc08b4 100644 --- a/gusto_embedded/docs/models/operations/putv1jobsjobidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1jobsjobidrequest.md @@ -7,6 +7,9 @@ import { PutV1JobsJobIdRequest } from "@gusto/embedded-api/models/operations/put let value: PutV1JobsJobIdRequest = { jobId: "", + requestBody: { + version: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1locationslocationidrequest.md b/gusto_embedded/docs/models/operations/putv1locationslocationidrequest.md index 0819ef5c..424955a8 100644 --- a/gusto_embedded/docs/models/operations/putv1locationslocationidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1locationslocationidrequest.md @@ -7,6 +7,14 @@ import { PutV1LocationsLocationIdRequest } from "@gusto/embedded-api/models/oper let value: PutV1LocationsLocationIdRequest = { locationId: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + phoneNumber: "8009360383", + street1: "300 3rd Street", + street2: "Apartment 318", + city: "San Francisco", + zip: "94107", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1locationslocationidrequestbody.md b/gusto_embedded/docs/models/operations/putv1locationslocationidrequestbody.md index 88be5494..7d7e621b 100644 --- a/gusto_embedded/docs/models/operations/putv1locationslocationidrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1locationslocationidrequestbody.md @@ -6,21 +6,26 @@ import { PutV1LocationsLocationIdRequestBody } from "@gusto/embedded-api/models/operations/putv1locationslocationid.js"; let value: PutV1LocationsLocationIdRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", + phoneNumber: "8009360383", + street1: "300 3rd Street", + street2: "Apartment 318", + city: "San Francisco", + zip: "94107", }; ``` ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `phoneNumber` | *string* | :heavy_minus_sign: | N/A | -| `street1` | *string* | :heavy_minus_sign: | N/A | -| `street2` | *string* | :heavy_minus_sign: | N/A | -| `city` | *string* | :heavy_minus_sign: | N/A | -| `state` | *string* | :heavy_minus_sign: | N/A | -| `zip` | *string* | :heavy_minus_sign: | N/A | -| `country` | *string* | :heavy_minus_sign: | N/A | -| `mailingAddress` | *boolean* | :heavy_minus_sign: | For a company location, specify if this location is the company's mailing address. A company has a single mailing address, so this designation will override any previous selection. | -| `filingAddress` | *boolean* | :heavy_minus_sign: | For a company location, specify if this location is the company's filing address. A company has a single filing address, so this designation will override any previous selection. | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `phoneNumber` | *string* | :heavy_minus_sign: | N/A | 8009360383 | +| `street1` | *string* | :heavy_minus_sign: | N/A | 300 3rd Street | +| `street2` | *string* | :heavy_minus_sign: | N/A | Apartment 318 | +| `city` | *string* | :heavy_minus_sign: | N/A | San Francisco | +| `state` | *string* | :heavy_minus_sign: | N/A | | +| `zip` | *string* | :heavy_minus_sign: | N/A | 94107 | +| `country` | *string* | :heavy_minus_sign: | N/A | | +| `mailingAddress` | *boolean* | :heavy_minus_sign: | For a company location, specify if this location is the company's mailing address. A company has a single mailing address, so this designation will override any previous selection. | | +| `filingAddress` | *boolean* | :heavy_minus_sign: | For a company location, specify if this location is the company's filing address. A company has a single filing address, so this designation will override any previous selection. | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1partnermanagedcompaniescompanyuuidmigraterequest.md b/gusto_embedded/docs/models/operations/putv1partnermanagedcompaniescompanyuuidmigraterequest.md index cae34c25..158ec5af 100644 --- a/gusto_embedded/docs/models/operations/putv1partnermanagedcompaniescompanyuuidmigraterequest.md +++ b/gusto_embedded/docs/models/operations/putv1partnermanagedcompaniescompanyuuidmigraterequest.md @@ -7,6 +7,11 @@ import { PutV1PartnerManagedCompaniesCompanyUuidMigrateRequest } from "@gusto/em let value: PutV1PartnerManagedCompaniesCompanyUuidMigrateRequest = { companyUuid: "", + requestBody: { + email: "Matt_Johns38@gmail.com", + ipAddress: "1bad:0b2a:cd03:1e9d:f15e:d9ef:94e8:c754", + externalUserId: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1taxliabilitiesrequest.md b/gusto_embedded/docs/models/operations/putv1taxliabilitiesrequest.md index 42e2ce34..c3e2d7a1 100644 --- a/gusto_embedded/docs/models/operations/putv1taxliabilitiesrequest.md +++ b/gusto_embedded/docs/models/operations/putv1taxliabilitiesrequest.md @@ -7,6 +7,7 @@ import { PutV1TaxLiabilitiesRequest } from "@gusto/embedded-api/models/operation let value: PutV1TaxLiabilitiesRequest = { companyUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequest.md b/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequest.md index bff82482..28cdbf9d 100644 --- a/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequest.md @@ -7,6 +7,10 @@ import { PutV1TerminationsEmployeeIdRequest } from "@gusto/embedded-api/models/o let value: PutV1TerminationsEmployeeIdRequest = { employeeId: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + effectiveDate: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequestbody.md b/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequestbody.md index 85313699..5d00f6d6 100644 --- a/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1terminationsemployeeidrequestbody.md @@ -6,15 +6,15 @@ import { PutV1TerminationsEmployeeIdRequestBody } from "@gusto/embedded-api/models/operations/putv1terminationsemployeeid.js"; let value: PutV1TerminationsEmployeeIdRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", effectiveDate: "", }; ``` ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | -| `effectiveDate` | *string* | :heavy_check_mark: | The employee's last day of work. | -| `runTerminationPayroll` | *boolean* | :heavy_minus_sign: | If true, the employee should receive their final wages via an off-cycle payroll. If false, they should receive their final wages on their current pay schedule. | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | +| `effectiveDate` | *string* | :heavy_check_mark: | The employee's last day of work. | | +| `runTerminationPayroll` | *boolean* | :heavy_minus_sign: | If true, the employee should receive their final wages via an off-cycle payroll. If false, they should receive their final wages on their current pay schedule. | | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putv1timeoffpoliciestimeoffpolicyuuidremoveemployeesrequest.md b/gusto_embedded/docs/models/operations/putv1timeoffpoliciestimeoffpolicyuuidremoveemployeesrequest.md index fe2b9dec..a17875ec 100644 --- a/gusto_embedded/docs/models/operations/putv1timeoffpoliciestimeoffpolicyuuidremoveemployeesrequest.md +++ b/gusto_embedded/docs/models/operations/putv1timeoffpoliciestimeoffpolicyuuidremoveemployeesrequest.md @@ -7,6 +7,7 @@ import { PutV1TimeOffPoliciesTimeOffPolicyUuidRemoveEmployeesRequest } from "@gu let value: PutV1TimeOffPoliciesTimeOffPolicyUuidRemoveEmployeesRequest = { timeOffPolicyUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1verifywebhooksubscriptionuuidrequest.md b/gusto_embedded/docs/models/operations/putv1verifywebhooksubscriptionuuidrequest.md index b28828d6..eba622c7 100644 --- a/gusto_embedded/docs/models/operations/putv1verifywebhooksubscriptionuuidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1verifywebhooksubscriptionuuidrequest.md @@ -7,6 +7,9 @@ import { PutV1VerifyWebhookSubscriptionUuidRequest } from "@gusto/embedded-api/m let value: PutV1VerifyWebhookSubscriptionUuidRequest = { webhookSubscriptionUuid: "", + requestBody: { + verificationToken: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1webhooksubscriptionuuidrequest.md b/gusto_embedded/docs/models/operations/putv1webhooksubscriptionuuidrequest.md index 21962128..774582df 100644 --- a/gusto_embedded/docs/models/operations/putv1webhooksubscriptionuuidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1webhooksubscriptionuuidrequest.md @@ -7,6 +7,9 @@ import { PutV1WebhookSubscriptionUuidRequest } from "@gusto/embedded-api/models/ let value: PutV1WebhookSubscriptionUuidRequest = { webhookSubscriptionUuid: "", + requestBody: { + subscriptionTypes: [], + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequest.md b/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequest.md index af3a2ca5..b556798d 100644 --- a/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequest.md +++ b/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequest.md @@ -4,9 +4,15 @@ ```typescript import { PutV1WorkAddressesWorkAddressUuidRequest } from "@gusto/embedded-api/models/operations/putv1workaddressesworkaddressuuid.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PutV1WorkAddressesWorkAddressUuidRequest = { workAddressUuid: "", + requestBody: { + version: "56d00c178bc7393b2a206ed6a86afcb4", + locationUuid: "6a119be7-b4b0-4e27-aaa0-89d5f2524635", + effectiveDate: new RFCDate("2023-05-15"), + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequestbody.md b/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequestbody.md index c0aba135..ac7bc5f7 100644 --- a/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequestbody.md +++ b/gusto_embedded/docs/models/operations/putv1workaddressesworkaddressuuidrequestbody.md @@ -7,7 +7,7 @@ import { PutV1WorkAddressesWorkAddressUuidRequestBody } from "@gusto/embedded-ap import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; let value: PutV1WorkAddressesWorkAddressUuidRequestBody = { - version: "", + version: "56d00c178bc7393b2a206ed6a86afcb4", locationUuid: "6a119be7-b4b0-4e27-aaa0-89d5f2524635", effectiveDate: new RFCDate("2023-05-15"), }; @@ -17,6 +17,6 @@ let value: PutV1WorkAddressesWorkAddressUuidRequestBody = { | Field | Type | Required | Description | Example | | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | | +| `version` | *string* | :heavy_check_mark: | The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. | 56d00c178bc7393b2a206ed6a86afcb4 | | `locationUuid` | *string* | :heavy_minus_sign: | Reference to a company location | 6a119be7-b4b0-4e27-aaa0-89d5f2524635 | | `effectiveDate` | [RFCDate](../../types/rfcdate.md) | :heavy_minus_sign: | N/A | 2023-05-15 | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidaddemployeesrequest.md b/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidaddemployeesrequest.md index a5f8d26b..01a821ef 100644 --- a/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidaddemployeesrequest.md +++ b/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidaddemployeesrequest.md @@ -7,6 +7,7 @@ import { PutVersionTimeOffPoliciesTimeOffPolicyUuidAddEmployeesRequest } from "@ let value: PutVersionTimeOffPoliciesTimeOffPolicyUuidAddEmployeesRequest = { timeOffPolicyUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidbalancerequest.md b/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidbalancerequest.md index 784cef62..81f57fbe 100644 --- a/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidbalancerequest.md +++ b/gusto_embedded/docs/models/operations/putversiontimeoffpoliciestimeoffpolicyuuidbalancerequest.md @@ -7,6 +7,7 @@ import { PutVersionTimeOffPoliciesTimeOffPolicyUuidBalanceRequest } from "@gusto let value: PutVersionTimeOffPoliciesTimeOffPolicyUuidBalanceRequest = { timeOffPolicyUuid: "", + requestBody: {}, }; ``` diff --git a/gusto_embedded/docs/models/operations/putwireinrequestswireinrequestuuidrequest.md b/gusto_embedded/docs/models/operations/putwireinrequestswireinrequestuuidrequest.md index 555341dd..6780438e 100644 --- a/gusto_embedded/docs/models/operations/putwireinrequestswireinrequestuuidrequest.md +++ b/gusto_embedded/docs/models/operations/putwireinrequestswireinrequestuuidrequest.md @@ -7,6 +7,11 @@ import { PutWireInRequestsWireInRequestUuidRequest } from "@gusto/embedded-api/m let value: PutWireInRequestsWireInRequestUuidRequest = { wireInRequestUuid: "", + requestBody: { + dateSent: "", + bankName: "", + amountSent: "", + }, }; ``` diff --git a/gusto_embedded/docs/models/operations/refreshaccesstokenrequest.md b/gusto_embedded/docs/models/operations/refreshaccesstokenrequest.md index 0bf335af..fb638a1d 100644 --- a/gusto_embedded/docs/models/operations/refreshaccesstokenrequest.md +++ b/gusto_embedded/docs/models/operations/refreshaccesstokenrequest.md @@ -5,7 +5,14 @@ ```typescript import { RefreshAccessTokenRequest } from "@gusto/embedded-api/models/operations/refreshaccesstoken.js"; -let value: RefreshAccessTokenRequest = {}; +let value: RefreshAccessTokenRequest = { + requestBody: { + clientId: "", + clientSecret: "", + refreshToken: "", + grantType: "", + }, +}; ``` ## Fields diff --git a/gusto_embedded/docs/models/operations/two.md b/gusto_embedded/docs/models/operations/two.md index 750e8936..d21e91ed 100644 --- a/gusto_embedded/docs/models/operations/two.md +++ b/gusto_embedded/docs/models/operations/two.md @@ -12,7 +12,7 @@ let value: Two = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | -| `threshold` | *string* | :heavy_minus_sign: | The percentage threshold at which this tier ends (inclusive).

For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll.

If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | +| `threshold` | *string* | :heavy_minus_sign: | Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to.

Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards.

For example:

If the first tier has a threshold of "3", and rate of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll.

If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. | \ No newline at end of file diff --git a/gusto_embedded/docs/models/operations/value2.md b/gusto_embedded/docs/models/operations/value2.md index c1d2ae50..71df39dc 100644 --- a/gusto_embedded/docs/models/operations/value2.md +++ b/gusto_embedded/docs/models/operations/value2.md @@ -12,7 +12,7 @@ let value: Value2 = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | -| `threshold` | *string* | :heavy_minus_sign: | The percentage threshold at which this tier ends (inclusive).

For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll.

If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `rate` | *string* | :heavy_minus_sign: | The percentage of employee deduction within this tier the company contribution will match. | +| `threshold` | *string* | :heavy_minus_sign: | Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to.

Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards.

For example:

If the first tier has a threshold of "3", and rate of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll.

If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. | \ No newline at end of file diff --git a/gusto_embedded/docs/sdks/contractorpaymentgroups/README.md b/gusto_embedded/docs/sdks/contractorpaymentgroups/README.md index 6b6a5953..3f14a178 100644 --- a/gusto_embedded/docs/sdks/contractorpaymentgroups/README.md +++ b/gusto_embedded/docs/sdks/contractorpaymentgroups/README.md @@ -11,6 +11,8 @@ * [get](#get) - Fetch a contractor payment group * [delete](#delete) - Cancel a contractor payment group * [fund](#fund) - Fund a contractor payment group [DEMO] +* [getV1ContractorPaymentGroupsIdPartnerDisbursements](#getv1contractorpaymentgroupsidpartnerdisbursements) - Get partner disbursements for a contractor payment group +* [patchV1ContractorPaymentGroupsIdPartnerDisbursements](#patchv1contractorpaymentgroupsidpartnerdisbursements) - Update partner disbursements for a contractor payment group ## create @@ -642,4 +644,215 @@ import { | Error Type | Status Code | Content Type | | ------------------------------------- | ------------------------------------- | ------------------------------------- | | errors.UnprocessableEntityErrorObject | 422 | application/json | +| errors.APIError | 4XX, 5XX | \*/\* | + +## getV1ContractorPaymentGroupsIdPartnerDisbursements + +Get partner disbursements for a specific contractor payment group. + +scope: `partner_disbursements:read` + + +### Example Usage + +```typescript +import { GustoEmbedded } from "@gusto/embedded-api"; + +const gustoEmbedded = new GustoEmbedded({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const result = await gustoEmbedded.contractorPaymentGroups.getV1ContractorPaymentGroupsIdPartnerDisbursements({ + id: "", + }); + + console.log(result); +} + +run(); +``` + +### Standalone function + +The standalone function version of this method: + +```typescript +import { GustoEmbeddedCore } from "@gusto/embedded-api/core.js"; +import { contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements } from "@gusto/embedded-api/funcs/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.js"; + +// Use `GustoEmbeddedCore` for best tree-shaking performance. +// You can create one instance of it to use across an application. +const gustoEmbedded = new GustoEmbeddedCore({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const res = await contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements(gustoEmbedded, { + id: "", + }); + if (res.ok) { + const { value: result } = res; + console.log(result); + } else { + console.log("contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements failed:", res.error); + } +} + +run(); +``` + +### React hooks and utilities + +This method can be used in React components through the following hooks and +associated utilities. + +> Check out [this guide][hook-guide] for information about each of the utilities +> below and how to get started using React hooks. + +[hook-guide]: ../../../REACT_QUERY.md + +```tsx +import { + // Query hooks for fetching data. + useContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements, + useContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsSuspense, + + // Utility for prefetching data during server-side rendering and in React + // Server Components that will be immediately available to client components + // using the hooks. + prefetchContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements, + + // Utilities to invalidate the query cache for this query in response to + // mutations and other user actions. + invalidateContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements, + invalidateAllContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements, +} from "@gusto/embedded-api/react-query/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.js"; +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `request` | [operations.GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest](../../models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsrequest.md) | :heavy_check_mark: | The request object to use for the request. | +| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | +| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | +| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | + +### Response + +**Promise\<[operations.GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse](../../models/operations/getv1contractorpaymentgroupsidpartnerdisbursementsresponse.md)\>** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------------- | ------------------------------------- | ------------------------------------- | +| errors.UnprocessableEntityErrorObject | 404 | application/json | +| errors.APIError | 4XX, 5XX | \*/\* | + +## patchV1ContractorPaymentGroupsIdPartnerDisbursements + +Update partner disbursements for a specific contractor payment group. + +scope: `partner_disbursements:write` + + +### Example Usage + +```typescript +import { GustoEmbedded } from "@gusto/embedded-api"; + +const gustoEmbedded = new GustoEmbedded({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const result = await gustoEmbedded.contractorPaymentGroups.patchV1ContractorPaymentGroupsIdPartnerDisbursements({ + id: "", + requestBody: { + disbursements: [ + { + contractorPaymentUuid: "9f8e7d6c-5b4a-3928-1c2d-3e4f5a6b7c8d", + }, + ], + }, + }); + + console.log(result); +} + +run(); +``` + +### Standalone function + +The standalone function version of this method: + +```typescript +import { GustoEmbeddedCore } from "@gusto/embedded-api/core.js"; +import { contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements } from "@gusto/embedded-api/funcs/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.js"; + +// Use `GustoEmbeddedCore` for best tree-shaking performance. +// You can create one instance of it to use across an application. +const gustoEmbedded = new GustoEmbeddedCore({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const res = await contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements(gustoEmbedded, { + id: "", + requestBody: { + disbursements: [ + { + contractorPaymentUuid: "9f8e7d6c-5b4a-3928-1c2d-3e4f5a6b7c8d", + }, + ], + }, + }); + if (res.ok) { + const { value: result } = res; + console.log(result); + } else { + console.log("contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements failed:", res.error); + } +} + +run(); +``` + +### React hooks and utilities + +This method can be used in React components through the following hooks and +associated utilities. + +> Check out [this guide][hook-guide] for information about each of the utilities +> below and how to get started using React hooks. + +[hook-guide]: ../../../REACT_QUERY.md + +```tsx +import { + // Mutation hook for triggering the API call. + useContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutation +} from "@gusto/embedded-api/react-query/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.js"; +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `request` | [operations.PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest](../../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsrequest.md) | :heavy_check_mark: | The request object to use for the request. | +| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | +| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | +| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | + +### Response + +**Promise\<[operations.PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse](../../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursementsresponse.md)\>** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------------- | ------------------------------------- | ------------------------------------- | +| errors.UnprocessableEntityErrorObject | 404, 422 | application/json | | errors.APIError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/gusto_embedded/docs/sdks/employeeaddresses/README.md b/gusto_embedded/docs/sdks/employeeaddresses/README.md index 708321d8..bb20bb9a 100644 --- a/gusto_embedded/docs/sdks/employeeaddresses/README.md +++ b/gusto_embedded/docs/sdks/employeeaddresses/README.md @@ -135,6 +135,7 @@ scope: `employees:write` ```typescript import { GustoEmbedded } from "@gusto/embedded-api"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; const gustoEmbedded = new GustoEmbedded({ companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", @@ -144,10 +145,13 @@ async function run() { const result = await gustoEmbedded.employeeAddresses.create({ employeeId: "", requestBody: { - street1: "500 3rd Street", + street1: "300 3rd Street", + street2: null, city: "San Francisco", state: "CA", zip: "94107", + effectiveDate: new RFCDate("2021-01-01"), + courtesyWithholding: true, }, }); @@ -164,6 +168,7 @@ The standalone function version of this method: ```typescript import { GustoEmbeddedCore } from "@gusto/embedded-api/core.js"; import { employeeAddressesCreate } from "@gusto/embedded-api/funcs/employeeAddressesCreate.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; // Use `GustoEmbeddedCore` for best tree-shaking performance. // You can create one instance of it to use across an application. @@ -175,10 +180,13 @@ async function run() { const res = await employeeAddressesCreate(gustoEmbedded, { employeeId: "", requestBody: { - street1: "500 3rd Street", + street1: "300 3rd Street", + street2: null, city: "San Francisco", state: "CA", zip: "94107", + effectiveDate: new RFCDate("2021-01-01"), + courtesyWithholding: true, }, }); if (res.ok) { @@ -348,6 +356,7 @@ scope: `employees:write` ```typescript import { GustoEmbedded } from "@gusto/embedded-api"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; const gustoEmbedded = new GustoEmbedded({ companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", @@ -357,12 +366,14 @@ async function run() { const result = await gustoEmbedded.employeeAddresses.update({ homeAddressUuid: "", requestBody: { - version: "6c3c23e4cc840bd3f1416f72b5380eff", - street1: "600 4th Street", - city: "Miami", - state: "FL", - zip: "33173", - courtesyWithholding: false, + version: "fe75bd065ff48b91c35fe8ff842f986c", + street1: "300 3rd Street", + street2: null, + city: "San Francisco", + state: "CA", + zip: "94107", + effectiveDate: new RFCDate("2021-01-01"), + courtesyWithholding: true, }, }); @@ -379,6 +390,7 @@ The standalone function version of this method: ```typescript import { GustoEmbeddedCore } from "@gusto/embedded-api/core.js"; import { employeeAddressesUpdate } from "@gusto/embedded-api/funcs/employeeAddressesUpdate.js"; +import { RFCDate } from "@gusto/embedded-api/types/rfcdate.js"; // Use `GustoEmbeddedCore` for best tree-shaking performance. // You can create one instance of it to use across an application. @@ -390,12 +402,14 @@ async function run() { const res = await employeeAddressesUpdate(gustoEmbedded, { homeAddressUuid: "", requestBody: { - version: "6c3c23e4cc840bd3f1416f72b5380eff", - street1: "600 4th Street", - city: "Miami", - state: "FL", - zip: "33173", - courtesyWithholding: false, + version: "fe75bd065ff48b91c35fe8ff842f986c", + street1: "300 3rd Street", + street2: null, + city: "San Francisco", + state: "CA", + zip: "94107", + effectiveDate: new RFCDate("2021-01-01"), + courtesyWithholding: true, }, }); if (res.ok) { diff --git a/gusto_embedded/docs/sdks/employeetaxsetup/README.md b/gusto_embedded/docs/sdks/employeetaxsetup/README.md index 5faf4b06..42b1b414 100644 --- a/gusto_embedded/docs/sdks/employeetaxsetup/README.md +++ b/gusto_embedded/docs/sdks/employeetaxsetup/README.md @@ -375,6 +375,36 @@ async function run() { }, ], }, + { + key: "withholding_allowance", + answers: [ + { + value: 2, + validFrom: "2010-01-01", + validUpTo: null, + }, + ], + }, + { + key: "additional_withholding", + answers: [ + { + value: "25.0", + validFrom: "2010-01-01", + validUpTo: null, + }, + ], + }, + { + key: "file_new_hire_report", + answers: [ + { + value: true, + validFrom: "2010-01-01", + validUpTo: null, + }, + ], + }, ], }, ], @@ -419,6 +449,36 @@ async function run() { }, ], }, + { + key: "withholding_allowance", + answers: [ + { + value: 2, + validFrom: "2010-01-01", + validUpTo: null, + }, + ], + }, + { + key: "additional_withholding", + answers: [ + { + value: "25.0", + validFrom: "2010-01-01", + validUpTo: null, + }, + ], + }, + { + key: "file_new_hire_report", + answers: [ + { + value: true, + validFrom: "2010-01-01", + validUpTo: null, + }, + ], + }, ], }, ], diff --git a/gusto_embedded/docs/sdks/paymentconfigs/README.md b/gusto_embedded/docs/sdks/paymentconfigs/README.md index 4b579c4b..02fa5dfb 100644 --- a/gusto_embedded/docs/sdks/paymentconfigs/README.md +++ b/gusto_embedded/docs/sdks/paymentconfigs/README.md @@ -10,7 +10,7 @@ ## get -Get payment speed for the company and fast payment limit (1-day is only applicable to partners that opt in). +Get payment speed configurations for the company and fast payment limit (1-day is only applicable to partners that opt in). scope: `company_payment_configs:read` diff --git a/gusto_embedded/docs/sdks/payrolls/README.md b/gusto_embedded/docs/sdks/payrolls/README.md index 27f1e5d3..264b524d 100644 --- a/gusto_embedded/docs/sdks/payrolls/README.md +++ b/gusto_embedded/docs/sdks/payrolls/README.md @@ -22,6 +22,8 @@ * [getPayStub](#getpaystub) - Get an employee pay stub (pdf) * [getPayStubs](#getpaystubs) - Get an employee's pay stubs * [generatePrintableChecks](#generateprintablechecks) - Generate printable payroll checks (pdf) +* [getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements](#getv1companiescompanyidpayrollsidpartnerdisbursements) - Get partner disbursements for a payroll +* [patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements](#patchv1companiescompanyidpayrollsidpartnerdisbursements) - Update partner disbursements for a payroll ## list @@ -167,10 +169,10 @@ async function run() { const result = await gustoEmbedded.payrolls.createOffCycle({ companyId: "", requestBody: { - offCycle: true, - offCycleReason: "Bonus", - startDate: new RFCDate("2025-06-12"), - endDate: new RFCDate("2025-06-18"), + offCycle: false, + offCycleReason: "Correction", + startDate: new RFCDate(""), + endDate: new RFCDate(""), }, }); @@ -199,10 +201,10 @@ async function run() { const res = await payrollsCreateOffCycle(gustoEmbedded, { companyId: "", requestBody: { - offCycle: true, - offCycleReason: "Bonus", - startDate: new RFCDate("2025-06-12"), - endDate: new RFCDate("2025-06-18"), + offCycle: false, + offCycleReason: "Correction", + startDate: new RFCDate(""), + endDate: new RFCDate(""), }, }); if (res.ok) { @@ -368,6 +370,7 @@ Notes: scope: `payrolls:read` + ### Example Usage ```typescript @@ -462,9 +465,10 @@ import { ### Errors -| Error Type | Status Code | Content Type | -| --------------- | --------------- | --------------- | -| errors.APIError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| ------------------------------------- | ------------------------------------- | ------------------------------------- | +| errors.UnprocessableEntityErrorObject | 404 | application/json | +| errors.APIError | 4XX, 5XX | \*/\* | ## update @@ -475,6 +479,7 @@ will not be removed from the payroll. scope: `payrolls:write` + ### Example Usage ```typescript @@ -488,7 +493,7 @@ async function run() { const result = await gustoEmbedded.payrolls.update({ companyId: "", payrollId: "", - requestBody: { + payrollUpdate: { employeeCompensations: [ {}, {}, @@ -521,7 +526,7 @@ async function run() { const res = await payrollsUpdate(gustoEmbedded, { companyId: "", payrollId: "", - requestBody: { + payrollUpdate: { employeeCompensations: [ {}, {}, @@ -574,7 +579,7 @@ import { | Error Type | Status Code | Content Type | | ------------------------------------- | ------------------------------------- | ------------------------------------- | -| errors.UnprocessableEntityErrorObject | 422 | application/json | +| errors.UnprocessableEntityErrorObject | 404, 422 | application/json | | errors.APIError | 4XX, 5XX | \*/\* | ## delete @@ -585,6 +590,7 @@ By default the payroll and associated data is deleted synchronously. To request scope: `payrolls:run` + ### Example Usage ```typescript @@ -668,9 +674,10 @@ import { ### Errors -| Error Type | Status Code | Content Type | -| --------------- | --------------- | --------------- | -| errors.APIError | 4XX, 5XX | \*/\* | +| Error Type | Status Code | Content Type | +| ------------------------------------- | ------------------------------------- | ------------------------------------- | +| errors.UnprocessableEntityErrorObject | 404 | application/json | +| errors.APIError | 4XX, 5XX | \*/\* | ## prepare @@ -1793,4 +1800,219 @@ import { | Error Type | Status Code | Content Type | | ------------------------------------- | ------------------------------------- | ------------------------------------- | | errors.UnprocessableEntityErrorObject | 422 | application/json | +| errors.APIError | 4XX, 5XX | \*/\* | + +## getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements + +Get partner disbursements for a specific payroll. + +scope: `partner_disbursements:read` + + +### Example Usage + +```typescript +import { GustoEmbedded } from "@gusto/embedded-api"; + +const gustoEmbedded = new GustoEmbedded({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const result = await gustoEmbedded.payrolls.getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements({ + companyId: "", + id: "", + }); + + console.log(result); +} + +run(); +``` + +### Standalone function + +The standalone function version of this method: + +```typescript +import { GustoEmbeddedCore } from "@gusto/embedded-api/core.js"; +import { payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements } from "@gusto/embedded-api/funcs/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; + +// Use `GustoEmbeddedCore` for best tree-shaking performance. +// You can create one instance of it to use across an application. +const gustoEmbedded = new GustoEmbeddedCore({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const res = await payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements(gustoEmbedded, { + companyId: "", + id: "", + }); + if (res.ok) { + const { value: result } = res; + console.log(result); + } else { + console.log("payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements failed:", res.error); + } +} + +run(); +``` + +### React hooks and utilities + +This method can be used in React components through the following hooks and +associated utilities. + +> Check out [this guide][hook-guide] for information about each of the utilities +> below and how to get started using React hooks. + +[hook-guide]: ../../../REACT_QUERY.md + +```tsx +import { + // Query hooks for fetching data. + usePayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements, + usePayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsSuspense, + + // Utility for prefetching data during server-side rendering and in React + // Server Components that will be immediately available to client components + // using the hooks. + prefetchPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements, + + // Utilities to invalidate the query cache for this query in response to + // mutations and other user actions. + invalidatePayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements, + invalidateAllPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements, +} from "@gusto/embedded-api/react-query/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `request` | [operations.GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest](../../models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md) | :heavy_check_mark: | The request object to use for the request. | +| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | +| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | +| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | + +### Response + +**Promise\<[operations.GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse](../../models/operations/getv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md)\>** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------------- | ------------------------------------- | ------------------------------------- | +| errors.UnprocessableEntityErrorObject | 404 | application/json | +| errors.APIError | 4XX, 5XX | \*/\* | + +## patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements + +Update partner disbursements for a specific payroll. + +scope: `partner_disbursements:write` + + +### Example Usage + +```typescript +import { GustoEmbedded } from "@gusto/embedded-api"; + +const gustoEmbedded = new GustoEmbedded({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const result = await gustoEmbedded.payrolls.patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements({ + companyId: "", + id: "", + requestBody: { + disbursements: [ + { + employeeUuid: "1a2b3c4d-5e6f-7890-abcd-ef1234567890", + }, + ], + }, + }); + + console.log(result); +} + +run(); +``` + +### Standalone function + +The standalone function version of this method: + +```typescript +import { GustoEmbeddedCore } from "@gusto/embedded-api/core.js"; +import { payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements } from "@gusto/embedded-api/funcs/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; + +// Use `GustoEmbeddedCore` for best tree-shaking performance. +// You can create one instance of it to use across an application. +const gustoEmbedded = new GustoEmbeddedCore({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function run() { + const res = await payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements(gustoEmbedded, { + companyId: "", + id: "", + requestBody: { + disbursements: [ + { + employeeUuid: "1a2b3c4d-5e6f-7890-abcd-ef1234567890", + }, + ], + }, + }); + if (res.ok) { + const { value: result } = res; + console.log(result); + } else { + console.log("payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements failed:", res.error); + } +} + +run(); +``` + +### React hooks and utilities + +This method can be used in React components through the following hooks and +associated utilities. + +> Check out [this guide][hook-guide] for information about each of the utilities +> below and how to get started using React hooks. + +[hook-guide]: ../../../REACT_QUERY.md + +```tsx +import { + // Mutation hook for triggering the API call. + usePayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutation +} from "@gusto/embedded-api/react-query/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; +``` + +### Parameters + +| Parameter | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| `request` | [operations.PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest](../../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsrequest.md) | :heavy_check_mark: | The request object to use for the request. | +| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | +| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | +| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | + +### Response + +**Promise\<[operations.PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse](../../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursementsresponse.md)\>** + +### Errors + +| Error Type | Status Code | Content Type | +| ------------------------------------- | ------------------------------------- | ------------------------------------- | +| errors.UnprocessableEntityErrorObject | 404, 422 | application/json | | errors.APIError | 4XX, 5XX | \*/\* | \ No newline at end of file diff --git a/gusto_embedded/docs/sdks/reports/README.md b/gusto_embedded/docs/sdks/reports/README.md index dc8dc64d..b6c699e9 100644 --- a/gusto_embedded/docs/sdks/reports/README.md +++ b/gusto_embedded/docs/sdks/reports/README.md @@ -138,9 +138,9 @@ import { Create a general ledger report for a payroll. The report can be aggregated by different dimensions such as job or department. -Use the `request_uuid` in the response with the [report GET endpoint](https://docs.gusto.com/embedded-payroll/reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. +Use the `request_uuid` in the response with the [report GET endpoint](../reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. -scope: `company_reports:write` +scope: `company_reports:write` OR `company_reports:write:general_ledger` ### Example Usage @@ -238,6 +238,8 @@ import { Get a company's report given the `request_uuid`. The response will include the report request's status and, if complete, the report URL. +Reports containing PHI are inaccessible with `company_reports:read:tier_2_only` data scope + scope: `company_reports:read` ### Example Usage diff --git a/gusto_embedded/examples/.env.template b/gusto_embedded/examples/.env.template new file mode 100644 index 00000000..61c4d785 --- /dev/null +++ b/gusto_embedded/examples/.env.template @@ -0,0 +1,16 @@ +# @gusto/embedded-api SDK Environment Variables +# Copy this file to .env and fill in your actual values +# DO NOT commit the .env file to version control + +# Security Configuration +# The SDK supports loading security credentials from environment variables +# with the prefix: GUSTOEMBEDDED_ +# +# Example security environment variables: +# GUSTOEMBEDDED_API_KEY=your_api_key_here +# GUSTOEMBEDDED_BEARER_TOKEN=your_bearer_token_here +# GUSTOEMBEDDED_USERNAME=your_username_here +# GUSTOEMBEDDED_PASSWORD=your_password_here +# +# Check the SDK documentation for the exact environment variable names +# required for your specific authentication method. diff --git a/gusto_embedded/examples/README.md b/gusto_embedded/examples/README.md new file mode 100644 index 00000000..88bd5a0d --- /dev/null +++ b/gusto_embedded/examples/README.md @@ -0,0 +1,26 @@ +# @gusto/embedded-api Examples + +This directory contains example scripts demonstrating how to use the @gusto/embedded-api SDK. + +## Prerequisites + +- Node.js (v18 or higher) +- npm + +## Setup + +1. Copy `.env.template` to `.env`: + ```bash + cp .env.template .env + ``` + +2. Edit `.env` and add your actual credentials (API keys, tokens, etc.) + +## Running the Examples + +To run an example file from the examples directory: + +```bash +npm run build && npx tsx example.ts +``` + diff --git a/gusto_embedded/examples/introspectionGetInfo.example.ts b/gusto_embedded/examples/introspectionGetInfo.example.ts new file mode 100644 index 00000000..be4d9fdf --- /dev/null +++ b/gusto_embedded/examples/introspectionGetInfo.example.ts @@ -0,0 +1,24 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +/** + * Example usage of the @gusto/embedded-api SDK + * + * To run this example from the examples directory: + * npm run build && npx tsx introspectionGetInfo.ts + */ + +import { GustoEmbedded } from "@gusto/embedded-api"; + +const gustoEmbedded = new GustoEmbedded({ + companyAccessAuth: process.env["GUSTOEMBEDDED_COMPANY_ACCESS_AUTH"] ?? "", +}); + +async function main() { + const result = await gustoEmbedded.getInfo({}); + + console.log(result); +} + +main().catch(console.error); diff --git a/gusto_embedded/examples/package-lock.json b/gusto_embedded/examples/package-lock.json new file mode 100644 index 00000000..ec6b03f8 --- /dev/null +++ b/gusto_embedded/examples/package-lock.json @@ -0,0 +1,627 @@ +{ + "name": "@gusto/embedded-api-examples", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "@gusto/embedded-api-examples", + "version": "1.0.0", + "dependencies": { + "@gusto/embedded-api": "file:.." + }, + "devDependencies": { + "@types/node": "^20.0.0", + "dotenv": "^16.4.5", + "tsx": "^4.19.2" + } + }, + "..": { + "name": "@gusto/embedded-api", + "version": "0.6.5", + "devDependencies": { + "@eslint/js": "^9.19.0", + "@tanstack/react-query": "^5.61.4", + "@types/react": "^18.3.12", + "eslint": "^9.19.0", + "globals": "^15.14.0", + "typescript": "^5.4.5", + "typescript-eslint": "^8.22.0", + "zod": "^3.25.17" + }, + "peerDependencies": { + "@tanstack/react-query": "^5", + "react": "^18 || ^19", + "react-dom": "^18 || ^19", + "zod": "^3" + }, + "peerDependenciesMeta": { + "@tanstack/react-query": { + "optional": true + }, + "react": { + "optional": true + }, + "react-dom": { + "optional": true + } + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.6.tgz", + "integrity": "sha512-ShbM/3XxwuxjFiuVBHA+d3j5dyac0aEVVq1oluIDf71hUw0aRF59dV/efUsIwFnR6m8JNM2FjZOzmaZ8yG61kw==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.6.tgz", + "integrity": "sha512-S8ToEOVfg++AU/bHwdksHNnyLyVM+eMVAOf6yRKFitnwnbwwPNqKr3srzFRe7nzV69RQKb5DgchIX5pt3L53xg==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.6.tgz", + "integrity": "sha512-hd5zdUarsK6strW+3Wxi5qWws+rJhCCbMiC9QZyzoxfk5uHRIE8T287giQxzVpEvCwuJ9Qjg6bEjcRJcgfLqoA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.6.tgz", + "integrity": "sha512-0Z7KpHSr3VBIO9A/1wcT3NTy7EB4oNC4upJ5ye3R7taCc2GUdeynSLArnon5G8scPwaU866d3H4BCrE5xLW25A==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.6.tgz", + "integrity": "sha512-FFCssz3XBavjxcFxKsGy2DYK5VSvJqa6y5HXljKzhRZ87LvEi13brPrf/wdyl/BbpbMKJNOr1Sd0jtW4Ge1pAA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.6.tgz", + "integrity": "sha512-GfXs5kry/TkGM2vKqK2oyiLFygJRqKVhawu3+DOCk7OxLy/6jYkWXhlHwOoTb0WqGnWGAS7sooxbZowy+pK9Yg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.6.tgz", + "integrity": "sha512-aoLF2c3OvDn2XDTRvn8hN6DRzVVpDlj2B/F66clWd/FHLiHaG3aVZjxQX2DYphA5y/evbdGvC6Us13tvyt4pWg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.6.tgz", + "integrity": "sha512-2SkqTjTSo2dYi/jzFbU9Plt1vk0+nNg8YC8rOXXea+iA3hfNJWebKYPs3xnOUf9+ZWhKAaxnQNUf2X9LOpeiMQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.6.tgz", + "integrity": "sha512-SZHQlzvqv4Du5PrKE2faN0qlbsaW/3QQfUUc6yO2EjFcA83xnwm91UbEEVx4ApZ9Z5oG8Bxz4qPE+HFwtVcfyw==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.6.tgz", + "integrity": "sha512-b967hU0gqKd9Drsh/UuAm21Khpoh6mPBSgz8mKRq4P5mVK8bpA+hQzmm/ZwGVULSNBzKdZPQBRT3+WuVavcWsQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.6.tgz", + "integrity": "sha512-aHWdQ2AAltRkLPOsKdi3xv0mZ8fUGPdlKEjIEhxCPm5yKEThcUjHpWB1idN74lfXGnZ5SULQSgtr5Qos5B0bPw==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.6.tgz", + "integrity": "sha512-VgKCsHdXRSQ7E1+QXGdRPlQ/e08bN6WMQb27/TMfV+vPjjTImuT9PmLXupRlC90S1JeNNW5lzkAEO/McKeJ2yg==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.6.tgz", + "integrity": "sha512-WViNlpivRKT9/py3kCmkHnn44GkGXVdXfdc4drNmRl15zVQ2+D2uFwdlGh6IuK5AAnGTo2qPB1Djppj+t78rzw==", + "cpu": [ + "mips64el" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.6.tgz", + "integrity": "sha512-wyYKZ9NTdmAMb5730I38lBqVu6cKl4ZfYXIs31Baf8aoOtB4xSGi3THmDYt4BTFHk7/EcVixkOV2uZfwU3Q2Jw==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.6.tgz", + "integrity": "sha512-KZh7bAGGcrinEj4qzilJ4hqTY3Dg2U82c8bv+e1xqNqZCrCyc+TL9AUEn5WGKDzm3CfC5RODE/qc96OcbIe33w==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.6.tgz", + "integrity": "sha512-9N1LsTwAuE9oj6lHMyyAM+ucxGiVnEqUdp4v7IaMmrwb06ZTEVCIs3oPPplVsnjPfyjmxwHxHMF8b6vzUVAUGw==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.6.tgz", + "integrity": "sha512-A6bJB41b4lKFWRKNrWoP2LHsjVzNiaurf7wyj/XtFNTsnPuxwEBWHLty+ZE0dWBKuSK1fvKgrKaNjBS7qbFKig==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.6.tgz", + "integrity": "sha512-IjA+DcwoVpjEvyxZddDqBY+uJ2Snc6duLpjmkXm/v4xuS3H+3FkLZlDm9ZsAbF9rsfP3zeA0/ArNDORZgrxR/Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.6.tgz", + "integrity": "sha512-dUXuZr5WenIDlMHdMkvDc1FAu4xdWixTCRgP7RQLBOkkGgwuuzaGSYcOpW4jFxzpzL1ejb8yF620UxAqnBrR9g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.6.tgz", + "integrity": "sha512-l8ZCvXP0tbTJ3iaqdNf3pjaOSd5ex/e6/omLIQCVBLmHTlfXW3zAxQ4fnDmPLOB1x9xrcSi/xtCWFwCZRIaEwg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.6.tgz", + "integrity": "sha512-hKrmDa0aOFOr71KQ/19JC7az1P0GWtCN1t2ahYAf4O007DHZt/dW8ym5+CUdJhQ/qkZmI1HAF8KkJbEFtCL7gw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openharmony-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.25.6.tgz", + "integrity": "sha512-+SqBcAWoB1fYKmpWoQP4pGtx+pUUC//RNYhFdbcSA16617cchuryuhOCRpPsjCblKukAckWsV+aQ3UKT/RMPcA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openharmony" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.6.tgz", + "integrity": "sha512-dyCGxv1/Br7MiSC42qinGL8KkG4kX0pEsdb0+TKhmJZgCUDBGmyo1/ArCjNGiOLiIAgdbWgmWgib4HoCi5t7kA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.6.tgz", + "integrity": "sha512-42QOgcZeZOvXfsCBJF5Afw73t4veOId//XD3i+/9gSkhSV6Gk3VPlWncctI+JcOyERv85FUo7RxuxGy+z8A43Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.6.tgz", + "integrity": "sha512-4AWhgXmDuYN7rJI6ORB+uU9DHLq/erBbuMoAuB4VWJTu5KtCgcKYPynF0YI1VkBNuEfjNlLrFr9KZPJzrtLkrQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.6.tgz", + "integrity": "sha512-NgJPHHbEpLQgDH2MjQu90pzW/5vvXIZ7KOnPyNBm92A6WgZ/7b6fJyUBjoumLqeOQQGqY2QjQxRo97ah4Sj0cA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@gusto/embedded-api": { + "resolved": "..", + "link": true + }, + "node_modules/@types/node": { + "version": "20.19.8", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.8.tgz", + "integrity": "sha512-HzbgCY53T6bfu4tT7Aq3TvViJyHjLjPNaAS3HOuMc9pw97KHsUtXNX4L+wu59g1WnjsZSko35MbEqnO58rihhw==", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/dotenv": { + "version": "16.6.1", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.6.1.tgz", + "integrity": "sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://dotenvx.com" + } + }, + "node_modules/esbuild": { + "version": "0.25.6", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.6.tgz", + "integrity": "sha512-GVuzuUwtdsghE3ocJ9Bs8PNoF13HNQ5TXbEi2AhvVb8xU1Iwt9Fos9FEamfoee+u/TOsn7GUWc04lz46n2bbTg==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.25.6", + "@esbuild/android-arm": "0.25.6", + "@esbuild/android-arm64": "0.25.6", + "@esbuild/android-x64": "0.25.6", + "@esbuild/darwin-arm64": "0.25.6", + "@esbuild/darwin-x64": "0.25.6", + "@esbuild/freebsd-arm64": "0.25.6", + "@esbuild/freebsd-x64": "0.25.6", + "@esbuild/linux-arm": "0.25.6", + "@esbuild/linux-arm64": "0.25.6", + "@esbuild/linux-ia32": "0.25.6", + "@esbuild/linux-loong64": "0.25.6", + "@esbuild/linux-mips64el": "0.25.6", + "@esbuild/linux-ppc64": "0.25.6", + "@esbuild/linux-riscv64": "0.25.6", + "@esbuild/linux-s390x": "0.25.6", + "@esbuild/linux-x64": "0.25.6", + "@esbuild/netbsd-arm64": "0.25.6", + "@esbuild/netbsd-x64": "0.25.6", + "@esbuild/openbsd-arm64": "0.25.6", + "@esbuild/openbsd-x64": "0.25.6", + "@esbuild/openharmony-arm64": "0.25.6", + "@esbuild/sunos-x64": "0.25.6", + "@esbuild/win32-arm64": "0.25.6", + "@esbuild/win32-ia32": "0.25.6", + "@esbuild/win32-x64": "0.25.6" + } + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/get-tsconfig": { + "version": "4.10.1", + "resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.10.1.tgz", + "integrity": "sha512-auHyJ4AgMz7vgS8Hp3N6HXSmlMdUyhSUrfBF16w153rxtLIEOE+HGqaBppczZvnHLqQJfiHotCYpNhl0lUROFQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "resolve-pkg-maps": "^1.0.0" + }, + "funding": { + "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" + } + }, + "node_modules/resolve-pkg-maps": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz", + "integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" + } + }, + "node_modules/tsx": { + "version": "4.20.3", + "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.20.3.tgz", + "integrity": "sha512-qjbnuR9Tr+FJOMBqJCW5ehvIo/buZq7vH7qD7JziU98h6l3qGy0a/yPFjwO+y0/T7GFpNgNAvEcPPVfyT8rrPQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "~0.25.0", + "get-tsconfig": "^4.7.5" + }, + "bin": { + "tsx": "dist/cli.mjs" + }, + "engines": { + "node": ">=18.0.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "dev": true, + "license": "MIT" + } + } +} diff --git a/gusto_embedded/examples/package.json b/gusto_embedded/examples/package.json new file mode 100644 index 00000000..49ec9138 --- /dev/null +++ b/gusto_embedded/examples/package.json @@ -0,0 +1,18 @@ +{ + "name": "@gusto/embedded-api-examples", + "version": "1.0.0", + "private": true, + "scripts": { + "build:parent": "cd .. && npm i && npm run build && cd -", + "build:examples": "npm i", + "build": "npm run build:parent && npm run build:examples" + }, + "devDependencies": { + "@types/node": "^20.0.0", + "dotenv": "^16.4.5", + "tsx": "^4.19.2" + }, + "dependencies": { + "@gusto/embedded-api": "file:.." + } +} \ No newline at end of file diff --git a/gusto_embedded/jsr.json b/gusto_embedded/jsr.json index e92ea164..0506e0d2 100644 --- a/gusto_embedded/jsr.json +++ b/gusto_embedded/jsr.json @@ -2,7 +2,7 @@ { "name": "@gusto/embedded-api", - "version": "0.6.4", + "version": "0.6.5", "exports": { ".": "./src/index.ts", "./models/errors": "./src/models/errors/index.ts", diff --git a/gusto_embedded/package-lock.json b/gusto_embedded/package-lock.json index 68164577..3f010b8b 100644 --- a/gusto_embedded/package-lock.json +++ b/gusto_embedded/package-lock.json @@ -1,12 +1,12 @@ { "name": "@gusto/embedded-api", - "version": "0.6.4", + "version": "0.6.5", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@gusto/embedded-api", - "version": "0.6.4", + "version": "0.6.5", "devDependencies": { "@eslint/js": "^9.19.0", "@tanstack/react-query": "^5.61.4", @@ -21,7 +21,7 @@ "@tanstack/react-query": "^5", "react": "^18 || ^19", "react-dom": "^18 || ^19", - "zod": ">= 3" + "zod": "^3" }, "peerDependenciesMeta": { "@tanstack/react-query": { diff --git a/gusto_embedded/package.json b/gusto_embedded/package.json index c9d73eff..1e959392 100644 --- a/gusto_embedded/package.json +++ b/gusto_embedded/package.json @@ -1,6 +1,6 @@ { "name": "@gusto/embedded-api", - "version": "0.6.4", + "version": "0.6.5", "author": "Speakeasy", "type": "module", "main": "./esm/index.js", @@ -37,7 +37,7 @@ "@tanstack/react-query": "^5", "react": "^18 || ^19", "react-dom": "^18 || ^19", - "zod": ">= 3" + "zod": "^3" }, "peerDependenciesMeta": { "@tanstack/react-query": {"optional":true}, diff --git a/gusto_embedded/src/funcs/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts b/gusto_embedded/src/funcs/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts new file mode 100644 index 00000000..884f842c --- /dev/null +++ b/gusto_embedded/src/funcs/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts @@ -0,0 +1,200 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { GustoEmbeddedCore } from "../core.js"; +import { encodeSimple } from "../lib/encodings.js"; +import * as M from "../lib/matchers.js"; +import { compactMap } from "../lib/primitives.js"; +import { safeParse } from "../lib/schemas.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js"; +import { pathToFunc } from "../lib/url.js"; +import { GustoEmbeddedError } from "../models/errors/gustoembeddederror.js"; +import { + ConnectionError, + InvalidRequestError, + RequestAbortedError, + RequestTimeoutError, + UnexpectedClientError, +} from "../models/errors/httpclienterrors.js"; +import { ResponseValidationError } from "../models/errors/responsevalidationerror.js"; +import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; +import { + UnprocessableEntityErrorObject, + UnprocessableEntityErrorObject$inboundSchema, +} from "../models/errors/unprocessableentityerrorobject.js"; +import { + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema, +} from "../models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.js"; +import { APICall, APIPromise } from "../types/async.js"; +import { Result } from "../types/fp.js"; + +/** + * Get partner disbursements for a contractor payment group + * + * @remarks + * Get partner disbursements for a specific contractor payment group. + * + * scope: `partner_disbursements:read` + */ +export function contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + client: GustoEmbeddedCore, + request: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): APIPromise< + Result< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + > +> { + return new APIPromise($do( + client, + request, + options, + )); +} + +async function $do( + client: GustoEmbeddedCore, + request: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): Promise< + [ + Result< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >, + APICall, + ] +> { + const parsed = safeParse( + request, + (value) => + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema + .parse(value), + "Input validation failed", + ); + if (!parsed.ok) { + return [parsed, { status: "invalid" }]; + } + const payload = parsed.value; + const body = null; + + const pathParams = { + id: encodeSimple("id", payload.id, { + explode: false, + charEncoding: "percent", + }), + }; + + const path = pathToFunc( + "/v1/contractor_payment_groups/{id}/partner_disbursements", + )(pathParams); + + const headers = new Headers(compactMap({ + Accept: "application/json", + "X-Gusto-API-Version": encodeSimple( + "X-Gusto-API-Version", + payload["X-Gusto-API-Version"], + { explode: false, charEncoding: "none" }, + ), + })); + + const secConfig = await extractSecurity(client._options.companyAccessAuth); + const securityInput = secConfig == null + ? {} + : { companyAccessAuth: secConfig }; + const requestSecurity = resolveGlobalSecurity(securityInput); + + const context = { + options: client._options, + baseURL: options?.serverURL ?? client._baseURL ?? "", + operationID: "get-v1-contractor_payment_groups-id-partner_disbursements", + oAuth2Scopes: [], + + resolvedSecurity: requestSecurity, + + securitySource: client._options.companyAccessAuth, + retryConfig: options?.retries + || client._options.retryConfig + || { strategy: "none" }, + retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"], + }; + + const requestRes = client._createRequest(context, { + security: requestSecurity, + method: "GET", + baseURL: options?.serverURL, + path: path, + headers: headers, + body: body, + userAgent: client._options.userAgent, + timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1, + }, options); + if (!requestRes.ok) { + return [requestRes, { status: "invalid" }]; + } + const req = requestRes.value; + + const doResult = await client._do(req, { + context, + errorCodes: ["404", "4XX", "5XX"], + retryConfig: context.retryConfig, + retryCodes: context.retryCodes, + }); + if (!doResult.ok) { + return [doResult, { status: "request-error", request: req }]; + } + const response = doResult.value; + + const responseFields = { + HttpMeta: { Response: response, Request: req }, + }; + + const [result] = await M.match< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >( + M.json( + 200, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema, + { key: "Contractor-Payment-Group-Partner-Disbursements" }, + ), + M.jsonErr(404, UnprocessableEntityErrorObject$inboundSchema), + M.fail("4XX"), + M.fail("5XX"), + )(response, req, { extraFields: responseFields }); + if (!result.ok) { + return [result, { status: "complete", request: req, response }]; + } + + return [result, { status: "complete", request: req, response }]; +} diff --git a/gusto_embedded/src/funcs/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts b/gusto_embedded/src/funcs/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts new file mode 100644 index 00000000..f96aad3c --- /dev/null +++ b/gusto_embedded/src/funcs/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts @@ -0,0 +1,201 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { GustoEmbeddedCore } from "../core.js"; +import { encodeJSON, encodeSimple } from "../lib/encodings.js"; +import * as M from "../lib/matchers.js"; +import { compactMap } from "../lib/primitives.js"; +import { safeParse } from "../lib/schemas.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js"; +import { pathToFunc } from "../lib/url.js"; +import { GustoEmbeddedError } from "../models/errors/gustoembeddederror.js"; +import { + ConnectionError, + InvalidRequestError, + RequestAbortedError, + RequestTimeoutError, + UnexpectedClientError, +} from "../models/errors/httpclienterrors.js"; +import { ResponseValidationError } from "../models/errors/responsevalidationerror.js"; +import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; +import { + UnprocessableEntityErrorObject, + UnprocessableEntityErrorObject$inboundSchema, +} from "../models/errors/unprocessableentityerrorobject.js"; +import { + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema, +} from "../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; +import { APICall, APIPromise } from "../types/async.js"; +import { Result } from "../types/fp.js"; + +/** + * Update partner disbursements for a contractor payment group + * + * @remarks + * Update partner disbursements for a specific contractor payment group. + * + * scope: `partner_disbursements:write` + */ +export function contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements( + client: GustoEmbeddedCore, + request: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): APIPromise< + Result< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + > +> { + return new APIPromise($do( + client, + request, + options, + )); +} + +async function $do( + client: GustoEmbeddedCore, + request: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): Promise< + [ + Result< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >, + APICall, + ] +> { + const parsed = safeParse( + request, + (value) => + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema + .parse(value), + "Input validation failed", + ); + if (!parsed.ok) { + return [parsed, { status: "invalid" }]; + } + const payload = parsed.value; + const body = encodeJSON("body", payload.RequestBody, { explode: true }); + + const pathParams = { + id: encodeSimple("id", payload.id, { + explode: false, + charEncoding: "percent", + }), + }; + + const path = pathToFunc( + "/v1/contractor_payment_groups/{id}/partner_disbursements", + )(pathParams); + + const headers = new Headers(compactMap({ + "Content-Type": "application/json", + Accept: "application/json", + "X-Gusto-API-Version": encodeSimple( + "X-Gusto-API-Version", + payload["X-Gusto-API-Version"], + { explode: false, charEncoding: "none" }, + ), + })); + + const secConfig = await extractSecurity(client._options.companyAccessAuth); + const securityInput = secConfig == null + ? {} + : { companyAccessAuth: secConfig }; + const requestSecurity = resolveGlobalSecurity(securityInput); + + const context = { + options: client._options, + baseURL: options?.serverURL ?? client._baseURL ?? "", + operationID: "patch-v1-contractor_payment_groups-id-partner_disbursements", + oAuth2Scopes: [], + + resolvedSecurity: requestSecurity, + + securitySource: client._options.companyAccessAuth, + retryConfig: options?.retries + || client._options.retryConfig + || { strategy: "none" }, + retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"], + }; + + const requestRes = client._createRequest(context, { + security: requestSecurity, + method: "PATCH", + baseURL: options?.serverURL, + path: path, + headers: headers, + body: body, + userAgent: client._options.userAgent, + timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1, + }, options); + if (!requestRes.ok) { + return [requestRes, { status: "invalid" }]; + } + const req = requestRes.value; + + const doResult = await client._do(req, { + context, + errorCodes: ["404", "422", "4XX", "5XX"], + retryConfig: context.retryConfig, + retryCodes: context.retryCodes, + }); + if (!doResult.ok) { + return [doResult, { status: "request-error", request: req }]; + } + const response = doResult.value; + + const responseFields = { + HttpMeta: { Response: response, Request: req }, + }; + + const [result] = await M.match< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >( + M.json( + 200, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema, + { key: "Contractor-Payment-Group-Partner-Disbursements" }, + ), + M.jsonErr([404, 422], UnprocessableEntityErrorObject$inboundSchema), + M.fail("4XX"), + M.fail("5XX"), + )(response, req, { extraFields: responseFields }); + if (!result.ok) { + return [result, { status: "complete", request: req, response }]; + } + + return [result, { status: "complete", request: req, response }]; +} diff --git a/gusto_embedded/src/funcs/employeesList.ts b/gusto_embedded/src/funcs/employeesList.ts index 85263e00..b4f6e0b0 100644 --- a/gusto_embedded/src/funcs/employeesList.ts +++ b/gusto_embedded/src/funcs/employeesList.ts @@ -117,6 +117,7 @@ async function $do( "per": payload.per, "search_term": payload.search_term, "terminated": payload.terminated, + "uuids": payload.uuids, }), ); @@ -194,7 +195,7 @@ async function $do( | SDKValidationError >( M.json(200, GetV1CompaniesCompanyIdEmployeesResponse$inboundSchema, { - key: "Employees", + key: "Show-Employees", }), M.jsonErr(404, UnprocessableEntityErrorObject$inboundSchema), M.fail("4XX"), diff --git a/gusto_embedded/src/funcs/paymentConfigsGet.ts b/gusto_embedded/src/funcs/paymentConfigsGet.ts index 4b7aa25d..d77077fb 100644 --- a/gusto_embedded/src/funcs/paymentConfigsGet.ts +++ b/gusto_embedded/src/funcs/paymentConfigsGet.ts @@ -33,7 +33,7 @@ import { Result } from "../types/fp.js"; * Get a company's payment configs * * @remarks - * Get payment speed for the company and fast payment limit (1-day is only applicable to partners that opt in). + * Get payment speed configurations for the company and fast payment limit (1-day is only applicable to partners that opt in). * * scope: `company_payment_configs:read` */ diff --git a/gusto_embedded/src/funcs/payrollsDelete.ts b/gusto_embedded/src/funcs/payrollsDelete.ts index 32923020..28d30201 100644 --- a/gusto_embedded/src/funcs/payrollsDelete.ts +++ b/gusto_embedded/src/funcs/payrollsDelete.ts @@ -20,6 +20,10 @@ import { } from "../models/errors/httpclienterrors.js"; import { ResponseValidationError } from "../models/errors/responsevalidationerror.js"; import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; +import { + UnprocessableEntityErrorObject, + UnprocessableEntityErrorObject$inboundSchema, +} from "../models/errors/unprocessableentityerrorobject.js"; import { DeleteV1CompaniesCompanyIdPayrollsRequest, DeleteV1CompaniesCompanyIdPayrollsRequest$outboundSchema, @@ -46,6 +50,7 @@ export function payrollsDelete( ): APIPromise< Result< DeleteV1CompaniesCompanyIdPayrollsResponse, + | UnprocessableEntityErrorObject | GustoEmbeddedError | ResponseValidationError | ConnectionError @@ -71,6 +76,7 @@ async function $do( [ Result< DeleteV1CompaniesCompanyIdPayrollsResponse, + | UnprocessableEntityErrorObject | GustoEmbeddedError | ResponseValidationError | ConnectionError @@ -115,7 +121,7 @@ async function $do( }); const headers = new Headers(compactMap({ - Accept: "*/*", + Accept: "application/json", "X-Gusto-API-Version": encodeSimple( "X-Gusto-API-Version", payload["X-Gusto-API-Version"], @@ -162,7 +168,7 @@ async function $do( const doResult = await client._do(req, { context, - errorCodes: ["404", "422", "4XX", "5XX"], + errorCodes: ["404", "4XX", "5XX"], retryConfig: context.retryConfig, retryCodes: context.retryCodes, }); @@ -177,6 +183,7 @@ async function $do( const [result] = await M.match< DeleteV1CompaniesCompanyIdPayrollsResponse, + | UnprocessableEntityErrorObject | GustoEmbeddedError | ResponseValidationError | ConnectionError @@ -187,7 +194,8 @@ async function $do( | SDKValidationError >( M.nil([202, 204], DeleteV1CompaniesCompanyIdPayrollsResponse$inboundSchema), - M.fail([404, 422, "4XX"]), + M.jsonErr(404, UnprocessableEntityErrorObject$inboundSchema), + M.fail("4XX"), M.fail("5XX"), )(response, req, { extraFields: responseFields }); if (!result.ok) { diff --git a/gusto_embedded/src/funcs/payrollsGet.ts b/gusto_embedded/src/funcs/payrollsGet.ts index 00ec05a0..350bcb41 100644 --- a/gusto_embedded/src/funcs/payrollsGet.ts +++ b/gusto_embedded/src/funcs/payrollsGet.ts @@ -20,6 +20,10 @@ import { } from "../models/errors/httpclienterrors.js"; import { ResponseValidationError } from "../models/errors/responsevalidationerror.js"; import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; +import { + UnprocessableEntityErrorObject, + UnprocessableEntityErrorObject$inboundSchema, +} from "../models/errors/unprocessableentityerrorobject.js"; import { GetV1CompaniesCompanyIdPayrollsPayrollIdRequest, GetV1CompaniesCompanyIdPayrollsPayrollIdRequest$outboundSchema, @@ -51,6 +55,7 @@ export function payrollsGet( ): APIPromise< Result< GetV1CompaniesCompanyIdPayrollsPayrollIdResponse, + | UnprocessableEntityErrorObject | GustoEmbeddedError | ResponseValidationError | ConnectionError @@ -76,6 +81,7 @@ async function $do( [ Result< GetV1CompaniesCompanyIdPayrollsPayrollIdResponse, + | UnprocessableEntityErrorObject | GustoEmbeddedError | ResponseValidationError | ConnectionError @@ -184,6 +190,7 @@ async function $do( const [result] = await M.match< GetV1CompaniesCompanyIdPayrollsPayrollIdResponse, + | UnprocessableEntityErrorObject | GustoEmbeddedError | ResponseValidationError | ConnectionError @@ -198,7 +205,8 @@ async function $do( GetV1CompaniesCompanyIdPayrollsPayrollIdResponse$inboundSchema, { key: "Payroll" }, ), - M.fail([404, "4XX"]), + M.jsonErr(404, UnprocessableEntityErrorObject$inboundSchema), + M.fail("4XX"), M.fail("5XX"), )(response, req, { extraFields: responseFields }); if (!result.ok) { diff --git a/gusto_embedded/src/funcs/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts b/gusto_embedded/src/funcs/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts new file mode 100644 index 00000000..826c9e9f --- /dev/null +++ b/gusto_embedded/src/funcs/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts @@ -0,0 +1,205 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { GustoEmbeddedCore } from "../core.js"; +import { encodeSimple } from "../lib/encodings.js"; +import * as M from "../lib/matchers.js"; +import { compactMap } from "../lib/primitives.js"; +import { safeParse } from "../lib/schemas.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js"; +import { pathToFunc } from "../lib/url.js"; +import { GustoEmbeddedError } from "../models/errors/gustoembeddederror.js"; +import { + ConnectionError, + InvalidRequestError, + RequestAbortedError, + RequestTimeoutError, + UnexpectedClientError, +} from "../models/errors/httpclienterrors.js"; +import { ResponseValidationError } from "../models/errors/responsevalidationerror.js"; +import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; +import { + UnprocessableEntityErrorObject, + UnprocessableEntityErrorObject$inboundSchema, +} from "../models/errors/unprocessableentityerrorobject.js"; +import { + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema, +} from "../models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.js"; +import { APICall, APIPromise } from "../types/async.js"; +import { Result } from "../types/fp.js"; + +/** + * Get partner disbursements for a payroll + * + * @remarks + * Get partner disbursements for a specific payroll. + * + * scope: `partner_disbursements:read` + */ +export function payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + client: GustoEmbeddedCore, + request: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): APIPromise< + Result< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + > +> { + return new APIPromise($do( + client, + request, + options, + )); +} + +async function $do( + client: GustoEmbeddedCore, + request: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): Promise< + [ + Result< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >, + APICall, + ] +> { + const parsed = safeParse( + request, + (value) => + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema + .parse(value), + "Input validation failed", + ); + if (!parsed.ok) { + return [parsed, { status: "invalid" }]; + } + const payload = parsed.value; + const body = null; + + const pathParams = { + company_id: encodeSimple("company_id", payload.company_id, { + explode: false, + charEncoding: "percent", + }), + id: encodeSimple("id", payload.id, { + explode: false, + charEncoding: "percent", + }), + }; + + const path = pathToFunc( + "/v1/companies/{company_id}/payrolls/{id}/partner_disbursements", + )(pathParams); + + const headers = new Headers(compactMap({ + Accept: "application/json", + "X-Gusto-API-Version": encodeSimple( + "X-Gusto-API-Version", + payload["X-Gusto-API-Version"], + { explode: false, charEncoding: "none" }, + ), + })); + + const secConfig = await extractSecurity(client._options.companyAccessAuth); + const securityInput = secConfig == null + ? {} + : { companyAccessAuth: secConfig }; + const requestSecurity = resolveGlobalSecurity(securityInput); + + const context = { + options: client._options, + baseURL: options?.serverURL ?? client._baseURL ?? "", + operationID: + "get-v1-companies-company_id-payrolls-id-partner_disbursements", + oAuth2Scopes: [], + + resolvedSecurity: requestSecurity, + + securitySource: client._options.companyAccessAuth, + retryConfig: options?.retries + || client._options.retryConfig + || { strategy: "none" }, + retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"], + }; + + const requestRes = client._createRequest(context, { + security: requestSecurity, + method: "GET", + baseURL: options?.serverURL, + path: path, + headers: headers, + body: body, + userAgent: client._options.userAgent, + timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1, + }, options); + if (!requestRes.ok) { + return [requestRes, { status: "invalid" }]; + } + const req = requestRes.value; + + const doResult = await client._do(req, { + context, + errorCodes: ["404", "4XX", "5XX"], + retryConfig: context.retryConfig, + retryCodes: context.retryCodes, + }); + if (!doResult.ok) { + return [doResult, { status: "request-error", request: req }]; + } + const response = doResult.value; + + const responseFields = { + HttpMeta: { Response: response, Request: req }, + }; + + const [result] = await M.match< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >( + M.json( + 200, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema, + { key: "Payroll-Partner-Disbursements" }, + ), + M.jsonErr(404, UnprocessableEntityErrorObject$inboundSchema), + M.fail("4XX"), + M.fail("5XX"), + )(response, req, { extraFields: responseFields }); + if (!result.ok) { + return [result, { status: "complete", request: req, response }]; + } + + return [result, { status: "complete", request: req, response }]; +} diff --git a/gusto_embedded/src/funcs/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts b/gusto_embedded/src/funcs/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts new file mode 100644 index 00000000..d56bf14c --- /dev/null +++ b/gusto_embedded/src/funcs/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts @@ -0,0 +1,206 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { GustoEmbeddedCore } from "../core.js"; +import { encodeJSON, encodeSimple } from "../lib/encodings.js"; +import * as M from "../lib/matchers.js"; +import { compactMap } from "../lib/primitives.js"; +import { safeParse } from "../lib/schemas.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js"; +import { pathToFunc } from "../lib/url.js"; +import { GustoEmbeddedError } from "../models/errors/gustoembeddederror.js"; +import { + ConnectionError, + InvalidRequestError, + RequestAbortedError, + RequestTimeoutError, + UnexpectedClientError, +} from "../models/errors/httpclienterrors.js"; +import { ResponseValidationError } from "../models/errors/responsevalidationerror.js"; +import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; +import { + UnprocessableEntityErrorObject, + UnprocessableEntityErrorObject$inboundSchema, +} from "../models/errors/unprocessableentityerrorobject.js"; +import { + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema, +} from "../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; +import { APICall, APIPromise } from "../types/async.js"; +import { Result } from "../types/fp.js"; + +/** + * Update partner disbursements for a payroll + * + * @remarks + * Update partner disbursements for a specific payroll. + * + * scope: `partner_disbursements:write` + */ +export function payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + client: GustoEmbeddedCore, + request: PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): APIPromise< + Result< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + > +> { + return new APIPromise($do( + client, + request, + options, + )); +} + +async function $do( + client: GustoEmbeddedCore, + request: PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): Promise< + [ + Result< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >, + APICall, + ] +> { + const parsed = safeParse( + request, + (value) => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema + .parse(value), + "Input validation failed", + ); + if (!parsed.ok) { + return [parsed, { status: "invalid" }]; + } + const payload = parsed.value; + const body = encodeJSON("body", payload.RequestBody, { explode: true }); + + const pathParams = { + company_id: encodeSimple("company_id", payload.company_id, { + explode: false, + charEncoding: "percent", + }), + id: encodeSimple("id", payload.id, { + explode: false, + charEncoding: "percent", + }), + }; + + const path = pathToFunc( + "/v1/companies/{company_id}/payrolls/{id}/partner_disbursements", + )(pathParams); + + const headers = new Headers(compactMap({ + "Content-Type": "application/json", + Accept: "application/json", + "X-Gusto-API-Version": encodeSimple( + "X-Gusto-API-Version", + payload["X-Gusto-API-Version"], + { explode: false, charEncoding: "none" }, + ), + })); + + const secConfig = await extractSecurity(client._options.companyAccessAuth); + const securityInput = secConfig == null + ? {} + : { companyAccessAuth: secConfig }; + const requestSecurity = resolveGlobalSecurity(securityInput); + + const context = { + options: client._options, + baseURL: options?.serverURL ?? client._baseURL ?? "", + operationID: + "patch-v1-companies-company_id-payrolls-id-partner_disbursements", + oAuth2Scopes: [], + + resolvedSecurity: requestSecurity, + + securitySource: client._options.companyAccessAuth, + retryConfig: options?.retries + || client._options.retryConfig + || { strategy: "none" }, + retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"], + }; + + const requestRes = client._createRequest(context, { + security: requestSecurity, + method: "PATCH", + baseURL: options?.serverURL, + path: path, + headers: headers, + body: body, + userAgent: client._options.userAgent, + timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1, + }, options); + if (!requestRes.ok) { + return [requestRes, { status: "invalid" }]; + } + const req = requestRes.value; + + const doResult = await client._do(req, { + context, + errorCodes: ["404", "422", "4XX", "5XX"], + retryConfig: context.retryConfig, + retryCodes: context.retryCodes, + }); + if (!doResult.ok) { + return [doResult, { status: "request-error", request: req }]; + } + const response = doResult.value; + + const responseFields = { + HttpMeta: { Response: response, Request: req }, + }; + + const [result] = await M.match< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + | UnprocessableEntityErrorObject + | GustoEmbeddedError + | ResponseValidationError + | ConnectionError + | RequestAbortedError + | RequestTimeoutError + | InvalidRequestError + | UnexpectedClientError + | SDKValidationError + >( + M.json( + 200, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema, + { key: "Payroll-Partner-Disbursements" }, + ), + M.jsonErr([404, 422], UnprocessableEntityErrorObject$inboundSchema), + M.fail("4XX"), + M.fail("5XX"), + )(response, req, { extraFields: responseFields }); + if (!result.ok) { + return [result, { status: "complete", request: req, response }]; + } + + return [result, { status: "complete", request: req, response }]; +} diff --git a/gusto_embedded/src/funcs/payrollsUpdate.ts b/gusto_embedded/src/funcs/payrollsUpdate.ts index 75c73ffe..34392c21 100644 --- a/gusto_embedded/src/funcs/payrollsUpdate.ts +++ b/gusto_embedded/src/funcs/payrollsUpdate.ts @@ -100,7 +100,7 @@ async function $do( return [parsed, { status: "invalid" }]; } const payload = parsed.value; - const body = encodeJSON("body", payload.RequestBody, { explode: true }); + const body = encodeJSON("body", payload["Payroll-Update"], { explode: true }); const pathParams = { company_id: encodeSimple("company_id", payload.company_id, { @@ -193,8 +193,8 @@ async function $do( M.json(200, PutV1CompaniesCompanyIdPayrollsResponse$inboundSchema, { key: "Payroll-Prepared", }), - M.jsonErr(422, UnprocessableEntityErrorObject$inboundSchema), - M.fail([404, "4XX"]), + M.jsonErr([404, 422], UnprocessableEntityErrorObject$inboundSchema), + M.fail("4XX"), M.fail("5XX"), )(response, req, { extraFields: responseFields }); if (!result.ok) { diff --git a/gusto_embedded/src/funcs/reportsGetReportsRequestUuid.ts b/gusto_embedded/src/funcs/reportsGetReportsRequestUuid.ts index 32c3f650..7eb2f583 100644 --- a/gusto_embedded/src/funcs/reportsGetReportsRequestUuid.ts +++ b/gusto_embedded/src/funcs/reportsGetReportsRequestUuid.ts @@ -35,6 +35,8 @@ import { Result } from "../types/fp.js"; * @remarks * Get a company's report given the `request_uuid`. The response will include the report request's status and, if complete, the report URL. * + * Reports containing PHI are inaccessible with `company_reports:read:tier_2_only` data scope + * * scope: `company_reports:read` */ export function reportsGetReportsRequestUuid( diff --git a/gusto_embedded/src/funcs/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts b/gusto_embedded/src/funcs/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts index a95a334a..bf30c711 100644 --- a/gusto_embedded/src/funcs/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts +++ b/gusto_embedded/src/funcs/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts @@ -39,9 +39,9 @@ import { Result } from "../types/fp.js"; * @remarks * Create a general ledger report for a payroll. The report can be aggregated by different dimensions such as job or department. * - * Use the `request_uuid` in the response with the [report GET endpoint](https://docs.gusto.com/embedded-payroll/reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. + * Use the `request_uuid` in the response with the [report GET endpoint](../reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. * - * scope: `company_reports:write` + * scope: `company_reports:write` OR `company_reports:write:general_ledger` */ export function reportsPostPayrollsPayrollUuidReportsGeneralLedger( client: GustoEmbeddedCore, diff --git a/gusto_embedded/src/lib/config.ts b/gusto_embedded/src/lib/config.ts index cf6b0707..6c82ae8c 100644 --- a/gusto_embedded/src/lib/config.ts +++ b/gusto_embedded/src/lib/config.ts @@ -64,8 +64,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null { export const SDK_METADATA = { language: "typescript", openapiDocVersion: "2024-04-01", - sdkVersion: "0.6.4", - genVersion: "2.629.1", + sdkVersion: "0.6.5", + genVersion: "2.657.1", userAgent: - "speakeasy-sdk/typescript 0.6.4 2.629.1 2024-04-01 @gusto/embedded-api", + "speakeasy-sdk/typescript 0.6.5 2.657.1 2024-04-01 @gusto/embedded-api", } as const; diff --git a/gusto_embedded/src/models/components/companybenefitwithemployeebenefits.ts b/gusto_embedded/src/models/components/companybenefitwithemployeebenefits.ts index 84e9acbb..0d33cde4 100644 --- a/gusto_embedded/src/models/components/companybenefitwithemployeebenefits.ts +++ b/gusto_embedded/src/models/components/companybenefitwithemployeebenefits.ts @@ -33,13 +33,17 @@ export type CompanyBenefitWithEmployeeBenefitsValueTiers = { */ rate?: string | undefined; /** - * The percentage threshold at which this tier ends (inclusive). + * Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to. * * @remarks * - * For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll. + * Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards. * - * If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. + * For example: + * + * If the first tier has a threshold of "3", and `rate` of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll. + * + * If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. */ threshold?: string | undefined; /** diff --git a/gusto_embedded/src/models/components/contractorpaymentgrouppartnerdisbursements.ts b/gusto_embedded/src/models/components/contractorpaymentgrouppartnerdisbursements.ts new file mode 100644 index 00000000..144e0497 --- /dev/null +++ b/gusto_embedded/src/models/components/contractorpaymentgrouppartnerdisbursements.ts @@ -0,0 +1,283 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +/** + * The payment method for the disbursement + */ +export const ContractorPaymentGroupPartnerDisbursementsPaymentMethod = { + DirectDeposit: "Direct Deposit", + Check: "Check", +} as const; +/** + * The payment method for the disbursement + */ +export type ContractorPaymentGroupPartnerDisbursementsPaymentMethod = + ClosedEnum; + +/** + * The status of the payment + */ +export const ContractorPaymentGroupPartnerDisbursementsPaymentStatus = { + Pending: "Pending", + Paid: "Paid", + NotPartnerManaged: "Not partner managed", + ConvertedToCheck: "Converted to check", +} as const; +/** + * The status of the payment + */ +export type ContractorPaymentGroupPartnerDisbursementsPaymentStatus = + ClosedEnum; + +export type Disbursements = { + /** + * The UUID of the contractor payment + */ + contractorPaymentUuid?: string | undefined; + /** + * The UUID of the contractor + */ + contractorUuid?: string | undefined; + /** + * The payment method for the disbursement + */ + paymentMethod?: + | ContractorPaymentGroupPartnerDisbursementsPaymentMethod + | undefined; + /** + * The status of the payment + */ + paymentStatus?: + | ContractorPaymentGroupPartnerDisbursementsPaymentStatus + | undefined; +}; + +/** + * Partner disbursements for a contractor payment group + */ +export type ContractorPaymentGroupPartnerDisbursements = { + /** + * The UUID of the contractor payment group + */ + contractorPaymentGroupUuid?: string | undefined; + /** + * List of disbursements for the contractor payment group + */ + disbursements?: Array | undefined; +}; + +/** @internal */ +export const ContractorPaymentGroupPartnerDisbursementsPaymentMethod$inboundSchema: + z.ZodNativeEnum< + typeof ContractorPaymentGroupPartnerDisbursementsPaymentMethod + > = z.nativeEnum(ContractorPaymentGroupPartnerDisbursementsPaymentMethod); + +/** @internal */ +export const ContractorPaymentGroupPartnerDisbursementsPaymentMethod$outboundSchema: + z.ZodNativeEnum< + typeof ContractorPaymentGroupPartnerDisbursementsPaymentMethod + > = ContractorPaymentGroupPartnerDisbursementsPaymentMethod$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace ContractorPaymentGroupPartnerDisbursementsPaymentMethod$ { + /** @deprecated use `ContractorPaymentGroupPartnerDisbursementsPaymentMethod$inboundSchema` instead. */ + export const inboundSchema = + ContractorPaymentGroupPartnerDisbursementsPaymentMethod$inboundSchema; + /** @deprecated use `ContractorPaymentGroupPartnerDisbursementsPaymentMethod$outboundSchema` instead. */ + export const outboundSchema = + ContractorPaymentGroupPartnerDisbursementsPaymentMethod$outboundSchema; +} + +/** @internal */ +export const ContractorPaymentGroupPartnerDisbursementsPaymentStatus$inboundSchema: + z.ZodNativeEnum< + typeof ContractorPaymentGroupPartnerDisbursementsPaymentStatus + > = z.nativeEnum(ContractorPaymentGroupPartnerDisbursementsPaymentStatus); + +/** @internal */ +export const ContractorPaymentGroupPartnerDisbursementsPaymentStatus$outboundSchema: + z.ZodNativeEnum< + typeof ContractorPaymentGroupPartnerDisbursementsPaymentStatus + > = ContractorPaymentGroupPartnerDisbursementsPaymentStatus$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace ContractorPaymentGroupPartnerDisbursementsPaymentStatus$ { + /** @deprecated use `ContractorPaymentGroupPartnerDisbursementsPaymentStatus$inboundSchema` instead. */ + export const inboundSchema = + ContractorPaymentGroupPartnerDisbursementsPaymentStatus$inboundSchema; + /** @deprecated use `ContractorPaymentGroupPartnerDisbursementsPaymentStatus$outboundSchema` instead. */ + export const outboundSchema = + ContractorPaymentGroupPartnerDisbursementsPaymentStatus$outboundSchema; +} + +/** @internal */ +export const Disbursements$inboundSchema: z.ZodType< + Disbursements, + z.ZodTypeDef, + unknown +> = z.object({ + contractor_payment_uuid: z.string().optional(), + contractor_uuid: z.string().optional(), + payment_method: + ContractorPaymentGroupPartnerDisbursementsPaymentMethod$inboundSchema + .optional(), + payment_status: + ContractorPaymentGroupPartnerDisbursementsPaymentStatus$inboundSchema + .optional(), +}).transform((v) => { + return remap$(v, { + "contractor_payment_uuid": "contractorPaymentUuid", + "contractor_uuid": "contractorUuid", + "payment_method": "paymentMethod", + "payment_status": "paymentStatus", + }); +}); + +/** @internal */ +export type Disbursements$Outbound = { + contractor_payment_uuid?: string | undefined; + contractor_uuid?: string | undefined; + payment_method?: string | undefined; + payment_status?: string | undefined; +}; + +/** @internal */ +export const Disbursements$outboundSchema: z.ZodType< + Disbursements$Outbound, + z.ZodTypeDef, + Disbursements +> = z.object({ + contractorPaymentUuid: z.string().optional(), + contractorUuid: z.string().optional(), + paymentMethod: + ContractorPaymentGroupPartnerDisbursementsPaymentMethod$outboundSchema + .optional(), + paymentStatus: + ContractorPaymentGroupPartnerDisbursementsPaymentStatus$outboundSchema + .optional(), +}).transform((v) => { + return remap$(v, { + contractorPaymentUuid: "contractor_payment_uuid", + contractorUuid: "contractor_uuid", + paymentMethod: "payment_method", + paymentStatus: "payment_status", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Disbursements$ { + /** @deprecated use `Disbursements$inboundSchema` instead. */ + export const inboundSchema = Disbursements$inboundSchema; + /** @deprecated use `Disbursements$outboundSchema` instead. */ + export const outboundSchema = Disbursements$outboundSchema; + /** @deprecated use `Disbursements$Outbound` instead. */ + export type Outbound = Disbursements$Outbound; +} + +export function disbursementsToJSON(disbursements: Disbursements): string { + return JSON.stringify(Disbursements$outboundSchema.parse(disbursements)); +} + +export function disbursementsFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Disbursements$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Disbursements' from JSON`, + ); +} + +/** @internal */ +export const ContractorPaymentGroupPartnerDisbursements$inboundSchema: + z.ZodType = + z.object({ + contractor_payment_group_uuid: z.string().optional(), + disbursements: z.array(z.lazy(() => Disbursements$inboundSchema)) + .optional(), + }).transform((v) => { + return remap$(v, { + "contractor_payment_group_uuid": "contractorPaymentGroupUuid", + }); + }); + +/** @internal */ +export type ContractorPaymentGroupPartnerDisbursements$Outbound = { + contractor_payment_group_uuid?: string | undefined; + disbursements?: Array | undefined; +}; + +/** @internal */ +export const ContractorPaymentGroupPartnerDisbursements$outboundSchema: + z.ZodType< + ContractorPaymentGroupPartnerDisbursements$Outbound, + z.ZodTypeDef, + ContractorPaymentGroupPartnerDisbursements + > = z.object({ + contractorPaymentGroupUuid: z.string().optional(), + disbursements: z.array(z.lazy(() => Disbursements$outboundSchema)) + .optional(), + }).transform((v) => { + return remap$(v, { + contractorPaymentGroupUuid: "contractor_payment_group_uuid", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace ContractorPaymentGroupPartnerDisbursements$ { + /** @deprecated use `ContractorPaymentGroupPartnerDisbursements$inboundSchema` instead. */ + export const inboundSchema = + ContractorPaymentGroupPartnerDisbursements$inboundSchema; + /** @deprecated use `ContractorPaymentGroupPartnerDisbursements$outboundSchema` instead. */ + export const outboundSchema = + ContractorPaymentGroupPartnerDisbursements$outboundSchema; + /** @deprecated use `ContractorPaymentGroupPartnerDisbursements$Outbound` instead. */ + export type Outbound = ContractorPaymentGroupPartnerDisbursements$Outbound; +} + +export function contractorPaymentGroupPartnerDisbursementsToJSON( + contractorPaymentGroupPartnerDisbursements: + ContractorPaymentGroupPartnerDisbursements, +): string { + return JSON.stringify( + ContractorPaymentGroupPartnerDisbursements$outboundSchema.parse( + contractorPaymentGroupPartnerDisbursements, + ), + ); +} + +export function contractorPaymentGroupPartnerDisbursementsFromJSON( + jsonString: string, +): SafeParseResult< + ContractorPaymentGroupPartnerDisbursements, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + ContractorPaymentGroupPartnerDisbursements$inboundSchema.parse( + JSON.parse(x), + ), + `Failed to parse 'ContractorPaymentGroupPartnerDisbursements' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/components/employee.ts b/gusto_embedded/src/models/components/employee.ts index 1dd1a768..7fd711ce 100644 --- a/gusto_embedded/src/models/components/employee.ts +++ b/gusto_embedded/src/models/components/employee.ts @@ -48,7 +48,7 @@ import { /** * The current onboarding status of the employee */ -export const OnboardingStatus = { +export const EmployeeOnboardingStatus1 = { OnboardingCompleted: "onboarding_completed", AdminOnboardingIncomplete: "admin_onboarding_incomplete", SelfOnboardingPendingInvite: "self_onboarding_pending_invite", @@ -61,12 +61,14 @@ export const OnboardingStatus = { /** * The current onboarding status of the employee */ -export type OnboardingStatus = ClosedEnum; +export type EmployeeOnboardingStatus1 = ClosedEnum< + typeof EmployeeOnboardingStatus1 +>; /** * Configuration for an employee onboarding documents during onboarding */ -export type OnboardingDocumentsConfig = { +export type EmployeeOnboardingDocumentsConfig = { /** * The UUID of the onboarding documents config */ @@ -80,19 +82,19 @@ export type OnboardingDocumentsConfig = { /** * The employee's payment method */ -export const PaymentMethod = { +export const EmployeePaymentMethod1 = { DirectDeposit: "Direct Deposit", Check: "Check", } as const; /** * The employee's payment method */ -export type PaymentMethod = ClosedEnum; +export type EmployeePaymentMethod1 = ClosedEnum; /** * The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. */ -export const CurrentEmploymentStatus = { +export const EmployeeCurrentEmploymentStatus = { FullTime: "full_time", PartTimeUnderTwentyHours: "part_time_under_twenty_hours", PartTimeTwentyPlusHours: "part_time_twenty_plus_hours", @@ -102,8 +104,8 @@ export const CurrentEmploymentStatus = { /** * The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. */ -export type CurrentEmploymentStatus = ClosedEnum< - typeof CurrentEmploymentStatus +export type EmployeeCurrentEmploymentStatus = ClosedEnum< + typeof EmployeeCurrentEmploymentStatus >; /** @@ -156,11 +158,11 @@ export type Employee = { /** * The current onboarding status of the employee */ - onboardingStatus?: OnboardingStatus | null | undefined; + onboardingStatus?: EmployeeOnboardingStatus1 | null | undefined; /** * Configuration for an employee onboarding documents during onboarding */ - onboardingDocumentsConfig?: OnboardingDocumentsConfig | undefined; + onboardingDocumentsConfig?: EmployeeOnboardingDocumentsConfig | undefined; jobs?: Array | undefined; eligiblePaidTimeOff?: Array | undefined; terminations?: Array | undefined; @@ -183,11 +185,11 @@ export type Employee = { /** * The employee's payment method */ - paymentMethod?: PaymentMethod | undefined; + paymentMethod?: EmployeePaymentMethod1 | undefined; /** * The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. */ - currentEmploymentStatus?: CurrentEmploymentStatus | null | undefined; + currentEmploymentStatus?: EmployeeCurrentEmploymentStatus | null | undefined; historical?: boolean | undefined; /** * The short format code of the employee @@ -211,29 +213,29 @@ export type Employee = { }; /** @internal */ -export const OnboardingStatus$inboundSchema: z.ZodNativeEnum< - typeof OnboardingStatus -> = z.nativeEnum(OnboardingStatus); +export const EmployeeOnboardingStatus1$inboundSchema: z.ZodNativeEnum< + typeof EmployeeOnboardingStatus1 +> = z.nativeEnum(EmployeeOnboardingStatus1); /** @internal */ -export const OnboardingStatus$outboundSchema: z.ZodNativeEnum< - typeof OnboardingStatus -> = OnboardingStatus$inboundSchema; +export const EmployeeOnboardingStatus1$outboundSchema: z.ZodNativeEnum< + typeof EmployeeOnboardingStatus1 +> = EmployeeOnboardingStatus1$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace OnboardingStatus$ { - /** @deprecated use `OnboardingStatus$inboundSchema` instead. */ - export const inboundSchema = OnboardingStatus$inboundSchema; - /** @deprecated use `OnboardingStatus$outboundSchema` instead. */ - export const outboundSchema = OnboardingStatus$outboundSchema; +export namespace EmployeeOnboardingStatus1$ { + /** @deprecated use `EmployeeOnboardingStatus1$inboundSchema` instead. */ + export const inboundSchema = EmployeeOnboardingStatus1$inboundSchema; + /** @deprecated use `EmployeeOnboardingStatus1$outboundSchema` instead. */ + export const outboundSchema = EmployeeOnboardingStatus1$outboundSchema; } /** @internal */ -export const OnboardingDocumentsConfig$inboundSchema: z.ZodType< - OnboardingDocumentsConfig, +export const EmployeeOnboardingDocumentsConfig$inboundSchema: z.ZodType< + EmployeeOnboardingDocumentsConfig, z.ZodTypeDef, unknown > = z.object({ @@ -246,16 +248,16 @@ export const OnboardingDocumentsConfig$inboundSchema: z.ZodType< }); /** @internal */ -export type OnboardingDocumentsConfig$Outbound = { +export type EmployeeOnboardingDocumentsConfig$Outbound = { uuid?: string | null | undefined; i9_document?: boolean | undefined; }; /** @internal */ -export const OnboardingDocumentsConfig$outboundSchema: z.ZodType< - OnboardingDocumentsConfig$Outbound, +export const EmployeeOnboardingDocumentsConfig$outboundSchema: z.ZodType< + EmployeeOnboardingDocumentsConfig$Outbound, z.ZodTypeDef, - OnboardingDocumentsConfig + EmployeeOnboardingDocumentsConfig > = z.object({ uuid: z.nullable(z.string()).optional(), i9Document: z.boolean().optional(), @@ -269,73 +271,76 @@ export const OnboardingDocumentsConfig$outboundSchema: z.ZodType< * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace OnboardingDocumentsConfig$ { - /** @deprecated use `OnboardingDocumentsConfig$inboundSchema` instead. */ - export const inboundSchema = OnboardingDocumentsConfig$inboundSchema; - /** @deprecated use `OnboardingDocumentsConfig$outboundSchema` instead. */ - export const outboundSchema = OnboardingDocumentsConfig$outboundSchema; - /** @deprecated use `OnboardingDocumentsConfig$Outbound` instead. */ - export type Outbound = OnboardingDocumentsConfig$Outbound; +export namespace EmployeeOnboardingDocumentsConfig$ { + /** @deprecated use `EmployeeOnboardingDocumentsConfig$inboundSchema` instead. */ + export const inboundSchema = EmployeeOnboardingDocumentsConfig$inboundSchema; + /** @deprecated use `EmployeeOnboardingDocumentsConfig$outboundSchema` instead. */ + export const outboundSchema = + EmployeeOnboardingDocumentsConfig$outboundSchema; + /** @deprecated use `EmployeeOnboardingDocumentsConfig$Outbound` instead. */ + export type Outbound = EmployeeOnboardingDocumentsConfig$Outbound; } -export function onboardingDocumentsConfigToJSON( - onboardingDocumentsConfig: OnboardingDocumentsConfig, +export function employeeOnboardingDocumentsConfigToJSON( + employeeOnboardingDocumentsConfig: EmployeeOnboardingDocumentsConfig, ): string { return JSON.stringify( - OnboardingDocumentsConfig$outboundSchema.parse(onboardingDocumentsConfig), + EmployeeOnboardingDocumentsConfig$outboundSchema.parse( + employeeOnboardingDocumentsConfig, + ), ); } -export function onboardingDocumentsConfigFromJSON( +export function employeeOnboardingDocumentsConfigFromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult { return safeParse( jsonString, - (x) => OnboardingDocumentsConfig$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'OnboardingDocumentsConfig' from JSON`, + (x) => EmployeeOnboardingDocumentsConfig$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'EmployeeOnboardingDocumentsConfig' from JSON`, ); } /** @internal */ -export const PaymentMethod$inboundSchema: z.ZodNativeEnum< - typeof PaymentMethod -> = z.nativeEnum(PaymentMethod); +export const EmployeePaymentMethod1$inboundSchema: z.ZodNativeEnum< + typeof EmployeePaymentMethod1 +> = z.nativeEnum(EmployeePaymentMethod1); /** @internal */ -export const PaymentMethod$outboundSchema: z.ZodNativeEnum< - typeof PaymentMethod -> = PaymentMethod$inboundSchema; +export const EmployeePaymentMethod1$outboundSchema: z.ZodNativeEnum< + typeof EmployeePaymentMethod1 +> = EmployeePaymentMethod1$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace PaymentMethod$ { - /** @deprecated use `PaymentMethod$inboundSchema` instead. */ - export const inboundSchema = PaymentMethod$inboundSchema; - /** @deprecated use `PaymentMethod$outboundSchema` instead. */ - export const outboundSchema = PaymentMethod$outboundSchema; +export namespace EmployeePaymentMethod1$ { + /** @deprecated use `EmployeePaymentMethod1$inboundSchema` instead. */ + export const inboundSchema = EmployeePaymentMethod1$inboundSchema; + /** @deprecated use `EmployeePaymentMethod1$outboundSchema` instead. */ + export const outboundSchema = EmployeePaymentMethod1$outboundSchema; } /** @internal */ -export const CurrentEmploymentStatus$inboundSchema: z.ZodNativeEnum< - typeof CurrentEmploymentStatus -> = z.nativeEnum(CurrentEmploymentStatus); +export const EmployeeCurrentEmploymentStatus$inboundSchema: z.ZodNativeEnum< + typeof EmployeeCurrentEmploymentStatus +> = z.nativeEnum(EmployeeCurrentEmploymentStatus); /** @internal */ -export const CurrentEmploymentStatus$outboundSchema: z.ZodNativeEnum< - typeof CurrentEmploymentStatus -> = CurrentEmploymentStatus$inboundSchema; +export const EmployeeCurrentEmploymentStatus$outboundSchema: z.ZodNativeEnum< + typeof EmployeeCurrentEmploymentStatus +> = EmployeeCurrentEmploymentStatus$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace CurrentEmploymentStatus$ { - /** @deprecated use `CurrentEmploymentStatus$inboundSchema` instead. */ - export const inboundSchema = CurrentEmploymentStatus$inboundSchema; - /** @deprecated use `CurrentEmploymentStatus$outboundSchema` instead. */ - export const outboundSchema = CurrentEmploymentStatus$outboundSchema; +export namespace EmployeeCurrentEmploymentStatus$ { + /** @deprecated use `EmployeeCurrentEmploymentStatus$inboundSchema` instead. */ + export const inboundSchema = EmployeeCurrentEmploymentStatus$inboundSchema; + /** @deprecated use `EmployeeCurrentEmploymentStatus$outboundSchema` instead. */ + export const outboundSchema = EmployeeCurrentEmploymentStatus$outboundSchema; } /** @internal */ @@ -357,9 +362,10 @@ export const Employee$inboundSchema: z.ZodType< two_percent_shareholder: z.nullable(z.boolean()).optional(), work_email: z.nullable(z.string()).optional(), onboarded: z.boolean().optional(), - onboarding_status: z.nullable(OnboardingStatus$inboundSchema).optional(), + onboarding_status: z.nullable(EmployeeOnboardingStatus1$inboundSchema) + .optional(), onboarding_documents_config: z.lazy(() => - OnboardingDocumentsConfig$inboundSchema + EmployeeOnboardingDocumentsConfig$inboundSchema ).optional(), jobs: z.array(Job$inboundSchema).optional(), eligible_paid_time_off: z.array(PaidTimeOff$inboundSchema).optional(), @@ -371,9 +377,10 @@ export const Employee$inboundSchema: z.ZodType< ssn: z.string().optional(), phone: z.nullable(z.string()).optional(), preferred_first_name: z.nullable(z.string()).optional(), - payment_method: PaymentMethod$inboundSchema.default("Check"), - current_employment_status: z.nullable(CurrentEmploymentStatus$inboundSchema) - .optional(), + payment_method: EmployeePaymentMethod1$inboundSchema.default("Check"), + current_employment_status: z.nullable( + EmployeeCurrentEmploymentStatus$inboundSchema, + ).optional(), historical: z.boolean().optional(), employee_code: z.string().optional(), department_uuid: z.nullable(z.string()).optional(), @@ -425,7 +432,9 @@ export type Employee$Outbound = { work_email?: string | null | undefined; onboarded?: boolean | undefined; onboarding_status?: string | null | undefined; - onboarding_documents_config?: OnboardingDocumentsConfig$Outbound | undefined; + onboarding_documents_config?: + | EmployeeOnboardingDocumentsConfig$Outbound + | undefined; jobs?: Array | undefined; eligible_paid_time_off?: Array | undefined; terminations?: Array | undefined; @@ -467,9 +476,10 @@ export const Employee$outboundSchema: z.ZodType< twoPercentShareholder: z.nullable(z.boolean()).optional(), workEmail: z.nullable(z.string()).optional(), onboarded: z.boolean().optional(), - onboardingStatus: z.nullable(OnboardingStatus$outboundSchema).optional(), + onboardingStatus: z.nullable(EmployeeOnboardingStatus1$outboundSchema) + .optional(), onboardingDocumentsConfig: z.lazy(() => - OnboardingDocumentsConfig$outboundSchema + EmployeeOnboardingDocumentsConfig$outboundSchema ).optional(), jobs: z.array(Job$outboundSchema).optional(), eligiblePaidTimeOff: z.array(PaidTimeOff$outboundSchema).optional(), @@ -481,9 +491,10 @@ export const Employee$outboundSchema: z.ZodType< ssn: z.string().optional(), phone: z.nullable(z.string()).optional(), preferredFirstName: z.nullable(z.string()).optional(), - paymentMethod: PaymentMethod$outboundSchema.default("Check"), - currentEmploymentStatus: z.nullable(CurrentEmploymentStatus$outboundSchema) - .optional(), + paymentMethod: EmployeePaymentMethod1$outboundSchema.default("Check"), + currentEmploymentStatus: z.nullable( + EmployeeCurrentEmploymentStatus$outboundSchema, + ).optional(), historical: z.boolean().optional(), employeeCode: z.string().optional(), departmentUuid: z.nullable(z.string()).optional(), diff --git a/gusto_embedded/src/models/components/employeebenefit.ts b/gusto_embedded/src/models/components/employeebenefit.ts index 51f0812f..819f0a13 100644 --- a/gusto_embedded/src/models/components/employeebenefit.ts +++ b/gusto_embedded/src/models/components/employeebenefit.ts @@ -18,13 +18,17 @@ export type Tiers = { */ rate?: string | undefined; /** - * The percentage threshold at which this tier ends (inclusive). + * Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to. * * @remarks * - * For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll. + * Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards. * - * If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. + * For example: + * + * If the first tier has a threshold of "3", and `rate` of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll. + * + * If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. */ threshold?: string | undefined; /** diff --git a/gusto_embedded/src/models/components/employeebenefitforcompanybenefit.ts b/gusto_embedded/src/models/components/employeebenefitforcompanybenefit.ts index 95c86364..32e02433 100644 --- a/gusto_embedded/src/models/components/employeebenefitforcompanybenefit.ts +++ b/gusto_embedded/src/models/components/employeebenefitforcompanybenefit.ts @@ -18,13 +18,17 @@ export type ValueTiers = { */ rate?: string | undefined; /** - * The percentage threshold at which this tier ends (inclusive). + * Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to. * * @remarks * - * For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll. + * Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards. * - * If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. + * For example: + * + * If the first tier has a threshold of "3", and `rate` of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll. + * + * If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. */ threshold?: string | undefined; /** diff --git a/gusto_embedded/src/models/components/employeehomeaddress.ts b/gusto_embedded/src/models/components/employeehomeaddress.ts new file mode 100644 index 00000000..d5a35f80 --- /dev/null +++ b/gusto_embedded/src/models/components/employeehomeaddress.ts @@ -0,0 +1,111 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +export type EmployeeHomeAddress = { + street1?: string | null | undefined; + street2?: string | null | undefined; + city?: string | null | undefined; + state?: string | null | undefined; + zip?: string | null | undefined; + country?: string | null | undefined; + /** + * The status of the location. Inactive locations have been deleted, but may still have historical data associated with them. + */ + active?: boolean | undefined; + /** + * Unique identifier for this address. + */ + uuid?: string | undefined; +}; + +/** @internal */ +export const EmployeeHomeAddress$inboundSchema: z.ZodType< + EmployeeHomeAddress, + z.ZodTypeDef, + unknown +> = z.object({ + street_1: z.nullable(z.string()).optional(), + street_2: z.nullable(z.string()).optional(), + city: z.nullable(z.string()).optional(), + state: z.nullable(z.string()).optional(), + zip: z.nullable(z.string()).optional(), + country: z.nullable(z.string().default("USA")), + active: z.boolean().optional(), + uuid: z.string().optional(), +}).transform((v) => { + return remap$(v, { + "street_1": "street1", + "street_2": "street2", + }); +}); + +/** @internal */ +export type EmployeeHomeAddress$Outbound = { + street_1?: string | null | undefined; + street_2?: string | null | undefined; + city?: string | null | undefined; + state?: string | null | undefined; + zip?: string | null | undefined; + country: string | null; + active?: boolean | undefined; + uuid?: string | undefined; +}; + +/** @internal */ +export const EmployeeHomeAddress$outboundSchema: z.ZodType< + EmployeeHomeAddress$Outbound, + z.ZodTypeDef, + EmployeeHomeAddress +> = z.object({ + street1: z.nullable(z.string()).optional(), + street2: z.nullable(z.string()).optional(), + city: z.nullable(z.string()).optional(), + state: z.nullable(z.string()).optional(), + zip: z.nullable(z.string()).optional(), + country: z.nullable(z.string().default("USA")), + active: z.boolean().optional(), + uuid: z.string().optional(), +}).transform((v) => { + return remap$(v, { + street1: "street_1", + street2: "street_2", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace EmployeeHomeAddress$ { + /** @deprecated use `EmployeeHomeAddress$inboundSchema` instead. */ + export const inboundSchema = EmployeeHomeAddress$inboundSchema; + /** @deprecated use `EmployeeHomeAddress$outboundSchema` instead. */ + export const outboundSchema = EmployeeHomeAddress$outboundSchema; + /** @deprecated use `EmployeeHomeAddress$Outbound` instead. */ + export type Outbound = EmployeeHomeAddress$Outbound; +} + +export function employeeHomeAddressToJSON( + employeeHomeAddress: EmployeeHomeAddress, +): string { + return JSON.stringify( + EmployeeHomeAddress$outboundSchema.parse(employeeHomeAddress), + ); +} + +export function employeeHomeAddressFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => EmployeeHomeAddress$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'EmployeeHomeAddress' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/components/federaltaxdetails.ts b/gusto_embedded/src/models/components/federaltaxdetails.ts index 901b79ef..00776238 100644 --- a/gusto_embedded/src/models/components/federaltaxdetails.ts +++ b/gusto_embedded/src/models/components/federaltaxdetails.ts @@ -5,9 +5,50 @@ import * as z from "zod"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +/** + * The status of EIN verification: + * + * @remarks + * - `pending`: The EIN verification process has not completed (or the company does not yet have an EIN). + * - `verified`: The EIN has been successfully verified as a valid EIN with the IRS. + * - `failed`: The company's EIN did not pass verification. Common issues are being entered incorrectly or not matching the company's legal name. + */ +export const FederalTaxDetailsStatus = { + Pending: "pending", + Verified: "verified", + Failed: "failed", +} as const; +/** + * The status of EIN verification: + * + * @remarks + * - `pending`: The EIN verification process has not completed (or the company does not yet have an EIN). + * - `verified`: The EIN has been successfully verified as a valid EIN with the IRS. + * - `failed`: The company's EIN did not pass verification. Common issues are being entered incorrectly or not matching the company's legal name. + */ +export type FederalTaxDetailsStatus = ClosedEnum< + typeof FederalTaxDetailsStatus +>; + +/** + * Information about the status of verifying the company's Employer Identification Number (EIN) + */ +export type EinVerification = { + /** + * The status of EIN verification: + * + * @remarks + * - `pending`: The EIN verification process has not completed (or the company does not yet have an EIN). + * - `verified`: The EIN has been successfully verified as a valid EIN with the IRS. + * - `failed`: The company's EIN did not pass verification. Common issues are being entered incorrectly or not matching the company's legal name. + */ + status?: FederalTaxDetailsStatus | undefined; +}; + /** * Example response */ @@ -56,9 +97,13 @@ export type FederalTaxDetails = { */ hasEin?: boolean | undefined; /** - * Whether the EIN was able to be verified as a valid EIN with the IRS. + * Whether the EIN has been successfully verified as a valid EIN with the IRS. */ einVerified?: boolean | undefined; + /** + * Information about the status of verifying the company's Employer Identification Number (EIN) + */ + einVerification?: EinVerification | undefined; /** * The legal name of the company */ @@ -77,6 +122,79 @@ export type FederalTaxDetails = { depositSchedule?: string | undefined; }; +/** @internal */ +export const FederalTaxDetailsStatus$inboundSchema: z.ZodNativeEnum< + typeof FederalTaxDetailsStatus +> = z.nativeEnum(FederalTaxDetailsStatus); + +/** @internal */ +export const FederalTaxDetailsStatus$outboundSchema: z.ZodNativeEnum< + typeof FederalTaxDetailsStatus +> = FederalTaxDetailsStatus$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace FederalTaxDetailsStatus$ { + /** @deprecated use `FederalTaxDetailsStatus$inboundSchema` instead. */ + export const inboundSchema = FederalTaxDetailsStatus$inboundSchema; + /** @deprecated use `FederalTaxDetailsStatus$outboundSchema` instead. */ + export const outboundSchema = FederalTaxDetailsStatus$outboundSchema; +} + +/** @internal */ +export const EinVerification$inboundSchema: z.ZodType< + EinVerification, + z.ZodTypeDef, + unknown +> = z.object({ + status: FederalTaxDetailsStatus$inboundSchema.optional(), +}); + +/** @internal */ +export type EinVerification$Outbound = { + status?: string | undefined; +}; + +/** @internal */ +export const EinVerification$outboundSchema: z.ZodType< + EinVerification$Outbound, + z.ZodTypeDef, + EinVerification +> = z.object({ + status: FederalTaxDetailsStatus$outboundSchema.optional(), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace EinVerification$ { + /** @deprecated use `EinVerification$inboundSchema` instead. */ + export const inboundSchema = EinVerification$inboundSchema; + /** @deprecated use `EinVerification$outboundSchema` instead. */ + export const outboundSchema = EinVerification$outboundSchema; + /** @deprecated use `EinVerification$Outbound` instead. */ + export type Outbound = EinVerification$Outbound; +} + +export function einVerificationToJSON( + einVerification: EinVerification, +): string { + return JSON.stringify(EinVerification$outboundSchema.parse(einVerification)); +} + +export function einVerificationFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => EinVerification$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'EinVerification' from JSON`, + ); +} + /** @internal */ export const FederalTaxDetails$inboundSchema: z.ZodType< FederalTaxDetails, @@ -89,6 +207,7 @@ export const FederalTaxDetails$inboundSchema: z.ZodType< filing_form: z.string().optional(), has_ein: z.boolean().optional(), ein_verified: z.boolean().optional(), + ein_verification: z.lazy(() => EinVerification$inboundSchema).optional(), legal_name: z.string().optional(), effective_date: z.string().optional(), deposit_schedule: z.string().optional(), @@ -99,6 +218,7 @@ export const FederalTaxDetails$inboundSchema: z.ZodType< "filing_form": "filingForm", "has_ein": "hasEin", "ein_verified": "einVerified", + "ein_verification": "einVerification", "legal_name": "legalName", "effective_date": "effectiveDate", "deposit_schedule": "depositSchedule", @@ -113,6 +233,7 @@ export type FederalTaxDetails$Outbound = { filing_form?: string | undefined; has_ein?: boolean | undefined; ein_verified?: boolean | undefined; + ein_verification?: EinVerification$Outbound | undefined; legal_name?: string | undefined; effective_date?: string | undefined; deposit_schedule?: string | undefined; @@ -130,6 +251,7 @@ export const FederalTaxDetails$outboundSchema: z.ZodType< filingForm: z.string().optional(), hasEin: z.boolean().optional(), einVerified: z.boolean().optional(), + einVerification: z.lazy(() => EinVerification$outboundSchema).optional(), legalName: z.string().optional(), effectiveDate: z.string().optional(), depositSchedule: z.string().optional(), @@ -140,6 +262,7 @@ export const FederalTaxDetails$outboundSchema: z.ZodType< filingForm: "filing_form", hasEin: "has_ein", einVerified: "ein_verified", + einVerification: "ein_verification", legalName: "legal_name", effectiveDate: "effective_date", depositSchedule: "deposit_schedule", diff --git a/gusto_embedded/src/models/components/generalledgerreport.ts b/gusto_embedded/src/models/components/generalledgerreport.ts index 58fc294b..202d5998 100644 --- a/gusto_embedded/src/models/components/generalledgerreport.ts +++ b/gusto_embedded/src/models/components/generalledgerreport.ts @@ -16,12 +16,25 @@ export const Aggregation = { Default: "default", Job: "job", Department: "department", + Integration: "integration", } as const; /** * The breakdown level used for the report */ export type Aggregation = ClosedEnum; +/** + * The `integration_type` used for the report, if `aggregation` was 'integration.' Otherwise, this will be null. + */ +export const IntegrationType = { + Xero: "xero", + Qbo: "qbo", +} as const; +/** + * The `integration_type` used for the report, if `aggregation` was 'integration.' Otherwise, this will be null. + */ +export type IntegrationType = ClosedEnum; + /** * Successful response for general ledger report generation */ @@ -34,6 +47,10 @@ export type GeneralLedgerReport = { * The breakdown level used for the report */ aggregation?: Aggregation | undefined; + /** + * The `integration_type` used for the report, if `aggregation` was 'integration.' Otherwise, this will be null. + */ + integrationType?: IntegrationType | null | undefined; /** * UUID to use for polling the report status */ @@ -59,6 +76,27 @@ export namespace Aggregation$ { export const outboundSchema = Aggregation$outboundSchema; } +/** @internal */ +export const IntegrationType$inboundSchema: z.ZodNativeEnum< + typeof IntegrationType +> = z.nativeEnum(IntegrationType); + +/** @internal */ +export const IntegrationType$outboundSchema: z.ZodNativeEnum< + typeof IntegrationType +> = IntegrationType$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace IntegrationType$ { + /** @deprecated use `IntegrationType$inboundSchema` instead. */ + export const inboundSchema = IntegrationType$inboundSchema; + /** @deprecated use `IntegrationType$outboundSchema` instead. */ + export const outboundSchema = IntegrationType$outboundSchema; +} + /** @internal */ export const GeneralLedgerReport$inboundSchema: z.ZodType< GeneralLedgerReport, @@ -67,10 +105,12 @@ export const GeneralLedgerReport$inboundSchema: z.ZodType< > = z.object({ payroll_uuid: z.string().optional(), aggregation: Aggregation$inboundSchema.optional(), + integration_type: z.nullable(IntegrationType$inboundSchema).optional(), request_uuid: z.string().optional(), }).transform((v) => { return remap$(v, { "payroll_uuid": "payrollUuid", + "integration_type": "integrationType", "request_uuid": "requestUuid", }); }); @@ -79,6 +119,7 @@ export const GeneralLedgerReport$inboundSchema: z.ZodType< export type GeneralLedgerReport$Outbound = { payroll_uuid?: string | undefined; aggregation?: string | undefined; + integration_type?: string | null | undefined; request_uuid?: string | undefined; }; @@ -90,10 +131,12 @@ export const GeneralLedgerReport$outboundSchema: z.ZodType< > = z.object({ payrollUuid: z.string().optional(), aggregation: Aggregation$outboundSchema.optional(), + integrationType: z.nullable(IntegrationType$outboundSchema).optional(), requestUuid: z.string().optional(), }).transform((v) => { return remap$(v, { payrollUuid: "payroll_uuid", + integrationType: "integration_type", requestUuid: "request_uuid", }); }); diff --git a/gusto_embedded/src/models/components/paymentconfigs.ts b/gusto_embedded/src/models/components/paymentconfigs.ts index 8efd2951..985ee0c0 100644 --- a/gusto_embedded/src/models/components/paymentconfigs.ts +++ b/gusto_embedded/src/models/components/paymentconfigs.ts @@ -5,9 +5,33 @@ import * as z from "zod"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +/** + * The type of blocker + */ +export const BlockerType = { + MinimumDays: "minimum_days", + MinimumFundedPayments: "minimum_funded_payments", +} as const; +/** + * The type of blocker + */ +export type BlockerType = ClosedEnum; + +export type EarnedFastAchBlockers = { + /** + * The type of blocker + */ + blockerType?: BlockerType | undefined; + /** + * The threshold needed to unblock + */ + threshold?: number | undefined; +}; + /** * Example response */ @@ -28,8 +52,96 @@ export type PaymentConfigs = { * Payment speed for 1-day, 2-day, 4-day */ paymentSpeed?: string | undefined; + /** + * Blockers preventing the company from earning fast ACH payments + */ + earnedFastAchBlockers?: Array | undefined; +}; + +/** @internal */ +export const BlockerType$inboundSchema: z.ZodNativeEnum = z + .nativeEnum(BlockerType); + +/** @internal */ +export const BlockerType$outboundSchema: z.ZodNativeEnum = + BlockerType$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace BlockerType$ { + /** @deprecated use `BlockerType$inboundSchema` instead. */ + export const inboundSchema = BlockerType$inboundSchema; + /** @deprecated use `BlockerType$outboundSchema` instead. */ + export const outboundSchema = BlockerType$outboundSchema; +} + +/** @internal */ +export const EarnedFastAchBlockers$inboundSchema: z.ZodType< + EarnedFastAchBlockers, + z.ZodTypeDef, + unknown +> = z.object({ + blocker_type: BlockerType$inboundSchema.optional(), + threshold: z.number().optional(), +}).transform((v) => { + return remap$(v, { + "blocker_type": "blockerType", + }); +}); + +/** @internal */ +export type EarnedFastAchBlockers$Outbound = { + blocker_type?: string | undefined; + threshold?: number | undefined; }; +/** @internal */ +export const EarnedFastAchBlockers$outboundSchema: z.ZodType< + EarnedFastAchBlockers$Outbound, + z.ZodTypeDef, + EarnedFastAchBlockers +> = z.object({ + blockerType: BlockerType$outboundSchema.optional(), + threshold: z.number().optional(), +}).transform((v) => { + return remap$(v, { + blockerType: "blocker_type", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace EarnedFastAchBlockers$ { + /** @deprecated use `EarnedFastAchBlockers$inboundSchema` instead. */ + export const inboundSchema = EarnedFastAchBlockers$inboundSchema; + /** @deprecated use `EarnedFastAchBlockers$outboundSchema` instead. */ + export const outboundSchema = EarnedFastAchBlockers$outboundSchema; + /** @deprecated use `EarnedFastAchBlockers$Outbound` instead. */ + export type Outbound = EarnedFastAchBlockers$Outbound; +} + +export function earnedFastAchBlockersToJSON( + earnedFastAchBlockers: EarnedFastAchBlockers, +): string { + return JSON.stringify( + EarnedFastAchBlockers$outboundSchema.parse(earnedFastAchBlockers), + ); +} + +export function earnedFastAchBlockersFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => EarnedFastAchBlockers$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'EarnedFastAchBlockers' from JSON`, + ); +} + /** @internal */ export const PaymentConfigs$inboundSchema: z.ZodType< PaymentConfigs, @@ -40,12 +152,16 @@ export const PaymentConfigs$inboundSchema: z.ZodType< partner_uuid: z.string().optional(), fast_payment_limit: z.string().optional(), payment_speed: z.string().optional(), + earned_fast_ach_blockers: z.array( + z.lazy(() => EarnedFastAchBlockers$inboundSchema), + ).optional(), }).transform((v) => { return remap$(v, { "company_uuid": "companyUuid", "partner_uuid": "partnerUuid", "fast_payment_limit": "fastPaymentLimit", "payment_speed": "paymentSpeed", + "earned_fast_ach_blockers": "earnedFastAchBlockers", }); }); @@ -55,6 +171,7 @@ export type PaymentConfigs$Outbound = { partner_uuid?: string | undefined; fast_payment_limit?: string | undefined; payment_speed?: string | undefined; + earned_fast_ach_blockers?: Array | undefined; }; /** @internal */ @@ -67,12 +184,16 @@ export const PaymentConfigs$outboundSchema: z.ZodType< partnerUuid: z.string().optional(), fastPaymentLimit: z.string().optional(), paymentSpeed: z.string().optional(), + earnedFastAchBlockers: z.array( + z.lazy(() => EarnedFastAchBlockers$outboundSchema), + ).optional(), }).transform((v) => { return remap$(v, { companyUuid: "company_uuid", partnerUuid: "partner_uuid", fastPaymentLimit: "fast_payment_limit", paymentSpeed: "payment_speed", + earnedFastAchBlockers: "earned_fast_ach_blockers", }); }); diff --git a/gusto_embedded/src/models/components/payroll.ts b/gusto_embedded/src/models/components/payroll.ts index 344316ff..f58191e7 100644 --- a/gusto_embedded/src/models/components/payroll.ts +++ b/gusto_embedded/src/models/components/payroll.ts @@ -169,6 +169,10 @@ export type Payroll = { */ creditBlockers?: Array | undefined; processingRequest?: PayrollProcessingRequest | null | undefined; + /** + * Will money movement for the payroll be performed by the partner rather than by Gusto? + */ + partnerOwnedDisbursement?: boolean | null | undefined; }; /** @internal */ @@ -209,6 +213,7 @@ export const Payroll$inboundSchema: z.ZodType = .optional(), processing_request: z.nullable(PayrollProcessingRequest$inboundSchema) .optional(), + partner_owned_disbursement: z.nullable(z.boolean()).optional(), }).transform((v) => { return remap$(v, { "payroll_deadline": "payrollDeadline", @@ -233,6 +238,7 @@ export const Payroll$inboundSchema: z.ZodType = "submission_blockers": "submissionBlockers", "credit_blockers": "creditBlockers", "processing_request": "processingRequest", + "partner_owned_disbursement": "partnerOwnedDisbursement", }); }); @@ -268,6 +274,7 @@ export type Payroll$Outbound = { | undefined; credit_blockers?: Array | undefined; processing_request?: PayrollProcessingRequest$Outbound | null | undefined; + partner_owned_disbursement?: boolean | null | undefined; }; /** @internal */ @@ -308,6 +315,7 @@ export const Payroll$outboundSchema: z.ZodType< creditBlockers: z.array(PayrollCreditBlockersType$outboundSchema).optional(), processingRequest: z.nullable(PayrollProcessingRequest$outboundSchema) .optional(), + partnerOwnedDisbursement: z.nullable(z.boolean()).optional(), }).transform((v) => { return remap$(v, { payrollDeadline: "payroll_deadline", @@ -332,6 +340,7 @@ export const Payroll$outboundSchema: z.ZodType< submissionBlockers: "submission_blockers", creditBlockers: "credit_blockers", processingRequest: "processing_request", + partnerOwnedDisbursement: "partner_owned_disbursement", }); }); diff --git a/gusto_embedded/src/models/components/payrollemployeecompensationstype.ts b/gusto_embedded/src/models/components/payrollemployeecompensationstype.ts index fd61785a..32c2c33a 100644 --- a/gusto_embedded/src/models/components/payrollemployeecompensationstype.ts +++ b/gusto_embedded/src/models/components/payrollemployeecompensationstype.ts @@ -10,14 +10,15 @@ import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** - * The employee's compensation payment method. + * The employee's compensation payment method. Is *only* `Historical` when retrieving external payrolls initially run outside of Gusto, then put into Gusto. */ export const PayrollEmployeeCompensationsTypePaymentMethod = { DirectDeposit: "Direct Deposit", Check: "Check", + Historical: "Historical", } as const; /** - * The employee's compensation payment method. + * The employee's compensation payment method. Is *only* `Historical` when retrieving external payrolls initially run outside of Gusto, then put into Gusto. */ export type PayrollEmployeeCompensationsTypePaymentMethod = ClosedEnum< typeof PayrollEmployeeCompensationsTypePaymentMethod @@ -124,7 +125,7 @@ export type PayrollEmployeeCompensationsType = { */ checkAmount?: number | null | undefined; /** - * The employee's compensation payment method. + * The employee's compensation payment method. Is *only* `Historical` when retrieving external payrolls initially run outside of Gusto, then put into Gusto. */ paymentMethod?: | PayrollEmployeeCompensationsTypePaymentMethod diff --git a/gusto_embedded/src/models/components/payrollpartnerdisbursements.ts b/gusto_embedded/src/models/components/payrollpartnerdisbursements.ts new file mode 100644 index 00000000..8300ee47 --- /dev/null +++ b/gusto_embedded/src/models/components/payrollpartnerdisbursements.ts @@ -0,0 +1,275 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +/** + * The payment method for the disbursement + */ +export const PayrollPartnerDisbursementsPaymentMethod = { + DirectDeposit: "Direct Deposit", + Check: "Check", +} as const; +/** + * The payment method for the disbursement + */ +export type PayrollPartnerDisbursementsPaymentMethod = ClosedEnum< + typeof PayrollPartnerDisbursementsPaymentMethod +>; + +/** + * The status of the payment + */ +export const PayrollPartnerDisbursementsPaymentStatus = { + Pending: "Pending", + Paid: "Paid", + NotPartnerManaged: "Not partner managed", + ConvertedToCheck: "Converted to check", +} as const; +/** + * The status of the payment + */ +export type PayrollPartnerDisbursementsPaymentStatus = ClosedEnum< + typeof PayrollPartnerDisbursementsPaymentStatus +>; + +export type PayrollPartnerDisbursementsDisbursements = { + /** + * The UUID of the employee + */ + employeeUuid?: string | undefined; + /** + * The payment method for the disbursement + */ + paymentMethod?: PayrollPartnerDisbursementsPaymentMethod | undefined; + /** + * The status of the payment + */ + paymentStatus?: PayrollPartnerDisbursementsPaymentStatus | undefined; +}; + +/** + * Partner disbursements for a payroll + */ +export type PayrollPartnerDisbursements = { + /** + * The UUID of the payroll + */ + payrollUuid?: string | undefined; + /** + * List of disbursements for the payroll + */ + disbursements?: Array | undefined; +}; + +/** @internal */ +export const PayrollPartnerDisbursementsPaymentMethod$inboundSchema: + z.ZodNativeEnum = z + .nativeEnum(PayrollPartnerDisbursementsPaymentMethod); + +/** @internal */ +export const PayrollPartnerDisbursementsPaymentMethod$outboundSchema: + z.ZodNativeEnum = + PayrollPartnerDisbursementsPaymentMethod$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollPartnerDisbursementsPaymentMethod$ { + /** @deprecated use `PayrollPartnerDisbursementsPaymentMethod$inboundSchema` instead. */ + export const inboundSchema = + PayrollPartnerDisbursementsPaymentMethod$inboundSchema; + /** @deprecated use `PayrollPartnerDisbursementsPaymentMethod$outboundSchema` instead. */ + export const outboundSchema = + PayrollPartnerDisbursementsPaymentMethod$outboundSchema; +} + +/** @internal */ +export const PayrollPartnerDisbursementsPaymentStatus$inboundSchema: + z.ZodNativeEnum = z + .nativeEnum(PayrollPartnerDisbursementsPaymentStatus); + +/** @internal */ +export const PayrollPartnerDisbursementsPaymentStatus$outboundSchema: + z.ZodNativeEnum = + PayrollPartnerDisbursementsPaymentStatus$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollPartnerDisbursementsPaymentStatus$ { + /** @deprecated use `PayrollPartnerDisbursementsPaymentStatus$inboundSchema` instead. */ + export const inboundSchema = + PayrollPartnerDisbursementsPaymentStatus$inboundSchema; + /** @deprecated use `PayrollPartnerDisbursementsPaymentStatus$outboundSchema` instead. */ + export const outboundSchema = + PayrollPartnerDisbursementsPaymentStatus$outboundSchema; +} + +/** @internal */ +export const PayrollPartnerDisbursementsDisbursements$inboundSchema: z.ZodType< + PayrollPartnerDisbursementsDisbursements, + z.ZodTypeDef, + unknown +> = z.object({ + employee_uuid: z.string().optional(), + payment_method: PayrollPartnerDisbursementsPaymentMethod$inboundSchema + .optional(), + payment_status: PayrollPartnerDisbursementsPaymentStatus$inboundSchema + .optional(), +}).transform((v) => { + return remap$(v, { + "employee_uuid": "employeeUuid", + "payment_method": "paymentMethod", + "payment_status": "paymentStatus", + }); +}); + +/** @internal */ +export type PayrollPartnerDisbursementsDisbursements$Outbound = { + employee_uuid?: string | undefined; + payment_method?: string | undefined; + payment_status?: string | undefined; +}; + +/** @internal */ +export const PayrollPartnerDisbursementsDisbursements$outboundSchema: z.ZodType< + PayrollPartnerDisbursementsDisbursements$Outbound, + z.ZodTypeDef, + PayrollPartnerDisbursementsDisbursements +> = z.object({ + employeeUuid: z.string().optional(), + paymentMethod: PayrollPartnerDisbursementsPaymentMethod$outboundSchema + .optional(), + paymentStatus: PayrollPartnerDisbursementsPaymentStatus$outboundSchema + .optional(), +}).transform((v) => { + return remap$(v, { + employeeUuid: "employee_uuid", + paymentMethod: "payment_method", + paymentStatus: "payment_status", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollPartnerDisbursementsDisbursements$ { + /** @deprecated use `PayrollPartnerDisbursementsDisbursements$inboundSchema` instead. */ + export const inboundSchema = + PayrollPartnerDisbursementsDisbursements$inboundSchema; + /** @deprecated use `PayrollPartnerDisbursementsDisbursements$outboundSchema` instead. */ + export const outboundSchema = + PayrollPartnerDisbursementsDisbursements$outboundSchema; + /** @deprecated use `PayrollPartnerDisbursementsDisbursements$Outbound` instead. */ + export type Outbound = PayrollPartnerDisbursementsDisbursements$Outbound; +} + +export function payrollPartnerDisbursementsDisbursementsToJSON( + payrollPartnerDisbursementsDisbursements: + PayrollPartnerDisbursementsDisbursements, +): string { + return JSON.stringify( + PayrollPartnerDisbursementsDisbursements$outboundSchema.parse( + payrollPartnerDisbursementsDisbursements, + ), + ); +} + +export function payrollPartnerDisbursementsDisbursementsFromJSON( + jsonString: string, +): SafeParseResult< + PayrollPartnerDisbursementsDisbursements, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PayrollPartnerDisbursementsDisbursements$inboundSchema.parse( + JSON.parse(x), + ), + `Failed to parse 'PayrollPartnerDisbursementsDisbursements' from JSON`, + ); +} + +/** @internal */ +export const PayrollPartnerDisbursements$inboundSchema: z.ZodType< + PayrollPartnerDisbursements, + z.ZodTypeDef, + unknown +> = z.object({ + payroll_uuid: z.string().optional(), + disbursements: z.array( + z.lazy(() => PayrollPartnerDisbursementsDisbursements$inboundSchema), + ).optional(), +}).transform((v) => { + return remap$(v, { + "payroll_uuid": "payrollUuid", + }); +}); + +/** @internal */ +export type PayrollPartnerDisbursements$Outbound = { + payroll_uuid?: string | undefined; + disbursements?: + | Array + | undefined; +}; + +/** @internal */ +export const PayrollPartnerDisbursements$outboundSchema: z.ZodType< + PayrollPartnerDisbursements$Outbound, + z.ZodTypeDef, + PayrollPartnerDisbursements +> = z.object({ + payrollUuid: z.string().optional(), + disbursements: z.array( + z.lazy(() => PayrollPartnerDisbursementsDisbursements$outboundSchema), + ).optional(), +}).transform((v) => { + return remap$(v, { + payrollUuid: "payroll_uuid", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollPartnerDisbursements$ { + /** @deprecated use `PayrollPartnerDisbursements$inboundSchema` instead. */ + export const inboundSchema = PayrollPartnerDisbursements$inboundSchema; + /** @deprecated use `PayrollPartnerDisbursements$outboundSchema` instead. */ + export const outboundSchema = PayrollPartnerDisbursements$outboundSchema; + /** @deprecated use `PayrollPartnerDisbursements$Outbound` instead. */ + export type Outbound = PayrollPartnerDisbursements$Outbound; +} + +export function payrollPartnerDisbursementsToJSON( + payrollPartnerDisbursements: PayrollPartnerDisbursements, +): string { + return JSON.stringify( + PayrollPartnerDisbursements$outboundSchema.parse( + payrollPartnerDisbursements, + ), + ); +} + +export function payrollPartnerDisbursementsFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => PayrollPartnerDisbursements$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'PayrollPartnerDisbursements' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/components/payrollprepared.ts b/gusto_embedded/src/models/components/payrollprepared.ts index 0a72c7bb..5061faa0 100644 --- a/gusto_embedded/src/models/components/payrollprepared.ts +++ b/gusto_embedded/src/models/components/payrollprepared.ts @@ -136,6 +136,10 @@ export type PayrollPrepared = { createdAt?: Date | undefined; fixedCompensationTypes?: Array | undefined; processingRequest?: PayrollProcessingRequest | null | undefined; + /** + * Will money movement for the payroll be performed by the partner rather than by Gusto? + */ + partnerOwnedDisbursement?: boolean | null | undefined; }; /** @internal */ @@ -175,6 +179,7 @@ export const PayrollPrepared$inboundSchema: z.ZodType< ).optional(), processing_request: z.nullable(PayrollProcessingRequest$inboundSchema) .optional(), + partner_owned_disbursement: z.nullable(z.boolean()).optional(), }).transform((v) => { return remap$(v, { "payroll_deadline": "payrollDeadline", @@ -197,6 +202,7 @@ export const PayrollPrepared$inboundSchema: z.ZodType< "created_at": "createdAt", "fixed_compensation_types": "fixedCompensationTypes", "processing_request": "processingRequest", + "partner_owned_disbursement": "partnerOwnedDisbursement", }); }); @@ -229,6 +235,7 @@ export type PayrollPrepared$Outbound = { | Array | undefined; processing_request?: PayrollProcessingRequest$Outbound | null | undefined; + partner_owned_disbursement?: boolean | null | undefined; }; /** @internal */ @@ -267,6 +274,7 @@ export const PayrollPrepared$outboundSchema: z.ZodType< ).optional(), processingRequest: z.nullable(PayrollProcessingRequest$outboundSchema) .optional(), + partnerOwnedDisbursement: z.nullable(z.boolean()).optional(), }).transform((v) => { return remap$(v, { payrollDeadline: "payroll_deadline", @@ -289,6 +297,7 @@ export const PayrollPrepared$outboundSchema: z.ZodType< createdAt: "created_at", fixedCompensationTypes: "fixed_compensation_types", processingRequest: "processing_request", + partnerOwnedDisbursement: "partner_owned_disbursement", }); }); diff --git a/gusto_embedded/src/models/components/payrollreceipt.ts b/gusto_embedded/src/models/components/payrollreceipt.ts index 0c62ab9c..c97ae6c1 100644 --- a/gusto_embedded/src/models/components/payrollreceipt.ts +++ b/gusto_embedded/src/models/components/payrollreceipt.ts @@ -60,7 +60,7 @@ export type PayrollReceiptPaymentMethod = ClosedEnum< typeof PayrollReceiptPaymentMethod >; -export type EmployeeCompensations = { +export type PayrollReceiptEmployeeCompensations = { /** * The UUID of the employee. */ @@ -175,7 +175,9 @@ export type PayrollReceipt = { /** * An array of employee compensations and withholdings for this payroll */ - employeeCompensations?: Array | undefined; + employeeCompensations?: + | Array + | undefined; /** * The licensed payroll processor */ @@ -336,8 +338,8 @@ export namespace PayrollReceiptPaymentMethod$ { } /** @internal */ -export const EmployeeCompensations$inboundSchema: z.ZodType< - EmployeeCompensations, +export const PayrollReceiptEmployeeCompensations$inboundSchema: z.ZodType< + PayrollReceiptEmployeeCompensations, z.ZodTypeDef, unknown > = z.object({ @@ -365,7 +367,7 @@ export const EmployeeCompensations$inboundSchema: z.ZodType< }); /** @internal */ -export type EmployeeCompensations$Outbound = { +export type PayrollReceiptEmployeeCompensations$Outbound = { employee_uuid?: string | undefined; employee_first_name?: string | undefined; employee_last_name?: string | undefined; @@ -378,10 +380,10 @@ export type EmployeeCompensations$Outbound = { }; /** @internal */ -export const EmployeeCompensations$outboundSchema: z.ZodType< - EmployeeCompensations$Outbound, +export const PayrollReceiptEmployeeCompensations$outboundSchema: z.ZodType< + PayrollReceiptEmployeeCompensations$Outbound, z.ZodTypeDef, - EmployeeCompensations + PayrollReceiptEmployeeCompensations > = z.object({ employeeUuid: z.string().optional(), employeeFirstName: z.string().optional(), @@ -410,30 +412,35 @@ export const EmployeeCompensations$outboundSchema: z.ZodType< * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace EmployeeCompensations$ { - /** @deprecated use `EmployeeCompensations$inboundSchema` instead. */ - export const inboundSchema = EmployeeCompensations$inboundSchema; - /** @deprecated use `EmployeeCompensations$outboundSchema` instead. */ - export const outboundSchema = EmployeeCompensations$outboundSchema; - /** @deprecated use `EmployeeCompensations$Outbound` instead. */ - export type Outbound = EmployeeCompensations$Outbound; +export namespace PayrollReceiptEmployeeCompensations$ { + /** @deprecated use `PayrollReceiptEmployeeCompensations$inboundSchema` instead. */ + export const inboundSchema = + PayrollReceiptEmployeeCompensations$inboundSchema; + /** @deprecated use `PayrollReceiptEmployeeCompensations$outboundSchema` instead. */ + export const outboundSchema = + PayrollReceiptEmployeeCompensations$outboundSchema; + /** @deprecated use `PayrollReceiptEmployeeCompensations$Outbound` instead. */ + export type Outbound = PayrollReceiptEmployeeCompensations$Outbound; } -export function employeeCompensationsToJSON( - employeeCompensations: EmployeeCompensations, +export function payrollReceiptEmployeeCompensationsToJSON( + payrollReceiptEmployeeCompensations: PayrollReceiptEmployeeCompensations, ): string { return JSON.stringify( - EmployeeCompensations$outboundSchema.parse(employeeCompensations), + PayrollReceiptEmployeeCompensations$outboundSchema.parse( + payrollReceiptEmployeeCompensations, + ), ); } -export function employeeCompensationsFromJSON( +export function payrollReceiptEmployeeCompensationsFromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult { return safeParse( jsonString, - (x) => EmployeeCompensations$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'EmployeeCompensations' from JSON`, + (x) => + PayrollReceiptEmployeeCompensations$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'PayrollReceiptEmployeeCompensations' from JSON`, ); } @@ -531,7 +538,7 @@ export const PayrollReceipt$inboundSchema: z.ZodType< totals: z.lazy(() => Totals$inboundSchema).optional(), taxes: z.array(z.lazy(() => PayrollReceiptTaxes$inboundSchema)).optional(), employee_compensations: z.array( - z.lazy(() => EmployeeCompensations$inboundSchema), + z.lazy(() => PayrollReceiptEmployeeCompensations$inboundSchema), ).optional(), licensee: z.lazy(() => Licensee$inboundSchema).optional(), }).transform((v) => { @@ -563,7 +570,9 @@ export type PayrollReceipt$Outbound = { liability_of_licensee?: string | undefined; totals?: Totals$Outbound | undefined; taxes?: Array | undefined; - employee_compensations?: Array | undefined; + employee_compensations?: + | Array + | undefined; licensee?: Licensee$Outbound | undefined; }; @@ -586,7 +595,7 @@ export const PayrollReceipt$outboundSchema: z.ZodType< totals: z.lazy(() => Totals$outboundSchema).optional(), taxes: z.array(z.lazy(() => PayrollReceiptTaxes$outboundSchema)).optional(), employeeCompensations: z.array( - z.lazy(() => EmployeeCompensations$outboundSchema), + z.lazy(() => PayrollReceiptEmployeeCompensations$outboundSchema), ).optional(), licensee: z.lazy(() => Licensee$outboundSchema).optional(), }).transform((v) => { diff --git a/gusto_embedded/src/models/components/payrollupdate.ts b/gusto_embedded/src/models/components/payrollupdate.ts new file mode 100644 index 00000000..16ea70c4 --- /dev/null +++ b/gusto_embedded/src/models/components/payrollupdate.ts @@ -0,0 +1,578 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +/** + * The employee's compensation payment method. Invalid values will be ignored. + */ +export const PayrollUpdatePaymentMethod = { + DirectDeposit: "Direct Deposit", + Check: "Check", +} as const; +/** + * The employee's compensation payment method. Invalid values will be ignored. + */ +export type PayrollUpdatePaymentMethod = ClosedEnum< + typeof PayrollUpdatePaymentMethod +>; + +/** + * An array of fixed compensations for the employee. Fixed compensations include tips, bonuses, and one time reimbursements. + */ +export type PayrollUpdateFixedCompensations = { + /** + * The name of the compensation. This also serves as the unique, immutable identifier for this compensation. + */ + name?: string | undefined; + /** + * The amount of the compensation for the pay period. + */ + amount?: string | undefined; + /** + * The UUID of the job for the compensation. + */ + jobUuid?: string | undefined; +}; + +/** + * An array of hourly compensations for the employee. Hourly compensations include regular, overtime, and double overtime hours. + */ +export type PayrollUpdateHourlyCompensations = { + /** + * The name of the compensation. This also serves as the unique, immutable identifier for this compensation. + */ + name?: string | undefined; + /** + * The number of hours to be compensated for this pay period. + */ + hours?: string | undefined; + /** + * The UUIDs of the job for the compensation. + */ + jobUuid?: string | undefined; +}; + +export type PayrollUpdatePaidTimeOff = { + /** + * The name of the PTO. This also serves as the unique, immutable identifier for the PTO. Must pass in name or policy_uuid but not both. + */ + name?: string | undefined; + /** + * The hours of this PTO taken during the pay period. + */ + hours?: string | undefined; + /** + * The uuid of the PTO policy. Must pass in name or policy_uuid but not both. + */ + policyUuid?: string | undefined; + /** + * The outstanding hours paid upon termination. This field is only applicable for termination payrolls. + */ + finalPayoutUnusedHoursInput?: string | undefined; +}; + +export type EmployeeCompensations = { + /** + * The UUID of the employee. + */ + employeeUuid?: string | undefined; + /** + * The current version of this employee compensation from the prepared payroll. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. + */ + version?: string | undefined; + /** + * This employee will be excluded from payroll calculation and will not be paid for the payroll. + */ + excluded?: boolean | undefined; + /** + * The employee's compensation payment method. Invalid values will be ignored. + */ + paymentMethod?: PayrollUpdatePaymentMethod | undefined; + /** + * Custom text that will be printed as a personal note to the employee on a paystub. + */ + memo?: string | undefined; + fixedCompensations?: Array | undefined; + hourlyCompensations?: Array | undefined; + /** + * An array of all paid time off the employee is eligible for this pay period. Each paid time off object can be the name or the specific policy_uuid. + */ + paidTimeOff?: Array | undefined; +}; + +/** + * The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. + */ +export const WithholdingPayPeriod = { + EveryWeek: "Every week", + EveryOtherWeek: "Every other week", + TwicePerMonth: "Twice per month", + Monthly: "Monthly", + Quarterly: "Quarterly", + Semiannually: "Semiannually", + Annually: "Annually", +} as const; +/** + * The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. + */ +export type WithholdingPayPeriod = ClosedEnum; + +export type PayrollUpdate = { + employeeCompensations: Array; + /** + * The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. + */ + withholdingPayPeriod?: WithholdingPayPeriod | undefined; + /** + * Block regular deductions and contributions for this payroll. Only relevant for off-cycle payrolls. + */ + skipRegularDeductions?: boolean | undefined; + /** + * Enable taxes to be withheld at the IRS's required rate of 22% for federal income taxes. State income taxes will be taxed at the state's supplemental tax rate. Otherwise, we'll sum the entirety of the employee's wages and withhold taxes on the entire amount at the rate for regular wages. Only relevant for off-cycle payrolls. + */ + fixedWithholdingRate?: boolean | undefined; +}; + +/** @internal */ +export const PayrollUpdatePaymentMethod$inboundSchema: z.ZodNativeEnum< + typeof PayrollUpdatePaymentMethod +> = z.nativeEnum(PayrollUpdatePaymentMethod); + +/** @internal */ +export const PayrollUpdatePaymentMethod$outboundSchema: z.ZodNativeEnum< + typeof PayrollUpdatePaymentMethod +> = PayrollUpdatePaymentMethod$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollUpdatePaymentMethod$ { + /** @deprecated use `PayrollUpdatePaymentMethod$inboundSchema` instead. */ + export const inboundSchema = PayrollUpdatePaymentMethod$inboundSchema; + /** @deprecated use `PayrollUpdatePaymentMethod$outboundSchema` instead. */ + export const outboundSchema = PayrollUpdatePaymentMethod$outboundSchema; +} + +/** @internal */ +export const PayrollUpdateFixedCompensations$inboundSchema: z.ZodType< + PayrollUpdateFixedCompensations, + z.ZodTypeDef, + unknown +> = z.object({ + name: z.string().optional(), + amount: z.string().optional(), + job_uuid: z.string().optional(), +}).transform((v) => { + return remap$(v, { + "job_uuid": "jobUuid", + }); +}); + +/** @internal */ +export type PayrollUpdateFixedCompensations$Outbound = { + name?: string | undefined; + amount?: string | undefined; + job_uuid?: string | undefined; +}; + +/** @internal */ +export const PayrollUpdateFixedCompensations$outboundSchema: z.ZodType< + PayrollUpdateFixedCompensations$Outbound, + z.ZodTypeDef, + PayrollUpdateFixedCompensations +> = z.object({ + name: z.string().optional(), + amount: z.string().optional(), + jobUuid: z.string().optional(), +}).transform((v) => { + return remap$(v, { + jobUuid: "job_uuid", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollUpdateFixedCompensations$ { + /** @deprecated use `PayrollUpdateFixedCompensations$inboundSchema` instead. */ + export const inboundSchema = PayrollUpdateFixedCompensations$inboundSchema; + /** @deprecated use `PayrollUpdateFixedCompensations$outboundSchema` instead. */ + export const outboundSchema = PayrollUpdateFixedCompensations$outboundSchema; + /** @deprecated use `PayrollUpdateFixedCompensations$Outbound` instead. */ + export type Outbound = PayrollUpdateFixedCompensations$Outbound; +} + +export function payrollUpdateFixedCompensationsToJSON( + payrollUpdateFixedCompensations: PayrollUpdateFixedCompensations, +): string { + return JSON.stringify( + PayrollUpdateFixedCompensations$outboundSchema.parse( + payrollUpdateFixedCompensations, + ), + ); +} + +export function payrollUpdateFixedCompensationsFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => PayrollUpdateFixedCompensations$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'PayrollUpdateFixedCompensations' from JSON`, + ); +} + +/** @internal */ +export const PayrollUpdateHourlyCompensations$inboundSchema: z.ZodType< + PayrollUpdateHourlyCompensations, + z.ZodTypeDef, + unknown +> = z.object({ + name: z.string().optional(), + hours: z.string().optional(), + job_uuid: z.string().optional(), +}).transform((v) => { + return remap$(v, { + "job_uuid": "jobUuid", + }); +}); + +/** @internal */ +export type PayrollUpdateHourlyCompensations$Outbound = { + name?: string | undefined; + hours?: string | undefined; + job_uuid?: string | undefined; +}; + +/** @internal */ +export const PayrollUpdateHourlyCompensations$outboundSchema: z.ZodType< + PayrollUpdateHourlyCompensations$Outbound, + z.ZodTypeDef, + PayrollUpdateHourlyCompensations +> = z.object({ + name: z.string().optional(), + hours: z.string().optional(), + jobUuid: z.string().optional(), +}).transform((v) => { + return remap$(v, { + jobUuid: "job_uuid", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollUpdateHourlyCompensations$ { + /** @deprecated use `PayrollUpdateHourlyCompensations$inboundSchema` instead. */ + export const inboundSchema = PayrollUpdateHourlyCompensations$inboundSchema; + /** @deprecated use `PayrollUpdateHourlyCompensations$outboundSchema` instead. */ + export const outboundSchema = PayrollUpdateHourlyCompensations$outboundSchema; + /** @deprecated use `PayrollUpdateHourlyCompensations$Outbound` instead. */ + export type Outbound = PayrollUpdateHourlyCompensations$Outbound; +} + +export function payrollUpdateHourlyCompensationsToJSON( + payrollUpdateHourlyCompensations: PayrollUpdateHourlyCompensations, +): string { + return JSON.stringify( + PayrollUpdateHourlyCompensations$outboundSchema.parse( + payrollUpdateHourlyCompensations, + ), + ); +} + +export function payrollUpdateHourlyCompensationsFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => PayrollUpdateHourlyCompensations$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'PayrollUpdateHourlyCompensations' from JSON`, + ); +} + +/** @internal */ +export const PayrollUpdatePaidTimeOff$inboundSchema: z.ZodType< + PayrollUpdatePaidTimeOff, + z.ZodTypeDef, + unknown +> = z.object({ + name: z.string().optional(), + hours: z.string().optional(), + policy_uuid: z.string().optional(), + final_payout_unused_hours_input: z.string().optional(), +}).transform((v) => { + return remap$(v, { + "policy_uuid": "policyUuid", + "final_payout_unused_hours_input": "finalPayoutUnusedHoursInput", + }); +}); + +/** @internal */ +export type PayrollUpdatePaidTimeOff$Outbound = { + name?: string | undefined; + hours?: string | undefined; + policy_uuid?: string | undefined; + final_payout_unused_hours_input?: string | undefined; +}; + +/** @internal */ +export const PayrollUpdatePaidTimeOff$outboundSchema: z.ZodType< + PayrollUpdatePaidTimeOff$Outbound, + z.ZodTypeDef, + PayrollUpdatePaidTimeOff +> = z.object({ + name: z.string().optional(), + hours: z.string().optional(), + policyUuid: z.string().optional(), + finalPayoutUnusedHoursInput: z.string().optional(), +}).transform((v) => { + return remap$(v, { + policyUuid: "policy_uuid", + finalPayoutUnusedHoursInput: "final_payout_unused_hours_input", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollUpdatePaidTimeOff$ { + /** @deprecated use `PayrollUpdatePaidTimeOff$inboundSchema` instead. */ + export const inboundSchema = PayrollUpdatePaidTimeOff$inboundSchema; + /** @deprecated use `PayrollUpdatePaidTimeOff$outboundSchema` instead. */ + export const outboundSchema = PayrollUpdatePaidTimeOff$outboundSchema; + /** @deprecated use `PayrollUpdatePaidTimeOff$Outbound` instead. */ + export type Outbound = PayrollUpdatePaidTimeOff$Outbound; +} + +export function payrollUpdatePaidTimeOffToJSON( + payrollUpdatePaidTimeOff: PayrollUpdatePaidTimeOff, +): string { + return JSON.stringify( + PayrollUpdatePaidTimeOff$outboundSchema.parse(payrollUpdatePaidTimeOff), + ); +} + +export function payrollUpdatePaidTimeOffFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => PayrollUpdatePaidTimeOff$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'PayrollUpdatePaidTimeOff' from JSON`, + ); +} + +/** @internal */ +export const EmployeeCompensations$inboundSchema: z.ZodType< + EmployeeCompensations, + z.ZodTypeDef, + unknown +> = z.object({ + employee_uuid: z.string().optional(), + version: z.string().optional(), + excluded: z.boolean().optional(), + payment_method: PayrollUpdatePaymentMethod$inboundSchema.optional(), + memo: z.string().optional(), + fixed_compensations: z.array( + z.lazy(() => PayrollUpdateFixedCompensations$inboundSchema), + ).optional(), + hourly_compensations: z.array( + z.lazy(() => PayrollUpdateHourlyCompensations$inboundSchema), + ).optional(), + paid_time_off: z.array(z.lazy(() => PayrollUpdatePaidTimeOff$inboundSchema)) + .optional(), +}).transform((v) => { + return remap$(v, { + "employee_uuid": "employeeUuid", + "payment_method": "paymentMethod", + "fixed_compensations": "fixedCompensations", + "hourly_compensations": "hourlyCompensations", + "paid_time_off": "paidTimeOff", + }); +}); + +/** @internal */ +export type EmployeeCompensations$Outbound = { + employee_uuid?: string | undefined; + version?: string | undefined; + excluded?: boolean | undefined; + payment_method?: string | undefined; + memo?: string | undefined; + fixed_compensations?: + | Array + | undefined; + hourly_compensations?: + | Array + | undefined; + paid_time_off?: Array | undefined; +}; + +/** @internal */ +export const EmployeeCompensations$outboundSchema: z.ZodType< + EmployeeCompensations$Outbound, + z.ZodTypeDef, + EmployeeCompensations +> = z.object({ + employeeUuid: z.string().optional(), + version: z.string().optional(), + excluded: z.boolean().optional(), + paymentMethod: PayrollUpdatePaymentMethod$outboundSchema.optional(), + memo: z.string().optional(), + fixedCompensations: z.array( + z.lazy(() => PayrollUpdateFixedCompensations$outboundSchema), + ).optional(), + hourlyCompensations: z.array( + z.lazy(() => PayrollUpdateHourlyCompensations$outboundSchema), + ).optional(), + paidTimeOff: z.array(z.lazy(() => PayrollUpdatePaidTimeOff$outboundSchema)) + .optional(), +}).transform((v) => { + return remap$(v, { + employeeUuid: "employee_uuid", + paymentMethod: "payment_method", + fixedCompensations: "fixed_compensations", + hourlyCompensations: "hourly_compensations", + paidTimeOff: "paid_time_off", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace EmployeeCompensations$ { + /** @deprecated use `EmployeeCompensations$inboundSchema` instead. */ + export const inboundSchema = EmployeeCompensations$inboundSchema; + /** @deprecated use `EmployeeCompensations$outboundSchema` instead. */ + export const outboundSchema = EmployeeCompensations$outboundSchema; + /** @deprecated use `EmployeeCompensations$Outbound` instead. */ + export type Outbound = EmployeeCompensations$Outbound; +} + +export function employeeCompensationsToJSON( + employeeCompensations: EmployeeCompensations, +): string { + return JSON.stringify( + EmployeeCompensations$outboundSchema.parse(employeeCompensations), + ); +} + +export function employeeCompensationsFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => EmployeeCompensations$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'EmployeeCompensations' from JSON`, + ); +} + +/** @internal */ +export const WithholdingPayPeriod$inboundSchema: z.ZodNativeEnum< + typeof WithholdingPayPeriod +> = z.nativeEnum(WithholdingPayPeriod); + +/** @internal */ +export const WithholdingPayPeriod$outboundSchema: z.ZodNativeEnum< + typeof WithholdingPayPeriod +> = WithholdingPayPeriod$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace WithholdingPayPeriod$ { + /** @deprecated use `WithholdingPayPeriod$inboundSchema` instead. */ + export const inboundSchema = WithholdingPayPeriod$inboundSchema; + /** @deprecated use `WithholdingPayPeriod$outboundSchema` instead. */ + export const outboundSchema = WithholdingPayPeriod$outboundSchema; +} + +/** @internal */ +export const PayrollUpdate$inboundSchema: z.ZodType< + PayrollUpdate, + z.ZodTypeDef, + unknown +> = z.object({ + employee_compensations: z.array( + z.lazy(() => EmployeeCompensations$inboundSchema), + ), + withholding_pay_period: WithholdingPayPeriod$inboundSchema.optional(), + skip_regular_deductions: z.boolean().optional(), + fixed_withholding_rate: z.boolean().optional(), +}).transform((v) => { + return remap$(v, { + "employee_compensations": "employeeCompensations", + "withholding_pay_period": "withholdingPayPeriod", + "skip_regular_deductions": "skipRegularDeductions", + "fixed_withholding_rate": "fixedWithholdingRate", + }); +}); + +/** @internal */ +export type PayrollUpdate$Outbound = { + employee_compensations: Array; + withholding_pay_period?: string | undefined; + skip_regular_deductions?: boolean | undefined; + fixed_withholding_rate?: boolean | undefined; +}; + +/** @internal */ +export const PayrollUpdate$outboundSchema: z.ZodType< + PayrollUpdate$Outbound, + z.ZodTypeDef, + PayrollUpdate +> = z.object({ + employeeCompensations: z.array( + z.lazy(() => EmployeeCompensations$outboundSchema), + ), + withholdingPayPeriod: WithholdingPayPeriod$outboundSchema.optional(), + skipRegularDeductions: z.boolean().optional(), + fixedWithholdingRate: z.boolean().optional(), +}).transform((v) => { + return remap$(v, { + employeeCompensations: "employee_compensations", + withholdingPayPeriod: "withholding_pay_period", + skipRegularDeductions: "skip_regular_deductions", + fixedWithholdingRate: "fixed_withholding_rate", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PayrollUpdate$ { + /** @deprecated use `PayrollUpdate$inboundSchema` instead. */ + export const inboundSchema = PayrollUpdate$inboundSchema; + /** @deprecated use `PayrollUpdate$outboundSchema` instead. */ + export const outboundSchema = PayrollUpdate$outboundSchema; + /** @deprecated use `PayrollUpdate$Outbound` instead. */ + export type Outbound = PayrollUpdate$Outbound; +} + +export function payrollUpdateToJSON(payrollUpdate: PayrollUpdate): string { + return JSON.stringify(PayrollUpdate$outboundSchema.parse(payrollUpdate)); +} + +export function payrollUpdateFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => PayrollUpdate$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'PayrollUpdate' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/components/payscheduleassignmentemployee.ts b/gusto_embedded/src/models/components/payscheduleassignmentemployee.ts index feef0a49..1fb1d230 100644 --- a/gusto_embedded/src/models/components/payscheduleassignmentemployee.ts +++ b/gusto_embedded/src/models/components/payscheduleassignmentemployee.ts @@ -16,7 +16,7 @@ export type PayScheduleAssignmentEmployee = { /** * The employee's pay schedule UUID. */ - payScheduleUuid?: string | undefined; + payScheduleUuid?: string | null | undefined; }; /** @internal */ @@ -26,7 +26,7 @@ export const PayScheduleAssignmentEmployee$inboundSchema: z.ZodType< unknown > = z.object({ employee_uuid: z.string().optional(), - pay_schedule_uuid: z.string().optional(), + pay_schedule_uuid: z.nullable(z.string()).optional(), }).transform((v) => { return remap$(v, { "employee_uuid": "employeeUuid", @@ -37,7 +37,7 @@ export const PayScheduleAssignmentEmployee$inboundSchema: z.ZodType< /** @internal */ export type PayScheduleAssignmentEmployee$Outbound = { employee_uuid?: string | undefined; - pay_schedule_uuid?: string | undefined; + pay_schedule_uuid?: string | null | undefined; }; /** @internal */ @@ -47,7 +47,7 @@ export const PayScheduleAssignmentEmployee$outboundSchema: z.ZodType< PayScheduleAssignmentEmployee > = z.object({ employeeUuid: z.string().optional(), - payScheduleUuid: z.string().optional(), + payScheduleUuid: z.nullable(z.string()).optional(), }).transform((v) => { return remap$(v, { employeeUuid: "employee_uuid", diff --git a/gusto_embedded/src/models/components/showemployees.ts b/gusto_embedded/src/models/components/showemployees.ts new file mode 100644 index 00000000..f565cb69 --- /dev/null +++ b/gusto_embedded/src/models/components/showemployees.ts @@ -0,0 +1,579 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { + collectExtraKeys as collectExtraKeys$, + safeParse, +} from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { RFCDate } from "../../types/rfcdate.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +import { + EmployeeCustomField, + EmployeeCustomField$inboundSchema, + EmployeeCustomField$Outbound, + EmployeeCustomField$outboundSchema, +} from "./employeecustomfield.js"; +import { + EmployeeHomeAddress, + EmployeeHomeAddress$inboundSchema, + EmployeeHomeAddress$Outbound, + EmployeeHomeAddress$outboundSchema, +} from "./employeehomeaddress.js"; +import { + FlsaStatusType, + FlsaStatusType$inboundSchema, + FlsaStatusType$outboundSchema, +} from "./flsastatustype.js"; +import { + Garnishment, + Garnishment$inboundSchema, + Garnishment$Outbound, + Garnishment$outboundSchema, +} from "./garnishment.js"; +import { + Job, + Job$inboundSchema, + Job$Outbound, + Job$outboundSchema, +} from "./job.js"; +import { + PaidTimeOff, + PaidTimeOff$inboundSchema, + PaidTimeOff$Outbound, + PaidTimeOff$outboundSchema, +} from "./paidtimeoff.js"; +import { + Termination, + Termination$inboundSchema, + Termination$Outbound, + Termination$outboundSchema, +} from "./termination.js"; + +/** + * The current onboarding status of the employee + */ +export const OnboardingStatus = { + OnboardingCompleted: "onboarding_completed", + AdminOnboardingIncomplete: "admin_onboarding_incomplete", + SelfOnboardingPendingInvite: "self_onboarding_pending_invite", + SelfOnboardingInvited: "self_onboarding_invited", + SelfOnboardingInvitedStarted: "self_onboarding_invited_started", + SelfOnboardingInvitedOverdue: "self_onboarding_invited_overdue", + SelfOnboardingCompletedByEmployee: "self_onboarding_completed_by_employee", + SelfOnboardingAwaitingAdminReview: "self_onboarding_awaiting_admin_review", +} as const; +/** + * The current onboarding status of the employee + */ +export type OnboardingStatus = ClosedEnum; + +/** + * Configuration for an employee onboarding documents during onboarding + */ +export type OnboardingDocumentsConfig = { + /** + * The UUID of the onboarding documents config + */ + uuid?: string | null | undefined; + /** + * Whether to include Form I-9 for an employee during onboarding + */ + i9Document?: boolean | undefined; +}; + +/** + * The employee's payment method + */ +export const PaymentMethod = { + DirectDeposit: "Direct Deposit", + Check: "Check", +} as const; +/** + * The employee's payment method + */ +export type PaymentMethod = ClosedEnum; + +/** + * The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. + */ +export const CurrentEmploymentStatus = { + FullTime: "full_time", + PartTimeUnderTwentyHours: "part_time_under_twenty_hours", + PartTimeTwentyPlusHours: "part_time_twenty_plus_hours", + Variable: "variable", + Seasonal: "seasonal", +} as const; +/** + * The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. + */ +export type CurrentEmploymentStatus = ClosedEnum< + typeof CurrentEmploymentStatus +>; + +/** + * The representation of an employee in Gusto. + */ +export type ShowEmployees = { + /** + * The UUID of the employee in Gusto. + */ + uuid: string; + firstName: string; + middleInitial?: string | null | undefined; + lastName: string; + /** + * The personal email address of the employee. This is provided to support syncing users between our system and yours. You may not use this email address for any other purpose (e.g. marketing). + */ + email?: string | null | undefined; + /** + * The UUID of the company the employee is employed by. + */ + companyUuid?: string | undefined; + /** + * The UUID of the employee's manager. + */ + managerUuid?: string | null | undefined; + /** + * The current version of the employee. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. + */ + version?: string | undefined; + /** + * The employee's department in the company. + */ + department?: string | null | undefined; + /** + * Whether the employee is terminated. + */ + terminated?: boolean | undefined; + /** + * Whether the employee is a two percent shareholder of the company. This field only applies to companies with an S-Corp entity type. + */ + twoPercentShareholder?: boolean | null | undefined; + /** + * The work email address of the employee. This is provided to support syncing users between our system and yours. You may not use this email address for any other purpose (e.g. marketing). + */ + workEmail?: string | null | undefined; + /** + * Whether the employee has completed onboarding. + */ + onboarded?: boolean | undefined; + /** + * The current onboarding status of the employee + */ + onboardingStatus?: OnboardingStatus | null | undefined; + /** + * Configuration for an employee onboarding documents during onboarding + */ + onboardingDocumentsConfig?: OnboardingDocumentsConfig | undefined; + jobs?: Array | undefined; + eligiblePaidTimeOff?: Array | undefined; + terminations?: Array | undefined; + garnishments?: Array | undefined; + /** + * Custom fields are only included for the employee if the include param has the custom_fields value set + */ + customFields?: Array | undefined; + dateOfBirth?: string | null | undefined; + /** + * Indicates whether the employee has an SSN in Gusto. + */ + hasSsn?: boolean | undefined; + /** + * Deprecated. This field always returns an empty string. + */ + ssn?: string | undefined; + phone?: string | null | undefined; + preferredFirstName?: string | null | undefined; + /** + * The employee's payment method + */ + paymentMethod?: PaymentMethod | undefined; + /** + * The current employment status of the employee. Full-time employees work 30+ hours per week. Part-time employees are split into two groups: those that work 20-29 hours a week, and those that work under 20 hours a week. Variable employees have hours that vary each week. Seasonal employees are hired for 6 months of the year or less. + */ + currentEmploymentStatus?: CurrentEmploymentStatus | null | undefined; + historical?: boolean | undefined; + /** + * The short format code of the employee + */ + employeeCode?: string | undefined; + /** + * The UUID of the department the employee is under + */ + departmentUuid?: string | null | undefined; + title?: string | undefined; + /** + * The date when the employee was hired to the company + */ + hiredAt?: RFCDate | undefined; + hiddenSsn?: string | undefined; + /** + * The FLSA status for this compensation. Salaried ('Exempt') employees are paid a fixed salary every pay period. Salaried with overtime ('Salaried Nonexempt') employees are paid a fixed salary every pay period, and receive overtime pay when applicable. Hourly ('Nonexempt') employees are paid for the hours they work, and receive overtime pay when applicable. Commissioned employees ('Commission Only Exempt') earn wages based only on commission. Commissioned with overtime ('Commission Only Nonexempt') earn wages based on commission, and receive overtime pay when applicable. Owners ('Owner') are employees that own at least twenty percent of the company. + */ + flsaStatus?: FlsaStatusType | undefined; + applicableTaxIds?: Array | undefined; + currentHomeAddress?: EmployeeHomeAddress | undefined; + allHomeAddresses?: Array | undefined; + additionalProperties?: { [k: string]: any }; +}; + +/** @internal */ +export const OnboardingStatus$inboundSchema: z.ZodNativeEnum< + typeof OnboardingStatus +> = z.nativeEnum(OnboardingStatus); + +/** @internal */ +export const OnboardingStatus$outboundSchema: z.ZodNativeEnum< + typeof OnboardingStatus +> = OnboardingStatus$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace OnboardingStatus$ { + /** @deprecated use `OnboardingStatus$inboundSchema` instead. */ + export const inboundSchema = OnboardingStatus$inboundSchema; + /** @deprecated use `OnboardingStatus$outboundSchema` instead. */ + export const outboundSchema = OnboardingStatus$outboundSchema; +} + +/** @internal */ +export const OnboardingDocumentsConfig$inboundSchema: z.ZodType< + OnboardingDocumentsConfig, + z.ZodTypeDef, + unknown +> = z.object({ + uuid: z.nullable(z.string()).optional(), + i9_document: z.boolean().optional(), +}).transform((v) => { + return remap$(v, { + "i9_document": "i9Document", + }); +}); + +/** @internal */ +export type OnboardingDocumentsConfig$Outbound = { + uuid?: string | null | undefined; + i9_document?: boolean | undefined; +}; + +/** @internal */ +export const OnboardingDocumentsConfig$outboundSchema: z.ZodType< + OnboardingDocumentsConfig$Outbound, + z.ZodTypeDef, + OnboardingDocumentsConfig +> = z.object({ + uuid: z.nullable(z.string()).optional(), + i9Document: z.boolean().optional(), +}).transform((v) => { + return remap$(v, { + i9Document: "i9_document", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace OnboardingDocumentsConfig$ { + /** @deprecated use `OnboardingDocumentsConfig$inboundSchema` instead. */ + export const inboundSchema = OnboardingDocumentsConfig$inboundSchema; + /** @deprecated use `OnboardingDocumentsConfig$outboundSchema` instead. */ + export const outboundSchema = OnboardingDocumentsConfig$outboundSchema; + /** @deprecated use `OnboardingDocumentsConfig$Outbound` instead. */ + export type Outbound = OnboardingDocumentsConfig$Outbound; +} + +export function onboardingDocumentsConfigToJSON( + onboardingDocumentsConfig: OnboardingDocumentsConfig, +): string { + return JSON.stringify( + OnboardingDocumentsConfig$outboundSchema.parse(onboardingDocumentsConfig), + ); +} + +export function onboardingDocumentsConfigFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => OnboardingDocumentsConfig$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'OnboardingDocumentsConfig' from JSON`, + ); +} + +/** @internal */ +export const PaymentMethod$inboundSchema: z.ZodNativeEnum< + typeof PaymentMethod +> = z.nativeEnum(PaymentMethod); + +/** @internal */ +export const PaymentMethod$outboundSchema: z.ZodNativeEnum< + typeof PaymentMethod +> = PaymentMethod$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PaymentMethod$ { + /** @deprecated use `PaymentMethod$inboundSchema` instead. */ + export const inboundSchema = PaymentMethod$inboundSchema; + /** @deprecated use `PaymentMethod$outboundSchema` instead. */ + export const outboundSchema = PaymentMethod$outboundSchema; +} + +/** @internal */ +export const CurrentEmploymentStatus$inboundSchema: z.ZodNativeEnum< + typeof CurrentEmploymentStatus +> = z.nativeEnum(CurrentEmploymentStatus); + +/** @internal */ +export const CurrentEmploymentStatus$outboundSchema: z.ZodNativeEnum< + typeof CurrentEmploymentStatus +> = CurrentEmploymentStatus$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace CurrentEmploymentStatus$ { + /** @deprecated use `CurrentEmploymentStatus$inboundSchema` instead. */ + export const inboundSchema = CurrentEmploymentStatus$inboundSchema; + /** @deprecated use `CurrentEmploymentStatus$outboundSchema` instead. */ + export const outboundSchema = CurrentEmploymentStatus$outboundSchema; +} + +/** @internal */ +export const ShowEmployees$inboundSchema: z.ZodType< + ShowEmployees, + z.ZodTypeDef, + unknown +> = collectExtraKeys$( + z.object({ + uuid: z.string(), + first_name: z.string(), + middle_initial: z.nullable(z.string()).optional(), + last_name: z.string(), + email: z.nullable(z.string()).optional(), + company_uuid: z.string().optional(), + manager_uuid: z.nullable(z.string()).optional(), + version: z.string().optional(), + department: z.nullable(z.string()).optional(), + terminated: z.boolean().optional(), + two_percent_shareholder: z.nullable(z.boolean()).optional(), + work_email: z.nullable(z.string()).optional(), + onboarded: z.boolean().optional(), + onboarding_status: z.nullable(OnboardingStatus$inboundSchema).optional(), + onboarding_documents_config: z.lazy(() => + OnboardingDocumentsConfig$inboundSchema + ).optional(), + jobs: z.array(Job$inboundSchema).optional(), + eligible_paid_time_off: z.array(PaidTimeOff$inboundSchema).optional(), + terminations: z.array(Termination$inboundSchema).optional(), + garnishments: z.array(Garnishment$inboundSchema).optional(), + custom_fields: z.array(EmployeeCustomField$inboundSchema).optional(), + date_of_birth: z.nullable(z.string()).optional(), + has_ssn: z.boolean().optional(), + ssn: z.string().optional(), + phone: z.nullable(z.string()).optional(), + preferred_first_name: z.nullable(z.string()).optional(), + payment_method: PaymentMethod$inboundSchema.default("Check"), + current_employment_status: z.nullable(CurrentEmploymentStatus$inboundSchema) + .optional(), + historical: z.boolean().optional(), + employee_code: z.string().optional(), + department_uuid: z.nullable(z.string()).optional(), + title: z.string().optional(), + hired_at: z.string().transform(v => new RFCDate(v)).optional(), + hidden_ssn: z.string().optional(), + flsa_status: FlsaStatusType$inboundSchema.optional(), + applicable_tax_ids: z.array(z.number()).optional(), + current_home_address: EmployeeHomeAddress$inboundSchema.optional(), + all_home_addresses: z.array(EmployeeHomeAddress$inboundSchema).optional(), + }).catchall(z.any()), + "additionalProperties", + true, +).transform((v) => { + return remap$(v, { + "first_name": "firstName", + "middle_initial": "middleInitial", + "last_name": "lastName", + "company_uuid": "companyUuid", + "manager_uuid": "managerUuid", + "two_percent_shareholder": "twoPercentShareholder", + "work_email": "workEmail", + "onboarding_status": "onboardingStatus", + "onboarding_documents_config": "onboardingDocumentsConfig", + "eligible_paid_time_off": "eligiblePaidTimeOff", + "custom_fields": "customFields", + "date_of_birth": "dateOfBirth", + "has_ssn": "hasSsn", + "preferred_first_name": "preferredFirstName", + "payment_method": "paymentMethod", + "current_employment_status": "currentEmploymentStatus", + "employee_code": "employeeCode", + "department_uuid": "departmentUuid", + "hired_at": "hiredAt", + "hidden_ssn": "hiddenSsn", + "flsa_status": "flsaStatus", + "applicable_tax_ids": "applicableTaxIds", + "current_home_address": "currentHomeAddress", + "all_home_addresses": "allHomeAddresses", + }); +}); + +/** @internal */ +export type ShowEmployees$Outbound = { + uuid: string; + first_name: string; + middle_initial?: string | null | undefined; + last_name: string; + email?: string | null | undefined; + company_uuid?: string | undefined; + manager_uuid?: string | null | undefined; + version?: string | undefined; + department?: string | null | undefined; + terminated?: boolean | undefined; + two_percent_shareholder?: boolean | null | undefined; + work_email?: string | null | undefined; + onboarded?: boolean | undefined; + onboarding_status?: string | null | undefined; + onboarding_documents_config?: OnboardingDocumentsConfig$Outbound | undefined; + jobs?: Array | undefined; + eligible_paid_time_off?: Array | undefined; + terminations?: Array | undefined; + garnishments?: Array | undefined; + custom_fields?: Array | undefined; + date_of_birth?: string | null | undefined; + has_ssn?: boolean | undefined; + ssn?: string | undefined; + phone?: string | null | undefined; + preferred_first_name?: string | null | undefined; + payment_method: string; + current_employment_status?: string | null | undefined; + historical?: boolean | undefined; + employee_code?: string | undefined; + department_uuid?: string | null | undefined; + title?: string | undefined; + hired_at?: string | undefined; + hidden_ssn?: string | undefined; + flsa_status?: string | undefined; + applicable_tax_ids?: Array | undefined; + current_home_address?: EmployeeHomeAddress$Outbound | undefined; + all_home_addresses?: Array | undefined; + [additionalProperties: string]: unknown; +}; + +/** @internal */ +export const ShowEmployees$outboundSchema: z.ZodType< + ShowEmployees$Outbound, + z.ZodTypeDef, + ShowEmployees +> = z.object({ + uuid: z.string(), + firstName: z.string(), + middleInitial: z.nullable(z.string()).optional(), + lastName: z.string(), + email: z.nullable(z.string()).optional(), + companyUuid: z.string().optional(), + managerUuid: z.nullable(z.string()).optional(), + version: z.string().optional(), + department: z.nullable(z.string()).optional(), + terminated: z.boolean().optional(), + twoPercentShareholder: z.nullable(z.boolean()).optional(), + workEmail: z.nullable(z.string()).optional(), + onboarded: z.boolean().optional(), + onboardingStatus: z.nullable(OnboardingStatus$outboundSchema).optional(), + onboardingDocumentsConfig: z.lazy(() => + OnboardingDocumentsConfig$outboundSchema + ).optional(), + jobs: z.array(Job$outboundSchema).optional(), + eligiblePaidTimeOff: z.array(PaidTimeOff$outboundSchema).optional(), + terminations: z.array(Termination$outboundSchema).optional(), + garnishments: z.array(Garnishment$outboundSchema).optional(), + customFields: z.array(EmployeeCustomField$outboundSchema).optional(), + dateOfBirth: z.nullable(z.string()).optional(), + hasSsn: z.boolean().optional(), + ssn: z.string().optional(), + phone: z.nullable(z.string()).optional(), + preferredFirstName: z.nullable(z.string()).optional(), + paymentMethod: PaymentMethod$outboundSchema.default("Check"), + currentEmploymentStatus: z.nullable(CurrentEmploymentStatus$outboundSchema) + .optional(), + historical: z.boolean().optional(), + employeeCode: z.string().optional(), + departmentUuid: z.nullable(z.string()).optional(), + title: z.string().optional(), + hiredAt: z.instanceof(RFCDate).transform(v => v.toString()).optional(), + hiddenSsn: z.string().optional(), + flsaStatus: FlsaStatusType$outboundSchema.optional(), + applicableTaxIds: z.array(z.number()).optional(), + currentHomeAddress: EmployeeHomeAddress$outboundSchema.optional(), + allHomeAddresses: z.array(EmployeeHomeAddress$outboundSchema).optional(), + additionalProperties: z.record(z.any()), +}).transform((v) => { + return { + ...v.additionalProperties, + ...remap$(v, { + firstName: "first_name", + middleInitial: "middle_initial", + lastName: "last_name", + companyUuid: "company_uuid", + managerUuid: "manager_uuid", + twoPercentShareholder: "two_percent_shareholder", + workEmail: "work_email", + onboardingStatus: "onboarding_status", + onboardingDocumentsConfig: "onboarding_documents_config", + eligiblePaidTimeOff: "eligible_paid_time_off", + customFields: "custom_fields", + dateOfBirth: "date_of_birth", + hasSsn: "has_ssn", + preferredFirstName: "preferred_first_name", + paymentMethod: "payment_method", + currentEmploymentStatus: "current_employment_status", + employeeCode: "employee_code", + departmentUuid: "department_uuid", + hiredAt: "hired_at", + hiddenSsn: "hidden_ssn", + flsaStatus: "flsa_status", + applicableTaxIds: "applicable_tax_ids", + currentHomeAddress: "current_home_address", + allHomeAddresses: "all_home_addresses", + additionalProperties: null, + }), + }; +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace ShowEmployees$ { + /** @deprecated use `ShowEmployees$inboundSchema` instead. */ + export const inboundSchema = ShowEmployees$inboundSchema; + /** @deprecated use `ShowEmployees$outboundSchema` instead. */ + export const outboundSchema = ShowEmployees$outboundSchema; + /** @deprecated use `ShowEmployees$Outbound` instead. */ + export type Outbound = ShowEmployees$Outbound; +} + +export function showEmployeesToJSON(showEmployees: ShowEmployees): string { + return JSON.stringify(ShowEmployees$outboundSchema.parse(showEmployees)); +} + +export function showEmployeesFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => ShowEmployees$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'ShowEmployees' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/components/taxrequirementmetadata.ts b/gusto_embedded/src/models/components/taxrequirementmetadata.ts index 154bf7cc..48cc8651 100644 --- a/gusto_embedded/src/models/components/taxrequirementmetadata.ts +++ b/gusto_embedded/src/models/components/taxrequirementmetadata.ts @@ -68,7 +68,7 @@ export type TaxRequirementMetadataOptions = { /** * A less verbose label that may sometimes be available */ - shortLabel?: string | undefined; + shortLabel?: string | null | undefined; }; /** @@ -272,7 +272,7 @@ export const TaxRequirementMetadataOptions$inboundSchema: z.ZodType< > = z.object({ label: z.string(), value: z.union([z.string(), z.boolean()]), - short_label: z.string().optional(), + short_label: z.nullable(z.string()).optional(), }).transform((v) => { return remap$(v, { "short_label": "shortLabel", @@ -283,7 +283,7 @@ export const TaxRequirementMetadataOptions$inboundSchema: z.ZodType< export type TaxRequirementMetadataOptions$Outbound = { label: string; value: string | boolean; - short_label?: string | undefined; + short_label?: string | null | undefined; }; /** @internal */ @@ -294,7 +294,7 @@ export const TaxRequirementMetadataOptions$outboundSchema: z.ZodType< > = z.object({ label: z.string(), value: z.union([z.string(), z.boolean()]), - shortLabel: z.string().optional(), + shortLabel: z.nullable(z.string()).optional(), }).transform((v) => { return remap$(v, { shortLabel: "short_label", diff --git a/gusto_embedded/src/models/errors/apierror.ts b/gusto_embedded/src/models/errors/apierror.ts index 98824529..6a4000d0 100644 --- a/gusto_embedded/src/models/errors/apierror.ts +++ b/gusto_embedded/src/models/errors/apierror.ts @@ -25,8 +25,14 @@ export class APIError extends GustoEmbeddedError { }`; } const body = httpMeta.body || `""`; - message += body.length > 100 ? "\n" : " "; - message += `Body ${body}`; + message += body.length > 100 ? "\n" : ". "; + let bodyDisplay = body; + if (body.length > 10000) { + const truncated = body.substring(0, 10000); + const remaining = body.length - 10000; + bodyDisplay = `${truncated}...and ${remaining} more chars`; + } + message += `Body: ${bodyDisplay}`; message = message.trim(); super(message, httpMeta); this.name = "APIError"; diff --git a/gusto_embedded/src/models/operations/deletev1companiescompanyidpayrolls.ts b/gusto_embedded/src/models/operations/deletev1companiescompanyidpayrolls.ts index 7d434a70..b262430e 100644 --- a/gusto_embedded/src/models/operations/deletev1companiescompanyidpayrolls.ts +++ b/gusto_embedded/src/models/operations/deletev1companiescompanyidpayrolls.ts @@ -5,6 +5,7 @@ import * as z from "zod"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { HTTPMetadata, @@ -12,13 +13,20 @@ import { HTTPMetadata$Outbound, HTTPMetadata$outboundSchema, } from "../components/httpmetadata.js"; -import { - VersionHeader, - VersionHeader$inboundSchema, - VersionHeader$outboundSchema, -} from "../components/versionheader.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export const DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion = { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", +} as const; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export type DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion = + ClosedEnum; + export type DeleteV1CompaniesCompanyIdPayrollsRequest = { /** * The UUID of the company @@ -35,13 +43,40 @@ export type DeleteV1CompaniesCompanyIdPayrollsRequest = { /** * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ - xGustoAPIVersion?: VersionHeader | undefined; + xGustoAPIVersion?: + | DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion + | undefined; }; export type DeleteV1CompaniesCompanyIdPayrollsResponse = { httpMeta: HTTPMetadata; }; +/** @internal */ +export const DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum< + typeof DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion + > = z.nativeEnum(DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion); + +/** @internal */ +export const DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum< + typeof DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion + > = DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$ { + /** @deprecated use `DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema` instead. */ + export const inboundSchema = + DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema` instead. */ + export const outboundSchema = + DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema; +} + /** @internal */ export const DeleteV1CompaniesCompanyIdPayrollsRequest$inboundSchema: z.ZodType< DeleteV1CompaniesCompanyIdPayrollsRequest, @@ -51,7 +86,9 @@ export const DeleteV1CompaniesCompanyIdPayrollsRequest$inboundSchema: z.ZodType< company_id: z.string(), payroll_id: z.string(), async: z.boolean().optional(), - "X-Gusto-API-Version": VersionHeader$inboundSchema.default("2024-04-01"), + "X-Gusto-API-Version": + DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema + .default("2024-04-01"), }).transform((v) => { return remap$(v, { "company_id": "companyId", @@ -78,7 +115,9 @@ export const DeleteV1CompaniesCompanyIdPayrollsRequest$outboundSchema: companyId: z.string(), payrollId: z.string(), async: z.boolean().optional(), - xGustoAPIVersion: VersionHeader$outboundSchema.default("2024-04-01"), + xGustoAPIVersion: + DeleteV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema + .default("2024-04-01"), }).transform((v) => { return remap$(v, { companyId: "company_id", diff --git a/gusto_embedded/src/models/operations/getv1companiescompanyidemployees.ts b/gusto_embedded/src/models/operations/getv1companiescompanyidemployees.ts index fddbb831..85997eb8 100644 --- a/gusto_embedded/src/models/operations/getv1companiescompanyidemployees.ts +++ b/gusto_embedded/src/models/operations/getv1companiescompanyidemployees.ts @@ -7,18 +7,18 @@ import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; -import { - Employee, - Employee$inboundSchema, - Employee$Outbound, - Employee$outboundSchema, -} from "../components/employee.js"; import { HTTPMetadata, HTTPMetadata$inboundSchema, HTTPMetadata$Outbound, HTTPMetadata$outboundSchema, } from "../components/httpmetadata.js"; +import { + ShowEmployees, + ShowEmployees$inboundSchema, + ShowEmployees$Outbound, + ShowEmployees$outboundSchema, +} from "../components/showemployees.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** @@ -70,6 +70,10 @@ export type GetV1CompaniesCompanyIdEmployeesRequest = { * Filters employees by the provided boolean */ terminated?: boolean | undefined; + /** + * Optional subset of employees to fetch. + */ + uuids?: Array | undefined; /** * The page that is requested. When unspecified, will load all objects unless endpoint forces pagination. */ @@ -85,7 +89,7 @@ export type GetV1CompaniesCompanyIdEmployeesResponse = { /** * successful */ - employees?: Array | undefined; + showEmployees?: Array | undefined; }; /** @internal */ @@ -145,6 +149,7 @@ export const GetV1CompaniesCompanyIdEmployeesRequest$inboundSchema: z.ZodType< search_term: z.string().optional(), include: z.array(Include$inboundSchema).optional(), terminated: z.boolean().optional(), + uuids: z.array(z.string()).optional(), page: z.number().int().optional(), per: z.number().int().optional(), }).transform((v) => { @@ -162,6 +167,7 @@ export type GetV1CompaniesCompanyIdEmployeesRequest$Outbound = { search_term?: string | undefined; include?: Array | undefined; terminated?: boolean | undefined; + uuids?: Array | undefined; page?: number | undefined; per?: number | undefined; }; @@ -179,6 +185,7 @@ export const GetV1CompaniesCompanyIdEmployeesRequest$outboundSchema: z.ZodType< searchTerm: z.string().optional(), include: z.array(Include$outboundSchema).optional(), terminated: z.boolean().optional(), + uuids: z.array(z.string()).optional(), page: z.number().int().optional(), per: z.number().int().optional(), }).transform((v) => { @@ -238,18 +245,18 @@ export const GetV1CompaniesCompanyIdEmployeesResponse$inboundSchema: z.ZodType< unknown > = z.object({ HttpMeta: HTTPMetadata$inboundSchema, - Employees: z.array(Employee$inboundSchema).optional(), + "Show-Employees": z.array(ShowEmployees$inboundSchema).optional(), }).transform((v) => { return remap$(v, { "HttpMeta": "httpMeta", - "Employees": "employees", + "Show-Employees": "showEmployees", }); }); /** @internal */ export type GetV1CompaniesCompanyIdEmployeesResponse$Outbound = { HttpMeta: HTTPMetadata$Outbound; - Employees?: Array | undefined; + "Show-Employees"?: Array | undefined; }; /** @internal */ @@ -259,11 +266,11 @@ export const GetV1CompaniesCompanyIdEmployeesResponse$outboundSchema: z.ZodType< GetV1CompaniesCompanyIdEmployeesResponse > = z.object({ httpMeta: HTTPMetadata$outboundSchema, - employees: z.array(Employee$outboundSchema).optional(), + showEmployees: z.array(ShowEmployees$outboundSchema).optional(), }).transform((v) => { return remap$(v, { httpMeta: "HttpMeta", - employees: "Employees", + showEmployees: "Show-Employees", }); }); diff --git a/gusto_embedded/src/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.ts b/gusto_embedded/src/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.ts new file mode 100644 index 00000000..55c7d757 --- /dev/null +++ b/gusto_embedded/src/models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.ts @@ -0,0 +1,261 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { + HTTPMetadata, + HTTPMetadata$inboundSchema, + HTTPMetadata$Outbound, + HTTPMetadata$outboundSchema, +} from "../components/httpmetadata.js"; +import { + PayrollPartnerDisbursements, + PayrollPartnerDisbursements$inboundSchema, + PayrollPartnerDisbursements$Outbound, + PayrollPartnerDisbursements$outboundSchema, +} from "../components/payrollpartnerdisbursements.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export const GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion = + { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", + } as const; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export type GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion = + ClosedEnum< + typeof GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + >; + +export type GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest = { + /** + * The UUID of the company + */ + companyId: string; + /** + * The UUID of the payroll + */ + id: string; + /** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; +}; + +export type GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse = { + httpMeta: HTTPMetadata; + /** + * successful + */ + payrollPartnerDisbursements?: PayrollPartnerDisbursements | undefined; +}; + +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum< + typeof GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = z.nativeEnum( + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion, + ); + +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum< + typeof GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$ { + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema` instead. */ + export const inboundSchema = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema` instead. */ + export const outboundSchema = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema; +} + +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema: + z.ZodType< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + z.ZodTypeDef, + unknown + > = z.object({ + company_id: z.string(), + id: z.string(), + "X-Gusto-API-Version": + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema + .default("2024-04-01"), + }).transform((v) => { + return remap$(v, { + "company_id": "companyId", + "X-Gusto-API-Version": "xGustoAPIVersion", + }); + }); + +/** @internal */ +export type GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound = + { + company_id: string; + id: string; + "X-Gusto-API-Version": string; + }; + +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema: + z.ZodType< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound, + z.ZodTypeDef, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest + > = z.object({ + companyId: z.string(), + id: z.string(), + xGustoAPIVersion: + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema + .default("2024-04-01"), + }).transform((v) => { + return remap$(v, { + companyId: "company_id", + xGustoAPIVersion: "X-Gusto-API-Version", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$ { + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema` instead. */ + export const inboundSchema = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema; + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema` instead. */ + export const outboundSchema = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema; + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound` instead. */ + export type Outbound = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound; +} + +export function getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestToJSON( + getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest: + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, +): string { + return JSON.stringify( + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema + .parse(getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest), + ); +} + +export function getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestFromJSON( + jsonString: string, +): SafeParseResult< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest' from JSON`, + ); +} + +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema: + z.ZodType< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + z.ZodTypeDef, + unknown + > = z.object({ + HttpMeta: HTTPMetadata$inboundSchema, + "Payroll-Partner-Disbursements": PayrollPartnerDisbursements$inboundSchema + .optional(), + }).transform((v) => { + return remap$(v, { + "HttpMeta": "httpMeta", + "Payroll-Partner-Disbursements": "payrollPartnerDisbursements", + }); + }); + +/** @internal */ +export type GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound = + { + HttpMeta: HTTPMetadata$Outbound; + "Payroll-Partner-Disbursements"?: + | PayrollPartnerDisbursements$Outbound + | undefined; + }; + +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema: + z.ZodType< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound, + z.ZodTypeDef, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse + > = z.object({ + httpMeta: HTTPMetadata$outboundSchema, + payrollPartnerDisbursements: PayrollPartnerDisbursements$outboundSchema + .optional(), + }).transform((v) => { + return remap$(v, { + httpMeta: "HttpMeta", + payrollPartnerDisbursements: "Payroll-Partner-Disbursements", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$ { + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema` instead. */ + export const inboundSchema = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema; + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema` instead. */ + export const outboundSchema = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema; + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound` instead. */ + export type Outbound = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound; +} + +export function getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponseToJSON( + getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse: + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, +): string { + return JSON.stringify( + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema + .parse(getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse), + ); +} + +export function getV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponseFromJSON( + jsonString: string, +): SafeParseResult< + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/operations/getv1companiescompanyidpayrollspayrollid.ts b/gusto_embedded/src/models/operations/getv1companiescompanyidpayrollspayrollid.ts index d5e24b26..295005de 100644 --- a/gusto_embedded/src/models/operations/getv1companiescompanyidpayrollspayrollid.ts +++ b/gusto_embedded/src/models/operations/getv1companiescompanyidpayrollspayrollid.ts @@ -19,18 +19,30 @@ import { Payroll$Outbound, Payroll$outboundSchema, } from "../components/payroll.js"; -import { - VersionHeader, - VersionHeader$inboundSchema, - VersionHeader$outboundSchema, -} from "../components/versionheader.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export const GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion = { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", +} as const; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export type GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion = + ClosedEnum< + typeof GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + >; + export const GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude = { Benefits: "benefits", Deductions: "deductions", Taxes: "taxes", PayrollStatusMeta: "payroll_status_meta", + Totals: "totals", + RiskBlockers: "risk_blockers", + Reversals: "reversals", } as const; export type GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude = ClosedEnum; @@ -44,26 +56,56 @@ export type GetV1CompaniesCompanyIdPayrollsPayrollIdRequest = { * The UUID of the payroll */ payrollId: string; + /** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + | undefined; /** * Include the requested attribute in the response, for multiple attributes comma separate the values, i.e. `?include=benefits,deductions,taxes` */ include?: | Array | undefined; - /** - * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. - */ - xGustoAPIVersion?: VersionHeader | undefined; }; export type GetV1CompaniesCompanyIdPayrollsPayrollIdResponse = { httpMeta: HTTPMetadata; /** - * Example response + * successful */ payroll?: Payroll | undefined; }; +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum< + typeof GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + > = z.nativeEnum( + GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion, + ); + +/** @internal */ +export const GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum< + typeof GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + > = + GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$ { + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$inboundSchema` instead. */ + export const inboundSchema = + GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$outboundSchema` instead. */ + export const outboundSchema = + GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$outboundSchema; +} + /** @internal */ export const GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude$inboundSchema: z.ZodNativeEnum< @@ -98,10 +140,12 @@ export const GetV1CompaniesCompanyIdPayrollsPayrollIdRequest$inboundSchema: > = z.object({ company_id: z.string(), payroll_id: z.string(), + "X-Gusto-API-Version": + GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$inboundSchema + .default("2024-04-01"), include: z.array( GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude$inboundSchema, ).optional(), - "X-Gusto-API-Version": VersionHeader$inboundSchema.default("2024-04-01"), }).transform((v) => { return remap$(v, { "company_id": "companyId", @@ -114,8 +158,8 @@ export const GetV1CompaniesCompanyIdPayrollsPayrollIdRequest$inboundSchema: export type GetV1CompaniesCompanyIdPayrollsPayrollIdRequest$Outbound = { company_id: string; payroll_id: string; - include?: Array | undefined; "X-Gusto-API-Version": string; + include?: Array | undefined; }; /** @internal */ @@ -127,10 +171,12 @@ export const GetV1CompaniesCompanyIdPayrollsPayrollIdRequest$outboundSchema: > = z.object({ companyId: z.string(), payrollId: z.string(), + xGustoAPIVersion: + GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion$outboundSchema + .default("2024-04-01"), include: z.array( GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude$outboundSchema, ).optional(), - xGustoAPIVersion: VersionHeader$outboundSchema.default("2024-04-01"), }).transform((v) => { return remap$(v, { companyId: "company_id", diff --git a/gusto_embedded/src/models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.ts b/gusto_embedded/src/models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.ts new file mode 100644 index 00000000..15fe68af --- /dev/null +++ b/gusto_embedded/src/models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.ts @@ -0,0 +1,256 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { + ContractorPaymentGroupPartnerDisbursements, + ContractorPaymentGroupPartnerDisbursements$inboundSchema, + ContractorPaymentGroupPartnerDisbursements$Outbound, + ContractorPaymentGroupPartnerDisbursements$outboundSchema, +} from "../components/contractorpaymentgrouppartnerdisbursements.js"; +import { + HTTPMetadata, + HTTPMetadata$inboundSchema, + HTTPMetadata$Outbound, + HTTPMetadata$outboundSchema, +} from "../components/httpmetadata.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export const GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion = + { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", + } as const; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export type GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion = + ClosedEnum< + typeof GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + >; + +export type GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest = { + /** + * The UUID of the contractor payment group + */ + id: string; + /** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ + xGustoAPIVersion?: + | GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; +}; + +export type GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse = { + httpMeta: HTTPMetadata; + /** + * successful + */ + contractorPaymentGroupPartnerDisbursements?: + | ContractorPaymentGroupPartnerDisbursements + | undefined; +}; + +/** @internal */ +export const GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum< + typeof GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = z.nativeEnum( + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion, + ); + +/** @internal */ +export const GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum< + typeof GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$ { + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema` instead. */ + export const inboundSchema = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema` instead. */ + export const outboundSchema = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema; +} + +/** @internal */ +export const GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema: + z.ZodType< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + z.ZodTypeDef, + unknown + > = z.object({ + id: z.string(), + "X-Gusto-API-Version": + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema + .default("2024-04-01"), + }).transform((v) => { + return remap$(v, { + "X-Gusto-API-Version": "xGustoAPIVersion", + }); + }); + +/** @internal */ +export type GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound = + { + id: string; + "X-Gusto-API-Version": string; + }; + +/** @internal */ +export const GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema: + z.ZodType< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound, + z.ZodTypeDef, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest + > = z.object({ + id: z.string(), + xGustoAPIVersion: + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema + .default("2024-04-01"), + }).transform((v) => { + return remap$(v, { + xGustoAPIVersion: "X-Gusto-API-Version", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$ { + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema` instead. */ + export const inboundSchema = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema; + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema` instead. */ + export const outboundSchema = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema; + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound` instead. */ + export type Outbound = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound; +} + +export function getV1ContractorPaymentGroupsIdPartnerDisbursementsRequestToJSON( + getV1ContractorPaymentGroupsIdPartnerDisbursementsRequest: + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, +): string { + return JSON.stringify( + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema + .parse(getV1ContractorPaymentGroupsIdPartnerDisbursementsRequest), + ); +} + +export function getV1ContractorPaymentGroupsIdPartnerDisbursementsRequestFromJSON( + jsonString: string, +): SafeParseResult< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest' from JSON`, + ); +} + +/** @internal */ +export const GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema: + z.ZodType< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + z.ZodTypeDef, + unknown + > = z.object({ + HttpMeta: HTTPMetadata$inboundSchema, + "Contractor-Payment-Group-Partner-Disbursements": + ContractorPaymentGroupPartnerDisbursements$inboundSchema.optional(), + }).transform((v) => { + return remap$(v, { + "HttpMeta": "httpMeta", + "Contractor-Payment-Group-Partner-Disbursements": + "contractorPaymentGroupPartnerDisbursements", + }); + }); + +/** @internal */ +export type GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound = + { + HttpMeta: HTTPMetadata$Outbound; + "Contractor-Payment-Group-Partner-Disbursements"?: + | ContractorPaymentGroupPartnerDisbursements$Outbound + | undefined; + }; + +/** @internal */ +export const GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema: + z.ZodType< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound, + z.ZodTypeDef, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse + > = z.object({ + httpMeta: HTTPMetadata$outboundSchema, + contractorPaymentGroupPartnerDisbursements: + ContractorPaymentGroupPartnerDisbursements$outboundSchema.optional(), + }).transform((v) => { + return remap$(v, { + httpMeta: "HttpMeta", + contractorPaymentGroupPartnerDisbursements: + "Contractor-Payment-Group-Partner-Disbursements", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$ { + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema` instead. */ + export const inboundSchema = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema; + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema` instead. */ + export const outboundSchema = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema; + /** @deprecated use `GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound` instead. */ + export type Outbound = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound; +} + +export function getV1ContractorPaymentGroupsIdPartnerDisbursementsResponseToJSON( + getV1ContractorPaymentGroupsIdPartnerDisbursementsResponse: + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, +): string { + return JSON.stringify( + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema + .parse(getV1ContractorPaymentGroupsIdPartnerDisbursementsResponse), + ); +} + +export function getV1ContractorPaymentGroupsIdPartnerDisbursementsResponseFromJSON( + jsonString: string, +): SafeParseResult< + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/operations/getv1employeesemployeeidstatetaxes.ts b/gusto_embedded/src/models/operations/getv1employeesemployeeidstatetaxes.ts index 4644e97f..c40c19c9 100644 --- a/gusto_embedded/src/models/operations/getv1employeesemployeeidstatetaxes.ts +++ b/gusto_embedded/src/models/operations/getv1employeesemployeeidstatetaxes.ts @@ -22,20 +22,20 @@ import { import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** - * Determines the date-based API version associated with your API call. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ export const GetV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion = { TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", } as const; /** - * Determines the date-based API version associated with your API call. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ export type GetV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion = ClosedEnum; export type GetV1EmployeesEmployeeIdStateTaxesRequest = { /** - * Determines the date-based API version associated with your API call. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ xGustoAPIVersion?: | GetV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion diff --git a/gusto_embedded/src/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.ts b/gusto_embedded/src/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.ts new file mode 100644 index 00000000..a78a09e7 --- /dev/null +++ b/gusto_embedded/src/models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.ts @@ -0,0 +1,566 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { + HTTPMetadata, + HTTPMetadata$inboundSchema, + HTTPMetadata$Outbound, + HTTPMetadata$outboundSchema, +} from "../components/httpmetadata.js"; +import { + PayrollPartnerDisbursements, + PayrollPartnerDisbursements$inboundSchema, + PayrollPartnerDisbursements$Outbound, + PayrollPartnerDisbursements$outboundSchema, +} from "../components/payrollpartnerdisbursements.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion = + { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", + } as const; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion = + ClosedEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + >; + +/** + * Payment method for the employee + */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod = + { + DirectDeposit: "Direct Deposit", + Check: "Check", + } as const; +/** + * Payment method for the employee + */ +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod = + ClosedEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod + >; + +/** + * Status of the payment disbursement + */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus = + { + Pending: "Pending", + Paid: "Paid", + NotPartnerManaged: "Not partner managed", + ConvertedToCheck: "Converted to check", + } as const; +/** + * Status of the payment disbursement + */ +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus = + ClosedEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus + >; + +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements = + { + /** + * UUID of the employee + */ + employeeUuid: string; + /** + * Payment method for the employee + */ + paymentMethod?: + | PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod + | undefined; + /** + * Status of the payment disbursement + */ + paymentStatus?: + | PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus + | undefined; + }; + +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody = + { + disbursements: Array< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements + >; + }; + +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest = { + /** + * The UUID of the company + */ + companyId: string; + /** + * The UUID of the payroll + */ + id: string; + /** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ + xGustoAPIVersion?: + | PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + requestBody?: + | PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody + | undefined; +}; + +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse = { + httpMeta: HTTPMetadata; + /** + * successful + */ + payrollPartnerDisbursements?: PayrollPartnerDisbursements | undefined; +}; + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = z.nativeEnum( + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion, + ); + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$ { + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema` instead. */ + export const inboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema` instead. */ + export const outboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema; +} + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$inboundSchema: + z.ZodNativeEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod + > = z.nativeEnum( + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod, + ); + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$outboundSchema: + z.ZodNativeEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod + > = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$ { + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$inboundSchema` instead. */ + export const inboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$inboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$outboundSchema` instead. */ + export const outboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$outboundSchema; +} + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$inboundSchema: + z.ZodNativeEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus + > = z.nativeEnum( + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus, + ); + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$outboundSchema: + z.ZodNativeEnum< + typeof PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus + > = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$ { + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$inboundSchema` instead. */ + export const inboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$inboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$outboundSchema` instead. */ + export const outboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$outboundSchema; +} + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$inboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements, + z.ZodTypeDef, + unknown + > = z.object({ + employee_uuid: z.string(), + payment_method: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$inboundSchema + .optional(), + payment_status: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$inboundSchema + .optional(), + }).transform((v) => { + return remap$(v, { + "employee_uuid": "employeeUuid", + "payment_method": "paymentMethod", + "payment_status": "paymentStatus", + }); + }); + +/** @internal */ +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$Outbound = + { + employee_uuid: string; + payment_method?: string | undefined; + payment_status?: string | undefined; + }; + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$outboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$Outbound, + z.ZodTypeDef, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements + > = z.object({ + employeeUuid: z.string(), + paymentMethod: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentMethod$outboundSchema + .optional(), + paymentStatus: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsPaymentStatus$outboundSchema + .optional(), + }).transform((v) => { + return remap$(v, { + employeeUuid: "employee_uuid", + paymentMethod: "payment_method", + paymentStatus: "payment_status", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$ { + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$inboundSchema` instead. */ + export const inboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$inboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$outboundSchema` instead. */ + export const outboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$outboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$Outbound` instead. */ + export type Outbound = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$Outbound; +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursementsToJSON( + patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements, +): string { + return JSON.stringify( + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$outboundSchema + .parse( + patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements, + ), + ); +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursementsFromJSON( + jsonString: string, +): SafeParseResult< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements' from JSON`, + ); +} + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$inboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody, + z.ZodTypeDef, + unknown + > = z.object({ + disbursements: z.array( + z.lazy(() => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$inboundSchema + ), + ), + }); + +/** @internal */ +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$Outbound = + { + disbursements: Array< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$Outbound + >; + }; + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$outboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$Outbound, + z.ZodTypeDef, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody + > = z.object({ + disbursements: z.array( + z.lazy(() => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsDisbursements$outboundSchema + ), + ), + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$ { + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$inboundSchema` instead. */ + export const inboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$inboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$outboundSchema` instead. */ + export const outboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$outboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$Outbound` instead. */ + export type Outbound = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$Outbound; +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBodyToJSON( + patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody, +): string { + return JSON.stringify( + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$outboundSchema + .parse( + patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody, + ), + ); +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBodyFromJSON( + jsonString: string, +): SafeParseResult< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody' from JSON`, + ); +} + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + z.ZodTypeDef, + unknown + > = z.object({ + company_id: z.string(), + id: z.string(), + "X-Gusto-API-Version": + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema + .default("2024-04-01"), + RequestBody: z.lazy(() => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$inboundSchema + ).optional(), + }).transform((v) => { + return remap$(v, { + "company_id": "companyId", + "X-Gusto-API-Version": "xGustoAPIVersion", + "RequestBody": "requestBody", + }); + }); + +/** @internal */ +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound = + { + company_id: string; + id: string; + "X-Gusto-API-Version": string; + RequestBody?: + | PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$Outbound + | undefined; + }; + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound, + z.ZodTypeDef, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest + > = z.object({ + companyId: z.string(), + id: z.string(), + xGustoAPIVersion: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema + .default("2024-04-01"), + requestBody: z.lazy(() => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestBody$outboundSchema + ).optional(), + }).transform((v) => { + return remap$(v, { + companyId: "company_id", + xGustoAPIVersion: "X-Gusto-API-Version", + requestBody: "RequestBody", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$ { + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema` instead. */ + export const inboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema` instead. */ + export const outboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound` instead. */ + export type Outbound = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$Outbound; +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestToJSON( + patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, +): string { + return JSON.stringify( + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$outboundSchema + .parse(patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest), + ); +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequestFromJSON( + jsonString: string, +): SafeParseResult< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest' from JSON`, + ); +} + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + z.ZodTypeDef, + unknown + > = z.object({ + HttpMeta: HTTPMetadata$inboundSchema, + "Payroll-Partner-Disbursements": PayrollPartnerDisbursements$inboundSchema + .optional(), + }).transform((v) => { + return remap$(v, { + "HttpMeta": "httpMeta", + "Payroll-Partner-Disbursements": "payrollPartnerDisbursements", + }); + }); + +/** @internal */ +export type PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound = + { + HttpMeta: HTTPMetadata$Outbound; + "Payroll-Partner-Disbursements"?: + | PayrollPartnerDisbursements$Outbound + | undefined; + }; + +/** @internal */ +export const PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema: + z.ZodType< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound, + z.ZodTypeDef, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse + > = z.object({ + httpMeta: HTTPMetadata$outboundSchema, + payrollPartnerDisbursements: PayrollPartnerDisbursements$outboundSchema + .optional(), + }).transform((v) => { + return remap$(v, { + httpMeta: "HttpMeta", + payrollPartnerDisbursements: "Payroll-Partner-Disbursements", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$ { + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema` instead. */ + export const inboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema` instead. */ + export const outboundSchema = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema; + /** @deprecated use `PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound` instead. */ + export type Outbound = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$Outbound; +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponseToJSON( + patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse: + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, +): string { + return JSON.stringify( + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$outboundSchema + .parse(patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse), + ); +} + +export function patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponseFromJSON( + jsonString: string, +): SafeParseResult< + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.ts b/gusto_embedded/src/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.ts new file mode 100644 index 00000000..7a22bad4 --- /dev/null +++ b/gusto_embedded/src/models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.ts @@ -0,0 +1,509 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { + ContractorPaymentGroupPartnerDisbursements, + ContractorPaymentGroupPartnerDisbursements$inboundSchema, + ContractorPaymentGroupPartnerDisbursements$Outbound, + ContractorPaymentGroupPartnerDisbursements$outboundSchema, +} from "../components/contractorpaymentgrouppartnerdisbursements.js"; +import { + HTTPMetadata, + HTTPMetadata$inboundSchema, + HTTPMetadata$Outbound, + HTTPMetadata$outboundSchema, +} from "../components/httpmetadata.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion = + { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", + } as const; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion = + ClosedEnum< + typeof PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + >; + +/** + * Payment method for the contractor + */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod = + { + DirectDeposit: "Direct Deposit", + Check: "Check", + } as const; +/** + * Payment method for the contractor + */ +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod = + ClosedEnum< + typeof PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod + >; + +/** + * Status of the payment disbursement + */ +export const PaymentStatus = { + Pending: "Pending", + Paid: "Paid", + NotPartnerManaged: "Not partner managed", + ConvertedToCheck: "Converted to check", +} as const; +/** + * Status of the payment disbursement + */ +export type PaymentStatus = ClosedEnum; + +export type Disbursements = { + /** + * UUID of the contractor payment + */ + contractorPaymentUuid: string; + /** + * Payment method for the contractor + */ + paymentMethod?: + | PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod + | undefined; + /** + * Status of the payment disbursement + */ + paymentStatus?: PaymentStatus | undefined; +}; + +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody = { + disbursements: Array; +}; + +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest = { + /** + * The UUID of the contractor payment group + */ + id: string; + /** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ + xGustoAPIVersion?: + | PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + requestBody?: + | PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody + | undefined; +}; + +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse = { + httpMeta: HTTPMetadata; + /** + * successful + */ + contractorPaymentGroupPartnerDisbursements?: + | ContractorPaymentGroupPartnerDisbursements + | undefined; +}; + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum< + typeof PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = z.nativeEnum( + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion, + ); + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum< + typeof PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + > = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$ { + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema` instead. */ + export const inboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema` instead. */ + export const outboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema; +} + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$inboundSchema: + z.ZodNativeEnum< + typeof PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod + > = z.nativeEnum( + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod, + ); + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$outboundSchema: + z.ZodNativeEnum< + typeof PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod + > = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$ { + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$inboundSchema` instead. */ + export const inboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$inboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$outboundSchema` instead. */ + export const outboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$outboundSchema; +} + +/** @internal */ +export const PaymentStatus$inboundSchema: z.ZodNativeEnum< + typeof PaymentStatus +> = z.nativeEnum(PaymentStatus); + +/** @internal */ +export const PaymentStatus$outboundSchema: z.ZodNativeEnum< + typeof PaymentStatus +> = PaymentStatus$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PaymentStatus$ { + /** @deprecated use `PaymentStatus$inboundSchema` instead. */ + export const inboundSchema = PaymentStatus$inboundSchema; + /** @deprecated use `PaymentStatus$outboundSchema` instead. */ + export const outboundSchema = PaymentStatus$outboundSchema; +} + +/** @internal */ +export const Disbursements$inboundSchema: z.ZodType< + Disbursements, + z.ZodTypeDef, + unknown +> = z.object({ + contractor_payment_uuid: z.string(), + payment_method: + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$inboundSchema + .optional(), + payment_status: PaymentStatus$inboundSchema.optional(), +}).transform((v) => { + return remap$(v, { + "contractor_payment_uuid": "contractorPaymentUuid", + "payment_method": "paymentMethod", + "payment_status": "paymentStatus", + }); +}); + +/** @internal */ +export type Disbursements$Outbound = { + contractor_payment_uuid: string; + payment_method?: string | undefined; + payment_status?: string | undefined; +}; + +/** @internal */ +export const Disbursements$outboundSchema: z.ZodType< + Disbursements$Outbound, + z.ZodTypeDef, + Disbursements +> = z.object({ + contractorPaymentUuid: z.string(), + paymentMethod: + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsPaymentMethod$outboundSchema + .optional(), + paymentStatus: PaymentStatus$outboundSchema.optional(), +}).transform((v) => { + return remap$(v, { + contractorPaymentUuid: "contractor_payment_uuid", + paymentMethod: "payment_method", + paymentStatus: "payment_status", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Disbursements$ { + /** @deprecated use `Disbursements$inboundSchema` instead. */ + export const inboundSchema = Disbursements$inboundSchema; + /** @deprecated use `Disbursements$outboundSchema` instead. */ + export const outboundSchema = Disbursements$outboundSchema; + /** @deprecated use `Disbursements$Outbound` instead. */ + export type Outbound = Disbursements$Outbound; +} + +export function disbursementsToJSON(disbursements: Disbursements): string { + return JSON.stringify(Disbursements$outboundSchema.parse(disbursements)); +} + +export function disbursementsFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Disbursements$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Disbursements' from JSON`, + ); +} + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$inboundSchema: + z.ZodType< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody, + z.ZodTypeDef, + unknown + > = z.object({ + disbursements: z.array(z.lazy(() => Disbursements$inboundSchema)), + }); + +/** @internal */ +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$Outbound = + { + disbursements: Array; + }; + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$outboundSchema: + z.ZodType< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$Outbound, + z.ZodTypeDef, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody + > = z.object({ + disbursements: z.array(z.lazy(() => Disbursements$outboundSchema)), + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$ { + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$inboundSchema` instead. */ + export const inboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$inboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$outboundSchema` instead. */ + export const outboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$outboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$Outbound` instead. */ + export type Outbound = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$Outbound; +} + +export function patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBodyToJSON( + patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody: + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody, +): string { + return JSON.stringify( + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$outboundSchema + .parse(patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody), + ); +} + +export function patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBodyFromJSON( + jsonString: string, +): SafeParseResult< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody' from JSON`, + ); +} + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema: + z.ZodType< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + z.ZodTypeDef, + unknown + > = z.object({ + id: z.string(), + "X-Gusto-API-Version": + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$inboundSchema + .default("2024-04-01"), + RequestBody: z.lazy(() => + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$inboundSchema + ).optional(), + }).transform((v) => { + return remap$(v, { + "X-Gusto-API-Version": "xGustoAPIVersion", + "RequestBody": "requestBody", + }); + }); + +/** @internal */ +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound = + { + id: string; + "X-Gusto-API-Version": string; + RequestBody?: + | PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$Outbound + | undefined; + }; + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema: + z.ZodType< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound, + z.ZodTypeDef, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest + > = z.object({ + id: z.string(), + xGustoAPIVersion: + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion$outboundSchema + .default("2024-04-01"), + requestBody: z.lazy(() => + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestBody$outboundSchema + ).optional(), + }).transform((v) => { + return remap$(v, { + xGustoAPIVersion: "X-Gusto-API-Version", + requestBody: "RequestBody", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$ { + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema` instead. */ + export const inboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema` instead. */ + export const outboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound` instead. */ + export type Outbound = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$Outbound; +} + +export function patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestToJSON( + patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest: + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, +): string { + return JSON.stringify( + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$outboundSchema + .parse(patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest), + ); +} + +export function patchV1ContractorPaymentGroupsIdPartnerDisbursementsRequestFromJSON( + jsonString: string, +): SafeParseResult< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest' from JSON`, + ); +} + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema: + z.ZodType< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + z.ZodTypeDef, + unknown + > = z.object({ + HttpMeta: HTTPMetadata$inboundSchema, + "Contractor-Payment-Group-Partner-Disbursements": + ContractorPaymentGroupPartnerDisbursements$inboundSchema.optional(), + }).transform((v) => { + return remap$(v, { + "HttpMeta": "httpMeta", + "Contractor-Payment-Group-Partner-Disbursements": + "contractorPaymentGroupPartnerDisbursements", + }); + }); + +/** @internal */ +export type PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound = + { + HttpMeta: HTTPMetadata$Outbound; + "Contractor-Payment-Group-Partner-Disbursements"?: + | ContractorPaymentGroupPartnerDisbursements$Outbound + | undefined; + }; + +/** @internal */ +export const PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema: + z.ZodType< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound, + z.ZodTypeDef, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse + > = z.object({ + httpMeta: HTTPMetadata$outboundSchema, + contractorPaymentGroupPartnerDisbursements: + ContractorPaymentGroupPartnerDisbursements$outboundSchema.optional(), + }).transform((v) => { + return remap$(v, { + httpMeta: "HttpMeta", + contractorPaymentGroupPartnerDisbursements: + "Contractor-Payment-Group-Partner-Disbursements", + }); + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$ { + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema` instead. */ + export const inboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema` instead. */ + export const outboundSchema = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema; + /** @deprecated use `PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound` instead. */ + export type Outbound = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$Outbound; +} + +export function patchV1ContractorPaymentGroupsIdPartnerDisbursementsResponseToJSON( + patchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse: + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, +): string { + return JSON.stringify( + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$outboundSchema + .parse(patchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse), + ); +} + +export function patchV1ContractorPaymentGroupsIdPartnerDisbursementsResponseFromJSON( + jsonString: string, +): SafeParseResult< + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, + SDKValidationError +> { + return safeParse( + jsonString, + (x) => + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse$inboundSchema + .parse(JSON.parse(x)), + `Failed to parse 'PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse' from JSON`, + ); +} diff --git a/gusto_embedded/src/models/operations/postpayrollspayrolluuidreportsgeneralledger.ts b/gusto_embedded/src/models/operations/postpayrollspayrolluuidreportsgeneralledger.ts index 7ef35fbd..e8727fd7 100644 --- a/gusto_embedded/src/models/operations/postpayrollspayrolluuidreportsgeneralledger.ts +++ b/gusto_embedded/src/models/operations/postpayrollspayrolluuidreportsgeneralledger.ts @@ -33,17 +33,34 @@ export const Aggregation = { Default: "default", Job: "job", Department: "department", + Integration: "integration", } as const; /** * The breakdown of the report. Use 'default' for no split. */ export type Aggregation = ClosedEnum; +/** + * The kind of integration set up for the company. Required when `aggregation` is 'integration'. Must be null if `aggregation` is not 'integration'. + */ +export const IntegrationType = { + Xero: "xero", + Qbo: "qbo", +} as const; +/** + * The kind of integration set up for the company. Required when `aggregation` is 'integration'. Must be null if `aggregation` is not 'integration'. + */ +export type IntegrationType = ClosedEnum; + export type PostPayrollsPayrollUuidReportsGeneralLedgerRequestBody = { /** * The breakdown of the report. Use 'default' for no split. */ aggregation: Aggregation; + /** + * The kind of integration set up for the company. Required when `aggregation` is 'integration'. Must be null if `aggregation` is not 'integration'. + */ + integrationType?: IntegrationType | null | undefined; }; export type PostPayrollsPayrollUuidReportsGeneralLedgerRequest = { @@ -85,6 +102,27 @@ export namespace Aggregation$ { export const outboundSchema = Aggregation$outboundSchema; } +/** @internal */ +export const IntegrationType$inboundSchema: z.ZodNativeEnum< + typeof IntegrationType +> = z.nativeEnum(IntegrationType); + +/** @internal */ +export const IntegrationType$outboundSchema: z.ZodNativeEnum< + typeof IntegrationType +> = IntegrationType$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace IntegrationType$ { + /** @deprecated use `IntegrationType$inboundSchema` instead. */ + export const inboundSchema = IntegrationType$inboundSchema; + /** @deprecated use `IntegrationType$outboundSchema` instead. */ + export const outboundSchema = IntegrationType$outboundSchema; +} + /** @internal */ export const PostPayrollsPayrollUuidReportsGeneralLedgerRequestBody$inboundSchema: z.ZodType< @@ -93,11 +131,17 @@ export const PostPayrollsPayrollUuidReportsGeneralLedgerRequestBody$inboundSchem unknown > = z.object({ aggregation: Aggregation$inboundSchema, + integration_type: z.nullable(IntegrationType$inboundSchema).optional(), + }).transform((v) => { + return remap$(v, { + "integration_type": "integrationType", + }); }); /** @internal */ export type PostPayrollsPayrollUuidReportsGeneralLedgerRequestBody$Outbound = { aggregation: string; + integration_type?: string | null | undefined; }; /** @internal */ @@ -108,6 +152,11 @@ export const PostPayrollsPayrollUuidReportsGeneralLedgerRequestBody$outboundSche PostPayrollsPayrollUuidReportsGeneralLedgerRequestBody > = z.object({ aggregation: Aggregation$outboundSchema, + integrationType: z.nullable(IntegrationType$outboundSchema).optional(), + }).transform((v) => { + return remap$(v, { + integrationType: "integration_type", + }); }); /** diff --git a/gusto_embedded/src/models/operations/postv1companiescompanyidcontractorpayments.ts b/gusto_embedded/src/models/operations/postv1companiescompanyidcontractorpayments.ts index ad1dc7c4..9f01463a 100644 --- a/gusto_embedded/src/models/operations/postv1companiescompanyidcontractorpayments.ts +++ b/gusto_embedded/src/models/operations/postv1companiescompanyidcontractorpayments.ts @@ -27,13 +27,12 @@ import { } from "../components/versionheader.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; -export const PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod = { +export const PaymentMethod = { DirectDeposit: "Direct Deposit", Check: "Check", HistoricalPayment: "Historical Payment", } as const; -export type PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod = - ClosedEnum; +export type PaymentMethod = ClosedEnum; export type PostV1CompaniesCompanyIdContractorPaymentsRequestBody = { /** @@ -44,9 +43,7 @@ export type PostV1CompaniesCompanyIdContractorPaymentsRequestBody = { * Date of contractor payment */ date: RFCDate; - paymentMethod?: - | PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod - | undefined; + paymentMethod?: PaymentMethod | undefined; /** * If the contractor is on a fixed wage, this is the fixed wage payment for the contractor, regardless of hours worked */ @@ -86,28 +83,24 @@ export type PostV1CompaniesCompanyIdContractorPaymentsResponse = { }; /** @internal */ -export const PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$inboundSchema: - z.ZodNativeEnum< - typeof PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod - > = z.nativeEnum(PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod); +export const PaymentMethod$inboundSchema: z.ZodNativeEnum< + typeof PaymentMethod +> = z.nativeEnum(PaymentMethod); /** @internal */ -export const PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$outboundSchema: - z.ZodNativeEnum< - typeof PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod - > = PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$inboundSchema; +export const PaymentMethod$outboundSchema: z.ZodNativeEnum< + typeof PaymentMethod +> = PaymentMethod$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$ { - /** @deprecated use `PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$inboundSchema` instead. */ - export const inboundSchema = - PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$inboundSchema; - /** @deprecated use `PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$outboundSchema` instead. */ - export const outboundSchema = - PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$outboundSchema; +export namespace PaymentMethod$ { + /** @deprecated use `PaymentMethod$inboundSchema` instead. */ + export const inboundSchema = PaymentMethod$inboundSchema; + /** @deprecated use `PaymentMethod$outboundSchema` instead. */ + export const outboundSchema = PaymentMethod$outboundSchema; } /** @internal */ @@ -119,9 +112,7 @@ export const PostV1CompaniesCompanyIdContractorPaymentsRequestBody$inboundSchema > = z.object({ contractor_uuid: z.string(), date: z.string().transform(v => new RFCDate(v)), - payment_method: - PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$inboundSchema - .default("Direct Deposit"), + payment_method: PaymentMethod$inboundSchema.default("Direct Deposit"), wage: z.number().optional(), hours: z.number().optional(), bonus: z.number().optional(), @@ -153,9 +144,7 @@ export const PostV1CompaniesCompanyIdContractorPaymentsRequestBody$outboundSchem > = z.object({ contractorUuid: z.string(), date: z.instanceof(RFCDate).transform(v => v.toString()), - paymentMethod: - PostV1CompaniesCompanyIdContractorPaymentsPaymentMethod$outboundSchema - .default("Direct Deposit"), + paymentMethod: PaymentMethod$outboundSchema.default("Direct Deposit"), wage: z.number().optional(), hours: z.number().optional(), bonus: z.number().optional(), diff --git a/gusto_embedded/src/models/operations/postv1companiescompanyidpayrolls.ts b/gusto_embedded/src/models/operations/postv1companiescompanyidpayrolls.ts index d88ce067..ac77bd84 100644 --- a/gusto_embedded/src/models/operations/postv1companiescompanyidpayrolls.ts +++ b/gusto_embedded/src/models/operations/postv1companiescompanyidpayrolls.ts @@ -111,16 +111,16 @@ export type PostV1CompaniesCompanyIdPayrollsRequestBody = { }; export type PostV1CompaniesCompanyIdPayrollsRequest = { - /** - * The UUID of the company - */ - companyId: string; /** * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ xGustoAPIVersion?: | PostV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion | undefined; + /** + * The UUID of the company + */ + companyId: string; requestBody?: PostV1CompaniesCompanyIdPayrollsRequestBody | undefined; }; @@ -325,25 +325,25 @@ export const PostV1CompaniesCompanyIdPayrollsRequest$inboundSchema: z.ZodType< z.ZodTypeDef, unknown > = z.object({ - company_id: z.string(), "X-Gusto-API-Version": PostV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema .default("2024-04-01"), + company_id: z.string(), RequestBody: z.lazy(() => PostV1CompaniesCompanyIdPayrollsRequestBody$inboundSchema ).optional(), }).transform((v) => { return remap$(v, { - "company_id": "companyId", "X-Gusto-API-Version": "xGustoAPIVersion", + "company_id": "companyId", "RequestBody": "requestBody", }); }); /** @internal */ export type PostV1CompaniesCompanyIdPayrollsRequest$Outbound = { - company_id: string; "X-Gusto-API-Version": string; + company_id: string; RequestBody?: | PostV1CompaniesCompanyIdPayrollsRequestBody$Outbound | undefined; @@ -355,17 +355,17 @@ export const PostV1CompaniesCompanyIdPayrollsRequest$outboundSchema: z.ZodType< z.ZodTypeDef, PostV1CompaniesCompanyIdPayrollsRequest > = z.object({ - companyId: z.string(), xGustoAPIVersion: PostV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema .default("2024-04-01"), + companyId: z.string(), requestBody: z.lazy(() => PostV1CompaniesCompanyIdPayrollsRequestBody$outboundSchema ).optional(), }).transform((v) => { return remap$(v, { - companyId: "company_id", xGustoAPIVersion: "X-Gusto-API-Version", + companyId: "company_id", requestBody: "RequestBody", }); }); diff --git a/gusto_embedded/src/models/operations/postv1employeesemployeeidemployeebenefits.ts b/gusto_embedded/src/models/operations/postv1employeesemployeeidemployeebenefits.ts index 7a6481c1..4d84f32e 100644 --- a/gusto_embedded/src/models/operations/postv1employeesemployeeidemployeebenefits.ts +++ b/gusto_embedded/src/models/operations/postv1employeesemployeeidemployeebenefits.ts @@ -66,13 +66,17 @@ export type Two = { */ rate?: string | undefined; /** - * The percentage threshold at which this tier ends (inclusive). + * Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to. * * @remarks * - * For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll. + * Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards. * - * If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. + * For example: + * + * If the first tier has a threshold of "3", and rate of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll. + * + * If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. */ threshold?: string | undefined; }; diff --git a/gusto_embedded/src/models/operations/putv1companiescompanyidpayrolls.ts b/gusto_embedded/src/models/operations/putv1companiescompanyidpayrolls.ts index 68b91385..f3bcace4 100644 --- a/gusto_embedded/src/models/operations/putv1companiescompanyidpayrolls.ts +++ b/gusto_embedded/src/models/operations/putv1companiescompanyidpayrolls.ts @@ -20,146 +20,33 @@ import { PayrollPrepared$outboundSchema, } from "../components/payrollprepared.js"; import { - VersionHeader, - VersionHeader$inboundSchema, - VersionHeader$outboundSchema, -} from "../components/versionheader.js"; + PayrollUpdate, + PayrollUpdate$inboundSchema, + PayrollUpdate$Outbound, + PayrollUpdate$outboundSchema, +} from "../components/payrollupdate.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** - * The employee's compensation payment method. Invalid values will be ignored. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ -export const PaymentMethod = { - DirectDeposit: "Direct Deposit", - Check: "Check", +export const PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion = { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", } as const; /** - * The employee's compensation payment method. Invalid values will be ignored. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ -export type PaymentMethod = ClosedEnum; - -/** - * An array of fixed compensations for the employee. Fixed compensations include tips, bonuses, and one time reimbursements. - */ -export type FixedCompensations = { - /** - * The name of the compensation. This also serves as the unique, immutable identifier for this compensation. - */ - name?: string | undefined; - /** - * The amount of the compensation for the pay period. - */ - amount?: string | undefined; - /** - * The UUID of the job for the compensation. - */ - jobUuid?: string | undefined; -}; - -/** - * An array of hourly compensations for the employee. Hourly compensations include regular, overtime, and double overtime hours. - */ -export type HourlyCompensations = { - /** - * The name of the compensation. This also serves as the unique, immutable identifier for this compensation. - */ - name?: string | undefined; - /** - * The number of hours to be compensated for this pay period. - */ - hours?: string | undefined; - /** - * The UUIDs of the job for the compensation. - */ - jobUuid?: string | undefined; -}; - -export type PaidTimeOff = { - /** - * The name of the PTO. This also serves as the unique, immutable identifier for the PTO. Must pass in name or policy_uuid but not both. - */ - name?: string | undefined; - /** - * The hours of this PTO taken during the pay period. - */ - hours?: string | undefined; - /** - * The uuid of the PTO policy. Must pass in name or policy_uuid but not both. - */ - policyUuid?: string | undefined; - /** - * The outstanding hours paid upon termination. This field is only applicable for termination payrolls. - */ - finalPayoutUnusedHoursInput?: string | undefined; -}; - -export type EmployeeCompensations = { - /** - * The UUID of the employee. - */ - employeeUuid?: string | undefined; - /** - * The current version of this employee compensation from the prepared payroll. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. - */ - version?: string | undefined; - /** - * This employee will be excluded from payroll calculation and will not be paid for the payroll. - */ - excluded?: boolean | undefined; - /** - * The employee's compensation payment method. Invalid values will be ignored. - */ - paymentMethod?: PaymentMethod | undefined; - /** - * Custom text that will be printed as a personal note to the employee on a paystub. - */ - memo?: string | undefined; - fixedCompensations?: Array | undefined; - hourlyCompensations?: Array | undefined; - /** - * An array of all paid time off the employee is eligible for this pay period. Each paid time off object can be the name or the specific policy_uuid. - */ - paidTimeOff?: Array | undefined; -}; - -/** - * The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. - */ -export const PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod = { - EveryWeek: "Every week", - EveryOtherWeek: "Every other week", - TwicePerMonth: "Twice per month", - Monthly: "Monthly", - Quarterly: "Quarterly", - Semiannually: "Semiannually", - Annually: "Annually", -} as const; -/** - * The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. - */ -export type PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod = ClosedEnum< - typeof PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod +export type PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion = ClosedEnum< + typeof PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion >; -export type PutV1CompaniesCompanyIdPayrollsRequestBody = { - employeeCompensations: Array; +export type PutV1CompaniesCompanyIdPayrollsRequest = { /** - * The payment schedule tax rate the payroll is based on. Only relevant for off-cycle payrolls. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ - withholdingPayPeriod?: - | PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod + xGustoAPIVersion?: + | PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion | undefined; - /** - * Block regular deductions and contributions for this payroll. Only relevant for off-cycle payrolls. - */ - skipRegularDeductions?: boolean | undefined; - /** - * Enable taxes to be withheld at the IRS's required rate of 22% for federal income taxes. State income taxes will be taxed at the state's supplemental tax rate. Otherwise, we'll sum the entirety of the employee's wages and withhold taxes on the entire amount at the rate for regular wages. Only relevant for off-cycle payrolls. - */ - fixedWithholdingRate?: boolean | undefined; -}; - -export type PutV1CompaniesCompanyIdPayrollsRequest = { /** * The UUID of the company */ @@ -168,458 +55,40 @@ export type PutV1CompaniesCompanyIdPayrollsRequest = { * The UUID of the payroll */ payrollId: string; - /** - * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. - */ - xGustoAPIVersion?: VersionHeader | undefined; - requestBody: PutV1CompaniesCompanyIdPayrollsRequestBody; + payrollUpdate: PayrollUpdate; }; export type PutV1CompaniesCompanyIdPayrollsResponse = { httpMeta: HTTPMetadata; /** - * A prepared payroll + * successful */ payrollPrepared?: PayrollPrepared | undefined; }; /** @internal */ -export const PaymentMethod$inboundSchema: z.ZodNativeEnum< - typeof PaymentMethod -> = z.nativeEnum(PaymentMethod); - -/** @internal */ -export const PaymentMethod$outboundSchema: z.ZodNativeEnum< - typeof PaymentMethod -> = PaymentMethod$inboundSchema; - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace PaymentMethod$ { - /** @deprecated use `PaymentMethod$inboundSchema` instead. */ - export const inboundSchema = PaymentMethod$inboundSchema; - /** @deprecated use `PaymentMethod$outboundSchema` instead. */ - export const outboundSchema = PaymentMethod$outboundSchema; -} - -/** @internal */ -export const FixedCompensations$inboundSchema: z.ZodType< - FixedCompensations, - z.ZodTypeDef, - unknown -> = z.object({ - name: z.string().optional(), - amount: z.string().optional(), - job_uuid: z.string().optional(), -}).transform((v) => { - return remap$(v, { - "job_uuid": "jobUuid", - }); -}); - -/** @internal */ -export type FixedCompensations$Outbound = { - name?: string | undefined; - amount?: string | undefined; - job_uuid?: string | undefined; -}; - -/** @internal */ -export const FixedCompensations$outboundSchema: z.ZodType< - FixedCompensations$Outbound, - z.ZodTypeDef, - FixedCompensations -> = z.object({ - name: z.string().optional(), - amount: z.string().optional(), - jobUuid: z.string().optional(), -}).transform((v) => { - return remap$(v, { - jobUuid: "job_uuid", - }); -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace FixedCompensations$ { - /** @deprecated use `FixedCompensations$inboundSchema` instead. */ - export const inboundSchema = FixedCompensations$inboundSchema; - /** @deprecated use `FixedCompensations$outboundSchema` instead. */ - export const outboundSchema = FixedCompensations$outboundSchema; - /** @deprecated use `FixedCompensations$Outbound` instead. */ - export type Outbound = FixedCompensations$Outbound; -} - -export function fixedCompensationsToJSON( - fixedCompensations: FixedCompensations, -): string { - return JSON.stringify( - FixedCompensations$outboundSchema.parse(fixedCompensations), - ); -} - -export function fixedCompensationsFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => FixedCompensations$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'FixedCompensations' from JSON`, - ); -} - -/** @internal */ -export const HourlyCompensations$inboundSchema: z.ZodType< - HourlyCompensations, - z.ZodTypeDef, - unknown -> = z.object({ - name: z.string().optional(), - hours: z.string().optional(), - job_uuid: z.string().optional(), -}).transform((v) => { - return remap$(v, { - "job_uuid": "jobUuid", - }); -}); - -/** @internal */ -export type HourlyCompensations$Outbound = { - name?: string | undefined; - hours?: string | undefined; - job_uuid?: string | undefined; -}; - -/** @internal */ -export const HourlyCompensations$outboundSchema: z.ZodType< - HourlyCompensations$Outbound, - z.ZodTypeDef, - HourlyCompensations -> = z.object({ - name: z.string().optional(), - hours: z.string().optional(), - jobUuid: z.string().optional(), -}).transform((v) => { - return remap$(v, { - jobUuid: "job_uuid", - }); -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace HourlyCompensations$ { - /** @deprecated use `HourlyCompensations$inboundSchema` instead. */ - export const inboundSchema = HourlyCompensations$inboundSchema; - /** @deprecated use `HourlyCompensations$outboundSchema` instead. */ - export const outboundSchema = HourlyCompensations$outboundSchema; - /** @deprecated use `HourlyCompensations$Outbound` instead. */ - export type Outbound = HourlyCompensations$Outbound; -} - -export function hourlyCompensationsToJSON( - hourlyCompensations: HourlyCompensations, -): string { - return JSON.stringify( - HourlyCompensations$outboundSchema.parse(hourlyCompensations), - ); -} - -export function hourlyCompensationsFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => HourlyCompensations$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'HourlyCompensations' from JSON`, - ); -} - -/** @internal */ -export const PaidTimeOff$inboundSchema: z.ZodType< - PaidTimeOff, - z.ZodTypeDef, - unknown -> = z.object({ - name: z.string().optional(), - hours: z.string().optional(), - policy_uuid: z.string().optional(), - final_payout_unused_hours_input: z.string().optional(), -}).transform((v) => { - return remap$(v, { - "policy_uuid": "policyUuid", - "final_payout_unused_hours_input": "finalPayoutUnusedHoursInput", - }); -}); - -/** @internal */ -export type PaidTimeOff$Outbound = { - name?: string | undefined; - hours?: string | undefined; - policy_uuid?: string | undefined; - final_payout_unused_hours_input?: string | undefined; -}; - -/** @internal */ -export const PaidTimeOff$outboundSchema: z.ZodType< - PaidTimeOff$Outbound, - z.ZodTypeDef, - PaidTimeOff -> = z.object({ - name: z.string().optional(), - hours: z.string().optional(), - policyUuid: z.string().optional(), - finalPayoutUnusedHoursInput: z.string().optional(), -}).transform((v) => { - return remap$(v, { - policyUuid: "policy_uuid", - finalPayoutUnusedHoursInput: "final_payout_unused_hours_input", - }); -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace PaidTimeOff$ { - /** @deprecated use `PaidTimeOff$inboundSchema` instead. */ - export const inboundSchema = PaidTimeOff$inboundSchema; - /** @deprecated use `PaidTimeOff$outboundSchema` instead. */ - export const outboundSchema = PaidTimeOff$outboundSchema; - /** @deprecated use `PaidTimeOff$Outbound` instead. */ - export type Outbound = PaidTimeOff$Outbound; -} - -export function paidTimeOffToJSON(paidTimeOff: PaidTimeOff): string { - return JSON.stringify(PaidTimeOff$outboundSchema.parse(paidTimeOff)); -} - -export function paidTimeOffFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => PaidTimeOff$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'PaidTimeOff' from JSON`, - ); -} - -/** @internal */ -export const EmployeeCompensations$inboundSchema: z.ZodType< - EmployeeCompensations, - z.ZodTypeDef, - unknown -> = z.object({ - employee_uuid: z.string().optional(), - version: z.string().optional(), - excluded: z.boolean().optional(), - payment_method: PaymentMethod$inboundSchema.optional(), - memo: z.string().optional(), - fixed_compensations: z.array(z.lazy(() => FixedCompensations$inboundSchema)) - .optional(), - hourly_compensations: z.array(z.lazy(() => HourlyCompensations$inboundSchema)) - .optional(), - paid_time_off: z.array(z.lazy(() => PaidTimeOff$inboundSchema)).optional(), -}).transform((v) => { - return remap$(v, { - "employee_uuid": "employeeUuid", - "payment_method": "paymentMethod", - "fixed_compensations": "fixedCompensations", - "hourly_compensations": "hourlyCompensations", - "paid_time_off": "paidTimeOff", - }); -}); - -/** @internal */ -export type EmployeeCompensations$Outbound = { - employee_uuid?: string | undefined; - version?: string | undefined; - excluded?: boolean | undefined; - payment_method?: string | undefined; - memo?: string | undefined; - fixed_compensations?: Array | undefined; - hourly_compensations?: Array | undefined; - paid_time_off?: Array | undefined; -}; - -/** @internal */ -export const EmployeeCompensations$outboundSchema: z.ZodType< - EmployeeCompensations$Outbound, - z.ZodTypeDef, - EmployeeCompensations -> = z.object({ - employeeUuid: z.string().optional(), - version: z.string().optional(), - excluded: z.boolean().optional(), - paymentMethod: PaymentMethod$outboundSchema.optional(), - memo: z.string().optional(), - fixedCompensations: z.array(z.lazy(() => FixedCompensations$outboundSchema)) - .optional(), - hourlyCompensations: z.array(z.lazy(() => HourlyCompensations$outboundSchema)) - .optional(), - paidTimeOff: z.array(z.lazy(() => PaidTimeOff$outboundSchema)).optional(), -}).transform((v) => { - return remap$(v, { - employeeUuid: "employee_uuid", - paymentMethod: "payment_method", - fixedCompensations: "fixed_compensations", - hourlyCompensations: "hourly_compensations", - paidTimeOff: "paid_time_off", - }); -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace EmployeeCompensations$ { - /** @deprecated use `EmployeeCompensations$inboundSchema` instead. */ - export const inboundSchema = EmployeeCompensations$inboundSchema; - /** @deprecated use `EmployeeCompensations$outboundSchema` instead. */ - export const outboundSchema = EmployeeCompensations$outboundSchema; - /** @deprecated use `EmployeeCompensations$Outbound` instead. */ - export type Outbound = EmployeeCompensations$Outbound; -} - -export function employeeCompensationsToJSON( - employeeCompensations: EmployeeCompensations, -): string { - return JSON.stringify( - EmployeeCompensations$outboundSchema.parse(employeeCompensations), - ); -} - -export function employeeCompensationsFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => EmployeeCompensations$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'EmployeeCompensations' from JSON`, - ); -} - -/** @internal */ -export const PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$inboundSchema: - z.ZodNativeEnum = - z.nativeEnum(PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod); +export const PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum< + typeof PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion + > = z.nativeEnum(PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion); /** @internal */ -export const PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$outboundSchema: - z.ZodNativeEnum = - PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$inboundSchema; +export const PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum< + typeof PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion + > = PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$ { - /** @deprecated use `PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$inboundSchema` instead. */ +export namespace PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$ { + /** @deprecated use `PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema` instead. */ export const inboundSchema = - PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$inboundSchema; - /** @deprecated use `PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$outboundSchema` instead. */ + PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema` instead. */ export const outboundSchema = - PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$outboundSchema; -} - -/** @internal */ -export const PutV1CompaniesCompanyIdPayrollsRequestBody$inboundSchema: - z.ZodType = - z.object({ - employee_compensations: z.array( - z.lazy(() => EmployeeCompensations$inboundSchema), - ), - withholding_pay_period: - PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$inboundSchema - .optional(), - skip_regular_deductions: z.boolean().optional(), - fixed_withholding_rate: z.boolean().optional(), - }).transform((v) => { - return remap$(v, { - "employee_compensations": "employeeCompensations", - "withholding_pay_period": "withholdingPayPeriod", - "skip_regular_deductions": "skipRegularDeductions", - "fixed_withholding_rate": "fixedWithholdingRate", - }); - }); - -/** @internal */ -export type PutV1CompaniesCompanyIdPayrollsRequestBody$Outbound = { - employee_compensations: Array; - withholding_pay_period?: string | undefined; - skip_regular_deductions?: boolean | undefined; - fixed_withholding_rate?: boolean | undefined; -}; - -/** @internal */ -export const PutV1CompaniesCompanyIdPayrollsRequestBody$outboundSchema: - z.ZodType< - PutV1CompaniesCompanyIdPayrollsRequestBody$Outbound, - z.ZodTypeDef, - PutV1CompaniesCompanyIdPayrollsRequestBody - > = z.object({ - employeeCompensations: z.array( - z.lazy(() => EmployeeCompensations$outboundSchema), - ), - withholdingPayPeriod: - PutV1CompaniesCompanyIdPayrollsWithholdingPayPeriod$outboundSchema - .optional(), - skipRegularDeductions: z.boolean().optional(), - fixedWithholdingRate: z.boolean().optional(), - }).transform((v) => { - return remap$(v, { - employeeCompensations: "employee_compensations", - withholdingPayPeriod: "withholding_pay_period", - skipRegularDeductions: "skip_regular_deductions", - fixedWithholdingRate: "fixed_withholding_rate", - }); - }); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace PutV1CompaniesCompanyIdPayrollsRequestBody$ { - /** @deprecated use `PutV1CompaniesCompanyIdPayrollsRequestBody$inboundSchema` instead. */ - export const inboundSchema = - PutV1CompaniesCompanyIdPayrollsRequestBody$inboundSchema; - /** @deprecated use `PutV1CompaniesCompanyIdPayrollsRequestBody$outboundSchema` instead. */ - export const outboundSchema = - PutV1CompaniesCompanyIdPayrollsRequestBody$outboundSchema; - /** @deprecated use `PutV1CompaniesCompanyIdPayrollsRequestBody$Outbound` instead. */ - export type Outbound = PutV1CompaniesCompanyIdPayrollsRequestBody$Outbound; -} - -export function putV1CompaniesCompanyIdPayrollsRequestBodyToJSON( - putV1CompaniesCompanyIdPayrollsRequestBody: - PutV1CompaniesCompanyIdPayrollsRequestBody, -): string { - return JSON.stringify( - PutV1CompaniesCompanyIdPayrollsRequestBody$outboundSchema.parse( - putV1CompaniesCompanyIdPayrollsRequestBody, - ), - ); -} - -export function putV1CompaniesCompanyIdPayrollsRequestBodyFromJSON( - jsonString: string, -): SafeParseResult< - PutV1CompaniesCompanyIdPayrollsRequestBody, - SDKValidationError -> { - return safeParse( - jsonString, - (x) => - PutV1CompaniesCompanyIdPayrollsRequestBody$inboundSchema.parse( - JSON.parse(x), - ), - `Failed to parse 'PutV1CompaniesCompanyIdPayrollsRequestBody' from JSON`, - ); + PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema; } /** @internal */ @@ -628,27 +97,28 @@ export const PutV1CompaniesCompanyIdPayrollsRequest$inboundSchema: z.ZodType< z.ZodTypeDef, unknown > = z.object({ + "X-Gusto-API-Version": + PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$inboundSchema.default( + "2024-04-01", + ), company_id: z.string(), payroll_id: z.string(), - "X-Gusto-API-Version": VersionHeader$inboundSchema.default("2024-04-01"), - RequestBody: z.lazy(() => - PutV1CompaniesCompanyIdPayrollsRequestBody$inboundSchema - ), + "Payroll-Update": PayrollUpdate$inboundSchema, }).transform((v) => { return remap$(v, { + "X-Gusto-API-Version": "xGustoAPIVersion", "company_id": "companyId", "payroll_id": "payrollId", - "X-Gusto-API-Version": "xGustoAPIVersion", - "RequestBody": "requestBody", + "Payroll-Update": "payrollUpdate", }); }); /** @internal */ export type PutV1CompaniesCompanyIdPayrollsRequest$Outbound = { + "X-Gusto-API-Version": string; company_id: string; payroll_id: string; - "X-Gusto-API-Version": string; - RequestBody: PutV1CompaniesCompanyIdPayrollsRequestBody$Outbound; + "Payroll-Update": PayrollUpdate$Outbound; }; /** @internal */ @@ -657,18 +127,18 @@ export const PutV1CompaniesCompanyIdPayrollsRequest$outboundSchema: z.ZodType< z.ZodTypeDef, PutV1CompaniesCompanyIdPayrollsRequest > = z.object({ + xGustoAPIVersion: + PutV1CompaniesCompanyIdPayrollsHeaderXGustoAPIVersion$outboundSchema + .default("2024-04-01"), companyId: z.string(), payrollId: z.string(), - xGustoAPIVersion: VersionHeader$outboundSchema.default("2024-04-01"), - requestBody: z.lazy(() => - PutV1CompaniesCompanyIdPayrollsRequestBody$outboundSchema - ), + payrollUpdate: PayrollUpdate$outboundSchema, }).transform((v) => { return remap$(v, { + xGustoAPIVersion: "X-Gusto-API-Version", companyId: "company_id", payrollId: "payroll_id", - xGustoAPIVersion: "X-Gusto-API-Version", - requestBody: "RequestBody", + payrollUpdate: "Payroll-Update", }); }); diff --git a/gusto_embedded/src/models/operations/putv1employeebenefitsemployeebenefitid.ts b/gusto_embedded/src/models/operations/putv1employeebenefitsemployeebenefitid.ts index 93167863..49b9e8ad 100644 --- a/gusto_embedded/src/models/operations/putv1employeebenefitsemployeebenefitid.ts +++ b/gusto_embedded/src/models/operations/putv1employeebenefitsemployeebenefitid.ts @@ -66,13 +66,17 @@ export type Value2 = { */ rate?: string | undefined; /** - * The percentage threshold at which this tier ends (inclusive). + * Specifies the upper limit (inclusive) percentage of the employee contribution that this tier applies to. * * @remarks * - * For example, a value of "5" means the company contribution will match employee deductions from the previous tier's threshold up to and including 5% of payroll. + * Use threshold to define each tier's end point, with tiers applied cumulatively from 0% upwards. * - * If this is the first tier, a value of "5" means the company contribution will match employee deductions from 0% up to and including 5% of payroll. + * For example: + * + * If the first tier has a threshold of "3", and rate of "100", the company will match 100% of employee contributions from 0% up to and including 3% of payroll. + * + * If the next tier has a threshold of "5" and a rate of "50", the company will match 50% of contributions from above 3% up to and including 5% of payroll. */ threshold?: string | undefined; }; diff --git a/gusto_embedded/src/models/operations/putv1employees.ts b/gusto_embedded/src/models/operations/putv1employees.ts index 3637eb02..6fcdc7a3 100644 --- a/gusto_embedded/src/models/operations/putv1employees.ts +++ b/gusto_embedded/src/models/operations/putv1employees.ts @@ -5,6 +5,7 @@ import * as z from "zod"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; +import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { Employee, @@ -20,6 +21,19 @@ import { } from "../components/httpmetadata.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export const PutV1EmployeesHeaderXGustoAPIVersion = { + TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", +} as const; +/** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ +export type PutV1EmployeesHeaderXGustoAPIVersion = ClosedEnum< + typeof PutV1EmployeesHeaderXGustoAPIVersion +>; + export type PutV1EmployeesRequestBody = { /** * The current version of the object. See the [versioning guide](https://docs.gusto.com/embedded-payroll/docs/idempotency) for information on how to use this field. @@ -40,7 +54,10 @@ export type PutV1EmployeesRequestBody = { }; export type PutV1EmployeesRequest = { - xGustoAPIVersion?: string | undefined; + /** + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. + */ + xGustoAPIVersion?: PutV1EmployeesHeaderXGustoAPIVersion | undefined; /** * The UUID of the employee */ @@ -56,6 +73,30 @@ export type PutV1EmployeesResponse = { employee?: Employee | undefined; }; +/** @internal */ +export const PutV1EmployeesHeaderXGustoAPIVersion$inboundSchema: + z.ZodNativeEnum = z.nativeEnum( + PutV1EmployeesHeaderXGustoAPIVersion, + ); + +/** @internal */ +export const PutV1EmployeesHeaderXGustoAPIVersion$outboundSchema: + z.ZodNativeEnum = + PutV1EmployeesHeaderXGustoAPIVersion$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PutV1EmployeesHeaderXGustoAPIVersion$ { + /** @deprecated use `PutV1EmployeesHeaderXGustoAPIVersion$inboundSchema` instead. */ + export const inboundSchema = + PutV1EmployeesHeaderXGustoAPIVersion$inboundSchema; + /** @deprecated use `PutV1EmployeesHeaderXGustoAPIVersion$outboundSchema` instead. */ + export const outboundSchema = + PutV1EmployeesHeaderXGustoAPIVersion$outboundSchema; +} + /** @internal */ export const PutV1EmployeesRequestBody$inboundSchema: z.ZodType< PutV1EmployeesRequestBody, @@ -163,7 +204,8 @@ export const PutV1EmployeesRequest$inboundSchema: z.ZodType< z.ZodTypeDef, unknown > = z.object({ - "X-Gusto-API-Version": z.string().optional(), + "X-Gusto-API-Version": PutV1EmployeesHeaderXGustoAPIVersion$inboundSchema + .default("2024-04-01"), employee_id: z.string(), RequestBody: z.lazy(() => PutV1EmployeesRequestBody$inboundSchema), }).transform((v) => { @@ -176,7 +218,7 @@ export const PutV1EmployeesRequest$inboundSchema: z.ZodType< /** @internal */ export type PutV1EmployeesRequest$Outbound = { - "X-Gusto-API-Version"?: string | undefined; + "X-Gusto-API-Version": string; employee_id: string; RequestBody: PutV1EmployeesRequestBody$Outbound; }; @@ -187,7 +229,9 @@ export const PutV1EmployeesRequest$outboundSchema: z.ZodType< z.ZodTypeDef, PutV1EmployeesRequest > = z.object({ - xGustoAPIVersion: z.string().optional(), + xGustoAPIVersion: PutV1EmployeesHeaderXGustoAPIVersion$outboundSchema.default( + "2024-04-01", + ), employeeId: z.string(), requestBody: z.lazy(() => PutV1EmployeesRequestBody$outboundSchema), }).transform((v) => { diff --git a/gusto_embedded/src/models/operations/putv1employeesemployeeidstatetaxes.ts b/gusto_embedded/src/models/operations/putv1employeesemployeeidstatetaxes.ts index 26423a9d..6a757a3f 100644 --- a/gusto_embedded/src/models/operations/putv1employeesemployeeidstatetaxes.ts +++ b/gusto_embedded/src/models/operations/putv1employeesemployeeidstatetaxes.ts @@ -28,20 +28,20 @@ import { import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** - * Determines the date-based API version associated with your API call. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ export const PutV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion = { TwoThousandAndTwentyFourMinus04Minus01: "2024-04-01", } as const; /** - * Determines the date-based API version associated with your API call. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ export type PutV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion = ClosedEnum; export type PutV1EmployeesEmployeeIdStateTaxesRequest = { /** - * Determines the date-based API version associated with your API call. + * Determines the date-based API version associated with your API call. If none is provided, your application's [minimum API version](https://docs.gusto.com/embedded-payroll/docs/api-versioning#minimum-api-version) is used. */ xGustoAPIVersion?: | PutV1EmployeesEmployeeIdStateTaxesHeaderXGustoAPIVersion diff --git a/gusto_embedded/src/react-query/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts b/gusto_embedded/src/react-query/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts new file mode 100644 index 00000000..9da8c57b --- /dev/null +++ b/gusto_embedded/src/react-query/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.ts @@ -0,0 +1,225 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { + InvalidateQueryFilters, + QueryClient, + QueryFunctionContext, + QueryKey, + useQuery, + UseQueryResult, + useSuspenseQuery, + UseSuspenseQueryResult, +} from "@tanstack/react-query"; +import { GustoEmbeddedCore } from "../core.js"; +import { contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements } from "../funcs/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.js"; +import { combineSignals } from "../lib/primitives.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { + GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, +} from "../models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.js"; +import { unwrapAsync } from "../types/fp.js"; +import { useGustoEmbeddedContext } from "./_context.js"; +import { + QueryHookOptions, + SuspenseQueryHookOptions, + TupleToPrefixes, +} from "./_types.js"; + +export type ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData = + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse; + +/** + * Get partner disbursements for a contractor payment group + * + * @remarks + * Get partner disbursements for a specific contractor payment group. + * + * scope: `partner_disbursements:read` + */ +export function useContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + request: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: QueryHookOptions< + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData + >, +): UseQueryResult< + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData, + Error +> { + const client = useGustoEmbeddedContext(); + return useQuery({ + ...buildContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQuery( + client, + request, + options, + ), + ...options, + }); +} + +/** + * Get partner disbursements for a contractor payment group + * + * @remarks + * Get partner disbursements for a specific contractor payment group. + * + * scope: `partner_disbursements:read` + */ +export function useContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsSuspense( + request: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: SuspenseQueryHookOptions< + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData + >, +): UseSuspenseQueryResult< + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData, + Error +> { + const client = useGustoEmbeddedContext(); + return useSuspenseQuery({ + ...buildContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQuery( + client, + request, + options, + ), + ...options, + }); +} + +export function prefetchContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + queryClient: QueryClient, + client$: GustoEmbeddedCore, + request: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, +): Promise { + return queryClient.prefetchQuery({ + ...buildContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQuery( + client$, + request, + ), + }); +} + +export function setContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsData( + client: QueryClient, + queryKeyBase: [ + id: string, + parameters: { + xGustoAPIVersion?: + | GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + }, + ], + data: + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData, +): + | ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData + | undefined +{ + const key = + queryKeyContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + ...queryKeyBase, + ); + + return client.setQueryData< + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData + >(key, data); +} + +export function invalidateContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + client: QueryClient, + queryKeyBase: TupleToPrefixes< + [ + id: string, + parameters: { + xGustoAPIVersion?: + | GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + }, + ] + >, + filters?: Omit, +): Promise { + return client.invalidateQueries({ + ...filters, + queryKey: [ + "@gusto/embedded-api", + "contractorPaymentGroups", + "getV1ContractorPaymentGroupsIdPartnerDisbursements", + ...queryKeyBase, + ], + }); +} + +export function invalidateAllContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + client: QueryClient, + filters?: Omit, +): Promise { + return client.invalidateQueries({ + ...filters, + queryKey: [ + "@gusto/embedded-api", + "contractorPaymentGroups", + "getV1ContractorPaymentGroupsIdPartnerDisbursements", + ], + }); +} + +export function buildContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQuery( + client$: GustoEmbeddedCore, + request: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): { + queryKey: QueryKey; + queryFn: ( + context: QueryFunctionContext, + ) => Promise< + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData + >; +} { + return { + queryKey: + queryKeyContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + request.id, + { xGustoAPIVersion: request.xGustoAPIVersion }, + ), + queryFn: + async function contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryFn( + ctx, + ): Promise< + ContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursementsQueryData + > { + const sig = combineSignals(ctx.signal, options?.fetchOptions?.signal); + const mergedOptions = { + ...options, + fetchOptions: { ...options?.fetchOptions, signal: sig }, + }; + + return unwrapAsync( + contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + client$, + request, + mergedOptions, + ), + ); + }, + }; +} + +export function queryKeyContractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + id: string, + parameters: { + xGustoAPIVersion?: + | GetV1ContractorPaymentGroupsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + }, +): QueryKey { + return [ + "@gusto/embedded-api", + "contractorPaymentGroups", + "getV1ContractorPaymentGroupsIdPartnerDisbursements", + id, + parameters, + ]; +} diff --git a/gusto_embedded/src/react-query/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts b/gusto_embedded/src/react-query/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts new file mode 100644 index 00000000..fcca17e0 --- /dev/null +++ b/gusto_embedded/src/react-query/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.ts @@ -0,0 +1,113 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { + MutationKey, + useMutation, + UseMutationResult, +} from "@tanstack/react-query"; +import { GustoEmbeddedCore } from "../core.js"; +import { contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements } from "../funcs/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.js"; +import { combineSignals } from "../lib/primitives.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, +} from "../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; +import { unwrapAsync } from "../types/fp.js"; +import { useGustoEmbeddedContext } from "./_context.js"; +import { MutationHookOptions } from "./_types.js"; + +export type ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationVariables = + { + request: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest; + options?: RequestOptions; + }; + +export type ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationData = + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse; + +/** + * Update partner disbursements for a contractor payment group + * + * @remarks + * Update partner disbursements for a specific contractor payment group. + * + * scope: `partner_disbursements:write` + */ +export function useContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutation( + options?: MutationHookOptions< + ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationData, + Error, + ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationVariables + >, +): UseMutationResult< + ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationData, + Error, + ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationVariables +> { + const client = useGustoEmbeddedContext(); + return useMutation({ + ...buildContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutation( + client, + options, + ), + ...options, + }); +} + +export function mutationKeyContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements(): MutationKey { + return [ + "@gusto/embedded-api", + "contractorPaymentGroups", + "patchV1ContractorPaymentGroupsIdPartnerDisbursements", + ]; +} + +export function buildContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutation( + client$: GustoEmbeddedCore, + hookOptions?: RequestOptions, +): { + mutationKey: MutationKey; + mutationFn: ( + variables: + ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationVariables, + ) => Promise< + ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationData + >; +} { + return { + mutationKey: + mutationKeyContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements(), + mutationFn: + function contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationFn( + { + request, + options, + }, + ): Promise< + ContractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursementsMutationData + > { + const mergedOptions = { + ...hookOptions, + ...options, + fetchOptions: { + ...hookOptions?.fetchOptions, + ...options?.fetchOptions, + signal: combineSignals( + hookOptions?.fetchOptions?.signal, + options?.fetchOptions?.signal, + ), + }, + }; + return unwrapAsync( + contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements( + client$, + request, + mergedOptions, + ), + ); + }, + }; +} diff --git a/gusto_embedded/src/react-query/employeesList.ts b/gusto_embedded/src/react-query/employeesList.ts index a997f013..20b88c7b 100644 --- a/gusto_embedded/src/react-query/employeesList.ts +++ b/gusto_embedded/src/react-query/employeesList.ts @@ -102,6 +102,7 @@ export function setEmployeesListData( searchTerm?: string | undefined; include?: Array | undefined; terminated?: boolean | undefined; + uuids?: Array | undefined; page?: number | undefined; per?: number | undefined; }, @@ -125,6 +126,7 @@ export function invalidateEmployeesList( searchTerm?: string | undefined; include?: Array | undefined; terminated?: boolean | undefined; + uuids?: Array | undefined; page?: number | undefined; per?: number | undefined; }, @@ -162,6 +164,7 @@ export function buildEmployeesListQuery( searchTerm: request.searchTerm, include: request.include, terminated: request.terminated, + uuids: request.uuids, page: request.page, per: request.per, }), @@ -192,6 +195,7 @@ export function queryKeyEmployeesList( searchTerm?: string | undefined; include?: Array | undefined; terminated?: boolean | undefined; + uuids?: Array | undefined; page?: number | undefined; per?: number | undefined; }, diff --git a/gusto_embedded/src/react-query/paymentConfigsGet.ts b/gusto_embedded/src/react-query/paymentConfigsGet.ts index 2cc27fcd..974a9d89 100644 --- a/gusto_embedded/src/react-query/paymentConfigsGet.ts +++ b/gusto_embedded/src/react-query/paymentConfigsGet.ts @@ -35,7 +35,7 @@ export type PaymentConfigsGetQueryData = GetV1CompanyPaymentConfigsResponse; * Get a company's payment configs * * @remarks - * Get payment speed for the company and fast payment limit (1-day is only applicable to partners that opt in). + * Get payment speed configurations for the company and fast payment limit (1-day is only applicable to partners that opt in). * * scope: `company_payment_configs:read` */ @@ -58,7 +58,7 @@ export function usePaymentConfigsGet( * Get a company's payment configs * * @remarks - * Get payment speed for the company and fast payment limit (1-day is only applicable to partners that opt in). + * Get payment speed configurations for the company and fast payment limit (1-day is only applicable to partners that opt in). * * scope: `company_payment_configs:read` */ diff --git a/gusto_embedded/src/react-query/payrollsGet.ts b/gusto_embedded/src/react-query/payrollsGet.ts index cfdae75c..e7af3151 100644 --- a/gusto_embedded/src/react-query/payrollsGet.ts +++ b/gusto_embedded/src/react-query/payrollsGet.ts @@ -16,8 +16,8 @@ import { GustoEmbeddedCore } from "../core.js"; import { payrollsGet } from "../funcs/payrollsGet.js"; import { combineSignals } from "../lib/primitives.js"; import { RequestOptions } from "../lib/sdks.js"; -import { VersionHeader } from "../models/components/versionheader.js"; import { + GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion, GetV1CompaniesCompanyIdPayrollsPayrollIdQueryParamInclude, GetV1CompaniesCompanyIdPayrollsPayrollIdRequest, GetV1CompaniesCompanyIdPayrollsPayrollIdResponse, @@ -112,10 +112,12 @@ export function setPayrollsGetData( companyId: string, payrollId: string, parameters: { + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + | undefined; include?: | Array | undefined; - xGustoAPIVersion?: VersionHeader | undefined; }, ], data: PayrollsGetQueryData, @@ -132,10 +134,12 @@ export function invalidatePayrollsGet( companyId: string, payrollId: string, parameters: { + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + | undefined; include?: | Array | undefined; - xGustoAPIVersion?: VersionHeader | undefined; }, ] >, @@ -167,8 +171,8 @@ export function buildPayrollsGetQuery( } { return { queryKey: queryKeyPayrollsGet(request.companyId, request.payrollId, { - include: request.include, xGustoAPIVersion: request.xGustoAPIVersion, + include: request.include, }), queryFn: async function payrollsGetQueryFn( ctx, @@ -192,10 +196,12 @@ export function queryKeyPayrollsGet( companyId: string, payrollId: string, parameters: { + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsPayrollIdHeaderXGustoAPIVersion + | undefined; include?: | Array | undefined; - xGustoAPIVersion?: VersionHeader | undefined; }, ): QueryKey { return [ diff --git a/gusto_embedded/src/react-query/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts b/gusto_embedded/src/react-query/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts new file mode 100644 index 00000000..58bbdb88 --- /dev/null +++ b/gusto_embedded/src/react-query/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts @@ -0,0 +1,229 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { + InvalidateQueryFilters, + QueryClient, + QueryFunctionContext, + QueryKey, + useQuery, + UseQueryResult, + useSuspenseQuery, + UseSuspenseQueryResult, +} from "@tanstack/react-query"; +import { GustoEmbeddedCore } from "../core.js"; +import { payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements } from "../funcs/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; +import { combineSignals } from "../lib/primitives.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, +} from "../models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.js"; +import { unwrapAsync } from "../types/fp.js"; +import { useGustoEmbeddedContext } from "./_context.js"; +import { + QueryHookOptions, + SuspenseQueryHookOptions, + TupleToPrefixes, +} from "./_types.js"; + +export type PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData = + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse; + +/** + * Get partner disbursements for a payroll + * + * @remarks + * Get partner disbursements for a specific payroll. + * + * scope: `partner_disbursements:read` + */ +export function usePayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + request: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: QueryHookOptions< + PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData + >, +): UseQueryResult< + PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData, + Error +> { + const client = useGustoEmbeddedContext(); + return useQuery({ + ...buildPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQuery( + client, + request, + options, + ), + ...options, + }); +} + +/** + * Get partner disbursements for a payroll + * + * @remarks + * Get partner disbursements for a specific payroll. + * + * scope: `partner_disbursements:read` + */ +export function usePayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsSuspense( + request: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: SuspenseQueryHookOptions< + PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData + >, +): UseSuspenseQueryResult< + PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData, + Error +> { + const client = useGustoEmbeddedContext(); + return useSuspenseQuery({ + ...buildPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQuery( + client, + request, + options, + ), + ...options, + }); +} + +export function prefetchPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + queryClient: QueryClient, + client$: GustoEmbeddedCore, + request: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, +): Promise { + return queryClient.prefetchQuery({ + ...buildPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQuery( + client$, + request, + ), + }); +} + +export function setPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsData( + client: QueryClient, + queryKeyBase: [ + companyId: string, + id: string, + parameters: { + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + }, + ], + data: PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData, +): + | PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData + | undefined +{ + const key = + queryKeyPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + ...queryKeyBase, + ); + + return client.setQueryData< + PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData + >(key, data); +} + +export function invalidatePayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + client: QueryClient, + queryKeyBase: TupleToPrefixes< + [ + companyId: string, + id: string, + parameters: { + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + }, + ] + >, + filters?: Omit, +): Promise { + return client.invalidateQueries({ + ...filters, + queryKey: [ + "@gusto/embedded-api", + "Payrolls", + "getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements", + ...queryKeyBase, + ], + }); +} + +export function invalidateAllPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + client: QueryClient, + filters?: Omit, +): Promise { + return client.invalidateQueries({ + ...filters, + queryKey: [ + "@gusto/embedded-api", + "Payrolls", + "getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements", + ], + }); +} + +export function buildPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQuery( + client$: GustoEmbeddedCore, + request: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: RequestOptions, +): { + queryKey: QueryKey; + queryFn: ( + context: QueryFunctionContext, + ) => Promise< + PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData + >; +} { + return { + queryKey: + queryKeyPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + request.companyId, + request.id, + { xGustoAPIVersion: request.xGustoAPIVersion }, + ), + queryFn: + async function payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryFn( + ctx, + ): Promise< + PayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsQueryData + > { + const sig = combineSignals(ctx.signal, options?.fetchOptions?.signal); + const mergedOptions = { + ...options, + fetchOptions: { ...options?.fetchOptions, signal: sig }, + }; + + return unwrapAsync( + payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + client$, + request, + mergedOptions, + ), + ); + }, + }; +} + +export function queryKeyPayrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + companyId: string, + id: string, + parameters: { + xGustoAPIVersion?: + | GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsHeaderXGustoAPIVersion + | undefined; + }, +): QueryKey { + return [ + "@gusto/embedded-api", + "Payrolls", + "getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements", + companyId, + id, + parameters, + ]; +} diff --git a/gusto_embedded/src/react-query/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts b/gusto_embedded/src/react-query/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts new file mode 100644 index 00000000..0e78a92d --- /dev/null +++ b/gusto_embedded/src/react-query/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.ts @@ -0,0 +1,113 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import { + MutationKey, + useMutation, + UseMutationResult, +} from "@tanstack/react-query"; +import { GustoEmbeddedCore } from "../core.js"; +import { payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements } from "../funcs/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; +import { combineSignals } from "../lib/primitives.js"; +import { RequestOptions } from "../lib/sdks.js"; +import { + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, +} from "../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; +import { unwrapAsync } from "../types/fp.js"; +import { useGustoEmbeddedContext } from "./_context.js"; +import { MutationHookOptions } from "./_types.js"; + +export type PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationVariables = + { + request: PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest; + options?: RequestOptions; + }; + +export type PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationData = + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse; + +/** + * Update partner disbursements for a payroll + * + * @remarks + * Update partner disbursements for a specific payroll. + * + * scope: `partner_disbursements:write` + */ +export function usePayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutation( + options?: MutationHookOptions< + PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationData, + Error, + PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationVariables + >, +): UseMutationResult< + PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationData, + Error, + PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationVariables +> { + const client = useGustoEmbeddedContext(); + return useMutation({ + ...buildPayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutation( + client, + options, + ), + ...options, + }); +} + +export function mutationKeyPayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements(): MutationKey { + return [ + "@gusto/embedded-api", + "Payrolls", + "patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements", + ]; +} + +export function buildPayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutation( + client$: GustoEmbeddedCore, + hookOptions?: RequestOptions, +): { + mutationKey: MutationKey; + mutationFn: ( + variables: + PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationVariables, + ) => Promise< + PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationData + >; +} { + return { + mutationKey: + mutationKeyPayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements(), + mutationFn: + function payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationFn( + { + request, + options, + }, + ): Promise< + PayrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsMutationData + > { + const mergedOptions = { + ...hookOptions, + ...options, + fetchOptions: { + ...hookOptions?.fetchOptions, + ...options?.fetchOptions, + signal: combineSignals( + hookOptions?.fetchOptions?.signal, + options?.fetchOptions?.signal, + ), + }, + }; + return unwrapAsync( + payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + client$, + request, + mergedOptions, + ), + ); + }, + }; +} diff --git a/gusto_embedded/src/react-query/reportsGetReportsRequestUuid.ts b/gusto_embedded/src/react-query/reportsGetReportsRequestUuid.ts index 2fdaf015..4f914acd 100644 --- a/gusto_embedded/src/react-query/reportsGetReportsRequestUuid.ts +++ b/gusto_embedded/src/react-query/reportsGetReportsRequestUuid.ts @@ -38,6 +38,8 @@ export type ReportsGetReportsRequestUuidQueryData = * @remarks * Get a company's report given the `request_uuid`. The response will include the report request's status and, if complete, the report URL. * + * Reports containing PHI are inaccessible with `company_reports:read:tier_2_only` data scope + * * scope: `company_reports:read` */ export function useReportsGetReportsRequestUuid( @@ -61,6 +63,8 @@ export function useReportsGetReportsRequestUuid( * @remarks * Get a company's report given the `request_uuid`. The response will include the report request's status and, if complete, the report URL. * + * Reports containing PHI are inaccessible with `company_reports:read:tier_2_only` data scope + * * scope: `company_reports:read` */ export function useReportsGetReportsRequestUuidSuspense( diff --git a/gusto_embedded/src/react-query/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts b/gusto_embedded/src/react-query/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts index 109fd093..dbf758b9 100644 --- a/gusto_embedded/src/react-query/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts +++ b/gusto_embedded/src/react-query/reportsPostPayrollsPayrollUuidReportsGeneralLedger.ts @@ -34,9 +34,9 @@ export type ReportsPostPayrollsPayrollUuidReportsGeneralLedgerMutationData = * @remarks * Create a general ledger report for a payroll. The report can be aggregated by different dimensions such as job or department. * - * Use the `request_uuid` in the response with the [report GET endpoint](https://docs.gusto.com/embedded-payroll/reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. + * Use the `request_uuid` in the response with the [report GET endpoint](../reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. * - * scope: `company_reports:write` + * scope: `company_reports:write` OR `company_reports:write:general_ledger` */ export function useReportsPostPayrollsPayrollUuidReportsGeneralLedgerMutation( options?: MutationHookOptions< diff --git a/gusto_embedded/src/sdk/contractorpaymentgroups.ts b/gusto_embedded/src/sdk/contractorpaymentgroups.ts index 4af310fe..8af479a8 100644 --- a/gusto_embedded/src/sdk/contractorpaymentgroups.ts +++ b/gusto_embedded/src/sdk/contractorpaymentgroups.ts @@ -7,6 +7,8 @@ import { contractorPaymentGroupsDelete } from "../funcs/contractorPaymentGroupsD import { contractorPaymentGroupsFund } from "../funcs/contractorPaymentGroupsFund.js"; import { contractorPaymentGroupsGet } from "../funcs/contractorPaymentGroupsGet.js"; import { contractorPaymentGroupsGetList } from "../funcs/contractorPaymentGroupsGetList.js"; +import { contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements } from "../funcs/contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements.js"; +import { contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements } from "../funcs/contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements.js"; import { contractorPaymentGroupsPreview } from "../funcs/contractorPaymentGroupsPreview.js"; import { ClientSDK, RequestOptions } from "../lib/sdks.js"; import { @@ -21,6 +23,14 @@ import { GetV1ContractorPaymentGroupsContractorPaymentGroupIdRequest, GetV1ContractorPaymentGroupsContractorPaymentGroupIdResponse, } from "../models/operations/getv1contractorpaymentgroupscontractorpaymentgroupid.js"; +import { + GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + GetV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, +} from "../models/operations/getv1contractorpaymentgroupsidpartnerdisbursements.js"; +import { + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + PatchV1ContractorPaymentGroupsIdPartnerDisbursementsResponse, +} from "../models/operations/patchv1contractorpaymentgroupsidpartnerdisbursements.js"; import { PostV1CompaniesCompanyIdContractorPaymentGroupsRequest, PostV1CompaniesCompanyIdContractorPaymentGroupsResponse, @@ -153,4 +163,46 @@ export class ContractorPaymentGroups extends ClientSDK { options, )); } + + /** + * Get partner disbursements for a contractor payment group + * + * @remarks + * Get partner disbursements for a specific contractor payment group. + * + * scope: `partner_disbursements:read` + */ + async getV1ContractorPaymentGroupsIdPartnerDisbursements( + request: GetV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: RequestOptions, + ): Promise { + return unwrapAsync( + contractorPaymentGroupsGetV1ContractorPaymentGroupsIdPartnerDisbursements( + this, + request, + options, + ), + ); + } + + /** + * Update partner disbursements for a contractor payment group + * + * @remarks + * Update partner disbursements for a specific contractor payment group. + * + * scope: `partner_disbursements:write` + */ + async patchV1ContractorPaymentGroupsIdPartnerDisbursements( + request: PatchV1ContractorPaymentGroupsIdPartnerDisbursementsRequest, + options?: RequestOptions, + ): Promise { + return unwrapAsync( + contractorPaymentGroupsPatchV1ContractorPaymentGroupsIdPartnerDisbursements( + this, + request, + options, + ), + ); + } } diff --git a/gusto_embedded/src/sdk/paymentconfigs.ts b/gusto_embedded/src/sdk/paymentconfigs.ts index d76dfa3c..25fa2b5e 100644 --- a/gusto_embedded/src/sdk/paymentconfigs.ts +++ b/gusto_embedded/src/sdk/paymentconfigs.ts @@ -20,7 +20,7 @@ export class PaymentConfigs extends ClientSDK { * Get a company's payment configs * * @remarks - * Get payment speed for the company and fast payment limit (1-day is only applicable to partners that opt in). + * Get payment speed configurations for the company and fast payment limit (1-day is only applicable to partners that opt in). * * scope: `company_payment_configs:read` */ diff --git a/gusto_embedded/src/sdk/payrolls.ts b/gusto_embedded/src/sdk/payrolls.ts index ace43e43..80e31f65 100644 --- a/gusto_embedded/src/sdk/payrolls.ts +++ b/gusto_embedded/src/sdk/payrolls.ts @@ -14,7 +14,9 @@ import { payrollsGetBlockers } from "../funcs/payrollsGetBlockers.js"; import { payrollsGetPayStub } from "../funcs/payrollsGetPayStub.js"; import { payrollsGetPayStubs } from "../funcs/payrollsGetPayStubs.js"; import { payrollsGetReceipt } from "../funcs/payrollsGetReceipt.js"; +import { payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements } from "../funcs/payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; import { payrollsList } from "../funcs/payrollsList.js"; +import { payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements } from "../funcs/payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements.js"; import { payrollsPrepare } from "../funcs/payrollsPrepare.js"; import { payrollsSkip } from "../funcs/payrollsSkip.js"; import { payrollsSubmit } from "../funcs/payrollsSubmit.js"; @@ -32,6 +34,10 @@ import { GetV1CompaniesCompanyIdPayrollsRequest, GetV1CompaniesCompanyIdPayrollsResponse, } from "../models/operations/getv1companiescompanyidpayrolls.js"; +import { + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, +} from "../models/operations/getv1companiescompanyidpayrollsidpartnerdisbursements.js"; import { GetV1CompaniesCompanyIdPayrollsPayrollIdRequest, GetV1CompaniesCompanyIdPayrollsPayrollIdResponse, @@ -52,6 +58,10 @@ import { GetV1PayrollsPayrollUuidEmployeesEmployeeUuidPayStubRequest, GetV1PayrollsPayrollUuidEmployeesEmployeeUuidPayStubResponse, } from "../models/operations/getv1payrollspayrolluuidemployeesemployeeuuidpaystub.js"; +import { + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsResponse, +} from "../models/operations/patchv1companiescompanyidpayrollsidpartnerdisbursements.js"; import { PostCompaniesPayrollSkipCompanyUuidRequest, PostCompaniesPayrollSkipCompanyUuidResponse, @@ -465,4 +475,46 @@ export class Payrolls extends ClientSDK { options, )); } + + /** + * Get partner disbursements for a payroll + * + * @remarks + * Get partner disbursements for a specific payroll. + * + * scope: `partner_disbursements:read` + */ + async getV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + request: GetV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: RequestOptions, + ): Promise { + return unwrapAsync( + payrollsGetV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + this, + request, + options, + ), + ); + } + + /** + * Update partner disbursements for a payroll + * + * @remarks + * Update partner disbursements for a specific payroll. + * + * scope: `partner_disbursements:write` + */ + async patchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + request: PatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursementsRequest, + options?: RequestOptions, + ): Promise { + return unwrapAsync( + payrollsPatchV1CompaniesCompanyIdPayrollsIdPartnerDisbursements( + this, + request, + options, + ), + ); + } } diff --git a/gusto_embedded/src/sdk/reports.ts b/gusto_embedded/src/sdk/reports.ts index e427d215..3c090157 100644 --- a/gusto_embedded/src/sdk/reports.ts +++ b/gusto_embedded/src/sdk/reports.ts @@ -51,9 +51,9 @@ export class Reports extends ClientSDK { * @remarks * Create a general ledger report for a payroll. The report can be aggregated by different dimensions such as job or department. * - * Use the `request_uuid` in the response with the [report GET endpoint](https://docs.gusto.com/embedded-payroll/reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. + * Use the `request_uuid` in the response with the [report GET endpoint](../reference/get-reports-request_uuid) to poll for the status and report URL upon completion. The retrieved report will be generated in a JSON format. * - * scope: `company_reports:write` + * scope: `company_reports:write` OR `company_reports:write:general_ledger` */ async postPayrollsPayrollUuidReportsGeneralLedger( request: PostPayrollsPayrollUuidReportsGeneralLedgerRequest, @@ -72,6 +72,8 @@ export class Reports extends ClientSDK { * @remarks * Get a company's report given the `request_uuid`. The response will include the report request's status and, if complete, the report URL. * + * Reports containing PHI are inaccessible with `company_reports:read:tier_2_only` data scope + * * scope: `company_reports:read` */ async getReportsRequestUuid( diff --git a/gusto_embedded/src/types/constdatetime.ts b/gusto_embedded/src/types/constdatetime.ts index c0a4409c..eeff4dde 100644 --- a/gusto_embedded/src/types/constdatetime.ts +++ b/gusto_embedded/src/types/constdatetime.ts @@ -11,5 +11,5 @@ export function constDateTime( return ( typeof v === "string" && new Date(v).getTime() === new Date(val).getTime() ); - }, `Value must be equivelant to ${val}`); + }, `Value must be equivalent to ${val}`); }