From 1086b5a6feea66087c195b50538d4acace0b6ca2 Mon Sep 17 00:00:00 2001 From: fern-api <115122769+fern-api[bot]@users.noreply.github.com> Date: Thu, 3 Jul 2025 15:51:40 +0000 Subject: [PATCH] SDK regeneration --- .mock/definition/accounting/__package__.yml | 3089 +++++++++++ .../definition/accounting/expenseReports.yml | 938 ++++ .mock/definition/accounting/fieldMapping.yml | 20 + .mock/definition/accounting/items.yml | 4 + .mock/definition/accounting/payments.yml | 16 +- package.json | 2 +- reference.md | 4561 +++++++++-------- src/Client.ts | 16 +- src/api/resources/accounting/client/Client.ts | 6 + .../resources/expenseReports/client/Client.ts | 842 +++ .../resources/expenseReports/client/index.ts | 1 + .../requests/ExpenseReportEndpointRequest.ts | 25 + .../ExpenseReportsLinesListRequest.ts | 40 + ...portsLinesRemoteFieldClassesListRequest.ts | 38 + .../requests/ExpenseReportsListRequest.ts | 64 + ...nseReportsRemoteFieldClassesListRequest.ts | 38 + .../requests/ExpenseReportsRetrieveRequest.ts | 28 + .../expenseReports/client/requests/index.ts | 6 + .../resources/expenseReports/index.ts | 2 + .../ExpenseReportsLinesListRequestExpand.ts | 133 + .../types/ExpenseReportsListRequestExpand.ts | 37 + .../ExpenseReportsRetrieveRequestExpand.ts | 37 + .../resources/expenseReports/types/index.ts | 3 + .../resources/accounting/resources/index.ts | 3 + .../accounting/types/ExpenseReport.ts | 366 ++ .../accounting/types/ExpenseReportCompany.ts | 10 + .../accounting/types/ExpenseReportLine.ts | 368 ++ .../types/ExpenseReportLineAccount.ts | 7 + .../types/ExpenseReportLineCompany.ts | 10 + .../types/ExpenseReportLineContact.ts | 7 + .../types/ExpenseReportLineEmployee.ts | 10 + .../types/ExpenseReportLineProject.ts | 7 + .../types/ExpenseReportLineRequest.ts | 363 ++ .../types/ExpenseReportLineRequestAccount.ts | 7 + .../types/ExpenseReportLineRequestCompany.ts | 10 + .../types/ExpenseReportLineRequestContact.ts | 7 + .../types/ExpenseReportLineRequestEmployee.ts | 10 + .../types/ExpenseReportLineRequestProject.ts | 7 + .../types/ExpenseReportLineRequestTaxRate.ts | 7 + .../types/ExpenseReportLineTaxRate.ts | 7 + .../accounting/types/ExpenseReportRequest.ts | 356 ++ .../ExpenseReportRequestAccountingPeriod.ts | 10 + .../types/ExpenseReportRequestCompany.ts | 10 + .../types/ExpenseReportRequestEmployee.ts | 10 + .../accounting/types/ExpenseReportResponse.ts | 12 + .../accounting/types/ExpenseReportStatus.ts | 15 + .../types/ExpenseReportStatusEnum.ts | 17 + .../types/ExternalTargetFieldApiResponse.ts | 1 + .../types/FieldMappingApiInstanceResponse.ts | 1 + src/api/resources/accounting/types/Item.ts | 9 + .../resources/accounting/types/ItemType.ts | 15 + .../types/PaginatedExpenseReportLineList.ts | 11 + .../types/PaginatedExpenseReportList.ts | 11 + src/api/resources/accounting/types/index.ts | 26 + src/api/resources/index.ts | 2 +- .../resources/expenseReports/client/index.ts | 1 + .../requests/ExpenseReportEndpointRequest.ts | 21 + .../expenseReports/client/requests/index.ts | 1 + .../resources/expenseReports/index.ts | 2 + .../ExpenseReportsLinesListRequestExpand.ts | 143 + .../types/ExpenseReportsListRequestExpand.ts | 47 + .../ExpenseReportsRetrieveRequestExpand.ts | 47 + .../resources/expenseReports/types/index.ts | 3 + .../resources/accounting/resources/index.ts | 3 + .../accounting/types/ExpenseReport.ts | 68 + .../accounting/types/ExpenseReportCompany.ts | 17 + .../accounting/types/ExpenseReportLine.ts | 77 + .../types/ExpenseReportLineAccount.ts | 17 + .../types/ExpenseReportLineCompany.ts | 17 + .../types/ExpenseReportLineContact.ts | 17 + .../types/ExpenseReportLineEmployee.ts | 17 + .../types/ExpenseReportLineProject.ts | 17 + .../types/ExpenseReportLineRequest.ts | 79 + .../types/ExpenseReportLineRequestAccount.ts | 17 + .../types/ExpenseReportLineRequestCompany.ts | 17 + .../types/ExpenseReportLineRequestContact.ts | 17 + .../types/ExpenseReportLineRequestEmployee.ts | 17 + .../types/ExpenseReportLineRequestProject.ts | 17 + .../types/ExpenseReportLineRequestTaxRate.ts | 17 + .../types/ExpenseReportLineTaxRate.ts | 17 + .../accounting/types/ExpenseReportRequest.ts | 59 + .../ExpenseReportRequestAccountingPeriod.ts | 17 + .../types/ExpenseReportRequestCompany.ts | 17 + .../types/ExpenseReportRequestEmployee.ts | 17 + .../accounting/types/ExpenseReportResponse.ts | 30 + .../accounting/types/ExpenseReportStatus.ts | 17 + .../types/ExpenseReportStatusEnum.ts | 16 + .../types/ExternalTargetFieldApiResponse.ts | 5 + .../types/FieldMappingApiInstanceResponse.ts | 5 + .../resources/accounting/types/Item.ts | 3 + .../resources/accounting/types/ItemType.ts | 15 + .../types/PaginatedExpenseReportLineList.ts | 25 + .../types/PaginatedExpenseReportList.ts | 25 + .../resources/accounting/types/index.ts | 26 + src/serialization/resources/index.ts | 2 +- src/version.ts | 2 +- tests/wire/accounting/expenseReports.test.ts | 1087 ++++ tests/wire/accounting/fieldMapping.test.ts | 56 + tests/wire/accounting/items.test.ts | 8 + tests/wire/accounting/payments.test.ts | 32 +- yarn.lock | 90 +- 101 files changed, 11791 insertions(+), 2134 deletions(-) create mode 100644 .mock/definition/accounting/expenseReports.yml create mode 100644 src/api/resources/accounting/resources/expenseReports/client/Client.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/index.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesListRequest.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesRemoteFieldClassesListRequest.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsListRequest.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRemoteFieldClassesListRequest.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRetrieveRequest.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/client/requests/index.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/index.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts create mode 100644 src/api/resources/accounting/resources/expenseReports/types/index.ts create mode 100644 src/api/resources/accounting/types/ExpenseReport.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportCompany.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLine.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineAccount.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineCompany.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineContact.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineEmployee.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineProject.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineRequest.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineRequestAccount.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineRequestCompany.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineRequestContact.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineRequestEmployee.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineRequestProject.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportLineTaxRate.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportRequest.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportRequestCompany.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportRequestEmployee.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportResponse.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportStatus.ts create mode 100644 src/api/resources/accounting/types/ExpenseReportStatusEnum.ts create mode 100644 src/api/resources/accounting/types/ItemType.ts create mode 100644 src/api/resources/accounting/types/PaginatedExpenseReportLineList.ts create mode 100644 src/api/resources/accounting/types/PaginatedExpenseReportList.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/client/index.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/client/requests/index.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/index.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts create mode 100644 src/serialization/resources/accounting/resources/expenseReports/types/index.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReport.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportCompany.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLine.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineAccount.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineCompany.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineContact.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineEmployee.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineProject.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineRequest.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineRequestAccount.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineRequestCompany.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineRequestContact.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineRequestEmployee.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineRequestProject.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportLineTaxRate.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportRequest.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportRequestCompany.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportRequestEmployee.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportResponse.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportStatus.ts create mode 100644 src/serialization/resources/accounting/types/ExpenseReportStatusEnum.ts create mode 100644 src/serialization/resources/accounting/types/ItemType.ts create mode 100644 src/serialization/resources/accounting/types/PaginatedExpenseReportLineList.ts create mode 100644 src/serialization/resources/accounting/types/PaginatedExpenseReportList.ts create mode 100644 tests/wire/accounting/expenseReports.test.ts diff --git a/.mock/definition/accounting/__package__.yml b/.mock/definition/accounting/__package__.yml index 8b5d4d048..3a198d776 100644 --- a/.mock/definition/accounting/__package__.yml +++ b/.mock/definition/accounting/__package__.yml @@ -20423,6 +20423,3055 @@ types: access: write-only source: openapi: openapi/openapi.yml + ExpenseReportStatus: + discriminated: false + docs: >- + Overall status of the expense report. One of DRAFT, SUBMITTED, APPROVED, + REJECTED + + + * `DRAFT` - DRAFT + + * `SUBMITTED` - SUBMITTED + + * `APPROVED` - APPROVED + + * `REJECTED` - REJECTED + union: + - ExpenseReportStatusEnum + - string + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportCompany: + discriminated: false + docs: The subsidiary that the expense report is created in + union: + - type: string + validation: + format: uuid + - CompanyInfo + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReport: + docs: >- + # The ExpenseReport Object + + ### Description + + The `ExpenseReport` object represents a collection of expenses submitted + for review and reimbursement. + + It includes details about the submitter, status, amounts, and associated + metadata. + + + ### Usage Example + + Fetch from the `GET ExpenseReport` endpoint to view details of expense + reports and their line items. + properties: + id: + type: optional + validation: + format: uuid + access: read-only + remote_id: + type: optional + docs: The third-party API ID of the matching object. + created_at: + type: optional + docs: The datetime that this object was created by Merge. + access: read-only + modified_at: + type: optional + docs: The datetime that this object was modified by Merge. + access: read-only + report_date: + type: optional + docs: The date of the expense report. + report_identifier: + type: optional + docs: Human-readable expense report identifier. + validation: + maxLength: 1024 + employee: + type: optional + docs: >- + Identifier for the employee who submitted or is associated with the + expense report + validation: + format: uuid + status: + type: optional + docs: >- + Overall status of the expense report. One of DRAFT, SUBMITTED, + APPROVED, REJECTED + + + * `DRAFT` - DRAFT + + * `SUBMITTED` - SUBMITTED + + * `APPROVED` - APPROVED + + * `REJECTED` - REJECTED + total_amount: + type: optional + docs: Total amount of the expense report + lines: + type: optional> + access: read-only + currency: + type: optional + docs: >- + Currency code for the expense report + + + * `XUA` - ADB Unit of Account + + * `AFN` - Afghan Afghani + + * `AFA` - Afghan Afghani (1927–2002) + + * `ALL` - Albanian Lek + + * `ALK` - Albanian Lek (1946–1965) + + * `DZD` - Algerian Dinar + + * `ADP` - Andorran Peseta + + * `AOA` - Angolan Kwanza + + * `AOK` - Angolan Kwanza (1977–1991) + + * `AON` - Angolan New Kwanza (1990–2000) + + * `AOR` - Angolan Readjusted Kwanza (1995–1999) + + * `ARA` - Argentine Austral + + * `ARS` - Argentine Peso + + * `ARM` - Argentine Peso (1881–1970) + + * `ARP` - Argentine Peso (1983–1985) + + * `ARL` - Argentine Peso Ley (1970–1983) + + * `AMD` - Armenian Dram + + * `AWG` - Aruban Florin + + * `AUD` - Australian Dollar + + * `ATS` - Austrian Schilling + + * `AZN` - Azerbaijani Manat + + * `AZM` - Azerbaijani Manat (1993–2006) + + * `BSD` - Bahamian Dollar + + * `BHD` - Bahraini Dinar + + * `BDT` - Bangladeshi Taka + + * `BBD` - Barbadian Dollar + + * `BYN` - Belarusian Ruble + + * `BYB` - Belarusian Ruble (1994–1999) + + * `BYR` - Belarusian Ruble (2000–2016) + + * `BEF` - Belgian Franc + + * `BEC` - Belgian Franc (convertible) + + * `BEL` - Belgian Franc (financial) + + * `BZD` - Belize Dollar + + * `BMD` - Bermudan Dollar + + * `BTN` - Bhutanese Ngultrum + + * `BOB` - Bolivian Boliviano + + * `BOL` - Bolivian Boliviano (1863–1963) + + * `BOV` - Bolivian Mvdol + + * `BOP` - Bolivian Peso + + * `BAM` - Bosnia-Herzegovina Convertible Mark + + * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + + * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + + * `BWP` - Botswanan Pula + + * `BRC` - Brazilian Cruzado (1986–1989) + + * `BRZ` - Brazilian Cruzeiro (1942–1967) + + * `BRE` - Brazilian Cruzeiro (1990–1993) + + * `BRR` - Brazilian Cruzeiro (1993–1994) + + * `BRN` - Brazilian New Cruzado (1989–1990) + + * `BRB` - Brazilian New Cruzeiro (1967–1986) + + * `BRL` - Brazilian Real + + * `GBP` - British Pound + + * `BND` - Brunei Dollar + + * `BGL` - Bulgarian Hard Lev + + * `BGN` - Bulgarian Lev + + * `BGO` - Bulgarian Lev (1879–1952) + + * `BGM` - Bulgarian Socialist Lev + + * `BUK` - Burmese Kyat + + * `BIF` - Burundian Franc + + * `XPF` - CFP Franc + + * `KHR` - Cambodian Riel + + * `CAD` - Canadian Dollar + + * `CVE` - Cape Verdean Escudo + + * `KYD` - Cayman Islands Dollar + + * `XAF` - Central African CFA Franc + + * `CLE` - Chilean Escudo + + * `CLP` - Chilean Peso + + * `CLF` - Chilean Unit of Account (UF) + + * `CNX` - Chinese People’s Bank Dollar + + * `CNY` - Chinese Yuan + + * `CNH` - Chinese Yuan (offshore) + + * `COP` - Colombian Peso + + * `COU` - Colombian Real Value Unit + + * `KMF` - Comorian Franc + + * `CDF` - Congolese Franc + + * `CRC` - Costa Rican Colón + + * `HRD` - Croatian Dinar + + * `HRK` - Croatian Kuna + + * `CUC` - Cuban Convertible Peso + + * `CUP` - Cuban Peso + + * `CYP` - Cypriot Pound + + * `CZK` - Czech Koruna + + * `CSK` - Czechoslovak Hard Koruna + + * `DKK` - Danish Krone + + * `DJF` - Djiboutian Franc + + * `DOP` - Dominican Peso + + * `NLG` - Dutch Guilder + + * `XCD` - East Caribbean Dollar + + * `DDM` - East German Mark + + * `ECS` - Ecuadorian Sucre + + * `ECV` - Ecuadorian Unit of Constant Value + + * `EGP` - Egyptian Pound + + * `GQE` - Equatorial Guinean Ekwele + + * `ERN` - Eritrean Nakfa + + * `EEK` - Estonian Kroon + + * `ETB` - Ethiopian Birr + + * `EUR` - Euro + + * `XBA` - European Composite Unit + + * `XEU` - European Currency Unit + + * `XBB` - European Monetary Unit + + * `XBC` - European Unit of Account (XBC) + + * `XBD` - European Unit of Account (XBD) + + * `FKP` - Falkland Islands Pound + + * `FJD` - Fijian Dollar + + * `FIM` - Finnish Markka + + * `FRF` - French Franc + + * `XFO` - French Gold Franc + + * `XFU` - French UIC-Franc + + * `GMD` - Gambian Dalasi + + * `GEK` - Georgian Kupon Larit + + * `GEL` - Georgian Lari + + * `DEM` - German Mark + + * `GHS` - Ghanaian Cedi + + * `GHC` - Ghanaian Cedi (1979–2007) + + * `GIP` - Gibraltar Pound + + * `XAU` - Gold + + * `GRD` - Greek Drachma + + * `GTQ` - Guatemalan Quetzal + + * `GWP` - Guinea-Bissau Peso + + * `GNF` - Guinean Franc + + * `GNS` - Guinean Syli + + * `GYD` - Guyanaese Dollar + + * `HTG` - Haitian Gourde + + * `HNL` - Honduran Lempira + + * `HKD` - Hong Kong Dollar + + * `HUF` - Hungarian Forint + + * `IMP` - IMP + + * `ISK` - Icelandic Króna + + * `ISJ` - Icelandic Króna (1918–1981) + + * `INR` - Indian Rupee + + * `IDR` - Indonesian Rupiah + + * `IRR` - Iranian Rial + + * `IQD` - Iraqi Dinar + + * `IEP` - Irish Pound + + * `ILS` - Israeli New Shekel + + * `ILP` - Israeli Pound + + * `ILR` - Israeli Shekel (1980–1985) + + * `ITL` - Italian Lira + + * `JMD` - Jamaican Dollar + + * `JPY` - Japanese Yen + + * `JOD` - Jordanian Dinar + + * `KZT` - Kazakhstani Tenge + + * `KES` - Kenyan Shilling + + * `KWD` - Kuwaiti Dinar + + * `KGS` - Kyrgystani Som + + * `LAK` - Laotian Kip + + * `LVL` - Latvian Lats + + * `LVR` - Latvian Ruble + + * `LBP` - Lebanese Pound + + * `LSL` - Lesotho Loti + + * `LRD` - Liberian Dollar + + * `LYD` - Libyan Dinar + + * `LTL` - Lithuanian Litas + + * `LTT` - Lithuanian Talonas + + * `LUL` - Luxembourg Financial Franc + + * `LUC` - Luxembourgian Convertible Franc + + * `LUF` - Luxembourgian Franc + + * `MOP` - Macanese Pataca + + * `MKD` - Macedonian Denar + + * `MKN` - Macedonian Denar (1992–1993) + + * `MGA` - Malagasy Ariary + + * `MGF` - Malagasy Franc + + * `MWK` - Malawian Kwacha + + * `MYR` - Malaysian Ringgit + + * `MVR` - Maldivian Rufiyaa + + * `MVP` - Maldivian Rupee (1947–1981) + + * `MLF` - Malian Franc + + * `MTL` - Maltese Lira + + * `MTP` - Maltese Pound + + * `MRU` - Mauritanian Ouguiya + + * `MRO` - Mauritanian Ouguiya (1973–2017) + + * `MUR` - Mauritian Rupee + + * `MXV` - Mexican Investment Unit + + * `MXN` - Mexican Peso + + * `MXP` - Mexican Silver Peso (1861–1992) + + * `MDC` - Moldovan Cupon + + * `MDL` - Moldovan Leu + + * `MCF` - Monegasque Franc + + * `MNT` - Mongolian Tugrik + + * `MAD` - Moroccan Dirham + + * `MAF` - Moroccan Franc + + * `MZE` - Mozambican Escudo + + * `MZN` - Mozambican Metical + + * `MZM` - Mozambican Metical (1980–2006) + + * `MMK` - Myanmar Kyat + + * `NAD` - Namibian Dollar + + * `NPR` - Nepalese Rupee + + * `ANG` - Netherlands Antillean Guilder + + * `TWD` - New Taiwan Dollar + + * `NZD` - New Zealand Dollar + + * `NIO` - Nicaraguan Córdoba + + * `NIC` - Nicaraguan Córdoba (1988–1991) + + * `NGN` - Nigerian Naira + + * `KPW` - North Korean Won + + * `NOK` - Norwegian Krone + + * `OMR` - Omani Rial + + * `PKR` - Pakistani Rupee + + * `XPD` - Palladium + + * `PAB` - Panamanian Balboa + + * `PGK` - Papua New Guinean Kina + + * `PYG` - Paraguayan Guarani + + * `PEI` - Peruvian Inti + + * `PEN` - Peruvian Sol + + * `PES` - Peruvian Sol (1863–1965) + + * `PHP` - Philippine Peso + + * `XPT` - Platinum + + * `PLN` - Polish Zloty + + * `PLZ` - Polish Zloty (1950–1995) + + * `PTE` - Portuguese Escudo + + * `GWE` - Portuguese Guinea Escudo + + * `QAR` - Qatari Rial + + * `XRE` - RINET Funds + + * `RHD` - Rhodesian Dollar + + * `RON` - Romanian Leu + + * `ROL` - Romanian Leu (1952–2006) + + * `RUB` - Russian Ruble + + * `RUR` - Russian Ruble (1991–1998) + + * `RWF` - Rwandan Franc + + * `SVC` - Salvadoran Colón + + * `WST` - Samoan Tala + + * `SAR` - Saudi Riyal + + * `RSD` - Serbian Dinar + + * `CSD` - Serbian Dinar (2002–2006) + + * `SCR` - Seychellois Rupee + + * `SLL` - Sierra Leonean Leone + + * `XAG` - Silver + + * `SGD` - Singapore Dollar + + * `SKK` - Slovak Koruna + + * `SIT` - Slovenian Tolar + + * `SBD` - Solomon Islands Dollar + + * `SOS` - Somali Shilling + + * `ZAR` - South African Rand + + * `ZAL` - South African Rand (financial) + + * `KRH` - South Korean Hwan (1953–1962) + + * `KRW` - South Korean Won + + * `KRO` - South Korean Won (1945–1953) + + * `SSP` - South Sudanese Pound + + * `SUR` - Soviet Rouble + + * `ESP` - Spanish Peseta + + * `ESA` - Spanish Peseta (A account) + + * `ESB` - Spanish Peseta (convertible account) + + * `XDR` - Special Drawing Rights + + * `LKR` - Sri Lankan Rupee + + * `SHP` - St. Helena Pound + + * `XSU` - Sucre + + * `SDD` - Sudanese Dinar (1992–2007) + + * `SDG` - Sudanese Pound + + * `SDP` - Sudanese Pound (1957–1998) + + * `SRD` - Surinamese Dollar + + * `SRG` - Surinamese Guilder + + * `SZL` - Swazi Lilangeni + + * `SEK` - Swedish Krona + + * `CHF` - Swiss Franc + + * `SYP` - Syrian Pound + + * `STN` - São Tomé & Príncipe Dobra + + * `STD` - São Tomé & Príncipe Dobra (1977–2017) + + * `TVD` - TVD + + * `TJR` - Tajikistani Ruble + + * `TJS` - Tajikistani Somoni + + * `TZS` - Tanzanian Shilling + + * `XTS` - Testing Currency Code + + * `THB` - Thai Baht + + * `XXX` - The codes assigned for transactions where no currency is + involved + + * `TPE` - Timorese Escudo + + * `TOP` - Tongan Paʻanga + + * `TTD` - Trinidad & Tobago Dollar + + * `TND` - Tunisian Dinar + + * `TRY` - Turkish Lira + + * `TRL` - Turkish Lira (1922–2005) + + * `TMT` - Turkmenistani Manat + + * `TMM` - Turkmenistani Manat (1993–2009) + + * `USD` - US Dollar + + * `USN` - US Dollar (Next day) + + * `USS` - US Dollar (Same day) + + * `UGX` - Ugandan Shilling + + * `UGS` - Ugandan Shilling (1966–1987) + + * `UAH` - Ukrainian Hryvnia + + * `UAK` - Ukrainian Karbovanets + + * `AED` - United Arab Emirates Dirham + + * `UYW` - Uruguayan Nominal Wage Index Unit + + * `UYU` - Uruguayan Peso + + * `UYP` - Uruguayan Peso (1975–1993) + + * `UYI` - Uruguayan Peso (Indexed Units) + + * `UZS` - Uzbekistani Som + + * `VUV` - Vanuatu Vatu + + * `VES` - Venezuelan Bolívar + + * `VEB` - Venezuelan Bolívar (1871–2008) + + * `VEF` - Venezuelan Bolívar (2008–2018) + + * `VND` - Vietnamese Dong + + * `VNN` - Vietnamese Dong (1978–1985) + + * `CHE` - WIR Euro + + * `CHW` - WIR Franc + + * `XOF` - West African CFA Franc + + * `YDD` - Yemeni Dinar + + * `YER` - Yemeni Rial + + * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + + * `YUD` - Yugoslavian Hard Dinar (1966–1990) + + * `YUM` - Yugoslavian New Dinar (1994–2002) + + * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + + * `ZWN` - ZWN + + * `ZRN` - Zairean New Zaire (1993–1998) + + * `ZRZ` - Zairean Zaire (1971–1993) + + * `ZMW` - Zambian Kwacha + + * `ZMK` - Zambian Kwacha (1968–2012) + + * `ZWD` - Zimbabwean Dollar (1980–2008) + + * `ZWR` - Zimbabwean Dollar (2008) + + * `ZWL` - Zimbabwean Dollar (2009) + description: + type: optional + docs: A brief description or purpose for the expense report + validation: + maxLength: 1024 + accounting_period: + type: optional + docs: The accounting period the report was posted in + validation: + format: uuid + company: + type: optional + docs: The subsidiary that the expense report is created in + tracking_categories: + docs: The related tracking categories associated with the expense report + type: list + remote_was_deleted: + type: optional + docs: >- + Indicates whether or not this object has been deleted in the third + party platform. Full coverage deletion detection is a premium add-on. + Native deletion detection is offered for free with limited coverage. + [Learn + more](https://docs.merge.dev/integrations/hris/supported-features/). + access: read-only + field_mappings: + type: optional> + access: read-only + remote_data: + type: optional> + access: read-only + remote_fields: + type: optional> + access: read-only + source: + openapi: openapi/openapi.yml + ExpenseReportLineAccount: + discriminated: false + union: + - type: string + validation: + format: uuid + - Account + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineEmployee: + discriminated: false + docs: >- + Identifier for the employee who submitted or is associated with the + expense report + union: + - type: string + validation: + format: uuid + - Employee + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineProject: + discriminated: false + union: + - type: string + validation: + format: uuid + - Project + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineCompany: + discriminated: false + docs: The subsidiary that the expense report is created in + union: + - type: string + validation: + format: uuid + - CompanyInfo + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineContact: + discriminated: false + union: + - type: string + validation: + format: uuid + - Contact + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineTaxRate: + discriminated: false + union: + - type: string + validation: + format: uuid + - TaxRate + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLine: + docs: >- + # The ExpenseReportLine Object + + ### Description + + The `ExpenseReportLine` object represents an individual line item within + an expense report, containing details about + + a specific expense such as amount, description, and associated metadata. + + + ### Usage Example + + Fetch from the `GET ExpenseReport` endpoint and expand the lines field to + view all line items in the expense report. + properties: + id: + type: optional + validation: + format: uuid + access: read-only + remote_id: + type: optional + docs: The third-party API ID of the matching object. + created_at: + type: optional + docs: The datetime that this object was created by Merge. + access: read-only + modified_at: + type: optional + docs: The datetime that this object was modified by Merge. + access: read-only + account: optional + description: + type: optional + docs: Description of the individual expense. + validation: + maxLength: 1024 + expense_date: + type: optional + docs: The date the individual expense was incurred. + amount: + type: optional + docs: The amount of the expense for the line item. + currency: + type: optional + docs: >- + Currency of the expense line (if different from the report currency). + + + * `XUA` - ADB Unit of Account + + * `AFN` - Afghan Afghani + + * `AFA` - Afghan Afghani (1927–2002) + + * `ALL` - Albanian Lek + + * `ALK` - Albanian Lek (1946–1965) + + * `DZD` - Algerian Dinar + + * `ADP` - Andorran Peseta + + * `AOA` - Angolan Kwanza + + * `AOK` - Angolan Kwanza (1977–1991) + + * `AON` - Angolan New Kwanza (1990–2000) + + * `AOR` - Angolan Readjusted Kwanza (1995–1999) + + * `ARA` - Argentine Austral + + * `ARS` - Argentine Peso + + * `ARM` - Argentine Peso (1881–1970) + + * `ARP` - Argentine Peso (1983–1985) + + * `ARL` - Argentine Peso Ley (1970–1983) + + * `AMD` - Armenian Dram + + * `AWG` - Aruban Florin + + * `AUD` - Australian Dollar + + * `ATS` - Austrian Schilling + + * `AZN` - Azerbaijani Manat + + * `AZM` - Azerbaijani Manat (1993–2006) + + * `BSD` - Bahamian Dollar + + * `BHD` - Bahraini Dinar + + * `BDT` - Bangladeshi Taka + + * `BBD` - Barbadian Dollar + + * `BYN` - Belarusian Ruble + + * `BYB` - Belarusian Ruble (1994–1999) + + * `BYR` - Belarusian Ruble (2000–2016) + + * `BEF` - Belgian Franc + + * `BEC` - Belgian Franc (convertible) + + * `BEL` - Belgian Franc (financial) + + * `BZD` - Belize Dollar + + * `BMD` - Bermudan Dollar + + * `BTN` - Bhutanese Ngultrum + + * `BOB` - Bolivian Boliviano + + * `BOL` - Bolivian Boliviano (1863–1963) + + * `BOV` - Bolivian Mvdol + + * `BOP` - Bolivian Peso + + * `BAM` - Bosnia-Herzegovina Convertible Mark + + * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + + * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + + * `BWP` - Botswanan Pula + + * `BRC` - Brazilian Cruzado (1986–1989) + + * `BRZ` - Brazilian Cruzeiro (1942–1967) + + * `BRE` - Brazilian Cruzeiro (1990–1993) + + * `BRR` - Brazilian Cruzeiro (1993–1994) + + * `BRN` - Brazilian New Cruzado (1989–1990) + + * `BRB` - Brazilian New Cruzeiro (1967–1986) + + * `BRL` - Brazilian Real + + * `GBP` - British Pound + + * `BND` - Brunei Dollar + + * `BGL` - Bulgarian Hard Lev + + * `BGN` - Bulgarian Lev + + * `BGO` - Bulgarian Lev (1879–1952) + + * `BGM` - Bulgarian Socialist Lev + + * `BUK` - Burmese Kyat + + * `BIF` - Burundian Franc + + * `XPF` - CFP Franc + + * `KHR` - Cambodian Riel + + * `CAD` - Canadian Dollar + + * `CVE` - Cape Verdean Escudo + + * `KYD` - Cayman Islands Dollar + + * `XAF` - Central African CFA Franc + + * `CLE` - Chilean Escudo + + * `CLP` - Chilean Peso + + * `CLF` - Chilean Unit of Account (UF) + + * `CNX` - Chinese People’s Bank Dollar + + * `CNY` - Chinese Yuan + + * `CNH` - Chinese Yuan (offshore) + + * `COP` - Colombian Peso + + * `COU` - Colombian Real Value Unit + + * `KMF` - Comorian Franc + + * `CDF` - Congolese Franc + + * `CRC` - Costa Rican Colón + + * `HRD` - Croatian Dinar + + * `HRK` - Croatian Kuna + + * `CUC` - Cuban Convertible Peso + + * `CUP` - Cuban Peso + + * `CYP` - Cypriot Pound + + * `CZK` - Czech Koruna + + * `CSK` - Czechoslovak Hard Koruna + + * `DKK` - Danish Krone + + * `DJF` - Djiboutian Franc + + * `DOP` - Dominican Peso + + * `NLG` - Dutch Guilder + + * `XCD` - East Caribbean Dollar + + * `DDM` - East German Mark + + * `ECS` - Ecuadorian Sucre + + * `ECV` - Ecuadorian Unit of Constant Value + + * `EGP` - Egyptian Pound + + * `GQE` - Equatorial Guinean Ekwele + + * `ERN` - Eritrean Nakfa + + * `EEK` - Estonian Kroon + + * `ETB` - Ethiopian Birr + + * `EUR` - Euro + + * `XBA` - European Composite Unit + + * `XEU` - European Currency Unit + + * `XBB` - European Monetary Unit + + * `XBC` - European Unit of Account (XBC) + + * `XBD` - European Unit of Account (XBD) + + * `FKP` - Falkland Islands Pound + + * `FJD` - Fijian Dollar + + * `FIM` - Finnish Markka + + * `FRF` - French Franc + + * `XFO` - French Gold Franc + + * `XFU` - French UIC-Franc + + * `GMD` - Gambian Dalasi + + * `GEK` - Georgian Kupon Larit + + * `GEL` - Georgian Lari + + * `DEM` - German Mark + + * `GHS` - Ghanaian Cedi + + * `GHC` - Ghanaian Cedi (1979–2007) + + * `GIP` - Gibraltar Pound + + * `XAU` - Gold + + * `GRD` - Greek Drachma + + * `GTQ` - Guatemalan Quetzal + + * `GWP` - Guinea-Bissau Peso + + * `GNF` - Guinean Franc + + * `GNS` - Guinean Syli + + * `GYD` - Guyanaese Dollar + + * `HTG` - Haitian Gourde + + * `HNL` - Honduran Lempira + + * `HKD` - Hong Kong Dollar + + * `HUF` - Hungarian Forint + + * `IMP` - IMP + + * `ISK` - Icelandic Króna + + * `ISJ` - Icelandic Króna (1918–1981) + + * `INR` - Indian Rupee + + * `IDR` - Indonesian Rupiah + + * `IRR` - Iranian Rial + + * `IQD` - Iraqi Dinar + + * `IEP` - Irish Pound + + * `ILS` - Israeli New Shekel + + * `ILP` - Israeli Pound + + * `ILR` - Israeli Shekel (1980–1985) + + * `ITL` - Italian Lira + + * `JMD` - Jamaican Dollar + + * `JPY` - Japanese Yen + + * `JOD` - Jordanian Dinar + + * `KZT` - Kazakhstani Tenge + + * `KES` - Kenyan Shilling + + * `KWD` - Kuwaiti Dinar + + * `KGS` - Kyrgystani Som + + * `LAK` - Laotian Kip + + * `LVL` - Latvian Lats + + * `LVR` - Latvian Ruble + + * `LBP` - Lebanese Pound + + * `LSL` - Lesotho Loti + + * `LRD` - Liberian Dollar + + * `LYD` - Libyan Dinar + + * `LTL` - Lithuanian Litas + + * `LTT` - Lithuanian Talonas + + * `LUL` - Luxembourg Financial Franc + + * `LUC` - Luxembourgian Convertible Franc + + * `LUF` - Luxembourgian Franc + + * `MOP` - Macanese Pataca + + * `MKD` - Macedonian Denar + + * `MKN` - Macedonian Denar (1992–1993) + + * `MGA` - Malagasy Ariary + + * `MGF` - Malagasy Franc + + * `MWK` - Malawian Kwacha + + * `MYR` - Malaysian Ringgit + + * `MVR` - Maldivian Rufiyaa + + * `MVP` - Maldivian Rupee (1947–1981) + + * `MLF` - Malian Franc + + * `MTL` - Maltese Lira + + * `MTP` - Maltese Pound + + * `MRU` - Mauritanian Ouguiya + + * `MRO` - Mauritanian Ouguiya (1973–2017) + + * `MUR` - Mauritian Rupee + + * `MXV` - Mexican Investment Unit + + * `MXN` - Mexican Peso + + * `MXP` - Mexican Silver Peso (1861–1992) + + * `MDC` - Moldovan Cupon + + * `MDL` - Moldovan Leu + + * `MCF` - Monegasque Franc + + * `MNT` - Mongolian Tugrik + + * `MAD` - Moroccan Dirham + + * `MAF` - Moroccan Franc + + * `MZE` - Mozambican Escudo + + * `MZN` - Mozambican Metical + + * `MZM` - Mozambican Metical (1980–2006) + + * `MMK` - Myanmar Kyat + + * `NAD` - Namibian Dollar + + * `NPR` - Nepalese Rupee + + * `ANG` - Netherlands Antillean Guilder + + * `TWD` - New Taiwan Dollar + + * `NZD` - New Zealand Dollar + + * `NIO` - Nicaraguan Córdoba + + * `NIC` - Nicaraguan Córdoba (1988–1991) + + * `NGN` - Nigerian Naira + + * `KPW` - North Korean Won + + * `NOK` - Norwegian Krone + + * `OMR` - Omani Rial + + * `PKR` - Pakistani Rupee + + * `XPD` - Palladium + + * `PAB` - Panamanian Balboa + + * `PGK` - Papua New Guinean Kina + + * `PYG` - Paraguayan Guarani + + * `PEI` - Peruvian Inti + + * `PEN` - Peruvian Sol + + * `PES` - Peruvian Sol (1863–1965) + + * `PHP` - Philippine Peso + + * `XPT` - Platinum + + * `PLN` - Polish Zloty + + * `PLZ` - Polish Zloty (1950–1995) + + * `PTE` - Portuguese Escudo + + * `GWE` - Portuguese Guinea Escudo + + * `QAR` - Qatari Rial + + * `XRE` - RINET Funds + + * `RHD` - Rhodesian Dollar + + * `RON` - Romanian Leu + + * `ROL` - Romanian Leu (1952–2006) + + * `RUB` - Russian Ruble + + * `RUR` - Russian Ruble (1991–1998) + + * `RWF` - Rwandan Franc + + * `SVC` - Salvadoran Colón + + * `WST` - Samoan Tala + + * `SAR` - Saudi Riyal + + * `RSD` - Serbian Dinar + + * `CSD` - Serbian Dinar (2002–2006) + + * `SCR` - Seychellois Rupee + + * `SLL` - Sierra Leonean Leone + + * `XAG` - Silver + + * `SGD` - Singapore Dollar + + * `SKK` - Slovak Koruna + + * `SIT` - Slovenian Tolar + + * `SBD` - Solomon Islands Dollar + + * `SOS` - Somali Shilling + + * `ZAR` - South African Rand + + * `ZAL` - South African Rand (financial) + + * `KRH` - South Korean Hwan (1953–1962) + + * `KRW` - South Korean Won + + * `KRO` - South Korean Won (1945–1953) + + * `SSP` - South Sudanese Pound + + * `SUR` - Soviet Rouble + + * `ESP` - Spanish Peseta + + * `ESA` - Spanish Peseta (A account) + + * `ESB` - Spanish Peseta (convertible account) + + * `XDR` - Special Drawing Rights + + * `LKR` - Sri Lankan Rupee + + * `SHP` - St. Helena Pound + + * `XSU` - Sucre + + * `SDD` - Sudanese Dinar (1992–2007) + + * `SDG` - Sudanese Pound + + * `SDP` - Sudanese Pound (1957–1998) + + * `SRD` - Surinamese Dollar + + * `SRG` - Surinamese Guilder + + * `SZL` - Swazi Lilangeni + + * `SEK` - Swedish Krona + + * `CHF` - Swiss Franc + + * `SYP` - Syrian Pound + + * `STN` - São Tomé & Príncipe Dobra + + * `STD` - São Tomé & Príncipe Dobra (1977–2017) + + * `TVD` - TVD + + * `TJR` - Tajikistani Ruble + + * `TJS` - Tajikistani Somoni + + * `TZS` - Tanzanian Shilling + + * `XTS` - Testing Currency Code + + * `THB` - Thai Baht + + * `XXX` - The codes assigned for transactions where no currency is + involved + + * `TPE` - Timorese Escudo + + * `TOP` - Tongan Paʻanga + + * `TTD` - Trinidad & Tobago Dollar + + * `TND` - Tunisian Dinar + + * `TRY` - Turkish Lira + + * `TRL` - Turkish Lira (1922–2005) + + * `TMT` - Turkmenistani Manat + + * `TMM` - Turkmenistani Manat (1993–2009) + + * `USD` - US Dollar + + * `USN` - US Dollar (Next day) + + * `USS` - US Dollar (Same day) + + * `UGX` - Ugandan Shilling + + * `UGS` - Ugandan Shilling (1966–1987) + + * `UAH` - Ukrainian Hryvnia + + * `UAK` - Ukrainian Karbovanets + + * `AED` - United Arab Emirates Dirham + + * `UYW` - Uruguayan Nominal Wage Index Unit + + * `UYU` - Uruguayan Peso + + * `UYP` - Uruguayan Peso (1975–1993) + + * `UYI` - Uruguayan Peso (Indexed Units) + + * `UZS` - Uzbekistani Som + + * `VUV` - Vanuatu Vatu + + * `VES` - Venezuelan Bolívar + + * `VEB` - Venezuelan Bolívar (1871–2008) + + * `VEF` - Venezuelan Bolívar (2008–2018) + + * `VND` - Vietnamese Dong + + * `VNN` - Vietnamese Dong (1978–1985) + + * `CHE` - WIR Euro + + * `CHW` - WIR Franc + + * `XOF` - West African CFA Franc + + * `YDD` - Yemeni Dinar + + * `YER` - Yemeni Rial + + * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + + * `YUD` - Yugoslavian Hard Dinar (1966–1990) + + * `YUM` - Yugoslavian New Dinar (1994–2002) + + * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + + * `ZWN` - ZWN + + * `ZRN` - Zairean New Zaire (1993–1998) + + * `ZRZ` - Zairean Zaire (1971–1993) + + * `ZMW` - Zambian Kwacha + + * `ZMK` - Zambian Kwacha (1968–2012) + + * `ZWD` - Zimbabwean Dollar (1980–2008) + + * `ZWR` - Zimbabwean Dollar (2008) + + * `ZWL` - Zimbabwean Dollar (2009) + exchange_rate: + type: optional + docs: Exchange rate used if the line item is in a foreign currency. + validation: + pattern: ^-?\d{0,32}(?:\.\d{0,16})?$ + is_billable: + type: optional + docs: Whether the expense line is billable to a client or project. + tracking_categories: + docs: >- + The related tracking categories associated with the expense report + (Department, Location, Class, Expense Category) + type: list + employee: + type: optional + docs: >- + Identifier for the employee who submitted or is associated with the + expense report + project: optional + company: + type: optional + docs: The subsidiary that the expense report is created in + contact: optional + quantity: + type: optional + docs: Quantity for the expense line (e.g., miles driven, items purchased). + unit_price: + type: optional + docs: Price per unit for the expense line (if applicable). + non_reimbursable: + type: optional + docs: >- + Whether the expense line is non-reimbursable (e.g., paid via company + card). + tax_amount: + type: optional + docs: Tax amount applicable for the line item. + inclusive_of_tax: + type: optional + docs: Whether the amount is inclusive of tax. + tax_rate: optional + remote_was_deleted: + type: optional + docs: >- + Indicates whether or not this object has been deleted in the third + party platform. Full coverage deletion detection is a premium add-on. + Native deletion detection is offered for free with limited coverage. + [Learn + more](https://docs.merge.dev/integrations/hris/supported-features/). + access: read-only + remote_fields: + type: optional> + access: read-only + source: + openapi: openapi/openapi.yml + ExpenseReportLineRequestAccount: + discriminated: false + union: + - type: string + validation: + format: uuid + - Account + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineRequestEmployee: + discriminated: false + docs: >- + Identifier for the employee who submitted or is associated with the + expense report + union: + - type: string + validation: + format: uuid + - Employee + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineRequestProject: + discriminated: false + union: + - type: string + validation: + format: uuid + - Project + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineRequestCompany: + discriminated: false + docs: The subsidiary that the expense report is created in + union: + - type: string + validation: + format: uuid + - CompanyInfo + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineRequestContact: + discriminated: false + union: + - type: string + validation: + format: uuid + - Contact + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineRequestTaxRate: + discriminated: false + union: + - type: string + validation: + format: uuid + - TaxRate + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportLineRequest: + docs: >- + # The ExpenseReportLine Object + + ### Description + + The `ExpenseReportLine` object represents an individual line item within + an expense report, containing details about + + a specific expense such as amount, description, and associated metadata. + + + ### Usage Example + + Fetch from the `GET ExpenseReport` endpoint and expand the lines field to + view all line items in the expense report. + properties: + remote_id: + type: optional + docs: The third-party API ID of the matching object. + account: optional + description: + type: optional + docs: Description of the individual expense. + validation: + maxLength: 1024 + expense_date: + type: optional + docs: The date the individual expense was incurred. + amount: + type: optional + docs: The amount of the expense for the line item. + currency: + type: optional + docs: >- + Currency of the expense line (if different from the report currency). + + + * `XUA` - ADB Unit of Account + + * `AFN` - Afghan Afghani + + * `AFA` - Afghan Afghani (1927–2002) + + * `ALL` - Albanian Lek + + * `ALK` - Albanian Lek (1946–1965) + + * `DZD` - Algerian Dinar + + * `ADP` - Andorran Peseta + + * `AOA` - Angolan Kwanza + + * `AOK` - Angolan Kwanza (1977–1991) + + * `AON` - Angolan New Kwanza (1990–2000) + + * `AOR` - Angolan Readjusted Kwanza (1995–1999) + + * `ARA` - Argentine Austral + + * `ARS` - Argentine Peso + + * `ARM` - Argentine Peso (1881–1970) + + * `ARP` - Argentine Peso (1983–1985) + + * `ARL` - Argentine Peso Ley (1970–1983) + + * `AMD` - Armenian Dram + + * `AWG` - Aruban Florin + + * `AUD` - Australian Dollar + + * `ATS` - Austrian Schilling + + * `AZN` - Azerbaijani Manat + + * `AZM` - Azerbaijani Manat (1993–2006) + + * `BSD` - Bahamian Dollar + + * `BHD` - Bahraini Dinar + + * `BDT` - Bangladeshi Taka + + * `BBD` - Barbadian Dollar + + * `BYN` - Belarusian Ruble + + * `BYB` - Belarusian Ruble (1994–1999) + + * `BYR` - Belarusian Ruble (2000–2016) + + * `BEF` - Belgian Franc + + * `BEC` - Belgian Franc (convertible) + + * `BEL` - Belgian Franc (financial) + + * `BZD` - Belize Dollar + + * `BMD` - Bermudan Dollar + + * `BTN` - Bhutanese Ngultrum + + * `BOB` - Bolivian Boliviano + + * `BOL` - Bolivian Boliviano (1863–1963) + + * `BOV` - Bolivian Mvdol + + * `BOP` - Bolivian Peso + + * `BAM` - Bosnia-Herzegovina Convertible Mark + + * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + + * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + + * `BWP` - Botswanan Pula + + * `BRC` - Brazilian Cruzado (1986–1989) + + * `BRZ` - Brazilian Cruzeiro (1942–1967) + + * `BRE` - Brazilian Cruzeiro (1990–1993) + + * `BRR` - Brazilian Cruzeiro (1993–1994) + + * `BRN` - Brazilian New Cruzado (1989–1990) + + * `BRB` - Brazilian New Cruzeiro (1967–1986) + + * `BRL` - Brazilian Real + + * `GBP` - British Pound + + * `BND` - Brunei Dollar + + * `BGL` - Bulgarian Hard Lev + + * `BGN` - Bulgarian Lev + + * `BGO` - Bulgarian Lev (1879–1952) + + * `BGM` - Bulgarian Socialist Lev + + * `BUK` - Burmese Kyat + + * `BIF` - Burundian Franc + + * `XPF` - CFP Franc + + * `KHR` - Cambodian Riel + + * `CAD` - Canadian Dollar + + * `CVE` - Cape Verdean Escudo + + * `KYD` - Cayman Islands Dollar + + * `XAF` - Central African CFA Franc + + * `CLE` - Chilean Escudo + + * `CLP` - Chilean Peso + + * `CLF` - Chilean Unit of Account (UF) + + * `CNX` - Chinese People’s Bank Dollar + + * `CNY` - Chinese Yuan + + * `CNH` - Chinese Yuan (offshore) + + * `COP` - Colombian Peso + + * `COU` - Colombian Real Value Unit + + * `KMF` - Comorian Franc + + * `CDF` - Congolese Franc + + * `CRC` - Costa Rican Colón + + * `HRD` - Croatian Dinar + + * `HRK` - Croatian Kuna + + * `CUC` - Cuban Convertible Peso + + * `CUP` - Cuban Peso + + * `CYP` - Cypriot Pound + + * `CZK` - Czech Koruna + + * `CSK` - Czechoslovak Hard Koruna + + * `DKK` - Danish Krone + + * `DJF` - Djiboutian Franc + + * `DOP` - Dominican Peso + + * `NLG` - Dutch Guilder + + * `XCD` - East Caribbean Dollar + + * `DDM` - East German Mark + + * `ECS` - Ecuadorian Sucre + + * `ECV` - Ecuadorian Unit of Constant Value + + * `EGP` - Egyptian Pound + + * `GQE` - Equatorial Guinean Ekwele + + * `ERN` - Eritrean Nakfa + + * `EEK` - Estonian Kroon + + * `ETB` - Ethiopian Birr + + * `EUR` - Euro + + * `XBA` - European Composite Unit + + * `XEU` - European Currency Unit + + * `XBB` - European Monetary Unit + + * `XBC` - European Unit of Account (XBC) + + * `XBD` - European Unit of Account (XBD) + + * `FKP` - Falkland Islands Pound + + * `FJD` - Fijian Dollar + + * `FIM` - Finnish Markka + + * `FRF` - French Franc + + * `XFO` - French Gold Franc + + * `XFU` - French UIC-Franc + + * `GMD` - Gambian Dalasi + + * `GEK` - Georgian Kupon Larit + + * `GEL` - Georgian Lari + + * `DEM` - German Mark + + * `GHS` - Ghanaian Cedi + + * `GHC` - Ghanaian Cedi (1979–2007) + + * `GIP` - Gibraltar Pound + + * `XAU` - Gold + + * `GRD` - Greek Drachma + + * `GTQ` - Guatemalan Quetzal + + * `GWP` - Guinea-Bissau Peso + + * `GNF` - Guinean Franc + + * `GNS` - Guinean Syli + + * `GYD` - Guyanaese Dollar + + * `HTG` - Haitian Gourde + + * `HNL` - Honduran Lempira + + * `HKD` - Hong Kong Dollar + + * `HUF` - Hungarian Forint + + * `IMP` - IMP + + * `ISK` - Icelandic Króna + + * `ISJ` - Icelandic Króna (1918–1981) + + * `INR` - Indian Rupee + + * `IDR` - Indonesian Rupiah + + * `IRR` - Iranian Rial + + * `IQD` - Iraqi Dinar + + * `IEP` - Irish Pound + + * `ILS` - Israeli New Shekel + + * `ILP` - Israeli Pound + + * `ILR` - Israeli Shekel (1980–1985) + + * `ITL` - Italian Lira + + * `JMD` - Jamaican Dollar + + * `JPY` - Japanese Yen + + * `JOD` - Jordanian Dinar + + * `KZT` - Kazakhstani Tenge + + * `KES` - Kenyan Shilling + + * `KWD` - Kuwaiti Dinar + + * `KGS` - Kyrgystani Som + + * `LAK` - Laotian Kip + + * `LVL` - Latvian Lats + + * `LVR` - Latvian Ruble + + * `LBP` - Lebanese Pound + + * `LSL` - Lesotho Loti + + * `LRD` - Liberian Dollar + + * `LYD` - Libyan Dinar + + * `LTL` - Lithuanian Litas + + * `LTT` - Lithuanian Talonas + + * `LUL` - Luxembourg Financial Franc + + * `LUC` - Luxembourgian Convertible Franc + + * `LUF` - Luxembourgian Franc + + * `MOP` - Macanese Pataca + + * `MKD` - Macedonian Denar + + * `MKN` - Macedonian Denar (1992–1993) + + * `MGA` - Malagasy Ariary + + * `MGF` - Malagasy Franc + + * `MWK` - Malawian Kwacha + + * `MYR` - Malaysian Ringgit + + * `MVR` - Maldivian Rufiyaa + + * `MVP` - Maldivian Rupee (1947–1981) + + * `MLF` - Malian Franc + + * `MTL` - Maltese Lira + + * `MTP` - Maltese Pound + + * `MRU` - Mauritanian Ouguiya + + * `MRO` - Mauritanian Ouguiya (1973–2017) + + * `MUR` - Mauritian Rupee + + * `MXV` - Mexican Investment Unit + + * `MXN` - Mexican Peso + + * `MXP` - Mexican Silver Peso (1861–1992) + + * `MDC` - Moldovan Cupon + + * `MDL` - Moldovan Leu + + * `MCF` - Monegasque Franc + + * `MNT` - Mongolian Tugrik + + * `MAD` - Moroccan Dirham + + * `MAF` - Moroccan Franc + + * `MZE` - Mozambican Escudo + + * `MZN` - Mozambican Metical + + * `MZM` - Mozambican Metical (1980–2006) + + * `MMK` - Myanmar Kyat + + * `NAD` - Namibian Dollar + + * `NPR` - Nepalese Rupee + + * `ANG` - Netherlands Antillean Guilder + + * `TWD` - New Taiwan Dollar + + * `NZD` - New Zealand Dollar + + * `NIO` - Nicaraguan Córdoba + + * `NIC` - Nicaraguan Córdoba (1988–1991) + + * `NGN` - Nigerian Naira + + * `KPW` - North Korean Won + + * `NOK` - Norwegian Krone + + * `OMR` - Omani Rial + + * `PKR` - Pakistani Rupee + + * `XPD` - Palladium + + * `PAB` - Panamanian Balboa + + * `PGK` - Papua New Guinean Kina + + * `PYG` - Paraguayan Guarani + + * `PEI` - Peruvian Inti + + * `PEN` - Peruvian Sol + + * `PES` - Peruvian Sol (1863–1965) + + * `PHP` - Philippine Peso + + * `XPT` - Platinum + + * `PLN` - Polish Zloty + + * `PLZ` - Polish Zloty (1950–1995) + + * `PTE` - Portuguese Escudo + + * `GWE` - Portuguese Guinea Escudo + + * `QAR` - Qatari Rial + + * `XRE` - RINET Funds + + * `RHD` - Rhodesian Dollar + + * `RON` - Romanian Leu + + * `ROL` - Romanian Leu (1952–2006) + + * `RUB` - Russian Ruble + + * `RUR` - Russian Ruble (1991–1998) + + * `RWF` - Rwandan Franc + + * `SVC` - Salvadoran Colón + + * `WST` - Samoan Tala + + * `SAR` - Saudi Riyal + + * `RSD` - Serbian Dinar + + * `CSD` - Serbian Dinar (2002–2006) + + * `SCR` - Seychellois Rupee + + * `SLL` - Sierra Leonean Leone + + * `XAG` - Silver + + * `SGD` - Singapore Dollar + + * `SKK` - Slovak Koruna + + * `SIT` - Slovenian Tolar + + * `SBD` - Solomon Islands Dollar + + * `SOS` - Somali Shilling + + * `ZAR` - South African Rand + + * `ZAL` - South African Rand (financial) + + * `KRH` - South Korean Hwan (1953–1962) + + * `KRW` - South Korean Won + + * `KRO` - South Korean Won (1945–1953) + + * `SSP` - South Sudanese Pound + + * `SUR` - Soviet Rouble + + * `ESP` - Spanish Peseta + + * `ESA` - Spanish Peseta (A account) + + * `ESB` - Spanish Peseta (convertible account) + + * `XDR` - Special Drawing Rights + + * `LKR` - Sri Lankan Rupee + + * `SHP` - St. Helena Pound + + * `XSU` - Sucre + + * `SDD` - Sudanese Dinar (1992–2007) + + * `SDG` - Sudanese Pound + + * `SDP` - Sudanese Pound (1957–1998) + + * `SRD` - Surinamese Dollar + + * `SRG` - Surinamese Guilder + + * `SZL` - Swazi Lilangeni + + * `SEK` - Swedish Krona + + * `CHF` - Swiss Franc + + * `SYP` - Syrian Pound + + * `STN` - São Tomé & Príncipe Dobra + + * `STD` - São Tomé & Príncipe Dobra (1977–2017) + + * `TVD` - TVD + + * `TJR` - Tajikistani Ruble + + * `TJS` - Tajikistani Somoni + + * `TZS` - Tanzanian Shilling + + * `XTS` - Testing Currency Code + + * `THB` - Thai Baht + + * `XXX` - The codes assigned for transactions where no currency is + involved + + * `TPE` - Timorese Escudo + + * `TOP` - Tongan Paʻanga + + * `TTD` - Trinidad & Tobago Dollar + + * `TND` - Tunisian Dinar + + * `TRY` - Turkish Lira + + * `TRL` - Turkish Lira (1922–2005) + + * `TMT` - Turkmenistani Manat + + * `TMM` - Turkmenistani Manat (1993–2009) + + * `USD` - US Dollar + + * `USN` - US Dollar (Next day) + + * `USS` - US Dollar (Same day) + + * `UGX` - Ugandan Shilling + + * `UGS` - Ugandan Shilling (1966–1987) + + * `UAH` - Ukrainian Hryvnia + + * `UAK` - Ukrainian Karbovanets + + * `AED` - United Arab Emirates Dirham + + * `UYW` - Uruguayan Nominal Wage Index Unit + + * `UYU` - Uruguayan Peso + + * `UYP` - Uruguayan Peso (1975–1993) + + * `UYI` - Uruguayan Peso (Indexed Units) + + * `UZS` - Uzbekistani Som + + * `VUV` - Vanuatu Vatu + + * `VES` - Venezuelan Bolívar + + * `VEB` - Venezuelan Bolívar (1871–2008) + + * `VEF` - Venezuelan Bolívar (2008–2018) + + * `VND` - Vietnamese Dong + + * `VNN` - Vietnamese Dong (1978–1985) + + * `CHE` - WIR Euro + + * `CHW` - WIR Franc + + * `XOF` - West African CFA Franc + + * `YDD` - Yemeni Dinar + + * `YER` - Yemeni Rial + + * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + + * `YUD` - Yugoslavian Hard Dinar (1966–1990) + + * `YUM` - Yugoslavian New Dinar (1994–2002) + + * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + + * `ZWN` - ZWN + + * `ZRN` - Zairean New Zaire (1993–1998) + + * `ZRZ` - Zairean Zaire (1971–1993) + + * `ZMW` - Zambian Kwacha + + * `ZMK` - Zambian Kwacha (1968–2012) + + * `ZWD` - Zimbabwean Dollar (1980–2008) + + * `ZWR` - Zimbabwean Dollar (2008) + + * `ZWL` - Zimbabwean Dollar (2009) + exchange_rate: + type: optional + docs: Exchange rate used if the line item is in a foreign currency. + validation: + pattern: ^-?\d{0,32}(?:\.\d{0,16})?$ + is_billable: + type: optional + docs: Whether the expense line is billable to a client or project. + tracking_categories: + docs: >- + The related tracking categories associated with the expense report + (Department, Location, Class, Expense Category) + type: list + employee: + type: optional + docs: >- + Identifier for the employee who submitted or is associated with the + expense report + project: optional + company: + type: optional + docs: The subsidiary that the expense report is created in + contact: optional + quantity: + type: optional + docs: Quantity for the expense line (e.g., miles driven, items purchased). + unit_price: + type: optional + docs: Price per unit for the expense line (if applicable). + non_reimbursable: + type: optional + docs: >- + Whether the expense line is non-reimbursable (e.g., paid via company + card). + tax_amount: + type: optional + docs: Tax amount applicable for the line item. + inclusive_of_tax: + type: optional + docs: Whether the amount is inclusive of tax. + tax_rate: optional + integration_params: + type: optional> + access: write-only + linked_account_params: + type: optional> + access: write-only + remote_fields: + type: optional> + access: write-only + source: + openapi: openapi/openapi.yml + ExpenseReportRequestEmployee: + discriminated: false + docs: >- + Identifier for the employee who submitted or is associated with the + expense report + union: + - type: string + validation: + format: uuid + - Employee + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportRequestAccountingPeriod: + discriminated: false + docs: The accounting period the report was posted in + union: + - type: string + validation: + format: uuid + - AccountingPeriod + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportRequestCompany: + discriminated: false + docs: The subsidiary that the expense report is created in + union: + - type: string + validation: + format: uuid + - CompanyInfo + source: + openapi: openapi/openapi.yml + inline: true + ExpenseReportRequest: + docs: >- + # The ExpenseReport Object + + ### Description + + The `ExpenseReport` object represents a collection of expenses submitted + for review and reimbursement. + + It includes details about the submitter, status, amounts, and associated + metadata. + + + ### Usage Example + + Fetch from the `GET ExpenseReport` endpoint to view details of expense + reports and their line items. + properties: + report_date: + type: optional + docs: The date of the expense report. + report_identifier: + type: optional + docs: Human-readable expense report identifier. + validation: + maxLength: 1024 + employee: + type: optional + docs: >- + Identifier for the employee who submitted or is associated with the + expense report + status: + type: optional + docs: >- + Overall status of the expense report. One of DRAFT, SUBMITTED, + APPROVED, REJECTED + + + * `DRAFT` - DRAFT + + * `SUBMITTED` - SUBMITTED + + * `APPROVED` - APPROVED + + * `REJECTED` - REJECTED + total_amount: + type: optional + docs: Total amount of the expense report + currency: + type: optional + docs: >- + Currency code for the expense report + + + * `XUA` - ADB Unit of Account + + * `AFN` - Afghan Afghani + + * `AFA` - Afghan Afghani (1927–2002) + + * `ALL` - Albanian Lek + + * `ALK` - Albanian Lek (1946–1965) + + * `DZD` - Algerian Dinar + + * `ADP` - Andorran Peseta + + * `AOA` - Angolan Kwanza + + * `AOK` - Angolan Kwanza (1977–1991) + + * `AON` - Angolan New Kwanza (1990–2000) + + * `AOR` - Angolan Readjusted Kwanza (1995–1999) + + * `ARA` - Argentine Austral + + * `ARS` - Argentine Peso + + * `ARM` - Argentine Peso (1881–1970) + + * `ARP` - Argentine Peso (1983–1985) + + * `ARL` - Argentine Peso Ley (1970–1983) + + * `AMD` - Armenian Dram + + * `AWG` - Aruban Florin + + * `AUD` - Australian Dollar + + * `ATS` - Austrian Schilling + + * `AZN` - Azerbaijani Manat + + * `AZM` - Azerbaijani Manat (1993–2006) + + * `BSD` - Bahamian Dollar + + * `BHD` - Bahraini Dinar + + * `BDT` - Bangladeshi Taka + + * `BBD` - Barbadian Dollar + + * `BYN` - Belarusian Ruble + + * `BYB` - Belarusian Ruble (1994–1999) + + * `BYR` - Belarusian Ruble (2000–2016) + + * `BEF` - Belgian Franc + + * `BEC` - Belgian Franc (convertible) + + * `BEL` - Belgian Franc (financial) + + * `BZD` - Belize Dollar + + * `BMD` - Bermudan Dollar + + * `BTN` - Bhutanese Ngultrum + + * `BOB` - Bolivian Boliviano + + * `BOL` - Bolivian Boliviano (1863–1963) + + * `BOV` - Bolivian Mvdol + + * `BOP` - Bolivian Peso + + * `BAM` - Bosnia-Herzegovina Convertible Mark + + * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + + * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + + * `BWP` - Botswanan Pula + + * `BRC` - Brazilian Cruzado (1986–1989) + + * `BRZ` - Brazilian Cruzeiro (1942–1967) + + * `BRE` - Brazilian Cruzeiro (1990–1993) + + * `BRR` - Brazilian Cruzeiro (1993–1994) + + * `BRN` - Brazilian New Cruzado (1989–1990) + + * `BRB` - Brazilian New Cruzeiro (1967–1986) + + * `BRL` - Brazilian Real + + * `GBP` - British Pound + + * `BND` - Brunei Dollar + + * `BGL` - Bulgarian Hard Lev + + * `BGN` - Bulgarian Lev + + * `BGO` - Bulgarian Lev (1879–1952) + + * `BGM` - Bulgarian Socialist Lev + + * `BUK` - Burmese Kyat + + * `BIF` - Burundian Franc + + * `XPF` - CFP Franc + + * `KHR` - Cambodian Riel + + * `CAD` - Canadian Dollar + + * `CVE` - Cape Verdean Escudo + + * `KYD` - Cayman Islands Dollar + + * `XAF` - Central African CFA Franc + + * `CLE` - Chilean Escudo + + * `CLP` - Chilean Peso + + * `CLF` - Chilean Unit of Account (UF) + + * `CNX` - Chinese People’s Bank Dollar + + * `CNY` - Chinese Yuan + + * `CNH` - Chinese Yuan (offshore) + + * `COP` - Colombian Peso + + * `COU` - Colombian Real Value Unit + + * `KMF` - Comorian Franc + + * `CDF` - Congolese Franc + + * `CRC` - Costa Rican Colón + + * `HRD` - Croatian Dinar + + * `HRK` - Croatian Kuna + + * `CUC` - Cuban Convertible Peso + + * `CUP` - Cuban Peso + + * `CYP` - Cypriot Pound + + * `CZK` - Czech Koruna + + * `CSK` - Czechoslovak Hard Koruna + + * `DKK` - Danish Krone + + * `DJF` - Djiboutian Franc + + * `DOP` - Dominican Peso + + * `NLG` - Dutch Guilder + + * `XCD` - East Caribbean Dollar + + * `DDM` - East German Mark + + * `ECS` - Ecuadorian Sucre + + * `ECV` - Ecuadorian Unit of Constant Value + + * `EGP` - Egyptian Pound + + * `GQE` - Equatorial Guinean Ekwele + + * `ERN` - Eritrean Nakfa + + * `EEK` - Estonian Kroon + + * `ETB` - Ethiopian Birr + + * `EUR` - Euro + + * `XBA` - European Composite Unit + + * `XEU` - European Currency Unit + + * `XBB` - European Monetary Unit + + * `XBC` - European Unit of Account (XBC) + + * `XBD` - European Unit of Account (XBD) + + * `FKP` - Falkland Islands Pound + + * `FJD` - Fijian Dollar + + * `FIM` - Finnish Markka + + * `FRF` - French Franc + + * `XFO` - French Gold Franc + + * `XFU` - French UIC-Franc + + * `GMD` - Gambian Dalasi + + * `GEK` - Georgian Kupon Larit + + * `GEL` - Georgian Lari + + * `DEM` - German Mark + + * `GHS` - Ghanaian Cedi + + * `GHC` - Ghanaian Cedi (1979–2007) + + * `GIP` - Gibraltar Pound + + * `XAU` - Gold + + * `GRD` - Greek Drachma + + * `GTQ` - Guatemalan Quetzal + + * `GWP` - Guinea-Bissau Peso + + * `GNF` - Guinean Franc + + * `GNS` - Guinean Syli + + * `GYD` - Guyanaese Dollar + + * `HTG` - Haitian Gourde + + * `HNL` - Honduran Lempira + + * `HKD` - Hong Kong Dollar + + * `HUF` - Hungarian Forint + + * `IMP` - IMP + + * `ISK` - Icelandic Króna + + * `ISJ` - Icelandic Króna (1918–1981) + + * `INR` - Indian Rupee + + * `IDR` - Indonesian Rupiah + + * `IRR` - Iranian Rial + + * `IQD` - Iraqi Dinar + + * `IEP` - Irish Pound + + * `ILS` - Israeli New Shekel + + * `ILP` - Israeli Pound + + * `ILR` - Israeli Shekel (1980–1985) + + * `ITL` - Italian Lira + + * `JMD` - Jamaican Dollar + + * `JPY` - Japanese Yen + + * `JOD` - Jordanian Dinar + + * `KZT` - Kazakhstani Tenge + + * `KES` - Kenyan Shilling + + * `KWD` - Kuwaiti Dinar + + * `KGS` - Kyrgystani Som + + * `LAK` - Laotian Kip + + * `LVL` - Latvian Lats + + * `LVR` - Latvian Ruble + + * `LBP` - Lebanese Pound + + * `LSL` - Lesotho Loti + + * `LRD` - Liberian Dollar + + * `LYD` - Libyan Dinar + + * `LTL` - Lithuanian Litas + + * `LTT` - Lithuanian Talonas + + * `LUL` - Luxembourg Financial Franc + + * `LUC` - Luxembourgian Convertible Franc + + * `LUF` - Luxembourgian Franc + + * `MOP` - Macanese Pataca + + * `MKD` - Macedonian Denar + + * `MKN` - Macedonian Denar (1992–1993) + + * `MGA` - Malagasy Ariary + + * `MGF` - Malagasy Franc + + * `MWK` - Malawian Kwacha + + * `MYR` - Malaysian Ringgit + + * `MVR` - Maldivian Rufiyaa + + * `MVP` - Maldivian Rupee (1947–1981) + + * `MLF` - Malian Franc + + * `MTL` - Maltese Lira + + * `MTP` - Maltese Pound + + * `MRU` - Mauritanian Ouguiya + + * `MRO` - Mauritanian Ouguiya (1973–2017) + + * `MUR` - Mauritian Rupee + + * `MXV` - Mexican Investment Unit + + * `MXN` - Mexican Peso + + * `MXP` - Mexican Silver Peso (1861–1992) + + * `MDC` - Moldovan Cupon + + * `MDL` - Moldovan Leu + + * `MCF` - Monegasque Franc + + * `MNT` - Mongolian Tugrik + + * `MAD` - Moroccan Dirham + + * `MAF` - Moroccan Franc + + * `MZE` - Mozambican Escudo + + * `MZN` - Mozambican Metical + + * `MZM` - Mozambican Metical (1980–2006) + + * `MMK` - Myanmar Kyat + + * `NAD` - Namibian Dollar + + * `NPR` - Nepalese Rupee + + * `ANG` - Netherlands Antillean Guilder + + * `TWD` - New Taiwan Dollar + + * `NZD` - New Zealand Dollar + + * `NIO` - Nicaraguan Córdoba + + * `NIC` - Nicaraguan Córdoba (1988–1991) + + * `NGN` - Nigerian Naira + + * `KPW` - North Korean Won + + * `NOK` - Norwegian Krone + + * `OMR` - Omani Rial + + * `PKR` - Pakistani Rupee + + * `XPD` - Palladium + + * `PAB` - Panamanian Balboa + + * `PGK` - Papua New Guinean Kina + + * `PYG` - Paraguayan Guarani + + * `PEI` - Peruvian Inti + + * `PEN` - Peruvian Sol + + * `PES` - Peruvian Sol (1863–1965) + + * `PHP` - Philippine Peso + + * `XPT` - Platinum + + * `PLN` - Polish Zloty + + * `PLZ` - Polish Zloty (1950–1995) + + * `PTE` - Portuguese Escudo + + * `GWE` - Portuguese Guinea Escudo + + * `QAR` - Qatari Rial + + * `XRE` - RINET Funds + + * `RHD` - Rhodesian Dollar + + * `RON` - Romanian Leu + + * `ROL` - Romanian Leu (1952–2006) + + * `RUB` - Russian Ruble + + * `RUR` - Russian Ruble (1991–1998) + + * `RWF` - Rwandan Franc + + * `SVC` - Salvadoran Colón + + * `WST` - Samoan Tala + + * `SAR` - Saudi Riyal + + * `RSD` - Serbian Dinar + + * `CSD` - Serbian Dinar (2002–2006) + + * `SCR` - Seychellois Rupee + + * `SLL` - Sierra Leonean Leone + + * `XAG` - Silver + + * `SGD` - Singapore Dollar + + * `SKK` - Slovak Koruna + + * `SIT` - Slovenian Tolar + + * `SBD` - Solomon Islands Dollar + + * `SOS` - Somali Shilling + + * `ZAR` - South African Rand + + * `ZAL` - South African Rand (financial) + + * `KRH` - South Korean Hwan (1953–1962) + + * `KRW` - South Korean Won + + * `KRO` - South Korean Won (1945–1953) + + * `SSP` - South Sudanese Pound + + * `SUR` - Soviet Rouble + + * `ESP` - Spanish Peseta + + * `ESA` - Spanish Peseta (A account) + + * `ESB` - Spanish Peseta (convertible account) + + * `XDR` - Special Drawing Rights + + * `LKR` - Sri Lankan Rupee + + * `SHP` - St. Helena Pound + + * `XSU` - Sucre + + * `SDD` - Sudanese Dinar (1992–2007) + + * `SDG` - Sudanese Pound + + * `SDP` - Sudanese Pound (1957–1998) + + * `SRD` - Surinamese Dollar + + * `SRG` - Surinamese Guilder + + * `SZL` - Swazi Lilangeni + + * `SEK` - Swedish Krona + + * `CHF` - Swiss Franc + + * `SYP` - Syrian Pound + + * `STN` - São Tomé & Príncipe Dobra + + * `STD` - São Tomé & Príncipe Dobra (1977–2017) + + * `TVD` - TVD + + * `TJR` - Tajikistani Ruble + + * `TJS` - Tajikistani Somoni + + * `TZS` - Tanzanian Shilling + + * `XTS` - Testing Currency Code + + * `THB` - Thai Baht + + * `XXX` - The codes assigned for transactions where no currency is + involved + + * `TPE` - Timorese Escudo + + * `TOP` - Tongan Paʻanga + + * `TTD` - Trinidad & Tobago Dollar + + * `TND` - Tunisian Dinar + + * `TRY` - Turkish Lira + + * `TRL` - Turkish Lira (1922–2005) + + * `TMT` - Turkmenistani Manat + + * `TMM` - Turkmenistani Manat (1993–2009) + + * `USD` - US Dollar + + * `USN` - US Dollar (Next day) + + * `USS` - US Dollar (Same day) + + * `UGX` - Ugandan Shilling + + * `UGS` - Ugandan Shilling (1966–1987) + + * `UAH` - Ukrainian Hryvnia + + * `UAK` - Ukrainian Karbovanets + + * `AED` - United Arab Emirates Dirham + + * `UYW` - Uruguayan Nominal Wage Index Unit + + * `UYU` - Uruguayan Peso + + * `UYP` - Uruguayan Peso (1975–1993) + + * `UYI` - Uruguayan Peso (Indexed Units) + + * `UZS` - Uzbekistani Som + + * `VUV` - Vanuatu Vatu + + * `VES` - Venezuelan Bolívar + + * `VEB` - Venezuelan Bolívar (1871–2008) + + * `VEF` - Venezuelan Bolívar (2008–2018) + + * `VND` - Vietnamese Dong + + * `VNN` - Vietnamese Dong (1978–1985) + + * `CHE` - WIR Euro + + * `CHW` - WIR Franc + + * `XOF` - West African CFA Franc + + * `YDD` - Yemeni Dinar + + * `YER` - Yemeni Rial + + * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + + * `YUD` - Yugoslavian Hard Dinar (1966–1990) + + * `YUM` - Yugoslavian New Dinar (1994–2002) + + * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + + * `ZWN` - ZWN + + * `ZRN` - Zairean New Zaire (1993–1998) + + * `ZRZ` - Zairean Zaire (1971–1993) + + * `ZMW` - Zambian Kwacha + + * `ZMK` - Zambian Kwacha (1968–2012) + + * `ZWD` - Zimbabwean Dollar (1980–2008) + + * `ZWR` - Zimbabwean Dollar (2008) + + * `ZWL` - Zimbabwean Dollar (2009) + description: + type: optional + docs: A brief description or purpose for the expense report + validation: + maxLength: 1024 + accounting_period: + type: optional + docs: The accounting period the report was posted in + company: + type: optional + docs: The subsidiary that the expense report is created in + tracking_categories: + docs: The related tracking categories associated with the expense report + type: list + integration_params: + type: optional> + access: write-only + linked_account_params: + type: optional> + access: write-only + remote_fields: + type: optional> + access: write-only + source: + openapi: openapi/openapi.yml + ExpenseReportResponse: + properties: + model: ExpenseReport + warnings: list + errors: list + logs: optional> + source: + openapi: openapi/openapi.yml + ExpenseReportStatusEnum: + enum: + - DRAFT + - SUBMITTED + - APPROVED + - REJECTED + docs: |- + * `DRAFT` - DRAFT + * `SUBMITTED` - SUBMITTED + * `APPROVED` - APPROVED + * `REJECTED` - REJECTED + source: + openapi: openapi/openapi.yml ExpenseRequestAccount: discriminated: false docs: The expense's payment account. @@ -21838,6 +24887,7 @@ types: CreditNote: optional> Item: optional> PurchaseOrder: optional> + ExpenseReport: optional> TrackingCategory: optional> JournalEntry: optional> TaxRate: optional> @@ -21935,6 +24985,7 @@ types: CreditNote: optional> Item: optional> PurchaseOrder: optional> + ExpenseReport: optional> TrackingCategory: optional> JournalEntry: optional> TaxRate: optional> @@ -32019,6 +35070,21 @@ types: source: openapi: openapi/openapi.yml inline: true + ItemType: + discriminated: false + docs: |- + The item's type. + + * `INVENTORY` - INVENTORY + * `NON_INVENTORY` - NON_INVENTORY + * `SERVICE` - SERVICE + * `UNKNOWN` - UNKNOWN + union: + - Type2BbEnum + - string + source: + openapi: openapi/openapi.yml + inline: true ItemPurchaseAccount: discriminated: false docs: References the default account used to record a purchase of the item. @@ -32109,6 +35175,15 @@ types: * `ACTIVE` - ACTIVE * `ARCHIVED` - ARCHIVED + type: + type: optional + docs: |- + The item's type. + + * `INVENTORY` - INVENTORY + * `NON_INVENTORY` - NON_INVENTORY + * `SERVICE` - SERVICE + * `UNKNOWN` - UNKNOWN unit_price: type: optional docs: The item's unit price. @@ -38096,6 +41171,20 @@ types: results: optional> source: openapi: openapi/openapi.yml + PaginatedExpenseReportLineList: + properties: + next: optional + previous: optional + results: optional> + source: + openapi: openapi/openapi.yml + PaginatedExpenseReportList: + properties: + next: optional + previous: optional + results: optional> + source: + openapi: openapi/openapi.yml PaginatedGeneralLedgerTransactionList: properties: next: optional diff --git a/.mock/definition/accounting/expenseReports.yml b/.mock/definition/accounting/expenseReports.yml new file mode 100644 index 000000000..d87949802 --- /dev/null +++ b/.mock/definition/accounting/expenseReports.yml @@ -0,0 +1,938 @@ +types: + ExpenseReportsListRequestExpand: + enum: + - accounting_period + - value: accounting_period,company + name: AccountingPeriodCompany + - company + - employee + - value: employee,accounting_period + name: EmployeeAccountingPeriod + - value: employee,accounting_period,company + name: EmployeeAccountingPeriodCompany + - value: employee,company + name: EmployeeCompany + - lines + - value: lines,accounting_period + name: LinesAccountingPeriod + - value: lines,accounting_period,company + name: LinesAccountingPeriodCompany + - value: lines,company + name: LinesCompany + - value: lines,employee + name: LinesEmployee + - value: lines,employee,accounting_period + name: LinesEmployeeAccountingPeriod + - value: lines,employee,accounting_period,company + name: LinesEmployeeAccountingPeriodCompany + - value: lines,employee,company + name: LinesEmployeeCompany + source: + openapi: openapi/openapi.yml + ExpenseReportsLinesListRequestExpand: + enum: + - account + - value: account,company + name: AccountCompany + - value: account,company,contact + name: AccountCompanyContact + - value: account,company,contact,tax_rate + name: AccountCompanyContactTaxRate + - value: account,company,tax_rate + name: AccountCompanyTaxRate + - value: account,contact + name: AccountContact + - value: account,contact,tax_rate + name: AccountContactTaxRate + - value: account,employee + name: AccountEmployee + - value: account,employee,company + name: AccountEmployeeCompany + - value: account,employee,company,contact + name: AccountEmployeeCompanyContact + - value: account,employee,company,contact,tax_rate + name: AccountEmployeeCompanyContactTaxRate + - value: account,employee,company,tax_rate + name: AccountEmployeeCompanyTaxRate + - value: account,employee,contact + name: AccountEmployeeContact + - value: account,employee,contact,tax_rate + name: AccountEmployeeContactTaxRate + - value: account,employee,project + name: AccountEmployeeProject + - value: account,employee,project,company + name: AccountEmployeeProjectCompany + - value: account,employee,project,company,contact + name: AccountEmployeeProjectCompanyContact + - value: account,employee,project,company,contact,tax_rate + name: AccountEmployeeProjectCompanyContactTaxRate + - value: account,employee,project,company,tax_rate + name: AccountEmployeeProjectCompanyTaxRate + - value: account,employee,project,contact + name: AccountEmployeeProjectContact + - value: account,employee,project,contact,tax_rate + name: AccountEmployeeProjectContactTaxRate + - value: account,employee,project,tax_rate + name: AccountEmployeeProjectTaxRate + - value: account,employee,tax_rate + name: AccountEmployeeTaxRate + - value: account,project + name: AccountProject + - value: account,project,company + name: AccountProjectCompany + - value: account,project,company,contact + name: AccountProjectCompanyContact + - value: account,project,company,contact,tax_rate + name: AccountProjectCompanyContactTaxRate + - value: account,project,company,tax_rate + name: AccountProjectCompanyTaxRate + - value: account,project,contact + name: AccountProjectContact + - value: account,project,contact,tax_rate + name: AccountProjectContactTaxRate + - value: account,project,tax_rate + name: AccountProjectTaxRate + - value: account,tax_rate + name: AccountTaxRate + - company + - value: company,contact + name: CompanyContact + - value: company,contact,tax_rate + name: CompanyContactTaxRate + - value: company,tax_rate + name: CompanyTaxRate + - contact + - value: contact,tax_rate + name: ContactTaxRate + - employee + - value: employee,company + name: EmployeeCompany + - value: employee,company,contact + name: EmployeeCompanyContact + - value: employee,company,contact,tax_rate + name: EmployeeCompanyContactTaxRate + - value: employee,company,tax_rate + name: EmployeeCompanyTaxRate + - value: employee,contact + name: EmployeeContact + - value: employee,contact,tax_rate + name: EmployeeContactTaxRate + - value: employee,project + name: EmployeeProject + - value: employee,project,company + name: EmployeeProjectCompany + - value: employee,project,company,contact + name: EmployeeProjectCompanyContact + - value: employee,project,company,contact,tax_rate + name: EmployeeProjectCompanyContactTaxRate + - value: employee,project,company,tax_rate + name: EmployeeProjectCompanyTaxRate + - value: employee,project,contact + name: EmployeeProjectContact + - value: employee,project,contact,tax_rate + name: EmployeeProjectContactTaxRate + - value: employee,project,tax_rate + name: EmployeeProjectTaxRate + - value: employee,tax_rate + name: EmployeeTaxRate + - project + - value: project,company + name: ProjectCompany + - value: project,company,contact + name: ProjectCompanyContact + - value: project,company,contact,tax_rate + name: ProjectCompanyContactTaxRate + - value: project,company,tax_rate + name: ProjectCompanyTaxRate + - value: project,contact + name: ProjectContact + - value: project,contact,tax_rate + name: ProjectContactTaxRate + - value: project,tax_rate + name: ProjectTaxRate + - tax_rate + source: + openapi: openapi/openapi.yml + ExpenseReportsRetrieveRequestExpand: + enum: + - accounting_period + - value: accounting_period,company + name: AccountingPeriodCompany + - company + - employee + - value: employee,accounting_period + name: EmployeeAccountingPeriod + - value: employee,accounting_period,company + name: EmployeeAccountingPeriodCompany + - value: employee,company + name: EmployeeCompany + - lines + - value: lines,accounting_period + name: LinesAccountingPeriod + - value: lines,accounting_period,company + name: LinesAccountingPeriodCompany + - value: lines,company + name: LinesCompany + - value: lines,employee + name: LinesEmployee + - value: lines,employee,accounting_period + name: LinesEmployeeAccountingPeriod + - value: lines,employee,accounting_period,company + name: LinesEmployeeAccountingPeriodCompany + - value: lines,employee,company + name: LinesEmployeeCompany + source: + openapi: openapi/openapi.yml +imports: + root: __package__.yml +service: + auth: false + base-path: '' + endpoints: + list: + path: /accounting/v1/expense-reports + method: GET + auth: true + docs: Returns a list of `ExpenseReport` objects. + source: + openapi: openapi/openapi.yml + request: + name: ExpenseReportsListRequest + query-parameters: + company_id: + type: optional + docs: If provided, will only return expense reports for this company. + created_after: + type: optional + docs: If provided, will only return objects created after this datetime. + created_before: + type: optional + docs: >- + If provided, will only return objects created before this + datetime. + cursor: + type: optional + docs: The pagination cursor value. + expand: + type: optional + docs: >- + Which relations should be returned in expanded form. Multiple + relation names should be comma separated without spaces. + include_deleted_data: + type: optional + docs: >- + Indicates whether or not this object has been deleted in the third + party platform. Full coverage deletion detection is a premium + add-on. Native deletion detection is offered for free with limited + coverage. [Learn + more](https://docs.merge.dev/integrations/hris/supported-features/). + include_remote_data: + type: optional + docs: >- + Whether to include the original data Merge fetched from the + third-party to produce these models. + include_remote_fields: + type: optional + docs: >- + Whether to include all remote fields, including fields that Merge + did not map to common models, in a normalized format. + include_shell_data: + type: optional + docs: >- + Whether to include shell records. Shell records are empty records + (they may contain some metadata but all other fields are null). + modified_after: + type: optional + docs: >- + If provided, only objects synced by Merge after this date time + will be returned. + modified_before: + type: optional + docs: >- + If provided, only objects synced by Merge before this date time + will be returned. + page_size: + type: optional + docs: Number of results to return per page. + remote_id: + type: optional + docs: The API provider's ID for the given object. + response: + docs: '' + type: root.PaginatedExpenseReportList + status-code: 200 + examples: + - headers: {} + response: + body: + next: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + previous: cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ + results: + - id: 123e4567-e89b-12d3-a456-426614174000 + remote_id: exp_123e4567-e89b-12d3-a456-426614174000 + created_at: '2024-01-31T12:00:00Z' + modified_at: '2024-01-31T14:30:00Z' + report_date: '2024-01-31T00:00:00Z' + report_identifier: EXP-2024-001 + employee: b9a9b824-6172-4d63-9d90-1c8a86c4f3b1 + status: DRAFT + total_amount: 150 + lines: + - id: '1234' + remote_id: abcd-1234 + created_at: '2021-09-15T00:00:00Z' + modified_at: '2021-10-16T00:00:00Z' + account: acc-1234 + description: Client lunch meeting + expense_date: '2024-01-15T00:00:00Z' + amount: 50 + currency: USD + exchange_rate: exchange_rate + is_billable: true + tracking_categories: + - cat-1 + - cat-2 + employee: emp-1234 + project: proj-5678 + company: comp-1234 + contact: cont-5678 + quantity: 1 + unit_price: 50 + non_reimbursable: false + tax_amount: 5 + inclusive_of_tax: false + tax_rate: tax-1234 + remote_was_deleted: false + currency: XUA + description: January 2024 Travel Expenses + accounting_period: 7d793c67-9f72-4a6b-9256-3936f237b0d9 + company: company + tracking_categories: + - a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d + - d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p + remote_was_deleted: true + field_mappings: + organization_defined_targets: + custom_key: custom_value + linked_account_defined_targets: + custom_key: custom_value + remote_data: + - path: /actions + data: + - Varies by platform + remote_fields: + - remote_field_class: remote_field_class + create: + path: /accounting/v1/expense-reports + method: POST + auth: true + docs: Creates an `ExpenseReport` object with the given values. + source: + openapi: openapi/openapi.yml + request: + name: ExpenseReportEndpointRequest + query-parameters: + is_debug_mode: + type: optional + docs: >- + Whether to include debug fields (such as log file links) in the + response. + run_async: + type: optional + docs: Whether or not third-party updates should be run asynchronously. + body: + properties: + model: root.ExpenseReportRequest + content-type: application/json + response: + docs: '' + type: root.ExpenseReportResponse + status-code: 201 + examples: + - headers: {} + request: + model: + tracking_categories: + - a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d + - d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p + response: + body: + model: + id: 123e4567-e89b-12d3-a456-426614174000 + remote_id: exp_123e4567-e89b-12d3-a456-426614174000 + created_at: '2024-01-31T12:00:00Z' + modified_at: '2024-01-31T14:30:00Z' + report_date: '2024-01-31T00:00:00Z' + report_identifier: EXP-2024-001 + employee: b9a9b824-6172-4d63-9d90-1c8a86c4f3b1 + status: DRAFT + total_amount: 150 + lines: + - id: '1234' + remote_id: abcd-1234 + created_at: '2021-09-15T00:00:00Z' + modified_at: '2021-10-16T00:00:00Z' + account: acc-1234 + description: Client lunch meeting + expense_date: '2024-01-15T00:00:00Z' + amount: 50 + currency: USD + exchange_rate: exchange_rate + is_billable: true + tracking_categories: + - cat-1 + - cat-2 + employee: emp-1234 + project: proj-5678 + company: comp-1234 + contact: cont-5678 + quantity: 1 + unit_price: 50 + non_reimbursable: false + tax_amount: 5 + inclusive_of_tax: false + tax_rate: tax-1234 + remote_was_deleted: false + currency: XUA + description: January 2024 Travel Expenses + accounting_period: 7d793c67-9f72-4a6b-9256-3936f237b0d9 + company: company + tracking_categories: + - a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d + - d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p + remote_was_deleted: true + field_mappings: + organization_defined_targets: + custom_key: custom_value + linked_account_defined_targets: + custom_key: custom_value + remote_data: + - path: /actions + data: + - Varies by platform + remote_fields: + - remote_field_class: remote_field_class + warnings: + - source: + pointer: pointer + title: Unrecognized Field + detail: An unrecognized field, age, was passed in with request data. + problem_type: UNRECOGNIZED_FIELD + errors: + - source: + pointer: pointer + title: Missing Required Field + detail: custom_fields is a required field on model. + problem_type: MISSING_REQUIRED_FIELD + logs: + - log_id: 99433219-8017-4acd-bb3c-ceb23d663832 + dashboard_view: >- + https://app.merge.dev/logs/99433219-8017-4acd-bb3c-ceb23d663832 + log_summary: + url: www.exampleintegration.com/api/v1/exampleapi + method: POST + status_code: 200 + linesList: + path: /accounting/v1/expense-reports/{expense_report_id}/lines + method: GET + auth: true + docs: >- + Returns a list of `ExpenseReportLine` objects that point to a + `ExpenseReport` with the given id. + source: + openapi: openapi/openapi.yml + path-parameters: + expense_report_id: string + request: + name: ExpenseReportsLinesListRequest + query-parameters: + cursor: + type: optional + docs: The pagination cursor value. + expand: + type: optional + docs: >- + Which relations should be returned in expanded form. Multiple + relation names should be comma separated without spaces. + include_deleted_data: + type: optional + docs: >- + Indicates whether or not this object has been deleted in the third + party platform. Full coverage deletion detection is a premium + add-on. Native deletion detection is offered for free with limited + coverage. [Learn + more](https://docs.merge.dev/integrations/hris/supported-features/). + include_remote_data: + type: optional + docs: >- + Whether to include the original data Merge fetched from the + third-party to produce these models. + include_remote_fields: + type: optional + docs: >- + Whether to include all remote fields, including fields that Merge + did not map to common models, in a normalized format. + include_shell_data: + type: optional + docs: >- + Whether to include shell records. Shell records are empty records + (they may contain some metadata but all other fields are null). + page_size: + type: optional + docs: Number of results to return per page. + response: + docs: '' + type: root.PaginatedExpenseReportLineList + status-code: 200 + examples: + - path-parameters: + expense_report_id: expense_report_id + headers: {} + response: + body: + next: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + previous: cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ + results: + - id: '1234' + remote_id: abcd-1234 + created_at: '2021-09-15T00:00:00Z' + modified_at: '2021-10-16T00:00:00Z' + account: account + description: Client lunch meeting + expense_date: '2024-01-15T00:00:00Z' + amount: 50 + currency: XUA + exchange_rate: exchange_rate + is_billable: true + tracking_categories: + - cat-1 + - cat-2 + employee: employee + project: project + company: company + contact: contact + quantity: 1 + unit_price: 50 + non_reimbursable: true + tax_amount: 5 + inclusive_of_tax: true + tax_rate: tax_rate + remote_was_deleted: true + remote_fields: + - remote_field_class: remote_field_class + retrieve: + path: /accounting/v1/expense-reports/{id} + method: GET + auth: true + docs: Returns an `ExpenseReport` object with the given `id`. + source: + openapi: openapi/openapi.yml + path-parameters: + id: string + request: + name: ExpenseReportsRetrieveRequest + query-parameters: + expand: + type: optional + docs: >- + Which relations should be returned in expanded form. Multiple + relation names should be comma separated without spaces. + include_remote_data: + type: optional + docs: >- + Whether to include the original data Merge fetched from the + third-party to produce these models. + include_remote_fields: + type: optional + docs: >- + Whether to include all remote fields, including fields that Merge + did not map to common models, in a normalized format. + include_shell_data: + type: optional + docs: >- + Whether to include shell records. Shell records are empty records + (they may contain some metadata but all other fields are null). + response: + docs: '' + type: root.ExpenseReport + status-code: 200 + examples: + - path-parameters: + id: id + headers: {} + response: + body: + id: 123e4567-e89b-12d3-a456-426614174000 + remote_id: exp_123e4567-e89b-12d3-a456-426614174000 + created_at: '2024-01-31T12:00:00Z' + modified_at: '2024-01-31T14:30:00Z' + report_date: '2024-01-31T00:00:00Z' + report_identifier: EXP-2024-001 + employee: b9a9b824-6172-4d63-9d90-1c8a86c4f3b1 + status: DRAFT + total_amount: 150 + lines: + - id: '1234' + remote_id: abcd-1234 + created_at: '2021-09-15T00:00:00Z' + modified_at: '2021-10-16T00:00:00Z' + account: acc-1234 + description: Client lunch meeting + expense_date: '2024-01-15T00:00:00Z' + amount: 50 + currency: USD + exchange_rate: exchange_rate + is_billable: true + tracking_categories: + - cat-1 + - cat-2 + employee: emp-1234 + project: proj-5678 + company: comp-1234 + contact: cont-5678 + quantity: 1 + unit_price: 50 + non_reimbursable: false + tax_amount: 5 + inclusive_of_tax: false + tax_rate: tax-1234 + remote_was_deleted: false + remote_fields: + - remote_field_class: remote_field_class + currency: XUA + description: January 2024 Travel Expenses + accounting_period: 7d793c67-9f72-4a6b-9256-3936f237b0d9 + company: company + tracking_categories: + - a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d + - d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p + remote_was_deleted: true + field_mappings: + organization_defined_targets: + custom_key: custom_value + linked_account_defined_targets: + custom_key: custom_value + remote_data: + - path: /actions + data: + - Varies by platform + remote_fields: + - remote_field_class: remote_field_class + value: + key: value + linesRemoteFieldClassesList: + path: /accounting/v1/expense-reports/lines/remote-field-classes + method: GET + auth: true + docs: Returns a list of `RemoteFieldClass` objects. + source: + openapi: openapi/openapi.yml + request: + name: ExpenseReportsLinesRemoteFieldClassesListRequest + query-parameters: + cursor: + type: optional + docs: The pagination cursor value. + include_deleted_data: + type: optional + docs: >- + Indicates whether or not this object has been deleted in the third + party platform. Full coverage deletion detection is a premium + add-on. Native deletion detection is offered for free with limited + coverage. [Learn + more](https://docs.merge.dev/integrations/hris/supported-features/). + include_remote_data: + type: optional + docs: >- + Whether to include the original data Merge fetched from the + third-party to produce these models. + include_shell_data: + type: optional + docs: >- + Whether to include shell records. Shell records are empty records + (they may contain some metadata but all other fields are null). + is_common_model_field: + type: optional + docs: >- + If provided, will only return remote field classes with this + is_common_model_field value + is_custom: + type: optional + docs: >- + If provided, will only return remote fields classes with this + is_custom value + page_size: + type: optional + docs: Number of results to return per page. + response: + docs: '' + type: root.PaginatedRemoteFieldClassList + status-code: 200 + examples: + - headers: {} + response: + body: + next: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + previous: cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ + results: + - id: id + display_name: display_name + remote_key_name: remote_key_name + description: description + is_custom: true + is_required: true + field_type: string + field_format: string + field_choices: + - field_choices + metaPostRetrieve: + path: /accounting/v1/expense-reports/meta/post + method: GET + auth: true + docs: Returns metadata for `ExpenseReport` POSTs. + source: + openapi: openapi/openapi.yml + response: + docs: '' + type: root.MetaResponse + status-code: 200 + examples: + - headers: {} + response: + body: + request_schema: + type: object + properties: + model: + type: object + required: + - last_name + - first_name + - merge_categories + - new_york_city_neighborhood + - favorite_tv_shows + - favorite_watch + properties: + email_addresses: + type: array + items: + type: object + properties: + value: + type: string + title: value + email_address_type: + type: string + title: email_address_type + integration_params: + type: object + title: integration_params + properties: {} + linked_account_params: + type: object + title: linked_account_params + properties: {} + title: email_addresses + description: Array of email_addresses objects + urls: + type: array + items: + type: object + properties: + value: + type: string + title: value + url_type: + type: string + title: url_type + integration_params: + type: object + title: integration_params + properties: {} + linked_account_params: + type: object + title: linked_account_params + properties: {} + title: urls + description: Array of urls objects + first_name: + type: string + title: first_name + description: The first name. + last_name: + type: string + title: last_name + description: The last name. + phone_numbers: + type: array + items: + type: object + properties: + value: + type: string + title: value + phone_number_type: + type: string + title: phone_number_type + integration_params: + type: object + title: integration_params + properties: {} + linked_account_params: + type: object + title: linked_account_params + properties: {} + title: phone_numbers + description: Array of phone_numbers objects + tags: + type: array + items: + type: string + format: uuid + title: tags + description: Array of tags names + attachments: + type: array + items: + type: object + properties: + id: + type: string + title: id + file_url: + type: string + title: file_url + file_name: + type: string + title: file_name + attachment_type: + type: string + title: attachment_type + integration_params: + type: object + title: integration_params + properties: {} + linked_account_params: + type: object + title: linked_account_params + properties: {} + title: attachments + description: 'Array of attachments objects ' + merge_categories: + type: array + categories: + type: string + enum: + - HRIS + - ATS + - Accounting + - Ticketing + - File Storage + - CRM + - Marketing Automation + enum_information: + - value: HRIS + description: Merge HRIS Category + - value: ATS + description: Merge ATS Category + - value: Accounting + description: Merge Accounting Category + - value: Ticketing + description: Merge Ticketing Category + - value: File Storage + description: Merge File Storage Category + - value: CRM + description: Merge CRM Category + - value: Marketing Automation + description: Merge Marketing Automation Category + title: Merge Categories + description: Array of Merge's Unified API Categories + new_york_city_neighborhood: + type: string + title: Borough + description: One of the 5 Boroughs of New York City + favorite_tv_shows: + type: array + items: + type: string + format: uuid + title: Favorite TV Shows + description: Array of TV Show objects on merge.tv_shows + favorite_watch: + type: string + title: Favorite Watch + description: Favorite watch of all time + remote_field_classes: + key: value + status: + linked_account_status: linked_account_status + can_make_request: true + has_conditional_params: true + has_required_linked_account_params: true + remoteFieldClassesList: + path: /accounting/v1/expense-reports/remote-field-classes + method: GET + auth: true + docs: Returns a list of `RemoteFieldClass` objects. + source: + openapi: openapi/openapi.yml + request: + name: ExpenseReportsRemoteFieldClassesListRequest + query-parameters: + cursor: + type: optional + docs: The pagination cursor value. + include_deleted_data: + type: optional + docs: >- + Indicates whether or not this object has been deleted in the third + party platform. Full coverage deletion detection is a premium + add-on. Native deletion detection is offered for free with limited + coverage. [Learn + more](https://docs.merge.dev/integrations/hris/supported-features/). + include_remote_data: + type: optional + docs: >- + Whether to include the original data Merge fetched from the + third-party to produce these models. + include_shell_data: + type: optional + docs: >- + Whether to include shell records. Shell records are empty records + (they may contain some metadata but all other fields are null). + is_common_model_field: + type: optional + docs: >- + If provided, will only return remote field classes with this + is_common_model_field value + is_custom: + type: optional + docs: >- + If provided, will only return remote fields classes with this + is_custom value + page_size: + type: optional + docs: Number of results to return per page. + response: + docs: '' + type: root.PaginatedRemoteFieldClassList + status-code: 200 + examples: + - headers: {} + response: + body: + next: cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw + previous: cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ + results: + - id: id + display_name: display_name + remote_key_name: remote_key_name + description: description + is_custom: true + is_required: true + field_type: string + field_format: string + field_choices: + - field_choices + source: + openapi: openapi/openapi.yml diff --git a/.mock/definition/accounting/fieldMapping.yml b/.mock/definition/accounting/fieldMapping.yml index 7f1061839..663890883 100644 --- a/.mock/definition/accounting/fieldMapping.yml +++ b/.mock/definition/accounting/fieldMapping.yml @@ -193,6 +193,22 @@ service: url_path: /example-url-path field_traversal_path: - example_remote_field_key + ExpenseReport: + - id: 3fa85f64-5717-4562-b3fc-2c963f66afa6 + is_integration_wide: true + target_field: + name: example_target_field_name + description: this is a example description of a target field + is_organization_wide: true + remote_field: + remote_key_name: example_remote_field_key + schema: + type: string + remote_endpoint_info: + method: GET + url_path: /example-url-path + field_traversal_path: + - example_remote_field_key TrackingCategory: - id: 3fa85f64-5717-4562-b3fc-2c963f66afa6 is_integration_wide: true @@ -1134,6 +1150,10 @@ service: - name: example_target_field_name description: this is a example description of a target field is_mapped: is_mapped + ExpenseReport: + - name: example_target_field_name + description: this is a example description of a target field + is_mapped: is_mapped TrackingCategory: - name: example_target_field_name description: this is a example description of a target field diff --git a/.mock/definition/accounting/items.yml b/.mock/definition/accounting/items.yml index 7ee5dea70..29a34438f 100644 --- a/.mock/definition/accounting/items.yml +++ b/.mock/definition/accounting/items.yml @@ -219,6 +219,7 @@ service: modified_at: '2021-10-16T00:00:00Z' name: Pickleball Paddle status: ACTIVE + type: INVENTORY unit_price: 10 purchase_price: 25 purchase_account: purchase_account @@ -276,6 +277,7 @@ service: modified_at: '2021-10-16T00:00:00Z' name: Pickleball Paddle status: ACTIVE + type: INVENTORY unit_price: 10 purchase_price: 25 purchase_account: purchase_account @@ -367,6 +369,7 @@ service: modified_at: '2021-10-16T00:00:00Z' name: Pickleball Paddle status: ACTIVE + type: INVENTORY unit_price: 10 purchase_price: 25 purchase_account: purchase_account @@ -428,6 +431,7 @@ service: modified_at: '2021-10-16T00:00:00Z' name: Pickleball Paddle status: ACTIVE + type: INVENTORY unit_price: 10 purchase_price: 25 purchase_account: purchase_account diff --git a/.mock/definition/accounting/payments.yml b/.mock/definition/accounting/payments.yml index 26c0f1b9b..be829a43a 100644 --- a/.mock/definition/accounting/payments.yml +++ b/.mock/definition/accounting/payments.yml @@ -653,7 +653,7 @@ service: remote_id: '234' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: a47e11b6-c73b-4a0c-be31-130fc48177fa related_object_type: INVOICE @@ -661,7 +661,7 @@ service: remote_id: '235' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: 9b96a886-29a5-452b-8733-2a1e03497cf4 related_object_type: CREDIT_NOTE @@ -734,7 +734,7 @@ service: remote_id: '234' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: a47e11b6-c73b-4a0c-be31-130fc48177fa related_object_type: INVOICE @@ -742,7 +742,7 @@ service: remote_id: '235' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: 9b96a886-29a5-452b-8733-2a1e03497cf4 related_object_type: CREDIT_NOTE @@ -844,7 +844,7 @@ service: remote_id: '234' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: a47e11b6-c73b-4a0c-be31-130fc48177fa related_object_type: INVOICE @@ -852,7 +852,7 @@ service: remote_id: '235' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: 9b96a886-29a5-452b-8733-2a1e03497cf4 related_object_type: CREDIT_NOTE @@ -931,7 +931,7 @@ service: remote_id: '234' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: a47e11b6-c73b-4a0c-be31-130fc48177fa related_object_type: INVOICE @@ -939,7 +939,7 @@ service: remote_id: '235' created_at: '2021-09-15T00:00:00Z' modified_at: '2021-10-16T00:00:00Z' - applied_amount: applied_amount + applied_amount: '25' applied_date: '2020-03-31T00:00:00Z' related_object_id: 9b96a886-29a5-452b-8733-2a1e03497cf4 related_object_type: CREDIT_NOTE diff --git a/package.json b/package.json index d5da4dde5..65535d4de 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mergeapi/merge-node-client", - "version": "2.0.1", + "version": "2.1.0", "private": false, "repository": "https://github.com/merge-api/merge-node-client", "main": "./index.js", diff --git a/reference.md b/reference.md index fcd0ba3fa..d0aca47a1 100644 --- a/reference.md +++ b/reference.md @@ -11249,9 +11249,9 @@ await client.ticketing.webhookReceivers.create({ -## Crm AccountDetails +## Ats AccountDetails -
client.crm.accountDetails.retrieve() -> Merge.AccountDetails +
client.ats.accountDetails.retrieve() -> Merge.AccountDetails
@@ -11279,7 +11279,7 @@ Get details for a linked account.
```typescript -await client.crm.accountDetails.retrieve(); +await client.ats.accountDetails.retrieve(); ```
@@ -11306,9 +11306,9 @@ await client.crm.accountDetails.retrieve();
-## Crm AccountToken +## Ats AccountToken -
client.crm.accountToken.retrieve(publicToken) -> Merge.AccountToken +
client.ats.accountToken.retrieve(publicToken) -> Merge.AccountToken
@@ -11336,7 +11336,7 @@ Returns the account token for the end user with the provided public token.
```typescript -await client.crm.accountToken.retrieve("public_token"); +await client.ats.accountToken.retrieve("public_token"); ```
@@ -11371,9 +11371,9 @@ await client.crm.accountToken.retrieve("public_token");
-## Crm Accounts +## Ats Activities -
client.crm.accounts.list({ ...params }) -> Merge.PaginatedAccountList +
client.ats.activities.list({ ...params }) -> Merge.PaginatedActivityList
@@ -11385,7 +11385,7 @@ await client.crm.accountToken.retrieve("public_token");
-Returns a list of `Account` objects. +Returns a list of `Activity` objects.
@@ -11401,7 +11401,7 @@ Returns a list of `Account` objects.
```typescript -await client.crm.accounts.list(); +await client.ats.activities.list(); ```
@@ -11417,7 +11417,7 @@ await client.crm.accounts.list();
-**request:** `Merge.crm.AccountsListRequest` +**request:** `Merge.ats.ActivitiesListRequest`
@@ -11425,7 +11425,7 @@ await client.crm.accounts.list();
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Activities.RequestOptions`
@@ -11436,7 +11436,7 @@ await client.crm.accounts.list();
-
client.crm.accounts.create({ ...params }) -> Merge.CrmAccountResponse +
client.ats.activities.create({ ...params }) -> Merge.ActivityResponse
@@ -11448,7 +11448,7 @@ await client.crm.accounts.list();
-Creates an `Account` object with the given values. +Creates an `Activity` object with the given values.
@@ -11464,8 +11464,9 @@ Creates an `Account` object with the given values.
```typescript -await client.crm.accounts.create({ +await client.ats.activities.create({ model: {}, + remoteUserId: "remote_user_id", }); ``` @@ -11482,7 +11483,7 @@ await client.crm.accounts.create({
-**request:** `Merge.crm.CrmAccountEndpointRequest` +**request:** `Merge.ats.ActivityEndpointRequest`
@@ -11490,7 +11491,7 @@ await client.crm.accounts.create({
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Activities.RequestOptions`
@@ -11501,7 +11502,7 @@ await client.crm.accounts.create({
-
client.crm.accounts.retrieve(id, { ...params }) -> Merge.Account +
client.ats.activities.retrieve(id, { ...params }) -> Merge.Activity
@@ -11513,7 +11514,7 @@ await client.crm.accounts.create({
-Returns an `Account` object with the given `id`. +Returns an `Activity` object with the given `id`.
@@ -11529,7 +11530,7 @@ Returns an `Account` object with the given `id`.
```typescript -await client.crm.accounts.retrieve("id"); +await client.ats.activities.retrieve("id"); ```
@@ -11553,7 +11554,7 @@ await client.crm.accounts.retrieve("id");
-**request:** `Merge.crm.AccountsRetrieveRequest` +**request:** `Merge.ats.ActivitiesRetrieveRequest`
@@ -11561,7 +11562,7 @@ await client.crm.accounts.retrieve("id");
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Activities.RequestOptions`
@@ -11572,7 +11573,7 @@ await client.crm.accounts.retrieve("id");
-
client.crm.accounts.partialUpdate(id, { ...params }) -> Merge.CrmAccountResponse +
client.ats.activities.metaPostRetrieve() -> Merge.MetaResponse
@@ -11584,7 +11585,7 @@ await client.crm.accounts.retrieve("id");
-Updates an `Account` object with the given `id`. +Returns metadata for `Activity` POSTs.
@@ -11600,9 +11601,7 @@ Updates an `Account` object with the given `id`.
```typescript -await client.crm.accounts.partialUpdate("id", { - model: {}, -}); +await client.ats.activities.metaPostRetrieve(); ```
@@ -11618,23 +11617,7 @@ await client.crm.accounts.partialUpdate("id", {
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.PatchedCrmAccountEndpointRequest` - -
-
- -
-
- -**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Activities.RequestOptions`
@@ -11645,7 +11628,9 @@ await client.crm.accounts.partialUpdate("id", {
-
client.crm.accounts.metaPatchRetrieve(id) -> Merge.MetaResponse +## Ats Applications + +
client.ats.applications.list({ ...params }) -> Merge.PaginatedApplicationList
@@ -11657,7 +11642,7 @@ await client.crm.accounts.partialUpdate("id", {
-Returns metadata for `CRMAccount` PATCHs. +Returns a list of `Application` objects.
@@ -11673,7 +11658,7 @@ Returns metadata for `CRMAccount` PATCHs.
```typescript -await client.crm.accounts.metaPatchRetrieve("id"); +await client.ats.applications.list(); ```
@@ -11689,7 +11674,7 @@ await client.crm.accounts.metaPatchRetrieve("id");
-**id:** `string` +**request:** `Merge.ats.ApplicationsListRequest`
@@ -11697,7 +11682,7 @@ await client.crm.accounts.metaPatchRetrieve("id");
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Applications.RequestOptions`
@@ -11708,7 +11693,7 @@ await client.crm.accounts.metaPatchRetrieve("id");
-
client.crm.accounts.metaPostRetrieve() -> Merge.MetaResponse +
client.ats.applications.create({ ...params }) -> Merge.ApplicationResponse
@@ -11720,7 +11705,10 @@ await client.crm.accounts.metaPatchRetrieve("id");
-Returns metadata for `CRMAccount` POSTs. +Creates an `Application` object with the given values. +For certain integrations, but not all, our API detects duplicate candidates and will associate applications with existing records in the third-party. New candidates are created and automatically linked to the application. + +See our [Help Center article](https://help.merge.dev/en/articles/10012366-updates-to-post-applications-oct-2024) for detailed support per integration.
@@ -11736,7 +11724,10 @@ Returns metadata for `CRMAccount` POSTs.
```typescript -await client.crm.accounts.metaPostRetrieve(); +await client.ats.applications.create({ + model: {}, + remoteUserId: "remote_user_id", +}); ```
@@ -11752,7 +11743,15 @@ await client.crm.accounts.metaPostRetrieve();
-**requestOptions:** `Accounts.RequestOptions` +**request:** `Merge.ats.ApplicationEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `Applications.RequestOptions`
@@ -11763,7 +11762,7 @@ await client.crm.accounts.metaPostRetrieve();
-
client.crm.accounts.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +
client.ats.applications.retrieve(id, { ...params }) -> Merge.Application
@@ -11775,7 +11774,7 @@ await client.crm.accounts.metaPostRetrieve();
-Returns a list of `RemoteFieldClass` objects. +Returns an `Application` object with the given `id`.
@@ -11791,7 +11790,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.accounts.remoteFieldClassesList(); +await client.ats.applications.retrieve("id"); ```
@@ -11807,7 +11806,7 @@ await client.crm.accounts.remoteFieldClassesList();
-**request:** `Merge.crm.AccountsRemoteFieldClassesListRequest` +**id:** `string`
@@ -11815,7 +11814,15 @@ await client.crm.accounts.remoteFieldClassesList();
-**requestOptions:** `Accounts.RequestOptions` +**request:** `Merge.ats.ApplicationsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Applications.RequestOptions`
@@ -11826,9 +11833,7 @@ await client.crm.accounts.remoteFieldClassesList();
-## Crm AsyncPassthrough - -
client.crm.asyncPassthrough.create({ ...params }) -> Merge.AsyncPassthroughReciept +
client.ats.applications.changeStageCreate(id, { ...params }) -> Merge.ApplicationResponse
@@ -11840,7 +11845,7 @@ await client.crm.accounts.remoteFieldClassesList();
-Asynchronously pull data from an endpoint not currently supported by Merge. +Updates the `current_stage` field of an `Application` object
@@ -11856,10 +11861,7 @@ Asynchronously pull data from an endpoint not currently supported by Merge.
```typescript -await client.crm.asyncPassthrough.create({ - method: "GET", - path: "/scooters", -}); +await client.ats.applications.changeStageCreate("id"); ```
@@ -11875,7 +11877,7 @@ await client.crm.asyncPassthrough.create({
-**request:** `Merge.DataPassthroughRequest` +**id:** `string`
@@ -11883,7 +11885,15 @@ await client.crm.asyncPassthrough.create({
-**requestOptions:** `AsyncPassthrough.RequestOptions` +**request:** `Merge.ats.UpdateApplicationStageRequest` + +
+
+ +
+
+ +**requestOptions:** `Applications.RequestOptions`
@@ -11894,7 +11904,7 @@ await client.crm.asyncPassthrough.create({
-
client.crm.asyncPassthrough.retrieve(asyncPassthroughReceiptId) -> Merge.AsyncPassthroughRetrieveResponse +
client.ats.applications.metaPostRetrieve({ ...params }) -> Merge.MetaResponse
@@ -11906,7 +11916,7 @@ await client.crm.asyncPassthrough.create({
-Retrieves data from earlier async-passthrough POST request +Returns metadata for `Application` POSTs.
@@ -11922,7 +11932,7 @@ Retrieves data from earlier async-passthrough POST request
```typescript -await client.crm.asyncPassthrough.retrieve("async_passthrough_receipt_id"); +await client.ats.applications.metaPostRetrieve(); ```
@@ -11938,7 +11948,7 @@ await client.crm.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-**asyncPassthroughReceiptId:** `string` +**request:** `Merge.ats.ApplicationsMetaPostRetrieveRequest`
@@ -11946,7 +11956,7 @@ await client.crm.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-**requestOptions:** `AsyncPassthrough.RequestOptions` +**requestOptions:** `Applications.RequestOptions`
@@ -11957,9 +11967,9 @@ await client.crm.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-## Crm AuditTrail +## Ats AsyncPassthrough -
client.crm.auditTrail.list({ ...params }) -> Merge.PaginatedAuditLogEventList +
client.ats.asyncPassthrough.create({ ...params }) -> Merge.AsyncPassthroughReciept
@@ -11971,7 +11981,7 @@ await client.crm.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-Gets a list of audit trail events. +Asynchronously pull data from an endpoint not currently supported by Merge.
@@ -11987,7 +11997,10 @@ Gets a list of audit trail events.
```typescript -await client.crm.auditTrail.list(); +await client.ats.asyncPassthrough.create({ + method: "GET", + path: "/scooters", +}); ```
@@ -12003,7 +12016,7 @@ await client.crm.auditTrail.list();
-**request:** `Merge.crm.AuditTrailListRequest` +**request:** `Merge.DataPassthroughRequest`
@@ -12011,7 +12024,7 @@ await client.crm.auditTrail.list();
-**requestOptions:** `AuditTrail.RequestOptions` +**requestOptions:** `AsyncPassthrough.RequestOptions`
@@ -12022,9 +12035,7 @@ await client.crm.auditTrail.list();
-## Crm AvailableActions - -
client.crm.availableActions.retrieve() -> Merge.AvailableActions +
client.ats.asyncPassthrough.retrieve(asyncPassthroughReceiptId) -> Merge.AsyncPassthroughRetrieveResponse
@@ -12036,7 +12047,7 @@ await client.crm.auditTrail.list();
-Returns a list of models and actions available for an account. +Retrieves data from earlier async-passthrough POST request
@@ -12052,7 +12063,7 @@ Returns a list of models and actions available for an account.
```typescript -await client.crm.availableActions.retrieve(); +await client.ats.asyncPassthrough.retrieve("async_passthrough_receipt_id"); ```
@@ -12068,7 +12079,15 @@ await client.crm.availableActions.retrieve();
-**requestOptions:** `AvailableActions.RequestOptions` +**asyncPassthroughReceiptId:** `string` + +
+
+ +
+
+ +**requestOptions:** `AsyncPassthrough.RequestOptions`
@@ -12079,9 +12098,9 @@ await client.crm.availableActions.retrieve();
-## Crm Contacts +## Ats Attachments -
client.crm.contacts.list({ ...params }) -> Merge.PaginatedContactList +
client.ats.attachments.list({ ...params }) -> Merge.PaginatedAttachmentList
@@ -12093,7 +12112,7 @@ await client.crm.availableActions.retrieve();
-Returns a list of `Contact` objects. +Returns a list of `Attachment` objects.
@@ -12109,7 +12128,7 @@ Returns a list of `Contact` objects.
```typescript -await client.crm.contacts.list(); +await client.ats.attachments.list(); ```
@@ -12125,7 +12144,7 @@ await client.crm.contacts.list();
-**request:** `Merge.crm.ContactsListRequest` +**request:** `Merge.ats.AttachmentsListRequest`
@@ -12133,7 +12152,7 @@ await client.crm.contacts.list();
-**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -12144,7 +12163,7 @@ await client.crm.contacts.list();
-
client.crm.contacts.create({ ...params }) -> Merge.CrmContactResponse +
client.ats.attachments.create({ ...params }) -> Merge.AttachmentResponse
@@ -12156,7 +12175,7 @@ await client.crm.contacts.list();
-Creates a `Contact` object with the given values. +Creates an `Attachment` object with the given values.
@@ -12172,8 +12191,9 @@ Creates a `Contact` object with the given values.
```typescript -await client.crm.contacts.create({ +await client.ats.attachments.create({ model: {}, + remoteUserId: "remote_user_id", }); ``` @@ -12190,7 +12210,7 @@ await client.crm.contacts.create({
-**request:** `Merge.crm.CrmContactEndpointRequest` +**request:** `Merge.ats.AttachmentEndpointRequest`
@@ -12198,7 +12218,7 @@ await client.crm.contacts.create({
-**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -12209,7 +12229,7 @@ await client.crm.contacts.create({
-
client.crm.contacts.retrieve(id, { ...params }) -> Merge.Contact +
client.ats.attachments.retrieve(id, { ...params }) -> Merge.Attachment
@@ -12221,7 +12241,7 @@ await client.crm.contacts.create({
-Returns a `Contact` object with the given `id`. +Returns an `Attachment` object with the given `id`.
@@ -12237,7 +12257,7 @@ Returns a `Contact` object with the given `id`.
```typescript -await client.crm.contacts.retrieve("id"); +await client.ats.attachments.retrieve("id"); ```
@@ -12261,7 +12281,7 @@ await client.crm.contacts.retrieve("id");
-**request:** `Merge.crm.ContactsRetrieveRequest` +**request:** `Merge.ats.AttachmentsRetrieveRequest`
@@ -12269,7 +12289,7 @@ await client.crm.contacts.retrieve("id");
-**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -12280,7 +12300,7 @@ await client.crm.contacts.retrieve("id");
-
client.crm.contacts.partialUpdate(id, { ...params }) -> Merge.CrmContactResponse +
client.ats.attachments.metaPostRetrieve() -> Merge.MetaResponse
@@ -12292,7 +12312,7 @@ await client.crm.contacts.retrieve("id");
-Updates a `Contact` object with the given `id`. +Returns metadata for `Attachment` POSTs.
@@ -12308,9 +12328,7 @@ Updates a `Contact` object with the given `id`.
```typescript -await client.crm.contacts.partialUpdate("id", { - model: {}, -}); +await client.ats.attachments.metaPostRetrieve(); ```
@@ -12326,23 +12344,7 @@ await client.crm.contacts.partialUpdate("id", {
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.PatchedCrmContactEndpointRequest` - -
-
- -
-
- -**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -12353,7 +12355,9 @@ await client.crm.contacts.partialUpdate("id", {
-
client.crm.contacts.ignoreCreate(modelId, { ...params }) -> void +## Ats AuditTrail + +
client.ats.auditTrail.list({ ...params }) -> Merge.PaginatedAuditLogEventList
@@ -12365,7 +12369,7 @@ await client.crm.contacts.partialUpdate("id", {
-Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in future syncs. The "reason" and "message" fields in the request body will be stored for audit purposes. +Gets a list of audit trail events.
@@ -12381,9 +12385,7 @@ Ignores a specific row based on the `model_id` in the url. These records will ha
```typescript -await client.crm.contacts.ignoreCreate("model_id", { - reason: "GENERAL_CUSTOMER_REQUEST", -}); +await client.ats.auditTrail.list(); ```
@@ -12399,7 +12401,7 @@ await client.crm.contacts.ignoreCreate("model_id", {
-**modelId:** `string` +**request:** `Merge.ats.AuditTrailListRequest`
@@ -12407,15 +12409,64 @@ await client.crm.contacts.ignoreCreate("model_id", {
-**request:** `Merge.IgnoreCommonModelRequest` +**requestOptions:** `AuditTrail.RequestOptions` + +
+
+ +
+
+## Ats AvailableActions + +
client.ats.availableActions.retrieve() -> Merge.AvailableActions
-**requestOptions:** `Contacts.RequestOptions` +#### 📝 Description + +
+
+ +
+
+ +Returns a list of models and actions available for an account. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.availableActions.retrieve(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `AvailableActions.RequestOptions`
@@ -12426,7 +12477,9 @@ await client.crm.contacts.ignoreCreate("model_id", {
-
client.crm.contacts.metaPatchRetrieve(id) -> Merge.MetaResponse +## Ats Candidates + +
client.ats.candidates.list({ ...params }) -> Merge.PaginatedCandidateList
@@ -12438,7 +12491,7 @@ await client.crm.contacts.ignoreCreate("model_id", {
-Returns metadata for `CRMContact` PATCHs. +Returns a list of `Candidate` objects.
@@ -12454,7 +12507,136 @@ Returns metadata for `CRMContact` PATCHs.
```typescript -await client.crm.contacts.metaPatchRetrieve("id"); +await client.ats.candidates.list(); +``` + +
+
+ + + +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Merge.ats.CandidatesListRequest` + +
+
+ +
+
+ +**requestOptions:** `Candidates.RequestOptions` + +
+
+
+
+ + + +
+ +
client.ats.candidates.create({ ...params }) -> Merge.CandidateResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Creates a `Candidate` object with the given values. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.candidates.create({ + model: {}, + remoteUserId: "remote_user_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Merge.ats.CandidateEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `Candidates.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ats.candidates.retrieve(id, { ...params }) -> Merge.Candidate +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Returns a `Candidate` object with the given `id`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.candidates.retrieve("id"); ```
@@ -12478,7 +12660,15 @@ await client.crm.contacts.metaPatchRetrieve("id");
-**requestOptions:** `Contacts.RequestOptions` +**request:** `Merge.ats.CandidatesRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Candidates.RequestOptions`
@@ -12489,7 +12679,7 @@ await client.crm.contacts.metaPatchRetrieve("id");
-
client.crm.contacts.metaPostRetrieve() -> Merge.MetaResponse +
client.ats.candidates.partialUpdate(id, { ...params }) -> Merge.CandidateResponse
@@ -12501,7 +12691,7 @@ await client.crm.contacts.metaPatchRetrieve("id");
-Returns metadata for `CRMContact` POSTs. +Updates a `Candidate` object with the given `id`.
@@ -12517,7 +12707,10 @@ Returns metadata for `CRMContact` POSTs.
```typescript -await client.crm.contacts.metaPostRetrieve(); +await client.ats.candidates.partialUpdate("id", { + model: {}, + remoteUserId: "remote_user_id", +}); ```
@@ -12533,7 +12726,23 @@ await client.crm.contacts.metaPostRetrieve();
-**requestOptions:** `Contacts.RequestOptions` +**id:** `string` + +
+
+ +
+
+ +**request:** `Merge.ats.PatchedCandidateEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `Candidates.RequestOptions`
@@ -12544,7 +12753,7 @@ await client.crm.contacts.metaPostRetrieve();
-
client.crm.contacts.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +
client.ats.candidates.ignoreCreate(modelId, { ...params }) -> void
@@ -12556,7 +12765,458 @@ await client.crm.contacts.metaPostRetrieve();
-Returns a list of `RemoteFieldClass` objects. +Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in future syncs. The "reason" and "message" fields in the request body will be stored for audit purposes. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.candidates.ignoreCreate("model_id", { + reason: "GENERAL_CUSTOMER_REQUEST", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**modelId:** `string` + +
+
+ +
+
+ +**request:** `Merge.ats.IgnoreCommonModelRequest` + +
+
+ +
+
+ +**requestOptions:** `Candidates.RequestOptions` + +
+
+
+
+ + + +
+ +
client.ats.candidates.metaPatchRetrieve(id) -> Merge.MetaResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Returns metadata for `Candidate` PATCHs. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.candidates.metaPatchRetrieve("id"); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `string` + +
+
+ +
+
+ +**requestOptions:** `Candidates.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ats.candidates.metaPostRetrieve() -> Merge.MetaResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Returns metadata for `Candidate` POSTs. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.candidates.metaPostRetrieve(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Candidates.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Ats Scopes + +
client.ats.scopes.defaultScopesRetrieve() -> Merge.CommonModelScopeApi +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.scopes.defaultScopesRetrieve(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Scopes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ats.scopes.linkedAccountScopesRetrieve() -> Merge.CommonModelScopeApi +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.scopes.linkedAccountScopesRetrieve(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Scopes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ats.scopes.linkedAccountScopesCreate({ ...params }) -> Merge.CommonModelScopeApi +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the default Scopes. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes) + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.scopes.linkedAccountScopesCreate({ + commonModels: [ + { + modelName: "Employee", + modelPermissions: { + READ: { + isEnabled: true, + }, + WRITE: { + isEnabled: false, + }, + }, + fieldPermissions: { + enabledFields: ["avatar", "home_location"], + disabledFields: ["work_location"], + }, + }, + { + modelName: "Benefit", + modelPermissions: { + WRITE: { + isEnabled: false, + }, + }, + }, + ], +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Merge.ats.LinkedAccountCommonModelScopeDeserializerRequest` + +
+
+ +
+
+ +**requestOptions:** `Scopes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Ats DeleteAccount + +
client.ats.deleteAccount.delete() -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete a linked account. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ats.deleteAccount.delete(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `DeleteAccount.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Ats Departments + +
client.ats.departments.list({ ...params }) -> Merge.PaginatedDepartmentList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Returns a list of `Department` objects.
@@ -12572,7 +13232,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.contacts.remoteFieldClassesList(); +await client.ats.departments.list(); ```
@@ -12588,7 +13248,7 @@ await client.crm.contacts.remoteFieldClassesList();
-**request:** `Merge.crm.ContactsRemoteFieldClassesListRequest` +**request:** `Merge.ats.DepartmentsListRequest`
@@ -12596,7 +13256,7 @@ await client.crm.contacts.remoteFieldClassesList();
-**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Departments.RequestOptions`
@@ -12607,9 +13267,7 @@ await client.crm.contacts.remoteFieldClassesList();
-## Crm CustomObjectClasses - -
client.crm.customObjectClasses.list({ ...params }) -> Merge.PaginatedCustomObjectClassList +
client.ats.departments.retrieve(id, { ...params }) -> Merge.Department
@@ -12621,7 +13279,7 @@ await client.crm.contacts.remoteFieldClassesList();
-Returns a list of `CustomObjectClass` objects. +Returns a `Department` object with the given `id`.
@@ -12637,7 +13295,7 @@ Returns a list of `CustomObjectClass` objects.
```typescript -await client.crm.customObjectClasses.list(); +await client.ats.departments.retrieve("id"); ```
@@ -12653,7 +13311,7 @@ await client.crm.customObjectClasses.list();
-**request:** `Merge.crm.CustomObjectClassesListRequest` +**id:** `string`
@@ -12661,7 +13319,15 @@ await client.crm.customObjectClasses.list();
-**requestOptions:** `CustomObjectClasses.RequestOptions` +**request:** `Merge.ats.DepartmentsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Departments.RequestOptions`
@@ -12672,7 +13338,9 @@ await client.crm.customObjectClasses.list();
-
client.crm.customObjectClasses.retrieve(id, { ...params }) -> Merge.CustomObjectClass +## Ats Eeocs + +
client.ats.eeocs.list({ ...params }) -> Merge.PaginatedEeocList
@@ -12684,7 +13352,7 @@ await client.crm.customObjectClasses.list();
-Returns a `CustomObjectClass` object with the given `id`. +Returns a list of `EEOC` objects.
@@ -12700,7 +13368,7 @@ Returns a `CustomObjectClass` object with the given `id`.
```typescript -await client.crm.customObjectClasses.retrieve("id"); +await client.ats.eeocs.list(); ```
@@ -12716,15 +13384,7 @@ await client.crm.customObjectClasses.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.CustomObjectClassesRetrieveRequest` +**request:** `Merge.ats.EeocsListRequest`
@@ -12732,7 +13392,7 @@ await client.crm.customObjectClasses.retrieve("id");
-**requestOptions:** `CustomObjectClasses.RequestOptions` +**requestOptions:** `Eeocs.RequestOptions`
@@ -12743,9 +13403,7 @@ await client.crm.customObjectClasses.retrieve("id");
-## Crm AssociationTypes - -
client.crm.associationTypes.customObjectClassesAssociationTypesList(customObjectClassId, { ...params }) -> Merge.PaginatedAssociationTypeList +
client.ats.eeocs.retrieve(id, { ...params }) -> Merge.Eeoc
@@ -12757,7 +13415,7 @@ await client.crm.customObjectClasses.retrieve("id");
-Returns a list of `AssociationType` objects. +Returns an `EEOC` object with the given `id`.
@@ -12773,7 +13431,7 @@ Returns a list of `AssociationType` objects.
```typescript -await client.crm.associationTypes.customObjectClassesAssociationTypesList("custom_object_class_id"); +await client.ats.eeocs.retrieve("id"); ```
@@ -12789,7 +13447,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesList("custo
-**customObjectClassId:** `string` +**id:** `string`
@@ -12797,7 +13455,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesList("custo
-**request:** `Merge.crm.CustomObjectClassesAssociationTypesListRequest` +**request:** `Merge.ats.EeocsRetrieveRequest`
@@ -12805,7 +13463,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesList("custo
-**requestOptions:** `AssociationTypes.RequestOptions` +**requestOptions:** `Eeocs.RequestOptions`
@@ -12816,7 +13474,9 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesList("custo
-
client.crm.associationTypes.customObjectClassesAssociationTypesCreate(customObjectClassId, { ...params }) -> Merge.CrmAssociationTypeResponse +## Ats FieldMapping + +
client.ats.fieldMapping.fieldMappingsRetrieve({ ...params }) -> Merge.FieldMappingApiInstanceResponse
@@ -12828,7 +13488,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesList("custo
-Creates an `AssociationType` object with the given values. +Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge fields. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/).
@@ -12844,21 +13504,7 @@ Creates an `AssociationType` object with the given values.
```typescript -await client.crm.associationTypes.customObjectClassesAssociationTypesCreate("custom_object_class_id", { - model: { - sourceObjectClass: { - id: "id", - originType: "CUSTOM_OBJECT", - }, - targetObjectClasses: [ - { - id: "id", - originType: "CUSTOM_OBJECT", - }, - ], - remoteKeyName: "remote_key_name", - }, -}); +await client.ats.fieldMapping.fieldMappingsRetrieve(); ```
@@ -12874,15 +13520,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesCreate("cus
-**customObjectClassId:** `string` - -
-
- -
-
- -**request:** `Merge.crm.CrmAssociationTypeEndpointRequest` +**request:** `Merge.ats.FieldMappingsRetrieveRequest`
@@ -12890,7 +13528,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesCreate("cus
-**requestOptions:** `AssociationTypes.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -12901,7 +13539,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesCreate("cus
-
client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve(customObjectClassId, id, { ...params }) -> Merge.AssociationType +
client.ats.fieldMapping.fieldMappingsCreate({ ...params }) -> Merge.FieldMappingInstanceResponse
@@ -12913,7 +13551,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesCreate("cus
-Returns an `AssociationType` object with the given `id`. +Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start.
@@ -12929,7 +13567,14 @@ Returns an `AssociationType` object with the given `id`.
```typescript -await client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve("custom_object_class_id", "id"); +await client.ats.fieldMapping.fieldMappingsCreate({ + targetFieldName: "example_target_field_name", + targetFieldDescription: "this is a example description of the target field", + remoteFieldTraversalPath: ["example_remote_field"], + remoteMethod: "GET", + remoteUrlPath: "/example-url-path", + commonModelName: "ExampleCommonModel", +}); ```
@@ -12945,23 +13590,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve("c
-**customObjectClassId:** `string` - -
-
- -
-
- -**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.CustomObjectClassesAssociationTypesRetrieveRequest` +**request:** `Merge.ats.CreateFieldMappingRequest`
@@ -12969,7 +13598,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve("c
-**requestOptions:** `AssociationTypes.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -12980,7 +13609,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve("c
-
client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRetrieve(customObjectClassId) -> Merge.MetaResponse +
client.ats.fieldMapping.fieldMappingsDestroy(fieldMappingId) -> Merge.FieldMappingInstanceResponse
@@ -12992,7 +13621,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve("c
-Returns metadata for `CRMAssociationType` POSTs. +Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start.
@@ -13008,7 +13637,7 @@ Returns metadata for `CRMAssociationType` POSTs.
```typescript -await client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRetrieve("custom_object_class_id"); +await client.ats.fieldMapping.fieldMappingsDestroy("field_mapping_id"); ```
@@ -13024,7 +13653,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRet
-**customObjectClassId:** `string` +**fieldMappingId:** `string`
@@ -13032,7 +13661,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRet
-**requestOptions:** `AssociationTypes.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -13043,9 +13672,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRet
-## Crm CustomObjects - -
client.crm.customObjects.customObjectClassesCustomObjectsList(customObjectClassId, { ...params }) -> Merge.PaginatedCustomObjectList +
client.ats.fieldMapping.fieldMappingsPartialUpdate(fieldMappingId, { ...params }) -> Merge.FieldMappingInstanceResponse
@@ -13057,7 +13684,7 @@ await client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRet
-Returns a list of `CustomObject` objects. +Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start.
@@ -13073,7 +13700,7 @@ Returns a list of `CustomObject` objects.
```typescript -await client.crm.customObjects.customObjectClassesCustomObjectsList("custom_object_class_id"); +await client.ats.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id"); ```
@@ -13089,7 +13716,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsList("custom_obje
-**customObjectClassId:** `string` +**fieldMappingId:** `string`
@@ -13097,7 +13724,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsList("custom_obje
-**request:** `Merge.crm.CustomObjectClassesCustomObjectsListRequest` +**request:** `Merge.ats.PatchedEditFieldMappingRequest`
@@ -13105,7 +13732,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsList("custom_obje
-**requestOptions:** `CustomObjects.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -13116,7 +13743,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsList("custom_obje
-
client.crm.customObjects.customObjectClassesCustomObjectsCreate(customObjectClassId, { ...params }) -> Merge.CrmCustomObjectResponse +
client.ats.fieldMapping.remoteFieldsRetrieve({ ...params }) -> Merge.RemoteFieldApiResponse
@@ -13128,7 +13755,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsList("custom_obje
-Creates a `CustomObject` object with the given values. +Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data is enabled. You can use remote fields to override existing Merge fields or map a new Merge field. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/).
@@ -13144,13 +13771,7 @@ Creates a `CustomObject` object with the given values.
```typescript -await client.crm.customObjects.customObjectClassesCustomObjectsCreate("custom_object_class_id", { - model: { - fields: { - test_field: "hello", - }, - }, -}); +await client.ats.fieldMapping.remoteFieldsRetrieve(); ```
@@ -13166,15 +13787,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsCreate("custom_ob
-**customObjectClassId:** `string` - -
-
- -
-
- -**request:** `Merge.crm.CrmCustomObjectEndpointRequest` +**request:** `Merge.ats.RemoteFieldsRetrieveRequest`
@@ -13182,7 +13795,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsCreate("custom_ob
-**requestOptions:** `CustomObjects.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -13193,7 +13806,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsCreate("custom_ob
-
client.crm.customObjects.customObjectClassesCustomObjectsRetrieve(customObjectClassId, id, { ...params }) -> Merge.CustomObject +
client.ats.fieldMapping.targetFieldsRetrieve() -> Merge.ExternalTargetFieldApiResponse
@@ -13205,7 +13818,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsCreate("custom_ob
-Returns a `CustomObject` object with the given `id`. +Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields are additional fields appended to the Merge Common Model for all Linked Accounts in a category. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/target-fields/).
@@ -13221,7 +13834,7 @@ Returns a `CustomObject` object with the given `id`.
```typescript -await client.crm.customObjects.customObjectClassesCustomObjectsRetrieve("custom_object_class_id", "id"); +await client.ats.fieldMapping.targetFieldsRetrieve(); ```
@@ -13237,31 +13850,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsRetrieve("custom_
-**customObjectClassId:** `string` - -
-
- -
-
- -**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.CustomObjectClassesCustomObjectsRetrieveRequest` - -
-
- -
-
- -**requestOptions:** `CustomObjects.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -13272,7 +13861,9 @@ await client.crm.customObjects.customObjectClassesCustomObjectsRetrieve("custom_
-
client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve(customObjectClassId) -> Merge.MetaResponse +## Ats GenerateKey + +
client.ats.generateKey.create({ ...params }) -> Merge.RemoteKey
@@ -13284,7 +13875,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsRetrieve("custom_
-Returns metadata for `CRMCustomObject` POSTs. +Create a remote key.
@@ -13300,7 +13891,9 @@ Returns metadata for `CRMCustomObject` POSTs.
```typescript -await client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve("custom_object_class_id"); +await client.ats.generateKey.create({ + name: "Remote Deployment Key 1", +}); ```
@@ -13316,7 +13909,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve(
-**customObjectClassId:** `string` +**request:** `Merge.ats.GenerateRemoteKeyRequest`
@@ -13324,7 +13917,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve(
-**requestOptions:** `CustomObjects.RequestOptions` +**requestOptions:** `GenerateKey.RequestOptions`
@@ -13335,7 +13928,9 @@ await client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve(
-
client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +## Ats Interviews + +
client.ats.interviews.list({ ...params }) -> Merge.PaginatedScheduledInterviewList
@@ -13347,7 +13942,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve(
-Returns a list of `RemoteFieldClass` objects. +Returns a list of `ScheduledInterview` objects.
@@ -13363,7 +13958,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClassesList(); +await client.ats.interviews.list(); ```
@@ -13379,7 +13974,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClasse
-**request:** `Merge.crm.CustomObjectClassesCustomObjectsRemoteFieldClassesListRequest` +**request:** `Merge.ats.InterviewsListRequest`
@@ -13387,7 +13982,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClasse
-**requestOptions:** `CustomObjects.RequestOptions` +**requestOptions:** `Interviews.RequestOptions`
@@ -13398,9 +13993,7 @@ await client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClasse
-## Crm Associations - -
client.crm.associations.customObjectClassesCustomObjectsAssociationsList(customObjectClassId, objectId, { ...params }) -> Merge.PaginatedAssociationList +
client.ats.interviews.create({ ...params }) -> Merge.ScheduledInterviewResponse
@@ -13412,31 +14005,14 @@ await client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClasse
-Returns a list of `Association` objects. - -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```typescript -await client.crm.associations.customObjectClassesCustomObjectsAssociationsList("custom_object_class_id", "object_id"); -``` - +Creates a `ScheduledInterview` object with the given values. +
-#### ⚙️ Parameters +#### 🔌 Usage
@@ -13444,23 +14020,27 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsList("
-**customObjectClassId:** `string` +```typescript +await client.ats.interviews.create({ + model: {}, + remoteUserId: "remote_user_id", +}); +```
+
+
+ +#### ⚙️ Parameters
-**objectId:** `string` - -
-
-
-**request:** `Merge.crm.CustomObjectClassesCustomObjectsAssociationsListRequest` +**request:** `Merge.ats.ScheduledInterviewEndpointRequest`
@@ -13468,7 +14048,7 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsList("
-**requestOptions:** `Associations.RequestOptions` +**requestOptions:** `Interviews.RequestOptions`
@@ -13479,7 +14059,7 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsList("
-
client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate(associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, { ...params }) -> Merge.Association +
client.ats.interviews.retrieve(id, { ...params }) -> Merge.ScheduledInterview
@@ -13491,7 +14071,7 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsList("
-Creates an Association between `source_object_id` and `target_object_id` of type `association_type_id`. +Returns a `ScheduledInterview` object with the given `id`.
@@ -13507,13 +14087,7 @@ Creates an Association between `source_object_id` and `target_object_id` of type
```typescript -await client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate( - "association_type_id", - "source_class_id", - "source_object_id", - "target_class_id", - "target_object_id", -); +await client.ats.interviews.retrieve("id"); ```
@@ -13529,7 +14103,7 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate
-**associationTypeId:** `string` +**id:** `string`
@@ -13537,7 +14111,7 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate
-**sourceClassId:** `string` +**request:** `Merge.ats.InterviewsRetrieveRequest`
@@ -13545,39 +14119,62 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate
-**sourceObjectId:** `string` +**requestOptions:** `Interviews.RequestOptions` + +
+
+ +
+
+
client.ats.interviews.metaPostRetrieve() -> Merge.MetaResponse
-**targetClassId:** `string` +#### 📝 Description -
-
+
+
-**targetObjectId:** `string` +Returns metadata for `ScheduledInterview` POSTs.
+
+
+ +#### 🔌 Usage
-**request:** `Merge.crm.CustomObjectClassesCustomObjectsAssociationsUpdateRequest` +
+
+ +```typescript +await client.ats.interviews.metaPostRetrieve(); +```
+
+
+ +#### ⚙️ Parameters
-**requestOptions:** `Associations.RequestOptions` +
+
+ +**requestOptions:** `Interviews.RequestOptions`
@@ -13588,9 +14185,9 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate
-## Crm Scopes +## Ats Issues -
client.crm.scopes.defaultScopesRetrieve() -> Merge.CommonModelScopeApi +
client.ats.issues.list({ ...params }) -> Merge.PaginatedIssueList
@@ -13602,7 +14199,7 @@ await client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate
-Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). +Gets all issues for Organization.
@@ -13618,7 +14215,7 @@ Get the default permissions for Merge Common Models and fields across all Linked
```typescript -await client.crm.scopes.defaultScopesRetrieve(); +await client.ats.issues.list(); ```
@@ -13634,7 +14231,15 @@ await client.crm.scopes.defaultScopesRetrieve();
-**requestOptions:** `Scopes.RequestOptions` +**request:** `Merge.ats.IssuesListRequest` + +
+
+ +
+
+ +**requestOptions:** `Issues.RequestOptions`
@@ -13645,7 +14250,7 @@ await client.crm.scopes.defaultScopesRetrieve();
-
client.crm.scopes.linkedAccountScopesRetrieve() -> Merge.CommonModelScopeApi +
client.ats.issues.retrieve(id) -> Merge.Issue
@@ -13657,7 +14262,7 @@ await client.crm.scopes.defaultScopesRetrieve();
-Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). +Get a specific issue.
@@ -13673,7 +14278,7 @@ Get all available permissions for Merge Common Models and fields for a single Li
```typescript -await client.crm.scopes.linkedAccountScopesRetrieve(); +await client.ats.issues.retrieve("id"); ```
@@ -13689,7 +14294,15 @@ await client.crm.scopes.linkedAccountScopesRetrieve();
-**requestOptions:** `Scopes.RequestOptions` +**id:** `string` + +
+
+ +
+
+ +**requestOptions:** `Issues.RequestOptions`
@@ -13700,7 +14313,9 @@ await client.crm.scopes.linkedAccountScopesRetrieve();
-
client.crm.scopes.linkedAccountScopesCreate({ ...params }) -> Merge.CommonModelScopeApi +## Ats JobInterviewStages + +
client.ats.jobInterviewStages.list({ ...params }) -> Merge.PaginatedJobInterviewStageList
@@ -13712,7 +14327,7 @@ await client.crm.scopes.linkedAccountScopesRetrieve();
-Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the default Scopes. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes) +Returns a list of `JobInterviewStage` objects.
@@ -13728,33 +14343,7 @@ Update permissions for any Common Model or field for a single Linked Account. An
```typescript -await client.crm.scopes.linkedAccountScopesCreate({ - commonModels: [ - { - modelName: "Employee", - modelPermissions: { - READ: { - isEnabled: true, - }, - WRITE: { - isEnabled: false, - }, - }, - fieldPermissions: { - enabledFields: ["avatar", "home_location"], - disabledFields: ["work_location"], - }, - }, - { - modelName: "Benefit", - modelPermissions: { - WRITE: { - isEnabled: false, - }, - }, - }, - ], -}); +await client.ats.jobInterviewStages.list(); ```
@@ -13770,7 +14359,7 @@ await client.crm.scopes.linkedAccountScopesCreate({
-**request:** `Merge.crm.LinkedAccountCommonModelScopeDeserializerRequest` +**request:** `Merge.ats.JobInterviewStagesListRequest`
@@ -13778,7 +14367,7 @@ await client.crm.scopes.linkedAccountScopesCreate({
-**requestOptions:** `Scopes.RequestOptions` +**requestOptions:** `JobInterviewStages.RequestOptions`
@@ -13789,9 +14378,7 @@ await client.crm.scopes.linkedAccountScopesCreate({
-## Crm DeleteAccount - -
client.crm.deleteAccount.delete() -> void +
client.ats.jobInterviewStages.retrieve(id, { ...params }) -> Merge.JobInterviewStage
@@ -13803,7 +14390,7 @@ await client.crm.scopes.linkedAccountScopesCreate({
-Delete a linked account. +Returns a `JobInterviewStage` object with the given `id`.
@@ -13819,7 +14406,7 @@ Delete a linked account.
```typescript -await client.crm.deleteAccount.delete(); +await client.ats.jobInterviewStages.retrieve("id"); ```
@@ -13835,7 +14422,23 @@ await client.crm.deleteAccount.delete();
-**requestOptions:** `DeleteAccount.RequestOptions` +**id:** `string` + +
+
+ +
+
+ +**request:** `Merge.ats.JobInterviewStagesRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `JobInterviewStages.RequestOptions`
@@ -13846,9 +14449,9 @@ await client.crm.deleteAccount.delete();
-## Crm EngagementTypes +## Ats JobPostings -
client.crm.engagementTypes.list({ ...params }) -> Merge.PaginatedEngagementTypeList +
client.ats.jobPostings.list({ ...params }) -> Merge.PaginatedJobPostingList
@@ -13860,7 +14463,7 @@ await client.crm.deleteAccount.delete();
-Returns a list of `EngagementType` objects. +Returns a list of `JobPosting` objects.
@@ -13876,7 +14479,7 @@ Returns a list of `EngagementType` objects.
```typescript -await client.crm.engagementTypes.list(); +await client.ats.jobPostings.list(); ```
@@ -13892,7 +14495,7 @@ await client.crm.engagementTypes.list();
-**request:** `Merge.crm.EngagementTypesListRequest` +**request:** `Merge.ats.JobPostingsListRequest`
@@ -13900,7 +14503,7 @@ await client.crm.engagementTypes.list();
-**requestOptions:** `EngagementTypes.RequestOptions` +**requestOptions:** `JobPostings.RequestOptions`
@@ -13911,7 +14514,7 @@ await client.crm.engagementTypes.list();
-
client.crm.engagementTypes.retrieve(id, { ...params }) -> Merge.EngagementType +
client.ats.jobPostings.retrieve(id, { ...params }) -> Merge.JobPosting
@@ -13923,7 +14526,7 @@ await client.crm.engagementTypes.list();
-Returns an `EngagementType` object with the given `id`. +Returns a `JobPosting` object with the given `id`.
@@ -13939,7 +14542,7 @@ Returns an `EngagementType` object with the given `id`.
```typescript -await client.crm.engagementTypes.retrieve("id"); +await client.ats.jobPostings.retrieve("id"); ```
@@ -13963,7 +14566,7 @@ await client.crm.engagementTypes.retrieve("id");
-**request:** `Merge.crm.EngagementTypesRetrieveRequest` +**request:** `Merge.ats.JobPostingsRetrieveRequest`
@@ -13971,7 +14574,7 @@ await client.crm.engagementTypes.retrieve("id");
-**requestOptions:** `EngagementTypes.RequestOptions` +**requestOptions:** `JobPostings.RequestOptions`
@@ -13982,7 +14585,9 @@ await client.crm.engagementTypes.retrieve("id");
-
client.crm.engagementTypes.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +## Ats Jobs + +
client.ats.jobs.list({ ...params }) -> Merge.PaginatedJobList
@@ -13994,7 +14599,7 @@ await client.crm.engagementTypes.retrieve("id");
-Returns a list of `RemoteFieldClass` objects. +Returns a list of `Job` objects.
@@ -14010,7 +14615,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.engagementTypes.remoteFieldClassesList(); +await client.ats.jobs.list(); ```
@@ -14026,7 +14631,7 @@ await client.crm.engagementTypes.remoteFieldClassesList();
-**request:** `Merge.crm.EngagementTypesRemoteFieldClassesListRequest` +**request:** `Merge.ats.JobsListRequest`
@@ -14034,7 +14639,7 @@ await client.crm.engagementTypes.remoteFieldClassesList();
-**requestOptions:** `EngagementTypes.RequestOptions` +**requestOptions:** `Jobs.RequestOptions`
@@ -14045,9 +14650,7 @@ await client.crm.engagementTypes.remoteFieldClassesList();
-## Crm Engagements - -
client.crm.engagements.list({ ...params }) -> Merge.PaginatedEngagementList +
client.ats.jobs.retrieve(id, { ...params }) -> Merge.Job
@@ -14059,7 +14662,7 @@ await client.crm.engagementTypes.remoteFieldClassesList();
-Returns a list of `Engagement` objects. +Returns a `Job` object with the given `id`.
@@ -14075,7 +14678,7 @@ Returns a list of `Engagement` objects.
```typescript -await client.crm.engagements.list(); +await client.ats.jobs.retrieve("id"); ```
@@ -14091,7 +14694,7 @@ await client.crm.engagements.list();
-**request:** `Merge.crm.EngagementsListRequest` +**id:** `string`
@@ -14099,7 +14702,15 @@ await client.crm.engagements.list();
-**requestOptions:** `Engagements.RequestOptions` +**request:** `Merge.ats.JobsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Jobs.RequestOptions`
@@ -14110,7 +14721,7 @@ await client.crm.engagements.list();
-
client.crm.engagements.create({ ...params }) -> Merge.EngagementResponse +
client.ats.jobs.screeningQuestionsList(jobId, { ...params }) -> Merge.PaginatedScreeningQuestionList
@@ -14122,7 +14733,7 @@ await client.crm.engagements.list();
-Creates an `Engagement` object with the given values. +Returns a list of `ScreeningQuestion` objects.
@@ -14138,9 +14749,7 @@ Creates an `Engagement` object with the given values.
```typescript -await client.crm.engagements.create({ - model: {}, -}); +await client.ats.jobs.screeningQuestionsList("job_id"); ```
@@ -14156,7 +14765,7 @@ await client.crm.engagements.create({
-**request:** `Merge.crm.EngagementEndpointRequest` +**jobId:** `string`
@@ -14164,7 +14773,15 @@ await client.crm.engagements.create({
-**requestOptions:** `Engagements.RequestOptions` +**request:** `Merge.ats.JobsScreeningQuestionsListRequest` + +
+
+ +
+
+ +**requestOptions:** `Jobs.RequestOptions`
@@ -14175,7 +14792,9 @@ await client.crm.engagements.create({
-
client.crm.engagements.retrieve(id, { ...params }) -> Merge.Engagement +## Ats LinkToken + +
client.ats.linkToken.create({ ...params }) -> Merge.LinkToken
@@ -14187,7 +14806,7 @@ await client.crm.engagements.create({
-Returns an `Engagement` object with the given `id`. +Creates a link token to be used when linking a new end user.
@@ -14203,7 +14822,12 @@ Returns an `Engagement` object with the given `id`.
```typescript -await client.crm.engagements.retrieve("id"); +await client.ats.linkToken.create({ + endUserEmailAddress: "example@gmail.com", + endUserOrganizationName: "Test Organization", + endUserOriginId: "12345", + categories: ["hris", "ats"], +}); ```
@@ -14219,15 +14843,7 @@ await client.crm.engagements.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.EngagementsRetrieveRequest` +**request:** `Merge.ats.EndUserDetailsRequest`
@@ -14235,7 +14851,7 @@ await client.crm.engagements.retrieve("id");
-**requestOptions:** `Engagements.RequestOptions` +**requestOptions:** `LinkToken.RequestOptions`
@@ -14246,7 +14862,9 @@ await client.crm.engagements.retrieve("id");
-
client.crm.engagements.partialUpdate(id, { ...params }) -> Merge.EngagementResponse +## Ats LinkedAccounts + +
client.ats.linkedAccounts.list({ ...params }) -> Merge.PaginatedAccountDetailsAndActionsList
@@ -14258,7 +14876,7 @@ await client.crm.engagements.retrieve("id");
-Updates an `Engagement` object with the given `id`. +List linked accounts for your organization.
@@ -14274,9 +14892,7 @@ Updates an `Engagement` object with the given `id`.
```typescript -await client.crm.engagements.partialUpdate("id", { - model: {}, -}); +await client.ats.linkedAccounts.list(); ```
@@ -14292,15 +14908,7 @@ await client.crm.engagements.partialUpdate("id", {
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.PatchedEngagementEndpointRequest` +**request:** `Merge.ats.LinkedAccountsListRequest`
@@ -14308,7 +14916,7 @@ await client.crm.engagements.partialUpdate("id", {
-**requestOptions:** `Engagements.RequestOptions` +**requestOptions:** `LinkedAccounts.RequestOptions`
@@ -14319,7 +14927,9 @@ await client.crm.engagements.partialUpdate("id", {
-
client.crm.engagements.metaPatchRetrieve(id) -> Merge.MetaResponse +## Ats Offers + +
client.ats.offers.list({ ...params }) -> Merge.PaginatedOfferList
@@ -14331,7 +14941,7 @@ await client.crm.engagements.partialUpdate("id", {
-Returns metadata for `Engagement` PATCHs. +Returns a list of `Offer` objects.
@@ -14347,7 +14957,7 @@ Returns metadata for `Engagement` PATCHs.
```typescript -await client.crm.engagements.metaPatchRetrieve("id"); +await client.ats.offers.list(); ```
@@ -14363,7 +14973,7 @@ await client.crm.engagements.metaPatchRetrieve("id");
-**id:** `string` +**request:** `Merge.ats.OffersListRequest`
@@ -14371,7 +14981,7 @@ await client.crm.engagements.metaPatchRetrieve("id");
-**requestOptions:** `Engagements.RequestOptions` +**requestOptions:** `Offers.RequestOptions`
@@ -14382,7 +14992,7 @@ await client.crm.engagements.metaPatchRetrieve("id");
-
client.crm.engagements.metaPostRetrieve() -> Merge.MetaResponse +
client.ats.offers.retrieve(id, { ...params }) -> Merge.Offer
@@ -14394,7 +15004,7 @@ await client.crm.engagements.metaPatchRetrieve("id");
-Returns metadata for `Engagement` POSTs. +Returns an `Offer` object with the given `id`.
@@ -14410,7 +15020,7 @@ Returns metadata for `Engagement` POSTs.
```typescript -await client.crm.engagements.metaPostRetrieve(); +await client.ats.offers.retrieve("id"); ```
@@ -14426,7 +15036,23 @@ await client.crm.engagements.metaPostRetrieve();
-**requestOptions:** `Engagements.RequestOptions` +**id:** `string` + +
+
+ +
+
+ +**request:** `Merge.ats.OffersRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Offers.RequestOptions`
@@ -14437,7 +15063,9 @@ await client.crm.engagements.metaPostRetrieve();
-
client.crm.engagements.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +## Ats Offices + +
client.ats.offices.list({ ...params }) -> Merge.PaginatedOfficeList
@@ -14449,7 +15077,7 @@ await client.crm.engagements.metaPostRetrieve();
-Returns a list of `RemoteFieldClass` objects. +Returns a list of `Office` objects.
@@ -14465,7 +15093,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.engagements.remoteFieldClassesList(); +await client.ats.offices.list(); ```
@@ -14481,7 +15109,7 @@ await client.crm.engagements.remoteFieldClassesList();
-**request:** `Merge.crm.EngagementsRemoteFieldClassesListRequest` +**request:** `Merge.ats.OfficesListRequest`
@@ -14489,7 +15117,7 @@ await client.crm.engagements.remoteFieldClassesList();
-**requestOptions:** `Engagements.RequestOptions` +**requestOptions:** `Offices.RequestOptions`
@@ -14500,9 +15128,7 @@ await client.crm.engagements.remoteFieldClassesList();
-## Crm FieldMapping - -
client.crm.fieldMapping.fieldMappingsRetrieve({ ...params }) -> Merge.FieldMappingApiInstanceResponse +
client.ats.offices.retrieve(id, { ...params }) -> Merge.Office
@@ -14514,7 +15140,7 @@ await client.crm.engagements.remoteFieldClassesList();
-Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge fields. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/). +Returns an `Office` object with the given `id`.
@@ -14530,7 +15156,7 @@ Get all Field Mappings for this Linked Account. Field Mappings are mappings betw
```typescript -await client.crm.fieldMapping.fieldMappingsRetrieve(); +await client.ats.offices.retrieve("id"); ```
@@ -14546,7 +15172,7 @@ await client.crm.fieldMapping.fieldMappingsRetrieve();
-**request:** `Merge.crm.FieldMappingsRetrieveRequest` +**id:** `string`
@@ -14554,7 +15180,15 @@ await client.crm.fieldMapping.fieldMappingsRetrieve();
-**requestOptions:** `FieldMapping.RequestOptions` +**request:** `Merge.ats.OfficesRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Offices.RequestOptions`
@@ -14565,7 +15199,9 @@ await client.crm.fieldMapping.fieldMappingsRetrieve();
-
client.crm.fieldMapping.fieldMappingsCreate({ ...params }) -> Merge.FieldMappingInstanceResponse +## Ats Passthrough + +
client.ats.passthrough.create({ ...params }) -> Merge.RemoteResponse
@@ -14577,7 +15213,7 @@ await client.crm.fieldMapping.fieldMappingsRetrieve();
-Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start. +Pull data from an endpoint not currently supported by Merge.
@@ -14593,13 +15229,9 @@ Create new Field Mappings that will be available after the next scheduled sync.
```typescript -await client.crm.fieldMapping.fieldMappingsCreate({ - targetFieldName: "example_target_field_name", - targetFieldDescription: "this is a example description of the target field", - remoteFieldTraversalPath: ["example_remote_field"], - remoteMethod: "GET", - remoteUrlPath: "/example-url-path", - commonModelName: "ExampleCommonModel", +await client.ats.passthrough.create({ + method: "GET", + path: "/scooters", }); ``` @@ -14616,7 +15248,7 @@ await client.crm.fieldMapping.fieldMappingsCreate({
-**request:** `Merge.crm.CreateFieldMappingRequest` +**request:** `Merge.DataPassthroughRequest`
@@ -14624,7 +15256,7 @@ await client.crm.fieldMapping.fieldMappingsCreate({
-**requestOptions:** `FieldMapping.RequestOptions` +**requestOptions:** `Passthrough.RequestOptions`
@@ -14635,7 +15267,9 @@ await client.crm.fieldMapping.fieldMappingsCreate({
-
client.crm.fieldMapping.fieldMappingsDestroy(fieldMappingId) -> Merge.FieldMappingInstanceResponse +## Ats RegenerateKey + +
client.ats.regenerateKey.create({ ...params }) -> Merge.RemoteKey
@@ -14647,7 +15281,7 @@ await client.crm.fieldMapping.fieldMappingsCreate({
-Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start. +Exchange remote keys.
@@ -14663,7 +15297,9 @@ Deletes Field Mappings for a Linked Account. All data related to this Field Mapp
```typescript -await client.crm.fieldMapping.fieldMappingsDestroy("field_mapping_id"); +await client.ats.regenerateKey.create({ + name: "Remote Deployment Key 1", +}); ```
@@ -14679,7 +15315,7 @@ await client.crm.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-**fieldMappingId:** `string` +**request:** `Merge.ats.RemoteKeyForRegenerationRequest`
@@ -14687,7 +15323,7 @@ await client.crm.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-**requestOptions:** `FieldMapping.RequestOptions` +**requestOptions:** `RegenerateKey.RequestOptions`
@@ -14698,7 +15334,9 @@ await client.crm.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-
client.crm.fieldMapping.fieldMappingsPartialUpdate(fieldMappingId, { ...params }) -> Merge.FieldMappingInstanceResponse +## Ats RejectReasons + +
client.ats.rejectReasons.list({ ...params }) -> Merge.PaginatedRejectReasonList
@@ -14710,7 +15348,7 @@ await client.crm.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start. +Returns a list of `RejectReason` objects.
@@ -14726,7 +15364,7 @@ Create or update existing Field Mappings for a Linked Account. Changes will be r
```typescript -await client.crm.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id"); +await client.ats.rejectReasons.list(); ```
@@ -14742,15 +15380,7 @@ await client.crm.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-**fieldMappingId:** `string` - -
-
- -
-
- -**request:** `Merge.crm.PatchedEditFieldMappingRequest` +**request:** `Merge.ats.RejectReasonsListRequest`
@@ -14758,7 +15388,7 @@ await client.crm.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-**requestOptions:** `FieldMapping.RequestOptions` +**requestOptions:** `RejectReasons.RequestOptions`
@@ -14769,7 +15399,7 @@ await client.crm.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-
client.crm.fieldMapping.remoteFieldsRetrieve({ ...params }) -> Merge.RemoteFieldApiResponse +
client.ats.rejectReasons.retrieve(id, { ...params }) -> Merge.RejectReason
@@ -14781,7 +15411,7 @@ await client.crm.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data is enabled. You can use remote fields to override existing Merge fields or map a new Merge field. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/). +Returns a `RejectReason` object with the given `id`.
@@ -14797,7 +15427,7 @@ Get all remote fields for a Linked Account. Remote fields are third-party fields
```typescript -await client.crm.fieldMapping.remoteFieldsRetrieve(); +await client.ats.rejectReasons.retrieve("id"); ```
@@ -14813,7 +15443,7 @@ await client.crm.fieldMapping.remoteFieldsRetrieve();
-**request:** `Merge.crm.RemoteFieldsRetrieveRequest` +**id:** `string`
@@ -14821,7 +15451,15 @@ await client.crm.fieldMapping.remoteFieldsRetrieve();
-**requestOptions:** `FieldMapping.RequestOptions` +**request:** `Merge.ats.RejectReasonsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `RejectReasons.RequestOptions`
@@ -14832,7 +15470,9 @@ await client.crm.fieldMapping.remoteFieldsRetrieve();
-
client.crm.fieldMapping.targetFieldsRetrieve() -> Merge.ExternalTargetFieldApiResponse +## Ats Scorecards + +
client.ats.scorecards.list({ ...params }) -> Merge.PaginatedScorecardList
@@ -14844,7 +15484,7 @@ await client.crm.fieldMapping.remoteFieldsRetrieve();
-Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields are additional fields appended to the Merge Common Model for all Linked Accounts in a category. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/target-fields/). +Returns a list of `Scorecard` objects.
@@ -14860,7 +15500,7 @@ Get all organization-wide Target Fields, this will not include any Linked Accoun
```typescript -await client.crm.fieldMapping.targetFieldsRetrieve(); +await client.ats.scorecards.list(); ```
@@ -14876,7 +15516,15 @@ await client.crm.fieldMapping.targetFieldsRetrieve();
-**requestOptions:** `FieldMapping.RequestOptions` +**request:** `Merge.ats.ScorecardsListRequest` + +
+
+ +
+
+ +**requestOptions:** `Scorecards.RequestOptions`
@@ -14887,9 +15535,7 @@ await client.crm.fieldMapping.targetFieldsRetrieve();
-## Crm GenerateKey - -
client.crm.generateKey.create({ ...params }) -> Merge.RemoteKey +
client.ats.scorecards.retrieve(id, { ...params }) -> Merge.Scorecard
@@ -14901,7 +15547,7 @@ await client.crm.fieldMapping.targetFieldsRetrieve();
-Create a remote key. +Returns a `Scorecard` object with the given `id`.
@@ -14917,9 +15563,7 @@ Create a remote key.
```typescript -await client.crm.generateKey.create({ - name: "Remote Deployment Key 1", -}); +await client.ats.scorecards.retrieve("id"); ```
@@ -14935,7 +15579,7 @@ await client.crm.generateKey.create({
-**request:** `Merge.crm.GenerateRemoteKeyRequest` +**id:** `string`
@@ -14943,7 +15587,15 @@ await client.crm.generateKey.create({
-**requestOptions:** `GenerateKey.RequestOptions` +**request:** `Merge.ats.ScorecardsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Scorecards.RequestOptions`
@@ -14954,9 +15606,9 @@ await client.crm.generateKey.create({
-## Crm Issues +## Ats SyncStatus -
client.crm.issues.list({ ...params }) -> Merge.PaginatedIssueList +
client.ats.syncStatus.list({ ...params }) -> Merge.PaginatedSyncStatusList
@@ -14968,7 +15620,7 @@ await client.crm.generateKey.create({
-Gets all issues for Organization. +Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. `last_sync_finished` represents the most recent time any sync completed. These timestamps may correspond to different sync instances which may result in a sync start time being later than a separate sync completed time. To ensure you are retrieving the latest available data reference the `last_sync_finished` timestamp where `last_sync_result` is `DONE`. Possible values for `status` and `last_sync_result` are `DISABLED`, `DONE`, `FAILED`, `PARTIALLY_SYNCED`, `PAUSED`, `SYNCING`. Learn more about sync status in our [Help Center](https://help.merge.dev/en/articles/8184193-merge-sync-statuses).
@@ -14984,7 +15636,7 @@ Gets all issues for Organization.
```typescript -await client.crm.issues.list(); +await client.ats.syncStatus.list(); ```
@@ -15000,7 +15652,7 @@ await client.crm.issues.list();
-**request:** `Merge.crm.IssuesListRequest` +**request:** `Merge.ats.SyncStatusListRequest`
@@ -15008,7 +15660,7 @@ await client.crm.issues.list();
-**requestOptions:** `Issues.RequestOptions` +**requestOptions:** `SyncStatus.RequestOptions`
@@ -15019,7 +15671,9 @@ await client.crm.issues.list();
-
client.crm.issues.retrieve(id) -> Merge.Issue +## Ats ForceResync + +
client.ats.forceResync.syncStatusResyncCreate() -> Merge.SyncStatus[]
@@ -15031,7 +15685,7 @@ await client.crm.issues.list();
-Get a specific issue. +Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or Enterprise plans. Doing so will consume a sync credit for the relevant linked account. Force re-syncs can also be triggered manually in the Merge Dashboard and is available for all customers.
@@ -15047,7 +15701,7 @@ Get a specific issue.
```typescript -await client.crm.issues.retrieve("id"); +await client.ats.forceResync.syncStatusResyncCreate(); ```
@@ -15063,15 +15717,7 @@ await client.crm.issues.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**requestOptions:** `Issues.RequestOptions` +**requestOptions:** `ForceResync.RequestOptions`
@@ -15082,9 +15728,9 @@ await client.crm.issues.retrieve("id");
-## Crm Leads +## Ats Tags -
client.crm.leads.list({ ...params }) -> Merge.PaginatedLeadList +
client.ats.tags.list({ ...params }) -> Merge.PaginatedTagList
@@ -15096,7 +15742,7 @@ await client.crm.issues.retrieve("id");
-Returns a list of `Lead` objects. +Returns a list of `Tag` objects.
@@ -15112,7 +15758,7 @@ Returns a list of `Lead` objects.
```typescript -await client.crm.leads.list(); +await client.ats.tags.list(); ```
@@ -15128,7 +15774,7 @@ await client.crm.leads.list();
-**request:** `Merge.crm.LeadsListRequest` +**request:** `Merge.ats.TagsListRequest`
@@ -15136,7 +15782,7 @@ await client.crm.leads.list();
-**requestOptions:** `Leads.RequestOptions` +**requestOptions:** `Tags.RequestOptions`
@@ -15147,7 +15793,9 @@ await client.crm.leads.list();
-
client.crm.leads.create({ ...params }) -> Merge.LeadResponse +## Ats Users + +
client.ats.users.list({ ...params }) -> Merge.PaginatedRemoteUserList
@@ -15159,7 +15807,7 @@ await client.crm.leads.list();
-Creates a `Lead` object with the given values. +Returns a list of `RemoteUser` objects.
@@ -15175,9 +15823,7 @@ Creates a `Lead` object with the given values.
```typescript -await client.crm.leads.create({ - model: {}, -}); +await client.ats.users.list(); ```
@@ -15193,7 +15839,7 @@ await client.crm.leads.create({
-**request:** `Merge.crm.LeadEndpointRequest` +**request:** `Merge.ats.UsersListRequest`
@@ -15201,7 +15847,7 @@ await client.crm.leads.create({
-**requestOptions:** `Leads.RequestOptions` +**requestOptions:** `Users.RequestOptions`
@@ -15212,7 +15858,7 @@ await client.crm.leads.create({
-
client.crm.leads.retrieve(id, { ...params }) -> Merge.Lead +
client.ats.users.retrieve(id, { ...params }) -> Merge.RemoteUser
@@ -15224,7 +15870,7 @@ await client.crm.leads.create({
-Returns a `Lead` object with the given `id`. +Returns a `RemoteUser` object with the given `id`.
@@ -15240,7 +15886,7 @@ Returns a `Lead` object with the given `id`.
```typescript -await client.crm.leads.retrieve("id"); +await client.ats.users.retrieve("id"); ```
@@ -15264,7 +15910,7 @@ await client.crm.leads.retrieve("id");
-**request:** `Merge.crm.LeadsRetrieveRequest` +**request:** `Merge.ats.UsersRetrieveRequest`
@@ -15272,7 +15918,7 @@ await client.crm.leads.retrieve("id");
-**requestOptions:** `Leads.RequestOptions` +**requestOptions:** `Users.RequestOptions`
@@ -15283,7 +15929,9 @@ await client.crm.leads.retrieve("id");
-
client.crm.leads.metaPostRetrieve() -> Merge.MetaResponse +## Ats WebhookReceivers + +
client.ats.webhookReceivers.list() -> Merge.WebhookReceiver[]
@@ -15295,7 +15943,7 @@ await client.crm.leads.retrieve("id");
-Returns metadata for `Lead` POSTs. +Returns a list of `WebhookReceiver` objects.
@@ -15311,7 +15959,7 @@ Returns metadata for `Lead` POSTs.
```typescript -await client.crm.leads.metaPostRetrieve(); +await client.ats.webhookReceivers.list(); ```
@@ -15327,7 +15975,7 @@ await client.crm.leads.metaPostRetrieve();
-**requestOptions:** `Leads.RequestOptions` +**requestOptions:** `WebhookReceivers.RequestOptions`
@@ -15338,7 +15986,7 @@ await client.crm.leads.metaPostRetrieve();
-
client.crm.leads.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +
client.ats.webhookReceivers.create({ ...params }) -> Merge.WebhookReceiver
@@ -15350,7 +15998,7 @@ await client.crm.leads.metaPostRetrieve();
-Returns a list of `RemoteFieldClass` objects. +Creates a `WebhookReceiver` object with the given values.
@@ -15366,7 +16014,10 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.leads.remoteFieldClassesList(); +await client.ats.webhookReceivers.create({ + event: "event", + isActive: true, +}); ```
@@ -15382,7 +16033,7 @@ await client.crm.leads.remoteFieldClassesList();
-**request:** `Merge.crm.LeadsRemoteFieldClassesListRequest` +**request:** `Merge.ats.WebhookReceiverRequest`
@@ -15390,7 +16041,7 @@ await client.crm.leads.remoteFieldClassesList();
-**requestOptions:** `Leads.RequestOptions` +**requestOptions:** `WebhookReceivers.RequestOptions`
@@ -15401,9 +16052,9 @@ await client.crm.leads.remoteFieldClassesList();
-## Crm LinkToken +## Crm AccountDetails -
client.crm.linkToken.create({ ...params }) -> Merge.LinkToken +
client.crm.accountDetails.retrieve() -> Merge.AccountDetails
@@ -15415,7 +16066,7 @@ await client.crm.leads.remoteFieldClassesList();
-Creates a link token to be used when linking a new end user. +Get details for a linked account.
@@ -15431,12 +16082,7 @@ Creates a link token to be used when linking a new end user.
```typescript -await client.crm.linkToken.create({ - endUserEmailAddress: "example@gmail.com", - endUserOrganizationName: "Test Organization", - endUserOriginId: "12345", - categories: ["hris", "ats"], -}); +await client.crm.accountDetails.retrieve(); ```
@@ -15452,15 +16098,7 @@ await client.crm.linkToken.create({
-**request:** `Merge.crm.EndUserDetailsRequest` - -
-
- -
-
- -**requestOptions:** `LinkToken.RequestOptions` +**requestOptions:** `AccountDetails.RequestOptions`
@@ -15471,9 +16109,9 @@ await client.crm.linkToken.create({
-## Crm LinkedAccounts +## Crm AccountToken -
client.crm.linkedAccounts.list({ ...params }) -> Merge.PaginatedAccountDetailsAndActionsList +
client.crm.accountToken.retrieve(publicToken) -> Merge.AccountToken
@@ -15485,7 +16123,7 @@ await client.crm.linkToken.create({
-List linked accounts for your organization. +Returns the account token for the end user with the provided public token.
@@ -15501,7 +16139,7 @@ List linked accounts for your organization.
```typescript -await client.crm.linkedAccounts.list(); +await client.crm.accountToken.retrieve("public_token"); ```
@@ -15517,7 +16155,7 @@ await client.crm.linkedAccounts.list();
-**request:** `Merge.crm.LinkedAccountsListRequest` +**publicToken:** `string`
@@ -15525,7 +16163,7 @@ await client.crm.linkedAccounts.list();
-**requestOptions:** `LinkedAccounts.RequestOptions` +**requestOptions:** `AccountToken.RequestOptions`
@@ -15536,9 +16174,9 @@ await client.crm.linkedAccounts.list();
-## Crm Notes +## Crm Accounts -
client.crm.notes.list({ ...params }) -> Merge.PaginatedNoteList +
client.crm.accounts.list({ ...params }) -> Merge.PaginatedAccountList
@@ -15550,7 +16188,7 @@ await client.crm.linkedAccounts.list();
-Returns a list of `Note` objects. +Returns a list of `Account` objects.
@@ -15566,7 +16204,7 @@ Returns a list of `Note` objects.
```typescript -await client.crm.notes.list(); +await client.crm.accounts.list(); ```
@@ -15582,7 +16220,7 @@ await client.crm.notes.list();
-**request:** `Merge.crm.NotesListRequest` +**request:** `Merge.crm.AccountsListRequest`
@@ -15590,7 +16228,7 @@ await client.crm.notes.list();
-**requestOptions:** `Notes.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -15601,7 +16239,7 @@ await client.crm.notes.list();
-
client.crm.notes.create({ ...params }) -> Merge.NoteResponse +
client.crm.accounts.create({ ...params }) -> Merge.CrmAccountResponse
@@ -15613,7 +16251,7 @@ await client.crm.notes.list();
-Creates a `Note` object with the given values. +Creates an `Account` object with the given values.
@@ -15629,7 +16267,7 @@ Creates a `Note` object with the given values.
```typescript -await client.crm.notes.create({ +await client.crm.accounts.create({ model: {}, }); ``` @@ -15647,7 +16285,7 @@ await client.crm.notes.create({
-**request:** `Merge.crm.NoteEndpointRequest` +**request:** `Merge.crm.CrmAccountEndpointRequest`
@@ -15655,7 +16293,7 @@ await client.crm.notes.create({
-**requestOptions:** `Notes.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -15666,7 +16304,7 @@ await client.crm.notes.create({
-
client.crm.notes.retrieve(id, { ...params }) -> Merge.Note +
client.crm.accounts.retrieve(id, { ...params }) -> Merge.Account
@@ -15678,7 +16316,7 @@ await client.crm.notes.create({
-Returns a `Note` object with the given `id`. +Returns an `Account` object with the given `id`.
@@ -15694,7 +16332,7 @@ Returns a `Note` object with the given `id`.
```typescript -await client.crm.notes.retrieve("id"); +await client.crm.accounts.retrieve("id"); ```
@@ -15718,7 +16356,7 @@ await client.crm.notes.retrieve("id");
-**request:** `Merge.crm.NotesRetrieveRequest` +**request:** `Merge.crm.AccountsRetrieveRequest`
@@ -15726,7 +16364,7 @@ await client.crm.notes.retrieve("id");
-**requestOptions:** `Notes.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -15737,7 +16375,7 @@ await client.crm.notes.retrieve("id");
-
client.crm.notes.metaPostRetrieve() -> Merge.MetaResponse +
client.crm.accounts.partialUpdate(id, { ...params }) -> Merge.CrmAccountResponse
@@ -15749,7 +16387,7 @@ await client.crm.notes.retrieve("id");
-Returns metadata for `Note` POSTs. +Updates an `Account` object with the given `id`.
@@ -15765,7 +16403,9 @@ Returns metadata for `Note` POSTs.
```typescript -await client.crm.notes.metaPostRetrieve(); +await client.crm.accounts.partialUpdate("id", { + model: {}, +}); ```
@@ -15781,62 +16421,15 @@ await client.crm.notes.metaPostRetrieve();
-**requestOptions:** `Notes.RequestOptions` - -
-
- -
- - - -
- -
client.crm.notes.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList -
-
- -#### 📝 Description - -
-
- -
-
- -Returns a list of `RemoteFieldClass` objects. - -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```typescript -await client.crm.notes.remoteFieldClassesList(); -``` +**id:** `string`
-
-
- -#### ⚙️ Parameters - -
-
-**request:** `Merge.crm.NotesRemoteFieldClassesListRequest` +**request:** `Merge.crm.PatchedCrmAccountEndpointRequest`
@@ -15844,7 +16437,7 @@ await client.crm.notes.remoteFieldClassesList();
-**requestOptions:** `Notes.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -15855,9 +16448,7 @@ await client.crm.notes.remoteFieldClassesList();
-## Crm Opportunities - -
client.crm.opportunities.list({ ...params }) -> Merge.PaginatedOpportunityList +
client.crm.accounts.metaPatchRetrieve(id) -> Merge.MetaResponse
@@ -15869,7 +16460,7 @@ await client.crm.notes.remoteFieldClassesList();
-Returns a list of `Opportunity` objects. +Returns metadata for `CRMAccount` PATCHs.
@@ -15885,7 +16476,7 @@ Returns a list of `Opportunity` objects.
```typescript -await client.crm.opportunities.list(); +await client.crm.accounts.metaPatchRetrieve("id"); ```
@@ -15901,7 +16492,7 @@ await client.crm.opportunities.list();
-**request:** `Merge.crm.OpportunitiesListRequest` +**id:** `string`
@@ -15909,7 +16500,7 @@ await client.crm.opportunities.list();
-**requestOptions:** `Opportunities.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -15920,7 +16511,7 @@ await client.crm.opportunities.list();
-
client.crm.opportunities.create({ ...params }) -> Merge.OpportunityResponse +
client.crm.accounts.metaPostRetrieve() -> Merge.MetaResponse
@@ -15932,7 +16523,7 @@ await client.crm.opportunities.list();
-Creates an `Opportunity` object with the given values. +Returns metadata for `CRMAccount` POSTs.
@@ -15948,9 +16539,7 @@ Creates an `Opportunity` object with the given values.
```typescript -await client.crm.opportunities.create({ - model: {}, -}); +await client.crm.accounts.metaPostRetrieve(); ```
@@ -15966,15 +16555,7 @@ await client.crm.opportunities.create({
-**request:** `Merge.crm.OpportunityEndpointRequest` - -
-
- -
-
- -**requestOptions:** `Opportunities.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -15985,7 +16566,7 @@ await client.crm.opportunities.create({
-
client.crm.opportunities.retrieve(id, { ...params }) -> Merge.Opportunity +
client.crm.accounts.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -15997,7 +16578,7 @@ await client.crm.opportunities.create({
-Returns an `Opportunity` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -16013,7 +16594,7 @@ Returns an `Opportunity` object with the given `id`.
```typescript -await client.crm.opportunities.retrieve("id"); +await client.crm.accounts.remoteFieldClassesList(); ```
@@ -16029,15 +16610,7 @@ await client.crm.opportunities.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.OpportunitiesRetrieveRequest` +**request:** `Merge.crm.AccountsRemoteFieldClassesListRequest`
@@ -16045,7 +16618,7 @@ await client.crm.opportunities.retrieve("id");
-**requestOptions:** `Opportunities.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -16056,7 +16629,9 @@ await client.crm.opportunities.retrieve("id");
-
client.crm.opportunities.partialUpdate(id, { ...params }) -> Merge.OpportunityResponse +## Crm AsyncPassthrough + +
client.crm.asyncPassthrough.create({ ...params }) -> Merge.AsyncPassthroughReciept
@@ -16068,7 +16643,7 @@ await client.crm.opportunities.retrieve("id");
-Updates an `Opportunity` object with the given `id`. +Asynchronously pull data from an endpoint not currently supported by Merge.
@@ -16084,8 +16659,9 @@ Updates an `Opportunity` object with the given `id`.
```typescript -await client.crm.opportunities.partialUpdate("id", { - model: {}, +await client.crm.asyncPassthrough.create({ + method: "GET", + path: "/scooters", }); ``` @@ -16102,15 +16678,7 @@ await client.crm.opportunities.partialUpdate("id", {
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.crm.PatchedOpportunityEndpointRequest` +**request:** `Merge.DataPassthroughRequest`
@@ -16118,7 +16686,7 @@ await client.crm.opportunities.partialUpdate("id", {
-**requestOptions:** `Opportunities.RequestOptions` +**requestOptions:** `AsyncPassthrough.RequestOptions`
@@ -16129,7 +16697,7 @@ await client.crm.opportunities.partialUpdate("id", {
-
client.crm.opportunities.metaPatchRetrieve(id) -> Merge.MetaResponse +
client.crm.asyncPassthrough.retrieve(asyncPassthroughReceiptId) -> Merge.AsyncPassthroughRetrieveResponse
@@ -16141,7 +16709,7 @@ await client.crm.opportunities.partialUpdate("id", {
-Returns metadata for `Opportunity` PATCHs. +Retrieves data from earlier async-passthrough POST request
@@ -16157,7 +16725,7 @@ Returns metadata for `Opportunity` PATCHs.
```typescript -await client.crm.opportunities.metaPatchRetrieve("id"); +await client.crm.asyncPassthrough.retrieve("async_passthrough_receipt_id"); ```
@@ -16173,7 +16741,7 @@ await client.crm.opportunities.metaPatchRetrieve("id");
-**id:** `string` +**asyncPassthroughReceiptId:** `string`
@@ -16181,7 +16749,7 @@ await client.crm.opportunities.metaPatchRetrieve("id");
-**requestOptions:** `Opportunities.RequestOptions` +**requestOptions:** `AsyncPassthrough.RequestOptions`
@@ -16192,7 +16760,9 @@ await client.crm.opportunities.metaPatchRetrieve("id");
-
client.crm.opportunities.metaPostRetrieve() -> Merge.MetaResponse +## Crm AuditTrail + +
client.crm.auditTrail.list({ ...params }) -> Merge.PaginatedAuditLogEventList
@@ -16204,7 +16774,7 @@ await client.crm.opportunities.metaPatchRetrieve("id");
-Returns metadata for `Opportunity` POSTs. +Gets a list of audit trail events.
@@ -16220,7 +16790,7 @@ Returns metadata for `Opportunity` POSTs.
```typescript -await client.crm.opportunities.metaPostRetrieve(); +await client.crm.auditTrail.list(); ```
@@ -16236,7 +16806,15 @@ await client.crm.opportunities.metaPostRetrieve();
-**requestOptions:** `Opportunities.RequestOptions` +**request:** `Merge.crm.AuditTrailListRequest` + +
+
+ +
+
+ +**requestOptions:** `AuditTrail.RequestOptions`
@@ -16247,7 +16825,9 @@ await client.crm.opportunities.metaPostRetrieve();
-
client.crm.opportunities.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +## Crm AvailableActions + +
client.crm.availableActions.retrieve() -> Merge.AvailableActions
@@ -16259,7 +16839,7 @@ await client.crm.opportunities.metaPostRetrieve();
-Returns a list of `RemoteFieldClass` objects. +Returns a list of models and actions available for an account.
@@ -16275,7 +16855,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.opportunities.remoteFieldClassesList(); +await client.crm.availableActions.retrieve(); ```
@@ -16291,15 +16871,7 @@ await client.crm.opportunities.remoteFieldClassesList();
-**request:** `Merge.crm.OpportunitiesRemoteFieldClassesListRequest` - -
-
- -
-
- -**requestOptions:** `Opportunities.RequestOptions` +**requestOptions:** `AvailableActions.RequestOptions`
@@ -16310,9 +16882,9 @@ await client.crm.opportunities.remoteFieldClassesList();
-## Crm Passthrough +## Crm Contacts -
client.crm.passthrough.create({ ...params }) -> Merge.RemoteResponse +
client.crm.contacts.list({ ...params }) -> Merge.PaginatedContactList
@@ -16324,7 +16896,7 @@ await client.crm.opportunities.remoteFieldClassesList();
-Pull data from an endpoint not currently supported by Merge. +Returns a list of `Contact` objects.
@@ -16340,10 +16912,7 @@ Pull data from an endpoint not currently supported by Merge.
```typescript -await client.crm.passthrough.create({ - method: "GET", - path: "/scooters", -}); +await client.crm.contacts.list(); ```
@@ -16359,7 +16928,7 @@ await client.crm.passthrough.create({
-**request:** `Merge.DataPassthroughRequest` +**request:** `Merge.crm.ContactsListRequest`
@@ -16367,7 +16936,7 @@ await client.crm.passthrough.create({
-**requestOptions:** `Passthrough.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -16378,9 +16947,7 @@ await client.crm.passthrough.create({
-## Crm RegenerateKey - -
client.crm.regenerateKey.create({ ...params }) -> Merge.RemoteKey +
client.crm.contacts.create({ ...params }) -> Merge.CrmContactResponse
@@ -16392,7 +16959,7 @@ await client.crm.passthrough.create({
-Exchange remote keys. +Creates a `Contact` object with the given values.
@@ -16408,8 +16975,8 @@ Exchange remote keys.
```typescript -await client.crm.regenerateKey.create({ - name: "Remote Deployment Key 1", +await client.crm.contacts.create({ + model: {}, }); ``` @@ -16426,7 +16993,7 @@ await client.crm.regenerateKey.create({
-**request:** `Merge.crm.RemoteKeyForRegenerationRequest` +**request:** `Merge.crm.CrmContactEndpointRequest`
@@ -16434,7 +17001,7 @@ await client.crm.regenerateKey.create({
-**requestOptions:** `RegenerateKey.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -16445,9 +17012,7 @@ await client.crm.regenerateKey.create({
-## Crm Stages - -
client.crm.stages.list({ ...params }) -> Merge.PaginatedStageList +
client.crm.contacts.retrieve(id, { ...params }) -> Merge.Contact
@@ -16459,7 +17024,7 @@ await client.crm.regenerateKey.create({
-Returns a list of `Stage` objects. +Returns a `Contact` object with the given `id`.
@@ -16475,7 +17040,7 @@ Returns a list of `Stage` objects.
```typescript -await client.crm.stages.list(); +await client.crm.contacts.retrieve("id"); ```
@@ -16491,7 +17056,7 @@ await client.crm.stages.list();
-**request:** `Merge.crm.StagesListRequest` +**id:** `string`
@@ -16499,7 +17064,15 @@ await client.crm.stages.list();
-**requestOptions:** `Stages.RequestOptions` +**request:** `Merge.crm.ContactsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions`
@@ -16510,7 +17083,7 @@ await client.crm.stages.list();
-
client.crm.stages.retrieve(id, { ...params }) -> Merge.Stage +
client.crm.contacts.partialUpdate(id, { ...params }) -> Merge.CrmContactResponse
@@ -16522,7 +17095,7 @@ await client.crm.stages.list();
-Returns a `Stage` object with the given `id`. +Updates a `Contact` object with the given `id`.
@@ -16538,7 +17111,9 @@ Returns a `Stage` object with the given `id`.
```typescript -await client.crm.stages.retrieve("id"); +await client.crm.contacts.partialUpdate("id", { + model: {}, +}); ```
@@ -16562,7 +17137,7 @@ await client.crm.stages.retrieve("id");
-**request:** `Merge.crm.StagesRetrieveRequest` +**request:** `Merge.crm.PatchedCrmContactEndpointRequest`
@@ -16570,7 +17145,7 @@ await client.crm.stages.retrieve("id");
-**requestOptions:** `Stages.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -16581,7 +17156,7 @@ await client.crm.stages.retrieve("id");
-
client.crm.stages.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +
client.crm.contacts.ignoreCreate(modelId, { ...params }) -> void
@@ -16593,7 +17168,7 @@ await client.crm.stages.retrieve("id");
-Returns a list of `RemoteFieldClass` objects. +Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in future syncs. The "reason" and "message" fields in the request body will be stored for audit purposes.
@@ -16609,7 +17184,9 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.stages.remoteFieldClassesList(); +await client.crm.contacts.ignoreCreate("model_id", { + reason: "GENERAL_CUSTOMER_REQUEST", +}); ```
@@ -16625,7 +17202,7 @@ await client.crm.stages.remoteFieldClassesList();
-**request:** `Merge.crm.StagesRemoteFieldClassesListRequest` +**modelId:** `string`
@@ -16633,7 +17210,15 @@ await client.crm.stages.remoteFieldClassesList();
-**requestOptions:** `Stages.RequestOptions` +**request:** `Merge.IgnoreCommonModelRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions`
@@ -16644,9 +17229,7 @@ await client.crm.stages.remoteFieldClassesList();
-## Crm SyncStatus - -
client.crm.syncStatus.list({ ...params }) -> Merge.PaginatedSyncStatusList +
client.crm.contacts.metaPatchRetrieve(id) -> Merge.MetaResponse
@@ -16658,7 +17241,7 @@ await client.crm.stages.remoteFieldClassesList();
-Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. `last_sync_finished` represents the most recent time any sync completed. These timestamps may correspond to different sync instances which may result in a sync start time being later than a separate sync completed time. To ensure you are retrieving the latest available data reference the `last_sync_finished` timestamp where `last_sync_result` is `DONE`. Possible values for `status` and `last_sync_result` are `DISABLED`, `DONE`, `FAILED`, `PARTIALLY_SYNCED`, `PAUSED`, `SYNCING`. Learn more about sync status in our [Help Center](https://help.merge.dev/en/articles/8184193-merge-sync-statuses). +Returns metadata for `CRMContact` PATCHs.
@@ -16674,7 +17257,7 @@ Get sync status for the current sync and the most recently finished sync. `last_
```typescript -await client.crm.syncStatus.list(); +await client.crm.contacts.metaPatchRetrieve("id"); ```
@@ -16690,7 +17273,7 @@ await client.crm.syncStatus.list();
-**request:** `Merge.crm.SyncStatusListRequest` +**id:** `string`
@@ -16698,7 +17281,7 @@ await client.crm.syncStatus.list();
-**requestOptions:** `SyncStatus.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -16709,9 +17292,7 @@ await client.crm.syncStatus.list();
-## Crm ForceResync - -
client.crm.forceResync.syncStatusResyncCreate() -> Merge.SyncStatus[] +
client.crm.contacts.metaPostRetrieve() -> Merge.MetaResponse
@@ -16723,7 +17304,7 @@ await client.crm.syncStatus.list();
-Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or Enterprise plans. Doing so will consume a sync credit for the relevant linked account. Force re-syncs can also be triggered manually in the Merge Dashboard and is available for all customers. +Returns metadata for `CRMContact` POSTs.
@@ -16739,7 +17320,7 @@ Force re-sync of all models. This endpoint is available for monthly, quarterly,
```typescript -await client.crm.forceResync.syncStatusResyncCreate(); +await client.crm.contacts.metaPostRetrieve(); ```
@@ -16755,7 +17336,7 @@ await client.crm.forceResync.syncStatusResyncCreate();
-**requestOptions:** `ForceResync.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -16766,9 +17347,7 @@ await client.crm.forceResync.syncStatusResyncCreate();
-## Crm Tasks - -
client.crm.tasks.list({ ...params }) -> Merge.PaginatedTaskList +
client.crm.contacts.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -16780,7 +17359,7 @@ await client.crm.forceResync.syncStatusResyncCreate();
-Returns a list of `Task` objects. +Returns a list of `RemoteFieldClass` objects.
@@ -16796,7 +17375,7 @@ Returns a list of `Task` objects.
```typescript -await client.crm.tasks.list(); +await client.crm.contacts.remoteFieldClassesList(); ```
@@ -16812,7 +17391,7 @@ await client.crm.tasks.list();
-**request:** `Merge.crm.TasksListRequest` +**request:** `Merge.crm.ContactsRemoteFieldClassesListRequest`
@@ -16820,7 +17399,7 @@ await client.crm.tasks.list();
-**requestOptions:** `Tasks.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -16831,7 +17410,9 @@ await client.crm.tasks.list();
-
client.crm.tasks.create({ ...params }) -> Merge.TaskResponse +## Crm CustomObjectClasses + +
client.crm.customObjectClasses.list({ ...params }) -> Merge.PaginatedCustomObjectClassList
@@ -16843,7 +17424,7 @@ await client.crm.tasks.list();
-Creates a `Task` object with the given values. +Returns a list of `CustomObjectClass` objects.
@@ -16859,9 +17440,7 @@ Creates a `Task` object with the given values.
```typescript -await client.crm.tasks.create({ - model: {}, -}); +await client.crm.customObjectClasses.list(); ```
@@ -16877,7 +17456,7 @@ await client.crm.tasks.create({
-**request:** `Merge.crm.TaskEndpointRequest` +**request:** `Merge.crm.CustomObjectClassesListRequest`
@@ -16885,7 +17464,7 @@ await client.crm.tasks.create({
-**requestOptions:** `Tasks.RequestOptions` +**requestOptions:** `CustomObjectClasses.RequestOptions`
@@ -16896,7 +17475,7 @@ await client.crm.tasks.create({
-
client.crm.tasks.retrieve(id, { ...params }) -> Merge.Task +
client.crm.customObjectClasses.retrieve(id, { ...params }) -> Merge.CustomObjectClass
@@ -16908,7 +17487,7 @@ await client.crm.tasks.create({
-Returns a `Task` object with the given `id`. +Returns a `CustomObjectClass` object with the given `id`.
@@ -16924,7 +17503,7 @@ Returns a `Task` object with the given `id`.
```typescript -await client.crm.tasks.retrieve("id"); +await client.crm.customObjectClasses.retrieve("id"); ```
@@ -16948,7 +17527,7 @@ await client.crm.tasks.retrieve("id");
-**request:** `Merge.crm.TasksRetrieveRequest` +**request:** `Merge.crm.CustomObjectClassesRetrieveRequest`
@@ -16956,7 +17535,7 @@ await client.crm.tasks.retrieve("id");
-**requestOptions:** `Tasks.RequestOptions` +**requestOptions:** `CustomObjectClasses.RequestOptions`
@@ -16967,7 +17546,9 @@ await client.crm.tasks.retrieve("id");
-
client.crm.tasks.partialUpdate(id, { ...params }) -> Merge.TaskResponse +## Crm AssociationTypes + +
client.crm.associationTypes.customObjectClassesAssociationTypesList(customObjectClassId, { ...params }) -> Merge.PaginatedAssociationTypeList
@@ -16979,7 +17560,7 @@ await client.crm.tasks.retrieve("id");
-Updates a `Task` object with the given `id`. +Returns a list of `AssociationType` objects.
@@ -16995,9 +17576,7 @@ Updates a `Task` object with the given `id`.
```typescript -await client.crm.tasks.partialUpdate("id", { - model: {}, -}); +await client.crm.associationTypes.customObjectClassesAssociationTypesList("custom_object_class_id"); ```
@@ -17013,7 +17592,7 @@ await client.crm.tasks.partialUpdate("id", {
-**id:** `string` +**customObjectClassId:** `string`
@@ -17021,7 +17600,7 @@ await client.crm.tasks.partialUpdate("id", {
-**request:** `Merge.crm.PatchedTaskEndpointRequest` +**request:** `Merge.crm.CustomObjectClassesAssociationTypesListRequest`
@@ -17029,7 +17608,7 @@ await client.crm.tasks.partialUpdate("id", {
-**requestOptions:** `Tasks.RequestOptions` +**requestOptions:** `AssociationTypes.RequestOptions`
@@ -17040,7 +17619,7 @@ await client.crm.tasks.partialUpdate("id", {
-
client.crm.tasks.metaPatchRetrieve(id) -> Merge.MetaResponse +
client.crm.associationTypes.customObjectClassesAssociationTypesCreate(customObjectClassId, { ...params }) -> Merge.CrmAssociationTypeResponse
@@ -17052,7 +17631,7 @@ await client.crm.tasks.partialUpdate("id", {
-Returns metadata for `Task` PATCHs. +Creates an `AssociationType` object with the given values.
@@ -17068,7 +17647,21 @@ Returns metadata for `Task` PATCHs.
```typescript -await client.crm.tasks.metaPatchRetrieve("id"); +await client.crm.associationTypes.customObjectClassesAssociationTypesCreate("custom_object_class_id", { + model: { + sourceObjectClass: { + id: "id", + originType: "CUSTOM_OBJECT", + }, + targetObjectClasses: [ + { + id: "id", + originType: "CUSTOM_OBJECT", + }, + ], + remoteKeyName: "remote_key_name", + }, +}); ```
@@ -17084,7 +17677,7 @@ await client.crm.tasks.metaPatchRetrieve("id");
-**id:** `string` +**customObjectClassId:** `string`
@@ -17092,7 +17685,15 @@ await client.crm.tasks.metaPatchRetrieve("id");
-**requestOptions:** `Tasks.RequestOptions` +**request:** `Merge.crm.CrmAssociationTypeEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `AssociationTypes.RequestOptions`
@@ -17103,7 +17704,7 @@ await client.crm.tasks.metaPatchRetrieve("id");
-
client.crm.tasks.metaPostRetrieve() -> Merge.MetaResponse +
client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve(customObjectClassId, id, { ...params }) -> Merge.AssociationType
@@ -17115,7 +17716,7 @@ await client.crm.tasks.metaPatchRetrieve("id");
-Returns metadata for `Task` POSTs. +Returns an `AssociationType` object with the given `id`.
@@ -17131,7 +17732,7 @@ Returns metadata for `Task` POSTs.
```typescript -await client.crm.tasks.metaPostRetrieve(); +await client.crm.associationTypes.customObjectClassesAssociationTypesRetrieve("custom_object_class_id", "id"); ```
@@ -17139,15 +17740,39 @@ await client.crm.tasks.metaPostRetrieve();
-#### ⚙️ Parameters - +#### ⚙️ Parameters + +
+
+ +
+
+ +**customObjectClassId:** `string` + +
+
+ +
+
+ +**id:** `string` + +
+
+
+**request:** `Merge.crm.CustomObjectClassesAssociationTypesRetrieveRequest` + +
+
+
-**requestOptions:** `Tasks.RequestOptions` +**requestOptions:** `AssociationTypes.RequestOptions`
@@ -17158,7 +17783,7 @@ await client.crm.tasks.metaPostRetrieve();
-
client.crm.tasks.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +
client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRetrieve(customObjectClassId) -> Merge.MetaResponse
@@ -17170,7 +17795,7 @@ await client.crm.tasks.metaPostRetrieve();
-Returns a list of `RemoteFieldClass` objects. +Returns metadata for `CRMAssociationType` POSTs.
@@ -17186,7 +17811,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.tasks.remoteFieldClassesList(); +await client.crm.associationTypes.customObjectClassesAssociationTypesMetaPostRetrieve("custom_object_class_id"); ```
@@ -17202,7 +17827,7 @@ await client.crm.tasks.remoteFieldClassesList();
-**request:** `Merge.crm.TasksRemoteFieldClassesListRequest` +**customObjectClassId:** `string`
@@ -17210,7 +17835,7 @@ await client.crm.tasks.remoteFieldClassesList();
-**requestOptions:** `Tasks.RequestOptions` +**requestOptions:** `AssociationTypes.RequestOptions`
@@ -17221,9 +17846,9 @@ await client.crm.tasks.remoteFieldClassesList();
-## Crm Users +## Crm CustomObjects -
client.crm.users.list({ ...params }) -> Merge.PaginatedUserList +
client.crm.customObjects.customObjectClassesCustomObjectsList(customObjectClassId, { ...params }) -> Merge.PaginatedCustomObjectList
@@ -17235,7 +17860,7 @@ await client.crm.tasks.remoteFieldClassesList();
-Returns a list of `User` objects. +Returns a list of `CustomObject` objects.
@@ -17251,7 +17876,7 @@ Returns a list of `User` objects.
```typescript -await client.crm.users.list(); +await client.crm.customObjects.customObjectClassesCustomObjectsList("custom_object_class_id"); ```
@@ -17267,7 +17892,7 @@ await client.crm.users.list();
-**request:** `Merge.crm.UsersListRequest` +**customObjectClassId:** `string`
@@ -17275,7 +17900,15 @@ await client.crm.users.list();
-**requestOptions:** `Users.RequestOptions` +**request:** `Merge.crm.CustomObjectClassesCustomObjectsListRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjects.RequestOptions`
@@ -17286,7 +17919,7 @@ await client.crm.users.list();
-
client.crm.users.retrieve(id, { ...params }) -> Merge.User +
client.crm.customObjects.customObjectClassesCustomObjectsCreate(customObjectClassId, { ...params }) -> Merge.CrmCustomObjectResponse
@@ -17298,7 +17931,7 @@ await client.crm.users.list();
-Returns a `User` object with the given `id`. +Creates a `CustomObject` object with the given values.
@@ -17314,7 +17947,13 @@ Returns a `User` object with the given `id`.
```typescript -await client.crm.users.retrieve("id"); +await client.crm.customObjects.customObjectClassesCustomObjectsCreate("custom_object_class_id", { + model: { + fields: { + test_field: "hello", + }, + }, +}); ```
@@ -17330,7 +17969,7 @@ await client.crm.users.retrieve("id");
-**id:** `string` +**customObjectClassId:** `string`
@@ -17338,7 +17977,7 @@ await client.crm.users.retrieve("id");
-**request:** `Merge.crm.UsersRetrieveRequest` +**request:** `Merge.crm.CrmCustomObjectEndpointRequest`
@@ -17346,7 +17985,7 @@ await client.crm.users.retrieve("id");
-**requestOptions:** `Users.RequestOptions` +**requestOptions:** `CustomObjects.RequestOptions`
@@ -17357,7 +17996,7 @@ await client.crm.users.retrieve("id");
-
client.crm.users.ignoreCreate(modelId, { ...params }) -> void +
client.crm.customObjects.customObjectClassesCustomObjectsRetrieve(customObjectClassId, id, { ...params }) -> Merge.CustomObject
@@ -17369,7 +18008,7 @@ await client.crm.users.retrieve("id");
-Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in future syncs. The "reason" and "message" fields in the request body will be stored for audit purposes. +Returns a `CustomObject` object with the given `id`.
@@ -17385,9 +18024,7 @@ Ignores a specific row based on the `model_id` in the url. These records will ha
```typescript -await client.crm.users.ignoreCreate("model_id", { - reason: "GENERAL_CUSTOMER_REQUEST", -}); +await client.crm.customObjects.customObjectClassesCustomObjectsRetrieve("custom_object_class_id", "id"); ```
@@ -17403,7 +18040,7 @@ await client.crm.users.ignoreCreate("model_id", {
-**modelId:** `string` +**customObjectClassId:** `string`
@@ -17411,7 +18048,7 @@ await client.crm.users.ignoreCreate("model_id", {
-**request:** `Merge.IgnoreCommonModelRequest` +**id:** `string`
@@ -17419,7 +18056,15 @@ await client.crm.users.ignoreCreate("model_id", {
-**requestOptions:** `Users.RequestOptions` +**request:** `Merge.crm.CustomObjectClassesCustomObjectsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjects.RequestOptions`
@@ -17430,7 +18075,7 @@ await client.crm.users.ignoreCreate("model_id", {
-
client.crm.users.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +
client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve(customObjectClassId) -> Merge.MetaResponse
@@ -17442,7 +18087,7 @@ await client.crm.users.ignoreCreate("model_id", {
-Returns a list of `RemoteFieldClass` objects. +Returns metadata for `CRMCustomObject` POSTs.
@@ -17458,7 +18103,7 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.crm.users.remoteFieldClassesList(); +await client.crm.customObjects.customObjectClassesCustomObjectsMetaPostRetrieve("custom_object_class_id"); ```
@@ -17474,7 +18119,7 @@ await client.crm.users.remoteFieldClassesList();
-**request:** `Merge.crm.UsersRemoteFieldClassesListRequest` +**customObjectClassId:** `string`
@@ -17482,7 +18127,7 @@ await client.crm.users.remoteFieldClassesList();
-**requestOptions:** `Users.RequestOptions` +**requestOptions:** `CustomObjects.RequestOptions`
@@ -17493,9 +18138,7 @@ await client.crm.users.remoteFieldClassesList();
-## Crm WebhookReceivers - -
client.crm.webhookReceivers.list() -> Merge.WebhookReceiver[] +
client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -17507,7 +18150,7 @@ await client.crm.users.remoteFieldClassesList();
-Returns a list of `WebhookReceiver` objects. +Returns a list of `RemoteFieldClass` objects.
@@ -17523,7 +18166,7 @@ Returns a list of `WebhookReceiver` objects.
```typescript -await client.crm.webhookReceivers.list(); +await client.crm.customObjects.customObjectClassesCustomObjectsRemoteFieldClassesList(); ```
@@ -17539,7 +18182,15 @@ await client.crm.webhookReceivers.list();
-**requestOptions:** `WebhookReceivers.RequestOptions` +**request:** `Merge.crm.CustomObjectClassesCustomObjectsRemoteFieldClassesListRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjects.RequestOptions`
@@ -17550,7 +18201,9 @@ await client.crm.webhookReceivers.list();
-
client.crm.webhookReceivers.create({ ...params }) -> Merge.WebhookReceiver +## Crm Associations + +
client.crm.associations.customObjectClassesCustomObjectsAssociationsList(customObjectClassId, objectId, { ...params }) -> Merge.PaginatedAssociationList
@@ -17562,7 +18215,7 @@ await client.crm.webhookReceivers.list();
-Creates a `WebhookReceiver` object with the given values. +Returns a list of `Association` objects.
@@ -17578,10 +18231,7 @@ Creates a `WebhookReceiver` object with the given values.
```typescript -await client.crm.webhookReceivers.create({ - event: "event", - isActive: true, -}); +await client.crm.associations.customObjectClassesCustomObjectsAssociationsList("custom_object_class_id", "object_id"); ```
@@ -17597,7 +18247,7 @@ await client.crm.webhookReceivers.create({
-**request:** `Merge.crm.WebhookReceiverRequest` +**customObjectClassId:** `string`
@@ -17605,7 +18255,23 @@ await client.crm.webhookReceivers.create({
-**requestOptions:** `WebhookReceivers.RequestOptions` +**objectId:** `string` + +
+
+ +
+
+ +**request:** `Merge.crm.CustomObjectClassesCustomObjectsAssociationsListRequest` + +
+
+ +
+
+ +**requestOptions:** `Associations.RequestOptions`
@@ -17616,9 +18282,7 @@ await client.crm.webhookReceivers.create({
-## Ats AccountDetails - -
client.ats.accountDetails.retrieve() -> Merge.AccountDetails +
client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate(associationTypeId, sourceClassId, sourceObjectId, targetClassId, targetObjectId, { ...params }) -> Merge.Association
@@ -17630,7 +18294,7 @@ await client.crm.webhookReceivers.create({
-Get details for a linked account. +Creates an Association between `source_object_id` and `target_object_id` of type `association_type_id`.
@@ -17646,7 +18310,13 @@ Get details for a linked account.
```typescript -await client.ats.accountDetails.retrieve(); +await client.crm.associations.customObjectClassesCustomObjectsAssociationsUpdate( + "association_type_id", + "source_class_id", + "source_object_id", + "target_class_id", + "target_object_id", +); ```
@@ -17662,64 +18332,47 @@ await client.ats.accountDetails.retrieve();
-**requestOptions:** `AccountDetails.RequestOptions` - -
-
- -
+**associationTypeId:** `string` -
-## Ats AccountToken - -
client.ats.accountToken.retrieve(publicToken) -> Merge.AccountToken
-#### 📝 Description +**sourceClassId:** `string` -
-
+
+
-Returns the account token for the end user with the provided public token. +**sourceObjectId:** `string`
-
-
- -#### 🔌 Usage - -
-
-```typescript -await client.ats.accountToken.retrieve("public_token"); -``` +**targetClassId:** `string` -
-
-#### ⚙️ Parameters -
+**targetObjectId:** `string` + +
+
+
-**publicToken:** `string` +**request:** `Merge.crm.CustomObjectClassesCustomObjectsAssociationsUpdateRequest`
@@ -17727,7 +18380,7 @@ await client.ats.accountToken.retrieve("public_token");
-**requestOptions:** `AccountToken.RequestOptions` +**requestOptions:** `Associations.RequestOptions`
@@ -17738,9 +18391,9 @@ await client.ats.accountToken.retrieve("public_token");
-## Ats Activities +## Crm Scopes -
client.ats.activities.list({ ...params }) -> Merge.PaginatedActivityList +
client.crm.scopes.defaultScopesRetrieve() -> Merge.CommonModelScopeApi
@@ -17752,7 +18405,7 @@ await client.ats.accountToken.retrieve("public_token");
-Returns a list of `Activity` objects. +Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes).
@@ -17768,7 +18421,7 @@ Returns a list of `Activity` objects.
```typescript -await client.ats.activities.list(); +await client.crm.scopes.defaultScopesRetrieve(); ```
@@ -17784,15 +18437,7 @@ await client.ats.activities.list();
-**request:** `Merge.ats.ActivitiesListRequest` - -
-
- -
-
- -**requestOptions:** `Activities.RequestOptions` +**requestOptions:** `Scopes.RequestOptions`
@@ -17803,7 +18448,7 @@ await client.ats.activities.list();
-
client.ats.activities.create({ ...params }) -> Merge.ActivityResponse +
client.crm.scopes.linkedAccountScopesRetrieve() -> Merge.CommonModelScopeApi
@@ -17815,7 +18460,7 @@ await client.ats.activities.list();
-Creates an `Activity` object with the given values. +Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes).
@@ -17831,10 +18476,7 @@ Creates an `Activity` object with the given values.
```typescript -await client.ats.activities.create({ - model: {}, - remoteUserId: "remote_user_id", -}); +await client.crm.scopes.linkedAccountScopesRetrieve(); ```
@@ -17850,15 +18492,7 @@ await client.ats.activities.create({
-**request:** `Merge.ats.ActivityEndpointRequest` - -
-
- -
-
- -**requestOptions:** `Activities.RequestOptions` +**requestOptions:** `Scopes.RequestOptions`
@@ -17869,7 +18503,7 @@ await client.ats.activities.create({
-
client.ats.activities.retrieve(id, { ...params }) -> Merge.Activity +
client.crm.scopes.linkedAccountScopesCreate({ ...params }) -> Merge.CommonModelScopeApi
@@ -17881,7 +18515,7 @@ await client.ats.activities.create({
-Returns an `Activity` object with the given `id`. +Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the default Scopes. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes)
@@ -17897,7 +18531,33 @@ Returns an `Activity` object with the given `id`.
```typescript -await client.ats.activities.retrieve("id"); +await client.crm.scopes.linkedAccountScopesCreate({ + commonModels: [ + { + modelName: "Employee", + modelPermissions: { + READ: { + isEnabled: true, + }, + WRITE: { + isEnabled: false, + }, + }, + fieldPermissions: { + enabledFields: ["avatar", "home_location"], + disabledFields: ["work_location"], + }, + }, + { + modelName: "Benefit", + modelPermissions: { + WRITE: { + isEnabled: false, + }, + }, + }, + ], +}); ```
@@ -17913,15 +18573,7 @@ await client.ats.activities.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.ActivitiesRetrieveRequest` +**request:** `Merge.crm.LinkedAccountCommonModelScopeDeserializerRequest`
@@ -17929,7 +18581,7 @@ await client.ats.activities.retrieve("id");
-**requestOptions:** `Activities.RequestOptions` +**requestOptions:** `Scopes.RequestOptions`
@@ -17940,7 +18592,9 @@ await client.ats.activities.retrieve("id");
-
client.ats.activities.metaPostRetrieve() -> Merge.MetaResponse +## Crm DeleteAccount + +
client.crm.deleteAccount.delete() -> void
@@ -17952,7 +18606,7 @@ await client.ats.activities.retrieve("id");
-Returns metadata for `Activity` POSTs. +Delete a linked account.
@@ -17968,7 +18622,7 @@ Returns metadata for `Activity` POSTs.
```typescript -await client.ats.activities.metaPostRetrieve(); +await client.crm.deleteAccount.delete(); ```
@@ -17984,7 +18638,7 @@ await client.ats.activities.metaPostRetrieve();
-**requestOptions:** `Activities.RequestOptions` +**requestOptions:** `DeleteAccount.RequestOptions`
@@ -17995,9 +18649,9 @@ await client.ats.activities.metaPostRetrieve();
-## Ats Applications +## Crm EngagementTypes -
client.ats.applications.list({ ...params }) -> Merge.PaginatedApplicationList +
client.crm.engagementTypes.list({ ...params }) -> Merge.PaginatedEngagementTypeList
@@ -18009,7 +18663,7 @@ await client.ats.activities.metaPostRetrieve();
-Returns a list of `Application` objects. +Returns a list of `EngagementType` objects.
@@ -18025,7 +18679,7 @@ Returns a list of `Application` objects.
```typescript -await client.ats.applications.list(); +await client.crm.engagementTypes.list(); ```
@@ -18041,7 +18695,7 @@ await client.ats.applications.list();
-**request:** `Merge.ats.ApplicationsListRequest` +**request:** `Merge.crm.EngagementTypesListRequest`
@@ -18049,7 +18703,7 @@ await client.ats.applications.list();
-**requestOptions:** `Applications.RequestOptions` +**requestOptions:** `EngagementTypes.RequestOptions`
@@ -18060,7 +18714,7 @@ await client.ats.applications.list();
-
client.ats.applications.create({ ...params }) -> Merge.ApplicationResponse +
client.crm.engagementTypes.retrieve(id, { ...params }) -> Merge.EngagementType
@@ -18072,10 +18726,7 @@ await client.ats.applications.list();
-Creates an `Application` object with the given values. -For certain integrations, but not all, our API detects duplicate candidates and will associate applications with existing records in the third-party. New candidates are created and automatically linked to the application. - -See our [Help Center article](https://help.merge.dev/en/articles/10012366-updates-to-post-applications-oct-2024) for detailed support per integration. +Returns an `EngagementType` object with the given `id`.
@@ -18091,10 +18742,7 @@ See our [Help Center article](https://help.merge.dev/en/articles/10012366-update
```typescript -await client.ats.applications.create({ - model: {}, - remoteUserId: "remote_user_id", -}); +await client.crm.engagementTypes.retrieve("id"); ```
@@ -18110,7 +18758,7 @@ await client.ats.applications.create({
-**request:** `Merge.ats.ApplicationEndpointRequest` +**id:** `string`
@@ -18118,7 +18766,15 @@ await client.ats.applications.create({
-**requestOptions:** `Applications.RequestOptions` +**request:** `Merge.crm.EngagementTypesRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `EngagementTypes.RequestOptions`
@@ -18129,7 +18785,7 @@ await client.ats.applications.create({
-
client.ats.applications.retrieve(id, { ...params }) -> Merge.Application +
client.crm.engagementTypes.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -18141,7 +18797,7 @@ await client.ats.applications.create({
-Returns an `Application` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -18157,7 +18813,7 @@ Returns an `Application` object with the given `id`.
```typescript -await client.ats.applications.retrieve("id"); +await client.crm.engagementTypes.remoteFieldClassesList(); ```
@@ -18173,15 +18829,7 @@ await client.ats.applications.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.ApplicationsRetrieveRequest` +**request:** `Merge.crm.EngagementTypesRemoteFieldClassesListRequest`
@@ -18189,7 +18837,7 @@ await client.ats.applications.retrieve("id");
-**requestOptions:** `Applications.RequestOptions` +**requestOptions:** `EngagementTypes.RequestOptions`
@@ -18200,7 +18848,9 @@ await client.ats.applications.retrieve("id");
-
client.ats.applications.changeStageCreate(id, { ...params }) -> Merge.ApplicationResponse +## Crm Engagements + +
client.crm.engagements.list({ ...params }) -> Merge.PaginatedEngagementList
@@ -18212,7 +18862,7 @@ await client.ats.applications.retrieve("id");
-Updates the `current_stage` field of an `Application` object +Returns a list of `Engagement` objects.
@@ -18228,7 +18878,7 @@ Updates the `current_stage` field of an `Application` object
```typescript -await client.ats.applications.changeStageCreate("id"); +await client.crm.engagements.list(); ```
@@ -18244,15 +18894,7 @@ await client.ats.applications.changeStageCreate("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.UpdateApplicationStageRequest` +**request:** `Merge.crm.EngagementsListRequest`
@@ -18260,7 +18902,7 @@ await client.ats.applications.changeStageCreate("id");
-**requestOptions:** `Applications.RequestOptions` +**requestOptions:** `Engagements.RequestOptions`
@@ -18271,7 +18913,7 @@ await client.ats.applications.changeStageCreate("id");
-
client.ats.applications.metaPostRetrieve({ ...params }) -> Merge.MetaResponse +
client.crm.engagements.create({ ...params }) -> Merge.EngagementResponse
@@ -18283,7 +18925,7 @@ await client.ats.applications.changeStageCreate("id");
-Returns metadata for `Application` POSTs. +Creates an `Engagement` object with the given values.
@@ -18299,7 +18941,9 @@ Returns metadata for `Application` POSTs.
```typescript -await client.ats.applications.metaPostRetrieve(); +await client.crm.engagements.create({ + model: {}, +}); ```
@@ -18315,7 +18959,7 @@ await client.ats.applications.metaPostRetrieve();
-**request:** `Merge.ats.ApplicationsMetaPostRetrieveRequest` +**request:** `Merge.crm.EngagementEndpointRequest`
@@ -18323,7 +18967,7 @@ await client.ats.applications.metaPostRetrieve();
-**requestOptions:** `Applications.RequestOptions` +**requestOptions:** `Engagements.RequestOptions`
@@ -18334,9 +18978,7 @@ await client.ats.applications.metaPostRetrieve();
-## Ats AsyncPassthrough - -
client.ats.asyncPassthrough.create({ ...params }) -> Merge.AsyncPassthroughReciept +
client.crm.engagements.retrieve(id, { ...params }) -> Merge.Engagement
@@ -18348,7 +18990,7 @@ await client.ats.applications.metaPostRetrieve();
-Asynchronously pull data from an endpoint not currently supported by Merge. +Returns an `Engagement` object with the given `id`.
@@ -18364,10 +19006,7 @@ Asynchronously pull data from an endpoint not currently supported by Merge.
```typescript -await client.ats.asyncPassthrough.create({ - method: "GET", - path: "/scooters", -}); +await client.crm.engagements.retrieve("id"); ```
@@ -18383,7 +19022,7 @@ await client.ats.asyncPassthrough.create({
-**request:** `Merge.DataPassthroughRequest` +**id:** `string`
@@ -18391,7 +19030,15 @@ await client.ats.asyncPassthrough.create({
-**requestOptions:** `AsyncPassthrough.RequestOptions` +**request:** `Merge.crm.EngagementsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Engagements.RequestOptions`
@@ -18402,7 +19049,7 @@ await client.ats.asyncPassthrough.create({
-
client.ats.asyncPassthrough.retrieve(asyncPassthroughReceiptId) -> Merge.AsyncPassthroughRetrieveResponse +
client.crm.engagements.partialUpdate(id, { ...params }) -> Merge.EngagementResponse
@@ -18414,7 +19061,7 @@ await client.ats.asyncPassthrough.create({
-Retrieves data from earlier async-passthrough POST request +Updates an `Engagement` object with the given `id`.
@@ -18430,7 +19077,9 @@ Retrieves data from earlier async-passthrough POST request
```typescript -await client.ats.asyncPassthrough.retrieve("async_passthrough_receipt_id"); +await client.crm.engagements.partialUpdate("id", { + model: {}, +}); ```
@@ -18446,7 +19095,7 @@ await client.ats.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-**asyncPassthroughReceiptId:** `string` +**id:** `string`
@@ -18454,7 +19103,15 @@ await client.ats.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-**requestOptions:** `AsyncPassthrough.RequestOptions` +**request:** `Merge.crm.PatchedEngagementEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `Engagements.RequestOptions`
@@ -18465,9 +19122,7 @@ await client.ats.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-## Ats Attachments - -
client.ats.attachments.list({ ...params }) -> Merge.PaginatedAttachmentList +
client.crm.engagements.metaPatchRetrieve(id) -> Merge.MetaResponse
@@ -18479,7 +19134,7 @@ await client.ats.asyncPassthrough.retrieve("async_passthrough_receipt_id");
-Returns a list of `Attachment` objects. +Returns metadata for `Engagement` PATCHs.
@@ -18495,7 +19150,7 @@ Returns a list of `Attachment` objects.
```typescript -await client.ats.attachments.list(); +await client.crm.engagements.metaPatchRetrieve("id"); ```
@@ -18511,7 +19166,7 @@ await client.ats.attachments.list();
-**request:** `Merge.ats.AttachmentsListRequest` +**id:** `string`
@@ -18519,7 +19174,7 @@ await client.ats.attachments.list();
-**requestOptions:** `Attachments.RequestOptions` +**requestOptions:** `Engagements.RequestOptions`
@@ -18530,7 +19185,7 @@ await client.ats.attachments.list();
-
client.ats.attachments.create({ ...params }) -> Merge.AttachmentResponse +
client.crm.engagements.metaPostRetrieve() -> Merge.MetaResponse
@@ -18542,7 +19197,7 @@ await client.ats.attachments.list();
-Creates an `Attachment` object with the given values. +Returns metadata for `Engagement` POSTs.
@@ -18558,10 +19213,7 @@ Creates an `Attachment` object with the given values.
```typescript -await client.ats.attachments.create({ - model: {}, - remoteUserId: "remote_user_id", -}); +await client.crm.engagements.metaPostRetrieve(); ```
@@ -18577,15 +19229,7 @@ await client.ats.attachments.create({
-**request:** `Merge.ats.AttachmentEndpointRequest` - -
-
- -
-
- -**requestOptions:** `Attachments.RequestOptions` +**requestOptions:** `Engagements.RequestOptions`
@@ -18596,7 +19240,7 @@ await client.ats.attachments.create({
-
client.ats.attachments.retrieve(id, { ...params }) -> Merge.Attachment +
client.crm.engagements.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -18608,7 +19252,7 @@ await client.ats.attachments.create({
-Returns an `Attachment` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -18624,7 +19268,7 @@ Returns an `Attachment` object with the given `id`.
```typescript -await client.ats.attachments.retrieve("id"); +await client.crm.engagements.remoteFieldClassesList(); ```
@@ -18640,15 +19284,7 @@ await client.ats.attachments.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.AttachmentsRetrieveRequest` +**request:** `Merge.crm.EngagementsRemoteFieldClassesListRequest`
@@ -18656,7 +19292,7 @@ await client.ats.attachments.retrieve("id");
-**requestOptions:** `Attachments.RequestOptions` +**requestOptions:** `Engagements.RequestOptions`
@@ -18667,7 +19303,9 @@ await client.ats.attachments.retrieve("id");
-
client.ats.attachments.metaPostRetrieve() -> Merge.MetaResponse +## Crm FieldMapping + +
client.crm.fieldMapping.fieldMappingsRetrieve({ ...params }) -> Merge.FieldMappingApiInstanceResponse
@@ -18679,7 +19317,7 @@ await client.ats.attachments.retrieve("id");
-Returns metadata for `Attachment` POSTs. +Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge fields. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/).
@@ -18695,7 +19333,7 @@ Returns metadata for `Attachment` POSTs.
```typescript -await client.ats.attachments.metaPostRetrieve(); +await client.crm.fieldMapping.fieldMappingsRetrieve(); ```
@@ -18711,7 +19349,15 @@ await client.ats.attachments.metaPostRetrieve();
-**requestOptions:** `Attachments.RequestOptions` +**request:** `Merge.crm.FieldMappingsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `FieldMapping.RequestOptions`
@@ -18722,9 +19368,7 @@ await client.ats.attachments.metaPostRetrieve();
-## Ats AuditTrail - -
client.ats.auditTrail.list({ ...params }) -> Merge.PaginatedAuditLogEventList +
client.crm.fieldMapping.fieldMappingsCreate({ ...params }) -> Merge.FieldMappingInstanceResponse
@@ -18736,7 +19380,7 @@ await client.ats.attachments.metaPostRetrieve();
-Gets a list of audit trail events. +Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start.
@@ -18752,7 +19396,14 @@ Gets a list of audit trail events.
```typescript -await client.ats.auditTrail.list(); +await client.crm.fieldMapping.fieldMappingsCreate({ + targetFieldName: "example_target_field_name", + targetFieldDescription: "this is a example description of the target field", + remoteFieldTraversalPath: ["example_remote_field"], + remoteMethod: "GET", + remoteUrlPath: "/example-url-path", + commonModelName: "ExampleCommonModel", +}); ```
@@ -18768,7 +19419,7 @@ await client.ats.auditTrail.list();
-**request:** `Merge.ats.AuditTrailListRequest` +**request:** `Merge.crm.CreateFieldMappingRequest`
@@ -18776,7 +19427,7 @@ await client.ats.auditTrail.list();
-**requestOptions:** `AuditTrail.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -18787,9 +19438,7 @@ await client.ats.auditTrail.list();
-## Ats AvailableActions - -
client.ats.availableActions.retrieve() -> Merge.AvailableActions +
client.crm.fieldMapping.fieldMappingsDestroy(fieldMappingId) -> Merge.FieldMappingInstanceResponse
@@ -18801,7 +19450,7 @@ await client.ats.auditTrail.list();
-Returns a list of models and actions available for an account. +Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start.
@@ -18817,7 +19466,7 @@ Returns a list of models and actions available for an account.
```typescript -await client.ats.availableActions.retrieve(); +await client.crm.fieldMapping.fieldMappingsDestroy("field_mapping_id"); ```
@@ -18833,7 +19482,15 @@ await client.ats.availableActions.retrieve();
-**requestOptions:** `AvailableActions.RequestOptions` +**fieldMappingId:** `string` + +
+
+ +
+
+ +**requestOptions:** `FieldMapping.RequestOptions`
@@ -18844,9 +19501,7 @@ await client.ats.availableActions.retrieve();
-## Ats Candidates - -
client.ats.candidates.list({ ...params }) -> Merge.PaginatedCandidateList +
client.crm.fieldMapping.fieldMappingsPartialUpdate(fieldMappingId, { ...params }) -> Merge.FieldMappingInstanceResponse
@@ -18858,7 +19513,7 @@ await client.ats.availableActions.retrieve();
-Returns a list of `Candidate` objects. +Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start.
@@ -18874,7 +19529,7 @@ Returns a list of `Candidate` objects.
```typescript -await client.ats.candidates.list(); +await client.crm.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id"); ```
@@ -18890,7 +19545,7 @@ await client.ats.candidates.list();
-**request:** `Merge.ats.CandidatesListRequest` +**fieldMappingId:** `string`
@@ -18898,7 +19553,15 @@ await client.ats.candidates.list();
-**requestOptions:** `Candidates.RequestOptions` +**request:** `Merge.crm.PatchedEditFieldMappingRequest` + +
+
+ +
+
+ +**requestOptions:** `FieldMapping.RequestOptions`
@@ -18909,7 +19572,7 @@ await client.ats.candidates.list();
-
client.ats.candidates.create({ ...params }) -> Merge.CandidateResponse +
client.crm.fieldMapping.remoteFieldsRetrieve({ ...params }) -> Merge.RemoteFieldApiResponse
@@ -18921,7 +19584,7 @@ await client.ats.candidates.list();
-Creates a `Candidate` object with the given values. +Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data is enabled. You can use remote fields to override existing Merge fields or map a new Merge field. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/).
@@ -18937,10 +19600,7 @@ Creates a `Candidate` object with the given values.
```typescript -await client.ats.candidates.create({ - model: {}, - remoteUserId: "remote_user_id", -}); +await client.crm.fieldMapping.remoteFieldsRetrieve(); ```
@@ -18956,7 +19616,7 @@ await client.ats.candidates.create({
-**request:** `Merge.ats.CandidateEndpointRequest` +**request:** `Merge.crm.RemoteFieldsRetrieveRequest`
@@ -18964,7 +19624,7 @@ await client.ats.candidates.create({
-**requestOptions:** `Candidates.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -18975,7 +19635,7 @@ await client.ats.candidates.create({
-
client.ats.candidates.retrieve(id, { ...params }) -> Merge.Candidate +
client.crm.fieldMapping.targetFieldsRetrieve() -> Merge.ExternalTargetFieldApiResponse
@@ -18987,7 +19647,7 @@ await client.ats.candidates.create({
-Returns a `Candidate` object with the given `id`. +Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields are additional fields appended to the Merge Common Model for all Linked Accounts in a category. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/target-fields/).
@@ -19003,7 +19663,7 @@ Returns a `Candidate` object with the given `id`.
```typescript -await client.ats.candidates.retrieve("id"); +await client.crm.fieldMapping.targetFieldsRetrieve(); ```
@@ -19019,23 +19679,7 @@ await client.ats.candidates.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.CandidatesRetrieveRequest` - -
-
- -
-
- -**requestOptions:** `Candidates.RequestOptions` +**requestOptions:** `FieldMapping.RequestOptions`
@@ -19046,7 +19690,9 @@ await client.ats.candidates.retrieve("id");
-
client.ats.candidates.partialUpdate(id, { ...params }) -> Merge.CandidateResponse +## Crm GenerateKey + +
client.crm.generateKey.create({ ...params }) -> Merge.RemoteKey
@@ -19058,7 +19704,7 @@ await client.ats.candidates.retrieve("id");
-Updates a `Candidate` object with the given `id`. +Create a remote key.
@@ -19074,9 +19720,8 @@ Updates a `Candidate` object with the given `id`.
```typescript -await client.ats.candidates.partialUpdate("id", { - model: {}, - remoteUserId: "remote_user_id", +await client.crm.generateKey.create({ + name: "Remote Deployment Key 1", }); ``` @@ -19093,15 +19738,7 @@ await client.ats.candidates.partialUpdate("id", {
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.PatchedCandidateEndpointRequest` +**request:** `Merge.crm.GenerateRemoteKeyRequest`
@@ -19109,7 +19746,7 @@ await client.ats.candidates.partialUpdate("id", {
-**requestOptions:** `Candidates.RequestOptions` +**requestOptions:** `GenerateKey.RequestOptions`
@@ -19120,7 +19757,9 @@ await client.ats.candidates.partialUpdate("id", {
-
client.ats.candidates.ignoreCreate(modelId, { ...params }) -> void +## Crm Issues + +
client.crm.issues.list({ ...params }) -> Merge.PaginatedIssueList
@@ -19132,7 +19771,7 @@ await client.ats.candidates.partialUpdate("id", {
-Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in future syncs. The "reason" and "message" fields in the request body will be stored for audit purposes. +Gets all issues for Organization.
@@ -19148,9 +19787,7 @@ Ignores a specific row based on the `model_id` in the url. These records will ha
```typescript -await client.ats.candidates.ignoreCreate("model_id", { - reason: "GENERAL_CUSTOMER_REQUEST", -}); +await client.crm.issues.list(); ```
@@ -19166,15 +19803,7 @@ await client.ats.candidates.ignoreCreate("model_id", {
-**modelId:** `string` - -
-
- -
-
- -**request:** `Merge.ats.IgnoreCommonModelRequest` +**request:** `Merge.crm.IssuesListRequest`
@@ -19182,7 +19811,7 @@ await client.ats.candidates.ignoreCreate("model_id", {
-**requestOptions:** `Candidates.RequestOptions` +**requestOptions:** `Issues.RequestOptions`
@@ -19193,7 +19822,7 @@ await client.ats.candidates.ignoreCreate("model_id", {
-
client.ats.candidates.metaPatchRetrieve(id) -> Merge.MetaResponse +
client.crm.issues.retrieve(id) -> Merge.Issue
@@ -19205,7 +19834,7 @@ await client.ats.candidates.ignoreCreate("model_id", {
-Returns metadata for `Candidate` PATCHs. +Get a specific issue.
@@ -19221,7 +19850,7 @@ Returns metadata for `Candidate` PATCHs.
```typescript -await client.ats.candidates.metaPatchRetrieve("id"); +await client.crm.issues.retrieve("id"); ```
@@ -19245,7 +19874,7 @@ await client.ats.candidates.metaPatchRetrieve("id");
-**requestOptions:** `Candidates.RequestOptions` +**requestOptions:** `Issues.RequestOptions`
@@ -19256,7 +19885,9 @@ await client.ats.candidates.metaPatchRetrieve("id");
-
client.ats.candidates.metaPostRetrieve() -> Merge.MetaResponse +## Crm Leads + +
client.crm.leads.list({ ...params }) -> Merge.PaginatedLeadList
@@ -19268,7 +19899,7 @@ await client.ats.candidates.metaPatchRetrieve("id");
-Returns metadata for `Candidate` POSTs. +Returns a list of `Lead` objects.
@@ -19284,7 +19915,7 @@ Returns metadata for `Candidate` POSTs.
```typescript -await client.ats.candidates.metaPostRetrieve(); +await client.crm.leads.list(); ```
@@ -19300,7 +19931,15 @@ await client.ats.candidates.metaPostRetrieve();
-**requestOptions:** `Candidates.RequestOptions` +**request:** `Merge.crm.LeadsListRequest` + +
+
+ +
+
+ +**requestOptions:** `Leads.RequestOptions`
@@ -19311,9 +19950,7 @@ await client.ats.candidates.metaPostRetrieve();
-## Ats Scopes - -
client.ats.scopes.defaultScopesRetrieve() -> Merge.CommonModelScopeApi +
client.crm.leads.create({ ...params }) -> Merge.LeadResponse
@@ -19325,7 +19962,7 @@ await client.ats.candidates.metaPostRetrieve();
-Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). +Creates a `Lead` object with the given values.
@@ -19341,7 +19978,9 @@ Get the default permissions for Merge Common Models and fields across all Linked
```typescript -await client.ats.scopes.defaultScopesRetrieve(); +await client.crm.leads.create({ + model: {}, +}); ```
@@ -19357,7 +19996,15 @@ await client.ats.scopes.defaultScopesRetrieve();
-**requestOptions:** `Scopes.RequestOptions` +**request:** `Merge.crm.LeadEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `Leads.RequestOptions`
@@ -19368,7 +20015,7 @@ await client.ats.scopes.defaultScopesRetrieve();
-
client.ats.scopes.linkedAccountScopesRetrieve() -> Merge.CommonModelScopeApi +
client.crm.leads.retrieve(id, { ...params }) -> Merge.Lead
@@ -19380,7 +20027,7 @@ await client.ats.scopes.defaultScopesRetrieve();
-Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). +Returns a `Lead` object with the given `id`.
@@ -19396,7 +20043,7 @@ Get all available permissions for Merge Common Models and fields for a single Li
```typescript -await client.ats.scopes.linkedAccountScopesRetrieve(); +await client.crm.leads.retrieve("id"); ```
@@ -19412,7 +20059,23 @@ await client.ats.scopes.linkedAccountScopesRetrieve();
-**requestOptions:** `Scopes.RequestOptions` +**id:** `string` + +
+
+ +
+
+ +**request:** `Merge.crm.LeadsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Leads.RequestOptions`
@@ -19423,7 +20086,7 @@ await client.ats.scopes.linkedAccountScopesRetrieve();
-
client.ats.scopes.linkedAccountScopesCreate({ ...params }) -> Merge.CommonModelScopeApi +
client.crm.leads.metaPostRetrieve() -> Merge.MetaResponse
@@ -19435,7 +20098,7 @@ await client.ats.scopes.linkedAccountScopesRetrieve();
-Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the default Scopes. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes) +Returns metadata for `Lead` POSTs.
@@ -19451,33 +20114,7 @@ Update permissions for any Common Model or field for a single Linked Account. An
```typescript -await client.ats.scopes.linkedAccountScopesCreate({ - commonModels: [ - { - modelName: "Employee", - modelPermissions: { - READ: { - isEnabled: true, - }, - WRITE: { - isEnabled: false, - }, - }, - fieldPermissions: { - enabledFields: ["avatar", "home_location"], - disabledFields: ["work_location"], - }, - }, - { - modelName: "Benefit", - modelPermissions: { - WRITE: { - isEnabled: false, - }, - }, - }, - ], -}); +await client.crm.leads.metaPostRetrieve(); ```
@@ -19493,15 +20130,7 @@ await client.ats.scopes.linkedAccountScopesCreate({
-**request:** `Merge.ats.LinkedAccountCommonModelScopeDeserializerRequest` - -
-
- -
-
- -**requestOptions:** `Scopes.RequestOptions` +**requestOptions:** `Leads.RequestOptions`
@@ -19512,9 +20141,7 @@ await client.ats.scopes.linkedAccountScopesCreate({
-## Ats DeleteAccount - -
client.ats.deleteAccount.delete() -> void +
client.crm.leads.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -19526,7 +20153,7 @@ await client.ats.scopes.linkedAccountScopesCreate({
-Delete a linked account. +Returns a list of `RemoteFieldClass` objects.
@@ -19542,7 +20169,7 @@ Delete a linked account.
```typescript -await client.ats.deleteAccount.delete(); +await client.crm.leads.remoteFieldClassesList(); ```
@@ -19558,7 +20185,15 @@ await client.ats.deleteAccount.delete();
-**requestOptions:** `DeleteAccount.RequestOptions` +**request:** `Merge.crm.LeadsRemoteFieldClassesListRequest` + +
+
+ +
+
+ +**requestOptions:** `Leads.RequestOptions`
@@ -19569,9 +20204,9 @@ await client.ats.deleteAccount.delete();
-## Ats Departments +## Crm LinkToken -
client.ats.departments.list({ ...params }) -> Merge.PaginatedDepartmentList +
client.crm.linkToken.create({ ...params }) -> Merge.LinkToken
@@ -19583,7 +20218,7 @@ await client.ats.deleteAccount.delete();
-Returns a list of `Department` objects. +Creates a link token to be used when linking a new end user.
@@ -19599,7 +20234,12 @@ Returns a list of `Department` objects.
```typescript -await client.ats.departments.list(); +await client.crm.linkToken.create({ + endUserEmailAddress: "example@gmail.com", + endUserOrganizationName: "Test Organization", + endUserOriginId: "12345", + categories: ["hris", "ats"], +}); ```
@@ -19615,7 +20255,7 @@ await client.ats.departments.list();
-**request:** `Merge.ats.DepartmentsListRequest` +**request:** `Merge.crm.EndUserDetailsRequest`
@@ -19623,7 +20263,7 @@ await client.ats.departments.list();
-**requestOptions:** `Departments.RequestOptions` +**requestOptions:** `LinkToken.RequestOptions`
@@ -19634,7 +20274,9 @@ await client.ats.departments.list();
-
client.ats.departments.retrieve(id, { ...params }) -> Merge.Department +## Crm LinkedAccounts + +
client.crm.linkedAccounts.list({ ...params }) -> Merge.PaginatedAccountDetailsAndActionsList
@@ -19646,7 +20288,7 @@ await client.ats.departments.list();
-Returns a `Department` object with the given `id`. +List linked accounts for your organization.
@@ -19662,7 +20304,7 @@ Returns a `Department` object with the given `id`.
```typescript -await client.ats.departments.retrieve("id"); +await client.crm.linkedAccounts.list(); ```
@@ -19678,15 +20320,7 @@ await client.ats.departments.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.DepartmentsRetrieveRequest` +**request:** `Merge.crm.LinkedAccountsListRequest`
@@ -19694,7 +20328,7 @@ await client.ats.departments.retrieve("id");
-**requestOptions:** `Departments.RequestOptions` +**requestOptions:** `LinkedAccounts.RequestOptions`
@@ -19705,9 +20339,9 @@ await client.ats.departments.retrieve("id");
-## Ats Eeocs +## Crm Notes -
client.ats.eeocs.list({ ...params }) -> Merge.PaginatedEeocList +
client.crm.notes.list({ ...params }) -> Merge.PaginatedNoteList
@@ -19719,7 +20353,7 @@ await client.ats.departments.retrieve("id");
-Returns a list of `EEOC` objects. +Returns a list of `Note` objects.
@@ -19735,7 +20369,7 @@ Returns a list of `EEOC` objects.
```typescript -await client.ats.eeocs.list(); +await client.crm.notes.list(); ```
@@ -19751,7 +20385,7 @@ await client.ats.eeocs.list();
-**request:** `Merge.ats.EeocsListRequest` +**request:** `Merge.crm.NotesListRequest`
@@ -19759,7 +20393,7 @@ await client.ats.eeocs.list();
-**requestOptions:** `Eeocs.RequestOptions` +**requestOptions:** `Notes.RequestOptions`
@@ -19770,7 +20404,7 @@ await client.ats.eeocs.list();
-
client.ats.eeocs.retrieve(id, { ...params }) -> Merge.Eeoc +
client.crm.notes.create({ ...params }) -> Merge.NoteResponse
@@ -19782,7 +20416,7 @@ await client.ats.eeocs.list();
-Returns an `EEOC` object with the given `id`. +Creates a `Note` object with the given values.
@@ -19798,7 +20432,9 @@ Returns an `EEOC` object with the given `id`.
```typescript -await client.ats.eeocs.retrieve("id"); +await client.crm.notes.create({ + model: {}, +}); ```
@@ -19814,15 +20450,7 @@ await client.ats.eeocs.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.EeocsRetrieveRequest` +**request:** `Merge.crm.NoteEndpointRequest`
@@ -19830,7 +20458,7 @@ await client.ats.eeocs.retrieve("id");
-**requestOptions:** `Eeocs.RequestOptions` +**requestOptions:** `Notes.RequestOptions`
@@ -19841,9 +20469,7 @@ await client.ats.eeocs.retrieve("id");
-## Ats FieldMapping - -
client.ats.fieldMapping.fieldMappingsRetrieve({ ...params }) -> Merge.FieldMappingApiInstanceResponse +
client.crm.notes.retrieve(id, { ...params }) -> Merge.Note
@@ -19855,7 +20481,7 @@ await client.ats.eeocs.retrieve("id");
-Get all Field Mappings for this Linked Account. Field Mappings are mappings between third-party Remote Fields and user defined Merge fields. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/). +Returns a `Note` object with the given `id`.
@@ -19871,7 +20497,7 @@ Get all Field Mappings for this Linked Account. Field Mappings are mappings betw
```typescript -await client.ats.fieldMapping.fieldMappingsRetrieve(); +await client.crm.notes.retrieve("id"); ```
@@ -19887,7 +20513,7 @@ await client.ats.fieldMapping.fieldMappingsRetrieve();
-**request:** `Merge.ats.FieldMappingsRetrieveRequest` +**id:** `string`
@@ -19895,7 +20521,15 @@ await client.ats.fieldMapping.fieldMappingsRetrieve();
-**requestOptions:** `FieldMapping.RequestOptions` +**request:** `Merge.crm.NotesRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Notes.RequestOptions`
@@ -19906,7 +20540,7 @@ await client.ats.fieldMapping.fieldMappingsRetrieve();
-
client.ats.fieldMapping.fieldMappingsCreate({ ...params }) -> Merge.FieldMappingInstanceResponse +
client.crm.notes.metaPostRetrieve() -> Merge.MetaResponse
@@ -19918,7 +20552,7 @@ await client.ats.fieldMapping.fieldMappingsRetrieve();
-Create new Field Mappings that will be available after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start. +Returns metadata for `Note` POSTs.
@@ -19934,14 +20568,7 @@ Create new Field Mappings that will be available after the next scheduled sync.
```typescript -await client.ats.fieldMapping.fieldMappingsCreate({ - targetFieldName: "example_target_field_name", - targetFieldDescription: "this is a example description of the target field", - remoteFieldTraversalPath: ["example_remote_field"], - remoteMethod: "GET", - remoteUrlPath: "/example-url-path", - commonModelName: "ExampleCommonModel", -}); +await client.crm.notes.metaPostRetrieve(); ```
@@ -19957,15 +20584,7 @@ await client.ats.fieldMapping.fieldMappingsCreate({
-**request:** `Merge.ats.CreateFieldMappingRequest` - -
-
- -
-
- -**requestOptions:** `FieldMapping.RequestOptions` +**requestOptions:** `Notes.RequestOptions`
@@ -19976,7 +20595,7 @@ await client.ats.fieldMapping.fieldMappingsCreate({
-
client.ats.fieldMapping.fieldMappingsDestroy(fieldMappingId) -> Merge.FieldMappingInstanceResponse +
client.crm.notes.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -19988,7 +20607,7 @@ await client.ats.fieldMapping.fieldMappingsCreate({
-Deletes Field Mappings for a Linked Account. All data related to this Field Mapping will be deleted and these changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start. +Returns a list of `RemoteFieldClass` objects.
@@ -20004,7 +20623,7 @@ Deletes Field Mappings for a Linked Account. All data related to this Field Mapp
```typescript -await client.ats.fieldMapping.fieldMappingsDestroy("field_mapping_id"); +await client.crm.notes.remoteFieldClassesList(); ```
@@ -20020,7 +20639,7 @@ await client.ats.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-**fieldMappingId:** `string` +**request:** `Merge.crm.NotesRemoteFieldClassesListRequest`
@@ -20028,7 +20647,7 @@ await client.ats.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-**requestOptions:** `FieldMapping.RequestOptions` +**requestOptions:** `Notes.RequestOptions`
@@ -20039,7 +20658,9 @@ await client.ats.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-
client.ats.fieldMapping.fieldMappingsPartialUpdate(fieldMappingId, { ...params }) -> Merge.FieldMappingInstanceResponse +## Crm Opportunities + +
client.crm.opportunities.list({ ...params }) -> Merge.PaginatedOpportunityList
@@ -20051,7 +20672,7 @@ await client.ats.fieldMapping.fieldMappingsDestroy("field_mapping_id");
-Create or update existing Field Mappings for a Linked Account. Changes will be reflected after the next scheduled sync. This will cause the next sync for this Linked Account to sync **ALL** data from start. +Returns a list of `Opportunity` objects.
@@ -20067,7 +20688,7 @@ Create or update existing Field Mappings for a Linked Account. Changes will be r
```typescript -await client.ats.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id"); +await client.crm.opportunities.list(); ```
@@ -20083,15 +20704,7 @@ await client.ats.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-**fieldMappingId:** `string` - -
-
- -
-
- -**request:** `Merge.ats.PatchedEditFieldMappingRequest` +**request:** `Merge.crm.OpportunitiesListRequest`
@@ -20099,7 +20712,7 @@ await client.ats.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-**requestOptions:** `FieldMapping.RequestOptions` +**requestOptions:** `Opportunities.RequestOptions`
@@ -20110,7 +20723,7 @@ await client.ats.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-
client.ats.fieldMapping.remoteFieldsRetrieve({ ...params }) -> Merge.RemoteFieldApiResponse +
client.crm.opportunities.create({ ...params }) -> Merge.OpportunityResponse
@@ -20122,7 +20735,7 @@ await client.ats.fieldMapping.fieldMappingsPartialUpdate("field_mapping_id");
-Get all remote fields for a Linked Account. Remote fields are third-party fields that are accessible after initial sync if remote_data is enabled. You can use remote fields to override existing Merge fields or map a new Merge field. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/overview/). +Creates an `Opportunity` object with the given values.
@@ -20138,7 +20751,9 @@ Get all remote fields for a Linked Account. Remote fields are third-party fields
```typescript -await client.ats.fieldMapping.remoteFieldsRetrieve(); +await client.crm.opportunities.create({ + model: {}, +}); ```
@@ -20154,7 +20769,7 @@ await client.ats.fieldMapping.remoteFieldsRetrieve();
-**request:** `Merge.ats.RemoteFieldsRetrieveRequest` +**request:** `Merge.crm.OpportunityEndpointRequest`
@@ -20162,7 +20777,7 @@ await client.ats.fieldMapping.remoteFieldsRetrieve();
-**requestOptions:** `FieldMapping.RequestOptions` +**requestOptions:** `Opportunities.RequestOptions`
@@ -20173,7 +20788,7 @@ await client.ats.fieldMapping.remoteFieldsRetrieve();
-
client.ats.fieldMapping.targetFieldsRetrieve() -> Merge.ExternalTargetFieldApiResponse +
client.crm.opportunities.retrieve(id, { ...params }) -> Merge.Opportunity
@@ -20185,7 +20800,7 @@ await client.ats.fieldMapping.remoteFieldsRetrieve();
-Get all organization-wide Target Fields, this will not include any Linked Account specific Target Fields. Organization-wide Target Fields are additional fields appended to the Merge Common Model for all Linked Accounts in a category. [Learn more](https://docs.merge.dev/supplemental-data/field-mappings/target-fields/). +Returns an `Opportunity` object with the given `id`.
@@ -20201,7 +20816,7 @@ Get all organization-wide Target Fields, this will not include any Linked Accoun
```typescript -await client.ats.fieldMapping.targetFieldsRetrieve(); +await client.crm.opportunities.retrieve("id"); ```
@@ -20217,20 +20832,34 @@ await client.ats.fieldMapping.targetFieldsRetrieve();
-**requestOptions:** `FieldMapping.RequestOptions` +**id:** `string`
+ +
+
+ +**request:** `Merge.crm.OpportunitiesRetrieveRequest` +
+
+
+ +**requestOptions:** `Opportunities.RequestOptions` + +
+
-
-## Ats GenerateKey + + +
-
client.ats.generateKey.create({ ...params }) -> Merge.RemoteKey +
client.crm.opportunities.partialUpdate(id, { ...params }) -> Merge.OpportunityResponse
@@ -20242,7 +20871,7 @@ await client.ats.fieldMapping.targetFieldsRetrieve();
-Create a remote key. +Updates an `Opportunity` object with the given `id`.
@@ -20258,8 +20887,8 @@ Create a remote key.
```typescript -await client.ats.generateKey.create({ - name: "Remote Deployment Key 1", +await client.crm.opportunities.partialUpdate("id", { + model: {}, }); ``` @@ -20276,7 +20905,7 @@ await client.ats.generateKey.create({
-**request:** `Merge.ats.GenerateRemoteKeyRequest` +**id:** `string`
@@ -20284,7 +20913,15 @@ await client.ats.generateKey.create({
-**requestOptions:** `GenerateKey.RequestOptions` +**request:** `Merge.crm.PatchedOpportunityEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `Opportunities.RequestOptions`
@@ -20295,9 +20932,7 @@ await client.ats.generateKey.create({
-## Ats Interviews - -
client.ats.interviews.list({ ...params }) -> Merge.PaginatedScheduledInterviewList +
client.crm.opportunities.metaPatchRetrieve(id) -> Merge.MetaResponse
@@ -20309,7 +20944,7 @@ await client.ats.generateKey.create({
-Returns a list of `ScheduledInterview` objects. +Returns metadata for `Opportunity` PATCHs.
@@ -20325,7 +20960,7 @@ Returns a list of `ScheduledInterview` objects.
```typescript -await client.ats.interviews.list(); +await client.crm.opportunities.metaPatchRetrieve("id"); ```
@@ -20341,7 +20976,7 @@ await client.ats.interviews.list();
-**request:** `Merge.ats.InterviewsListRequest` +**id:** `string`
@@ -20349,7 +20984,7 @@ await client.ats.interviews.list();
-**requestOptions:** `Interviews.RequestOptions` +**requestOptions:** `Opportunities.RequestOptions`
@@ -20360,7 +20995,7 @@ await client.ats.interviews.list();
-
client.ats.interviews.create({ ...params }) -> Merge.ScheduledInterviewResponse +
client.crm.opportunities.metaPostRetrieve() -> Merge.MetaResponse
@@ -20372,7 +21007,7 @@ await client.ats.interviews.list();
-Creates a `ScheduledInterview` object with the given values. +Returns metadata for `Opportunity` POSTs.
@@ -20388,10 +21023,7 @@ Creates a `ScheduledInterview` object with the given values.
```typescript -await client.ats.interviews.create({ - model: {}, - remoteUserId: "remote_user_id", -}); +await client.crm.opportunities.metaPostRetrieve(); ```
@@ -20407,15 +21039,7 @@ await client.ats.interviews.create({
-**request:** `Merge.ats.ScheduledInterviewEndpointRequest` - -
-
- -
-
- -**requestOptions:** `Interviews.RequestOptions` +**requestOptions:** `Opportunities.RequestOptions`
@@ -20426,7 +21050,7 @@ await client.ats.interviews.create({
-
client.ats.interviews.retrieve(id, { ...params }) -> Merge.ScheduledInterview +
client.crm.opportunities.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -20438,7 +21062,7 @@ await client.ats.interviews.create({
-Returns a `ScheduledInterview` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -20454,7 +21078,7 @@ Returns a `ScheduledInterview` object with the given `id`.
```typescript -await client.ats.interviews.retrieve("id"); +await client.crm.opportunities.remoteFieldClassesList(); ```
@@ -20470,15 +21094,7 @@ await client.ats.interviews.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.InterviewsRetrieveRequest` +**request:** `Merge.crm.OpportunitiesRemoteFieldClassesListRequest`
@@ -20486,7 +21102,7 @@ await client.ats.interviews.retrieve("id");
-**requestOptions:** `Interviews.RequestOptions` +**requestOptions:** `Opportunities.RequestOptions`
@@ -20497,7 +21113,9 @@ await client.ats.interviews.retrieve("id");
-
client.ats.interviews.metaPostRetrieve() -> Merge.MetaResponse +## Crm Passthrough + +
client.crm.passthrough.create({ ...params }) -> Merge.RemoteResponse
@@ -20509,7 +21127,7 @@ await client.ats.interviews.retrieve("id");
-Returns metadata for `ScheduledInterview` POSTs. +Pull data from an endpoint not currently supported by Merge.
@@ -20525,7 +21143,10 @@ Returns metadata for `ScheduledInterview` POSTs.
```typescript -await client.ats.interviews.metaPostRetrieve(); +await client.crm.passthrough.create({ + method: "GET", + path: "/scooters", +}); ```
@@ -20541,7 +21162,15 @@ await client.ats.interviews.metaPostRetrieve();
-**requestOptions:** `Interviews.RequestOptions` +**request:** `Merge.DataPassthroughRequest` + +
+
+ +
+
+ +**requestOptions:** `Passthrough.RequestOptions`
@@ -20552,9 +21181,9 @@ await client.ats.interviews.metaPostRetrieve();
-## Ats Issues +## Crm RegenerateKey -
client.ats.issues.list({ ...params }) -> Merge.PaginatedIssueList +
client.crm.regenerateKey.create({ ...params }) -> Merge.RemoteKey
@@ -20566,7 +21195,7 @@ await client.ats.interviews.metaPostRetrieve();
-Gets all issues for Organization. +Exchange remote keys.
@@ -20582,7 +21211,9 @@ Gets all issues for Organization.
```typescript -await client.ats.issues.list(); +await client.crm.regenerateKey.create({ + name: "Remote Deployment Key 1", +}); ```
@@ -20598,7 +21229,7 @@ await client.ats.issues.list();
-**request:** `Merge.ats.IssuesListRequest` +**request:** `Merge.crm.RemoteKeyForRegenerationRequest`
@@ -20606,7 +21237,7 @@ await client.ats.issues.list();
-**requestOptions:** `Issues.RequestOptions` +**requestOptions:** `RegenerateKey.RequestOptions`
@@ -20617,7 +21248,9 @@ await client.ats.issues.list();
-
client.ats.issues.retrieve(id) -> Merge.Issue +## Crm Stages + +
client.crm.stages.list({ ...params }) -> Merge.PaginatedStageList
@@ -20629,7 +21262,7 @@ await client.ats.issues.list();
-Get a specific issue. +Returns a list of `Stage` objects.
@@ -20645,7 +21278,7 @@ Get a specific issue.
```typescript -await client.ats.issues.retrieve("id"); +await client.crm.stages.list(); ```
@@ -20661,7 +21294,7 @@ await client.ats.issues.retrieve("id");
-**id:** `string` +**request:** `Merge.crm.StagesListRequest`
@@ -20669,7 +21302,7 @@ await client.ats.issues.retrieve("id");
-**requestOptions:** `Issues.RequestOptions` +**requestOptions:** `Stages.RequestOptions`
@@ -20680,9 +21313,7 @@ await client.ats.issues.retrieve("id");
-## Ats JobInterviewStages - -
client.ats.jobInterviewStages.list({ ...params }) -> Merge.PaginatedJobInterviewStageList +
client.crm.stages.retrieve(id, { ...params }) -> Merge.Stage
@@ -20694,7 +21325,7 @@ await client.ats.issues.retrieve("id");
-Returns a list of `JobInterviewStage` objects. +Returns a `Stage` object with the given `id`.
@@ -20710,7 +21341,7 @@ Returns a list of `JobInterviewStage` objects.
```typescript -await client.ats.jobInterviewStages.list(); +await client.crm.stages.retrieve("id"); ```
@@ -20726,7 +21357,7 @@ await client.ats.jobInterviewStages.list();
-**request:** `Merge.ats.JobInterviewStagesListRequest` +**id:** `string`
@@ -20734,7 +21365,15 @@ await client.ats.jobInterviewStages.list();
-**requestOptions:** `JobInterviewStages.RequestOptions` +**request:** `Merge.crm.StagesRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Stages.RequestOptions`
@@ -20745,7 +21384,7 @@ await client.ats.jobInterviewStages.list();
-
client.ats.jobInterviewStages.retrieve(id, { ...params }) -> Merge.JobInterviewStage +
client.crm.stages.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -20757,7 +21396,7 @@ await client.ats.jobInterviewStages.list();
-Returns a `JobInterviewStage` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -20773,7 +21412,7 @@ Returns a `JobInterviewStage` object with the given `id`.
```typescript -await client.ats.jobInterviewStages.retrieve("id"); +await client.crm.stages.remoteFieldClassesList(); ```
@@ -20789,15 +21428,7 @@ await client.ats.jobInterviewStages.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.JobInterviewStagesRetrieveRequest` +**request:** `Merge.crm.StagesRemoteFieldClassesListRequest`
@@ -20805,7 +21436,7 @@ await client.ats.jobInterviewStages.retrieve("id");
-**requestOptions:** `JobInterviewStages.RequestOptions` +**requestOptions:** `Stages.RequestOptions`
@@ -20816,9 +21447,9 @@ await client.ats.jobInterviewStages.retrieve("id");
-## Ats JobPostings +## Crm SyncStatus -
client.ats.jobPostings.list({ ...params }) -> Merge.PaginatedJobPostingList +
client.crm.syncStatus.list({ ...params }) -> Merge.PaginatedSyncStatusList
@@ -20830,7 +21461,7 @@ await client.ats.jobInterviewStages.retrieve("id");
-Returns a list of `JobPosting` objects. +Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. `last_sync_finished` represents the most recent time any sync completed. These timestamps may correspond to different sync instances which may result in a sync start time being later than a separate sync completed time. To ensure you are retrieving the latest available data reference the `last_sync_finished` timestamp where `last_sync_result` is `DONE`. Possible values for `status` and `last_sync_result` are `DISABLED`, `DONE`, `FAILED`, `PARTIALLY_SYNCED`, `PAUSED`, `SYNCING`. Learn more about sync status in our [Help Center](https://help.merge.dev/en/articles/8184193-merge-sync-statuses).
@@ -20846,7 +21477,7 @@ Returns a list of `JobPosting` objects.
```typescript -await client.ats.jobPostings.list(); +await client.crm.syncStatus.list(); ```
@@ -20862,7 +21493,7 @@ await client.ats.jobPostings.list();
-**request:** `Merge.ats.JobPostingsListRequest` +**request:** `Merge.crm.SyncStatusListRequest`
@@ -20870,7 +21501,7 @@ await client.ats.jobPostings.list();
-**requestOptions:** `JobPostings.RequestOptions` +**requestOptions:** `SyncStatus.RequestOptions`
@@ -20881,7 +21512,9 @@ await client.ats.jobPostings.list();
-
client.ats.jobPostings.retrieve(id, { ...params }) -> Merge.JobPosting +## Crm ForceResync + +
client.crm.forceResync.syncStatusResyncCreate() -> Merge.SyncStatus[]
@@ -20893,7 +21526,7 @@ await client.ats.jobPostings.list();
-Returns a `JobPosting` object with the given `id`. +Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or Enterprise plans. Doing so will consume a sync credit for the relevant linked account. Force re-syncs can also be triggered manually in the Merge Dashboard and is available for all customers.
@@ -20909,7 +21542,7 @@ Returns a `JobPosting` object with the given `id`.
```typescript -await client.ats.jobPostings.retrieve("id"); +await client.crm.forceResync.syncStatusResyncCreate(); ```
@@ -20925,23 +21558,7 @@ await client.ats.jobPostings.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.JobPostingsRetrieveRequest` - -
-
- -
-
- -**requestOptions:** `JobPostings.RequestOptions` +**requestOptions:** `ForceResync.RequestOptions`
@@ -20952,9 +21569,9 @@ await client.ats.jobPostings.retrieve("id");
-## Ats Jobs +## Crm Tasks -
client.ats.jobs.list({ ...params }) -> Merge.PaginatedJobList +
client.crm.tasks.list({ ...params }) -> Merge.PaginatedTaskList
@@ -20966,7 +21583,7 @@ await client.ats.jobPostings.retrieve("id");
-Returns a list of `Job` objects. +Returns a list of `Task` objects.
@@ -20982,7 +21599,7 @@ Returns a list of `Job` objects.
```typescript -await client.ats.jobs.list(); +await client.crm.tasks.list(); ```
@@ -20998,7 +21615,7 @@ await client.ats.jobs.list();
-**request:** `Merge.ats.JobsListRequest` +**request:** `Merge.crm.TasksListRequest`
@@ -21006,7 +21623,7 @@ await client.ats.jobs.list();
-**requestOptions:** `Jobs.RequestOptions` +**requestOptions:** `Tasks.RequestOptions`
@@ -21017,7 +21634,7 @@ await client.ats.jobs.list();
-
client.ats.jobs.retrieve(id, { ...params }) -> Merge.Job +
client.crm.tasks.create({ ...params }) -> Merge.TaskResponse
@@ -21029,7 +21646,7 @@ await client.ats.jobs.list();
-Returns a `Job` object with the given `id`. +Creates a `Task` object with the given values.
@@ -21045,7 +21662,9 @@ Returns a `Job` object with the given `id`.
```typescript -await client.ats.jobs.retrieve("id"); +await client.crm.tasks.create({ + model: {}, +}); ```
@@ -21061,15 +21680,7 @@ await client.ats.jobs.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.JobsRetrieveRequest` +**request:** `Merge.crm.TaskEndpointRequest`
@@ -21077,7 +21688,7 @@ await client.ats.jobs.retrieve("id");
-**requestOptions:** `Jobs.RequestOptions` +**requestOptions:** `Tasks.RequestOptions`
@@ -21088,7 +21699,7 @@ await client.ats.jobs.retrieve("id");
-
client.ats.jobs.screeningQuestionsList(jobId, { ...params }) -> Merge.PaginatedScreeningQuestionList +
client.crm.tasks.retrieve(id, { ...params }) -> Merge.Task
@@ -21100,7 +21711,7 @@ await client.ats.jobs.retrieve("id");
-Returns a list of `ScreeningQuestion` objects. +Returns a `Task` object with the given `id`.
@@ -21116,7 +21727,7 @@ Returns a list of `ScreeningQuestion` objects.
```typescript -await client.ats.jobs.screeningQuestionsList("job_id"); +await client.crm.tasks.retrieve("id"); ```
@@ -21132,7 +21743,7 @@ await client.ats.jobs.screeningQuestionsList("job_id");
-**jobId:** `string` +**id:** `string`
@@ -21140,7 +21751,7 @@ await client.ats.jobs.screeningQuestionsList("job_id");
-**request:** `Merge.ats.JobsScreeningQuestionsListRequest` +**request:** `Merge.crm.TasksRetrieveRequest`
@@ -21148,7 +21759,7 @@ await client.ats.jobs.screeningQuestionsList("job_id");
-**requestOptions:** `Jobs.RequestOptions` +**requestOptions:** `Tasks.RequestOptions`
@@ -21159,9 +21770,7 @@ await client.ats.jobs.screeningQuestionsList("job_id");
-## Ats LinkToken - -
client.ats.linkToken.create({ ...params }) -> Merge.LinkToken +
client.crm.tasks.partialUpdate(id, { ...params }) -> Merge.TaskResponse
@@ -21173,7 +21782,7 @@ await client.ats.jobs.screeningQuestionsList("job_id");
-Creates a link token to be used when linking a new end user. +Updates a `Task` object with the given `id`.
@@ -21189,11 +21798,8 @@ Creates a link token to be used when linking a new end user.
```typescript -await client.ats.linkToken.create({ - endUserEmailAddress: "example@gmail.com", - endUserOrganizationName: "Test Organization", - endUserOriginId: "12345", - categories: ["hris", "ats"], +await client.crm.tasks.partialUpdate("id", { + model: {}, }); ``` @@ -21210,7 +21816,7 @@ await client.ats.linkToken.create({
-**request:** `Merge.ats.EndUserDetailsRequest` +**id:** `string`
@@ -21218,7 +21824,15 @@ await client.ats.linkToken.create({
-**requestOptions:** `LinkToken.RequestOptions` +**request:** `Merge.crm.PatchedTaskEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `Tasks.RequestOptions`
@@ -21229,9 +21843,7 @@ await client.ats.linkToken.create({
-## Ats LinkedAccounts - -
client.ats.linkedAccounts.list({ ...params }) -> Merge.PaginatedAccountDetailsAndActionsList +
client.crm.tasks.metaPatchRetrieve(id) -> Merge.MetaResponse
@@ -21243,7 +21855,7 @@ await client.ats.linkToken.create({
-List linked accounts for your organization. +Returns metadata for `Task` PATCHs.
@@ -21259,7 +21871,7 @@ List linked accounts for your organization.
```typescript -await client.ats.linkedAccounts.list(); +await client.crm.tasks.metaPatchRetrieve("id"); ```
@@ -21275,7 +21887,7 @@ await client.ats.linkedAccounts.list();
-**request:** `Merge.ats.LinkedAccountsListRequest` +**id:** `string`
@@ -21283,7 +21895,7 @@ await client.ats.linkedAccounts.list();
-**requestOptions:** `LinkedAccounts.RequestOptions` +**requestOptions:** `Tasks.RequestOptions`
@@ -21294,9 +21906,7 @@ await client.ats.linkedAccounts.list();
-## Ats Offers - -
client.ats.offers.list({ ...params }) -> Merge.PaginatedOfferList +
client.crm.tasks.metaPostRetrieve() -> Merge.MetaResponse
@@ -21308,7 +21918,7 @@ await client.ats.linkedAccounts.list();
-Returns a list of `Offer` objects. +Returns metadata for `Task` POSTs.
@@ -21324,7 +21934,7 @@ Returns a list of `Offer` objects.
```typescript -await client.ats.offers.list(); +await client.crm.tasks.metaPostRetrieve(); ```
@@ -21340,15 +21950,7 @@ await client.ats.offers.list();
-**request:** `Merge.ats.OffersListRequest` - -
-
- -
-
- -**requestOptions:** `Offers.RequestOptions` +**requestOptions:** `Tasks.RequestOptions`
@@ -21359,7 +21961,7 @@ await client.ats.offers.list();
-
client.ats.offers.retrieve(id, { ...params }) -> Merge.Offer +
client.crm.tasks.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -21371,7 +21973,7 @@ await client.ats.offers.list();
-Returns an `Offer` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -21387,7 +21989,7 @@ Returns an `Offer` object with the given `id`.
```typescript -await client.ats.offers.retrieve("id"); +await client.crm.tasks.remoteFieldClassesList(); ```
@@ -21403,15 +22005,7 @@ await client.ats.offers.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.OffersRetrieveRequest` +**request:** `Merge.crm.TasksRemoteFieldClassesListRequest`
@@ -21419,7 +22013,7 @@ await client.ats.offers.retrieve("id");
-**requestOptions:** `Offers.RequestOptions` +**requestOptions:** `Tasks.RequestOptions`
@@ -21430,9 +22024,9 @@ await client.ats.offers.retrieve("id");
-## Ats Offices +## Crm Users -
client.ats.offices.list({ ...params }) -> Merge.PaginatedOfficeList +
client.crm.users.list({ ...params }) -> Merge.PaginatedUserList
@@ -21444,7 +22038,7 @@ await client.ats.offers.retrieve("id");
-Returns a list of `Office` objects. +Returns a list of `User` objects.
@@ -21460,7 +22054,7 @@ Returns a list of `Office` objects.
```typescript -await client.ats.offices.list(); +await client.crm.users.list(); ```
@@ -21476,7 +22070,7 @@ await client.ats.offices.list();
-**request:** `Merge.ats.OfficesListRequest` +**request:** `Merge.crm.UsersListRequest`
@@ -21484,7 +22078,7 @@ await client.ats.offices.list();
-**requestOptions:** `Offices.RequestOptions` +**requestOptions:** `Users.RequestOptions`
@@ -21495,7 +22089,7 @@ await client.ats.offices.list();
-
client.ats.offices.retrieve(id, { ...params }) -> Merge.Office +
client.crm.users.retrieve(id, { ...params }) -> Merge.User
@@ -21507,7 +22101,7 @@ await client.ats.offices.list();
-Returns an `Office` object with the given `id`. +Returns a `User` object with the given `id`.
@@ -21523,7 +22117,7 @@ Returns an `Office` object with the given `id`.
```typescript -await client.ats.offices.retrieve("id"); +await client.crm.users.retrieve("id"); ```
@@ -21547,7 +22141,7 @@ await client.ats.offices.retrieve("id");
-**request:** `Merge.ats.OfficesRetrieveRequest` +**request:** `Merge.crm.UsersRetrieveRequest`
@@ -21555,7 +22149,7 @@ await client.ats.offices.retrieve("id");
-**requestOptions:** `Offices.RequestOptions` +**requestOptions:** `Users.RequestOptions`
@@ -21566,9 +22160,7 @@ await client.ats.offices.retrieve("id");
-## Ats Passthrough - -
client.ats.passthrough.create({ ...params }) -> Merge.RemoteResponse +
client.crm.users.ignoreCreate(modelId, { ...params }) -> void
@@ -21580,7 +22172,7 @@ await client.ats.offices.retrieve("id");
-Pull data from an endpoint not currently supported by Merge. +Ignores a specific row based on the `model_id` in the url. These records will have their properties set to null, and will not be updated in future syncs. The "reason" and "message" fields in the request body will be stored for audit purposes.
@@ -21596,9 +22188,8 @@ Pull data from an endpoint not currently supported by Merge.
```typescript -await client.ats.passthrough.create({ - method: "GET", - path: "/scooters", +await client.crm.users.ignoreCreate("model_id", { + reason: "GENERAL_CUSTOMER_REQUEST", }); ``` @@ -21615,7 +22206,15 @@ await client.ats.passthrough.create({
-**request:** `Merge.DataPassthroughRequest` +**modelId:** `string` + +
+
+ +
+
+ +**request:** `Merge.IgnoreCommonModelRequest`
@@ -21623,7 +22222,7 @@ await client.ats.passthrough.create({
-**requestOptions:** `Passthrough.RequestOptions` +**requestOptions:** `Users.RequestOptions`
@@ -21634,9 +22233,7 @@ await client.ats.passthrough.create({
-## Ats RegenerateKey - -
client.ats.regenerateKey.create({ ...params }) -> Merge.RemoteKey +
client.crm.users.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -21648,7 +22245,7 @@ await client.ats.passthrough.create({
-Exchange remote keys. +Returns a list of `RemoteFieldClass` objects.
@@ -21664,9 +22261,7 @@ Exchange remote keys.
```typescript -await client.ats.regenerateKey.create({ - name: "Remote Deployment Key 1", -}); +await client.crm.users.remoteFieldClassesList(); ```
@@ -21682,7 +22277,7 @@ await client.ats.regenerateKey.create({
-**request:** `Merge.ats.RemoteKeyForRegenerationRequest` +**request:** `Merge.crm.UsersRemoteFieldClassesListRequest`
@@ -21690,7 +22285,7 @@ await client.ats.regenerateKey.create({
-**requestOptions:** `RegenerateKey.RequestOptions` +**requestOptions:** `Users.RequestOptions`
@@ -21701,9 +22296,9 @@ await client.ats.regenerateKey.create({
-## Ats RejectReasons +## Crm WebhookReceivers -
client.ats.rejectReasons.list({ ...params }) -> Merge.PaginatedRejectReasonList +
client.crm.webhookReceivers.list() -> Merge.WebhookReceiver[]
@@ -21715,7 +22310,7 @@ await client.ats.regenerateKey.create({
-Returns a list of `RejectReason` objects. +Returns a list of `WebhookReceiver` objects.
@@ -21731,7 +22326,7 @@ Returns a list of `RejectReason` objects.
```typescript -await client.ats.rejectReasons.list(); +await client.crm.webhookReceivers.list(); ```
@@ -21747,15 +22342,7 @@ await client.ats.rejectReasons.list();
-**request:** `Merge.ats.RejectReasonsListRequest` - -
-
- -
-
- -**requestOptions:** `RejectReasons.RequestOptions` +**requestOptions:** `WebhookReceivers.RequestOptions`
@@ -21766,7 +22353,7 @@ await client.ats.rejectReasons.list();
-
client.ats.rejectReasons.retrieve(id, { ...params }) -> Merge.RejectReason +
client.crm.webhookReceivers.create({ ...params }) -> Merge.WebhookReceiver
@@ -21778,7 +22365,7 @@ await client.ats.rejectReasons.list();
-Returns a `RejectReason` object with the given `id`. +Creates a `WebhookReceiver` object with the given values.
@@ -21794,7 +22381,10 @@ Returns a `RejectReason` object with the given `id`.
```typescript -await client.ats.rejectReasons.retrieve("id"); +await client.crm.webhookReceivers.create({ + event: "event", + isActive: true, +}); ```
@@ -21810,15 +22400,7 @@ await client.ats.rejectReasons.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.RejectReasonsRetrieveRequest` +**request:** `Merge.crm.WebhookReceiverRequest`
@@ -21826,7 +22408,7 @@ await client.ats.rejectReasons.retrieve("id");
-**requestOptions:** `RejectReasons.RequestOptions` +**requestOptions:** `WebhookReceivers.RequestOptions`
@@ -21837,9 +22419,9 @@ await client.ats.rejectReasons.retrieve("id");
-## Ats Scorecards +## Accounting AccountDetails -
client.ats.scorecards.list({ ...params }) -> Merge.PaginatedScorecardList +
client.accounting.accountDetails.retrieve() -> Merge.AccountDetails
@@ -21851,7 +22433,7 @@ await client.ats.rejectReasons.retrieve("id");
-Returns a list of `Scorecard` objects. +Get details for a linked account.
@@ -21867,7 +22449,7 @@ Returns a list of `Scorecard` objects.
```typescript -await client.ats.scorecards.list(); +await client.accounting.accountDetails.retrieve(); ```
@@ -21883,15 +22465,7 @@ await client.ats.scorecards.list();
-**request:** `Merge.ats.ScorecardsListRequest` - -
-
- -
-
- -**requestOptions:** `Scorecards.RequestOptions` +**requestOptions:** `AccountDetails.RequestOptions`
@@ -21902,7 +22476,9 @@ await client.ats.scorecards.list();
-
client.ats.scorecards.retrieve(id, { ...params }) -> Merge.Scorecard +## Accounting AccountToken + +
client.accounting.accountToken.retrieve(publicToken) -> Merge.AccountToken
@@ -21914,7 +22490,7 @@ await client.ats.scorecards.list();
-Returns a `Scorecard` object with the given `id`. +Returns the account token for the end user with the provided public token.
@@ -21930,7 +22506,7 @@ Returns a `Scorecard` object with the given `id`.
```typescript -await client.ats.scorecards.retrieve("id"); +await client.accounting.accountToken.retrieve("public_token"); ```
@@ -21946,15 +22522,7 @@ await client.ats.scorecards.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.ats.ScorecardsRetrieveRequest` +**publicToken:** `string`
@@ -21962,7 +22530,7 @@ await client.ats.scorecards.retrieve("id");
-**requestOptions:** `Scorecards.RequestOptions` +**requestOptions:** `AccountToken.RequestOptions`
@@ -21973,9 +22541,9 @@ await client.ats.scorecards.retrieve("id");
-## Ats SyncStatus +## Accounting AccountingPeriods -
client.ats.syncStatus.list({ ...params }) -> Merge.PaginatedSyncStatusList +
client.accounting.accountingPeriods.list({ ...params }) -> Merge.PaginatedAccountingPeriodList
@@ -21987,7 +22555,7 @@ await client.ats.scorecards.retrieve("id");
-Get sync status for the current sync and the most recently finished sync. `last_sync_start` represents the most recent time any sync began. `last_sync_finished` represents the most recent time any sync completed. These timestamps may correspond to different sync instances which may result in a sync start time being later than a separate sync completed time. To ensure you are retrieving the latest available data reference the `last_sync_finished` timestamp where `last_sync_result` is `DONE`. Possible values for `status` and `last_sync_result` are `DISABLED`, `DONE`, `FAILED`, `PARTIALLY_SYNCED`, `PAUSED`, `SYNCING`. Learn more about sync status in our [Help Center](https://help.merge.dev/en/articles/8184193-merge-sync-statuses). +Returns a list of `AccountingPeriod` objects.
@@ -22003,7 +22571,7 @@ Get sync status for the current sync and the most recently finished sync. `last_
```typescript -await client.ats.syncStatus.list(); +await client.accounting.accountingPeriods.list(); ```
@@ -22019,7 +22587,7 @@ await client.ats.syncStatus.list();
-**request:** `Merge.ats.SyncStatusListRequest` +**request:** `Merge.accounting.AccountingPeriodsListRequest`
@@ -22027,7 +22595,7 @@ await client.ats.syncStatus.list();
-**requestOptions:** `SyncStatus.RequestOptions` +**requestOptions:** `AccountingPeriods.RequestOptions`
@@ -22038,9 +22606,7 @@ await client.ats.syncStatus.list();
-## Ats ForceResync - -
client.ats.forceResync.syncStatusResyncCreate() -> Merge.SyncStatus[] +
client.accounting.accountingPeriods.retrieve(id, { ...params }) -> Merge.AccountingPeriod
@@ -22052,7 +22618,7 @@ await client.ats.syncStatus.list();
-Force re-sync of all models. This endpoint is available for monthly, quarterly, and highest sync frequency customers on the Professional or Enterprise plans. Doing so will consume a sync credit for the relevant linked account. Force re-syncs can also be triggered manually in the Merge Dashboard and is available for all customers. +Returns an `AccountingPeriod` object with the given `id`.
@@ -22068,7 +22634,7 @@ Force re-sync of all models. This endpoint is available for monthly, quarterly,
```typescript -await client.ats.forceResync.syncStatusResyncCreate(); +await client.accounting.accountingPeriods.retrieve("id"); ```
@@ -22084,7 +22650,23 @@ await client.ats.forceResync.syncStatusResyncCreate();
-**requestOptions:** `ForceResync.RequestOptions` +**id:** `string` + +
+
+ +
+
+ +**request:** `Merge.accounting.AccountingPeriodsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `AccountingPeriods.RequestOptions`
@@ -22095,9 +22677,9 @@ await client.ats.forceResync.syncStatusResyncCreate();
-## Ats Tags +## Accounting Accounts -
client.ats.tags.list({ ...params }) -> Merge.PaginatedTagList +
client.accounting.accounts.list({ ...params }) -> Merge.PaginatedAccountList
@@ -22109,7 +22691,7 @@ await client.ats.forceResync.syncStatusResyncCreate();
-Returns a list of `Tag` objects. +Returns a list of `Account` objects.
@@ -22125,7 +22707,7 @@ Returns a list of `Tag` objects.
```typescript -await client.ats.tags.list(); +await client.accounting.accounts.list(); ```
@@ -22141,7 +22723,7 @@ await client.ats.tags.list();
-**request:** `Merge.ats.TagsListRequest` +**request:** `Merge.accounting.AccountsListRequest`
@@ -22149,7 +22731,7 @@ await client.ats.tags.list();
-**requestOptions:** `Tags.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -22160,9 +22742,7 @@ await client.ats.tags.list();
-## Ats Users - -
client.ats.users.list({ ...params }) -> Merge.PaginatedRemoteUserList +
client.accounting.accounts.create({ ...params }) -> Merge.AccountResponse
@@ -22174,7 +22754,7 @@ await client.ats.tags.list();
-Returns a list of `RemoteUser` objects. +Creates an `Account` object with the given values.
@@ -22190,7 +22770,9 @@ Returns a list of `RemoteUser` objects.
```typescript -await client.ats.users.list(); +await client.accounting.accounts.create({ + model: {}, +}); ```
@@ -22206,7 +22788,7 @@ await client.ats.users.list();
-**request:** `Merge.ats.UsersListRequest` +**request:** `Merge.accounting.AccountEndpointRequest`
@@ -22214,7 +22796,7 @@ await client.ats.users.list();
-**requestOptions:** `Users.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -22225,7 +22807,7 @@ await client.ats.users.list();
-
client.ats.users.retrieve(id, { ...params }) -> Merge.RemoteUser +
client.accounting.accounts.retrieve(id, { ...params }) -> Merge.Account
@@ -22237,7 +22819,7 @@ await client.ats.users.list();
-Returns a `RemoteUser` object with the given `id`. +Returns an `Account` object with the given `id`.
@@ -22253,7 +22835,7 @@ Returns a `RemoteUser` object with the given `id`.
```typescript -await client.ats.users.retrieve("id"); +await client.accounting.accounts.retrieve("id"); ```
@@ -22277,7 +22859,7 @@ await client.ats.users.retrieve("id");
-**request:** `Merge.ats.UsersRetrieveRequest` +**request:** `Merge.accounting.AccountsRetrieveRequest`
@@ -22285,7 +22867,7 @@ await client.ats.users.retrieve("id");
-**requestOptions:** `Users.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -22296,9 +22878,7 @@ await client.ats.users.retrieve("id");
-## Ats WebhookReceivers - -
client.ats.webhookReceivers.list() -> Merge.WebhookReceiver[] +
client.accounting.accounts.metaPostRetrieve() -> Merge.MetaResponse
@@ -22310,7 +22890,7 @@ await client.ats.users.retrieve("id");
-Returns a list of `WebhookReceiver` objects. +Returns metadata for `Account` POSTs.
@@ -22326,7 +22906,7 @@ Returns a list of `WebhookReceiver` objects.
```typescript -await client.ats.webhookReceivers.list(); +await client.accounting.accounts.metaPostRetrieve(); ```
@@ -22342,7 +22922,7 @@ await client.ats.webhookReceivers.list();
-**requestOptions:** `WebhookReceivers.RequestOptions` +**requestOptions:** `Accounts.RequestOptions`
@@ -22353,7 +22933,9 @@ await client.ats.webhookReceivers.list();
-
client.ats.webhookReceivers.create({ ...params }) -> Merge.WebhookReceiver +## Accounting Addresses + +
client.accounting.addresses.retrieve(id, { ...params }) -> Merge.Address
@@ -22365,7 +22947,7 @@ await client.ats.webhookReceivers.list();
-Creates a `WebhookReceiver` object with the given values. +Returns an `Address` object with the given `id`.
@@ -22381,10 +22963,7 @@ Creates a `WebhookReceiver` object with the given values.
```typescript -await client.ats.webhookReceivers.create({ - event: "event", - isActive: true, -}); +await client.accounting.addresses.retrieve("id"); ```
@@ -22400,72 +22979,23 @@ await client.ats.webhookReceivers.create({
-**request:** `Merge.ats.WebhookReceiverRequest` - -
-
- -
-
- -**requestOptions:** `WebhookReceivers.RequestOptions` - -
-
- -
- - - -
- -## Accounting AccountDetails - -
client.accounting.accountDetails.retrieve() -> Merge.AccountDetails -
-
- -#### 📝 Description - -
-
- -
-
- -Get details for a linked account. +**id:** `string`
-
-
- -#### 🔌 Usage - -
-
-```typescript -await client.accounting.accountDetails.retrieve(); -``` +**request:** `Merge.accounting.AddressesRetrieveRequest`
-
-
- -#### ⚙️ Parameters - -
-
-**requestOptions:** `AccountDetails.RequestOptions` +**requestOptions:** `Addresses.RequestOptions`
@@ -22476,9 +23006,9 @@ await client.accounting.accountDetails.retrieve();
-## Accounting AccountToken +## Accounting AsyncPassthrough -
client.accounting.accountToken.retrieve(publicToken) -> Merge.AccountToken +
client.accounting.asyncPassthrough.create({ ...params }) -> Merge.AsyncPassthroughReciept
@@ -22490,7 +23020,7 @@ await client.accounting.accountDetails.retrieve();
-Returns the account token for the end user with the provided public token. +Asynchronously pull data from an endpoint not currently supported by Merge.
@@ -22506,7 +23036,10 @@ Returns the account token for the end user with the provided public token.
```typescript -await client.accounting.accountToken.retrieve("public_token"); +await client.accounting.asyncPassthrough.create({ + method: "GET", + path: "/scooters", +}); ```
@@ -22522,7 +23055,7 @@ await client.accounting.accountToken.retrieve("public_token");
-**publicToken:** `string` +**request:** `Merge.DataPassthroughRequest`
@@ -22530,7 +23063,7 @@ await client.accounting.accountToken.retrieve("public_token");
-**requestOptions:** `AccountToken.RequestOptions` +**requestOptions:** `AsyncPassthrough.RequestOptions`
@@ -22541,9 +23074,7 @@ await client.accounting.accountToken.retrieve("public_token");
-## Accounting AccountingPeriods - -
client.accounting.accountingPeriods.list({ ...params }) -> Merge.PaginatedAccountingPeriodList +
client.accounting.asyncPassthrough.retrieve(asyncPassthroughReceiptId) -> Merge.AsyncPassthroughRetrieveResponse
@@ -22555,7 +23086,7 @@ await client.accounting.accountToken.retrieve("public_token");
-Returns a list of `AccountingPeriod` objects. +Retrieves data from earlier async-passthrough POST request
@@ -22571,7 +23102,7 @@ Returns a list of `AccountingPeriod` objects.
```typescript -await client.accounting.accountingPeriods.list(); +await client.accounting.asyncPassthrough.retrieve("async_passthrough_receipt_id"); ```
@@ -22587,7 +23118,7 @@ await client.accounting.accountingPeriods.list();
-**request:** `Merge.accounting.AccountingPeriodsListRequest` +**asyncPassthroughReceiptId:** `string`
@@ -22595,7 +23126,7 @@ await client.accounting.accountingPeriods.list();
-**requestOptions:** `AccountingPeriods.RequestOptions` +**requestOptions:** `AsyncPassthrough.RequestOptions`
@@ -22606,7 +23137,9 @@ await client.accounting.accountingPeriods.list();
-
client.accounting.accountingPeriods.retrieve(id, { ...params }) -> Merge.AccountingPeriod +## Accounting AsyncTasks + +
client.accounting.asyncTasks.retrieve(id) -> Merge.AsyncPostTask
@@ -22618,7 +23151,7 @@ await client.accounting.accountingPeriods.list();
-Returns an `AccountingPeriod` object with the given `id`. +Returns an `AsyncPostTask` object with the given `id`.
@@ -22634,7 +23167,7 @@ Returns an `AccountingPeriod` object with the given `id`.
```typescript -await client.accounting.accountingPeriods.retrieve("id"); +await client.accounting.asyncTasks.retrieve("id"); ```
@@ -22658,15 +23191,7 @@ await client.accounting.accountingPeriods.retrieve("id");
-**request:** `Merge.accounting.AccountingPeriodsRetrieveRequest` - -
-
- -
-
- -**requestOptions:** `AccountingPeriods.RequestOptions` +**requestOptions:** `AsyncTasks.RequestOptions`
@@ -22677,9 +23202,9 @@ await client.accounting.accountingPeriods.retrieve("id");
-## Accounting Accounts +## Accounting Attachments -
client.accounting.accounts.list({ ...params }) -> Merge.PaginatedAccountList +
client.accounting.attachments.list({ ...params }) -> Merge.PaginatedAccountingAttachmentList
@@ -22691,7 +23216,7 @@ await client.accounting.accountingPeriods.retrieve("id");
-Returns a list of `Account` objects. +Returns a list of `AccountingAttachment` objects.
@@ -22707,7 +23232,7 @@ Returns a list of `Account` objects.
```typescript -await client.accounting.accounts.list(); +await client.accounting.attachments.list(); ```
@@ -22723,7 +23248,7 @@ await client.accounting.accounts.list();
-**request:** `Merge.accounting.AccountsListRequest` +**request:** `Merge.accounting.AttachmentsListRequest`
@@ -22731,7 +23256,7 @@ await client.accounting.accounts.list();
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -22742,7 +23267,7 @@ await client.accounting.accounts.list();
-
client.accounting.accounts.create({ ...params }) -> Merge.AccountResponse +
client.accounting.attachments.create({ ...params }) -> Merge.AccountingAttachmentResponse
@@ -22754,7 +23279,7 @@ await client.accounting.accounts.list();
-Creates an `Account` object with the given values. +Creates an `AccountingAttachment` object with the given values.
@@ -22770,7 +23295,7 @@ Creates an `Account` object with the given values.
```typescript -await client.accounting.accounts.create({ +await client.accounting.attachments.create({ model: {}, }); ``` @@ -22788,7 +23313,7 @@ await client.accounting.accounts.create({
-**request:** `Merge.accounting.AccountEndpointRequest` +**request:** `Merge.accounting.AccountingAttachmentEndpointRequest`
@@ -22796,7 +23321,7 @@ await client.accounting.accounts.create({
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -22807,7 +23332,7 @@ await client.accounting.accounts.create({
-
client.accounting.accounts.retrieve(id, { ...params }) -> Merge.Account +
client.accounting.attachments.retrieve(id, { ...params }) -> Merge.AccountingAttachment
@@ -22819,7 +23344,7 @@ await client.accounting.accounts.create({
-Returns an `Account` object with the given `id`. +Returns an `AccountingAttachment` object with the given `id`.
@@ -22835,7 +23360,7 @@ Returns an `Account` object with the given `id`.
```typescript -await client.accounting.accounts.retrieve("id"); +await client.accounting.attachments.retrieve("id"); ```
@@ -22859,7 +23384,7 @@ await client.accounting.accounts.retrieve("id");
-**request:** `Merge.accounting.AccountsRetrieveRequest` +**request:** `Merge.accounting.AttachmentsRetrieveRequest`
@@ -22867,7 +23392,7 @@ await client.accounting.accounts.retrieve("id");
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -22878,7 +23403,7 @@ await client.accounting.accounts.retrieve("id");
-
client.accounting.accounts.metaPostRetrieve() -> Merge.MetaResponse +
client.accounting.attachments.metaPostRetrieve() -> Merge.MetaResponse
@@ -22890,7 +23415,7 @@ await client.accounting.accounts.retrieve("id");
-Returns metadata for `Account` POSTs. +Returns metadata for `AccountingAttachment` POSTs.
@@ -22906,7 +23431,7 @@ Returns metadata for `Account` POSTs.
```typescript -await client.accounting.accounts.metaPostRetrieve(); +await client.accounting.attachments.metaPostRetrieve(); ```
@@ -22922,7 +23447,7 @@ await client.accounting.accounts.metaPostRetrieve();
-**requestOptions:** `Accounts.RequestOptions` +**requestOptions:** `Attachments.RequestOptions`
@@ -22933,9 +23458,9 @@ await client.accounting.accounts.metaPostRetrieve();
-## Accounting Addresses +## Accounting AuditTrail -
client.accounting.addresses.retrieve(id, { ...params }) -> Merge.Address +
client.accounting.auditTrail.list({ ...params }) -> Merge.PaginatedAuditLogEventList
@@ -22947,7 +23472,7 @@ await client.accounting.accounts.metaPostRetrieve();
-Returns an `Address` object with the given `id`. +Gets a list of audit trail events.
@@ -22963,7 +23488,7 @@ Returns an `Address` object with the given `id`.
```typescript -await client.accounting.addresses.retrieve("id"); +await client.accounting.auditTrail.list(); ```
@@ -22979,15 +23504,7 @@ await client.accounting.addresses.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.accounting.AddressesRetrieveRequest` +**request:** `Merge.accounting.AuditTrailListRequest`
@@ -22995,7 +23512,7 @@ await client.accounting.addresses.retrieve("id");
-**requestOptions:** `Addresses.RequestOptions` +**requestOptions:** `AuditTrail.RequestOptions`
@@ -23006,9 +23523,9 @@ await client.accounting.addresses.retrieve("id");
-## Accounting AsyncPassthrough +## Accounting AvailableActions -
client.accounting.asyncPassthrough.create({ ...params }) -> Merge.AsyncPassthroughReciept +
client.accounting.availableActions.retrieve() -> Merge.AvailableActions
@@ -23020,7 +23537,7 @@ await client.accounting.addresses.retrieve("id");
-Asynchronously pull data from an endpoint not currently supported by Merge. +Returns a list of models and actions available for an account.
@@ -23036,10 +23553,7 @@ Asynchronously pull data from an endpoint not currently supported by Merge.
```typescript -await client.accounting.asyncPassthrough.create({ - method: "GET", - path: "/scooters", -}); +await client.accounting.availableActions.retrieve(); ```
@@ -23055,15 +23569,7 @@ await client.accounting.asyncPassthrough.create({
-**request:** `Merge.DataPassthroughRequest` - -
-
- -
-
- -**requestOptions:** `AsyncPassthrough.RequestOptions` +**requestOptions:** `AvailableActions.RequestOptions`
@@ -23074,7 +23580,9 @@ await client.accounting.asyncPassthrough.create({
-
client.accounting.asyncPassthrough.retrieve(asyncPassthroughReceiptId) -> Merge.AsyncPassthroughRetrieveResponse +## Accounting BalanceSheets + +
client.accounting.balanceSheets.list({ ...params }) -> Merge.PaginatedBalanceSheetList
@@ -23086,7 +23594,7 @@ await client.accounting.asyncPassthrough.create({
-Retrieves data from earlier async-passthrough POST request +Returns a list of `BalanceSheet` objects.
@@ -23102,7 +23610,7 @@ Retrieves data from earlier async-passthrough POST request
```typescript -await client.accounting.asyncPassthrough.retrieve("async_passthrough_receipt_id"); +await client.accounting.balanceSheets.list(); ```
@@ -23118,7 +23626,7 @@ await client.accounting.asyncPassthrough.retrieve("async_passthrough_receipt_id"
-**asyncPassthroughReceiptId:** `string` +**request:** `Merge.accounting.BalanceSheetsListRequest`
@@ -23126,7 +23634,7 @@ await client.accounting.asyncPassthrough.retrieve("async_passthrough_receipt_id"
-**requestOptions:** `AsyncPassthrough.RequestOptions` +**requestOptions:** `BalanceSheets.RequestOptions`
@@ -23137,9 +23645,7 @@ await client.accounting.asyncPassthrough.retrieve("async_passthrough_receipt_id"
-## Accounting AsyncTasks - -
client.accounting.asyncTasks.retrieve(id) -> Merge.AsyncPostTask +
client.accounting.balanceSheets.retrieve(id, { ...params }) -> Merge.BalanceSheet
@@ -23151,7 +23657,7 @@ await client.accounting.asyncPassthrough.retrieve("async_passthrough_receipt_id"
-Returns an `AsyncPostTask` object with the given `id`. +Returns a `BalanceSheet` object with the given `id`.
@@ -23167,7 +23673,7 @@ Returns an `AsyncPostTask` object with the given `id`.
```typescript -await client.accounting.asyncTasks.retrieve("id"); +await client.accounting.balanceSheets.retrieve("id"); ```
@@ -23191,7 +23697,15 @@ await client.accounting.asyncTasks.retrieve("id");
-**requestOptions:** `AsyncTasks.RequestOptions` +**request:** `Merge.accounting.BalanceSheetsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `BalanceSheets.RequestOptions`
@@ -23202,9 +23716,9 @@ await client.accounting.asyncTasks.retrieve("id");
-## Accounting Attachments +## Accounting BankFeedAccounts -
client.accounting.attachments.list({ ...params }) -> Merge.PaginatedAccountingAttachmentList +
client.accounting.bankFeedAccounts.list({ ...params }) -> Merge.PaginatedBankFeedAccountList
@@ -23216,7 +23730,7 @@ await client.accounting.asyncTasks.retrieve("id");
-Returns a list of `AccountingAttachment` objects. +Returns a list of `BankFeedAccount` objects.
@@ -23232,7 +23746,7 @@ Returns a list of `AccountingAttachment` objects.
```typescript -await client.accounting.attachments.list(); +await client.accounting.bankFeedAccounts.list(); ```
@@ -23248,7 +23762,7 @@ await client.accounting.attachments.list();
-**request:** `Merge.accounting.AttachmentsListRequest` +**request:** `Merge.accounting.BankFeedAccountsListRequest`
@@ -23256,7 +23770,7 @@ await client.accounting.attachments.list();
-**requestOptions:** `Attachments.RequestOptions` +**requestOptions:** `BankFeedAccounts.RequestOptions`
@@ -23267,7 +23781,7 @@ await client.accounting.attachments.list();
-
client.accounting.attachments.create({ ...params }) -> Merge.AccountingAttachmentResponse +
client.accounting.bankFeedAccounts.create({ ...params }) -> Merge.BankFeedAccountResponse
@@ -23279,7 +23793,7 @@ await client.accounting.attachments.list();
-Creates an `AccountingAttachment` object with the given values. +Creates a `BankFeedAccount` object with the given values.
@@ -23295,7 +23809,7 @@ Creates an `AccountingAttachment` object with the given values.
```typescript -await client.accounting.attachments.create({ +await client.accounting.bankFeedAccounts.create({ model: {}, }); ``` @@ -23313,7 +23827,7 @@ await client.accounting.attachments.create({
-**request:** `Merge.accounting.AccountingAttachmentEndpointRequest` +**request:** `Merge.accounting.BankFeedAccountEndpointRequest`
@@ -23321,7 +23835,7 @@ await client.accounting.attachments.create({
-**requestOptions:** `Attachments.RequestOptions` +**requestOptions:** `BankFeedAccounts.RequestOptions`
@@ -23332,7 +23846,7 @@ await client.accounting.attachments.create({
-
client.accounting.attachments.retrieve(id, { ...params }) -> Merge.AccountingAttachment +
client.accounting.bankFeedAccounts.retrieve(id, { ...params }) -> Merge.BankFeedAccount
@@ -23344,7 +23858,7 @@ await client.accounting.attachments.create({
-Returns an `AccountingAttachment` object with the given `id`. +Returns a `BankFeedAccount` object with the given `id`.
@@ -23360,7 +23874,7 @@ Returns an `AccountingAttachment` object with the given `id`.
```typescript -await client.accounting.attachments.retrieve("id"); +await client.accounting.bankFeedAccounts.retrieve("id"); ```
@@ -23384,7 +23898,7 @@ await client.accounting.attachments.retrieve("id");
-**request:** `Merge.accounting.AttachmentsRetrieveRequest` +**request:** `Merge.accounting.BankFeedAccountsRetrieveRequest`
@@ -23392,7 +23906,7 @@ await client.accounting.attachments.retrieve("id");
-**requestOptions:** `Attachments.RequestOptions` +**requestOptions:** `BankFeedAccounts.RequestOptions`
@@ -23403,7 +23917,7 @@ await client.accounting.attachments.retrieve("id");
-
client.accounting.attachments.metaPostRetrieve() -> Merge.MetaResponse +
client.accounting.bankFeedAccounts.metaPostRetrieve() -> Merge.MetaResponse
@@ -23415,7 +23929,7 @@ await client.accounting.attachments.retrieve("id");
-Returns metadata for `AccountingAttachment` POSTs. +Returns metadata for `BankFeedAccount` POSTs.
@@ -23431,7 +23945,7 @@ Returns metadata for `AccountingAttachment` POSTs.
```typescript -await client.accounting.attachments.metaPostRetrieve(); +await client.accounting.bankFeedAccounts.metaPostRetrieve(); ```
@@ -23447,7 +23961,7 @@ await client.accounting.attachments.metaPostRetrieve();
-**requestOptions:** `Attachments.RequestOptions` +**requestOptions:** `BankFeedAccounts.RequestOptions`
@@ -23458,9 +23972,9 @@ await client.accounting.attachments.metaPostRetrieve();
-## Accounting AuditTrail +## Accounting BankFeedTransactions -
client.accounting.auditTrail.list({ ...params }) -> Merge.PaginatedAuditLogEventList +
client.accounting.bankFeedTransactions.list({ ...params }) -> Merge.PaginatedBankFeedTransactionList
@@ -23472,7 +23986,7 @@ await client.accounting.attachments.metaPostRetrieve();
-Gets a list of audit trail events. +Returns a list of `BankFeedTransaction` objects.
@@ -23488,7 +24002,7 @@ Gets a list of audit trail events.
```typescript -await client.accounting.auditTrail.list(); +await client.accounting.bankFeedTransactions.list(); ```
@@ -23504,72 +24018,15 @@ await client.accounting.auditTrail.list();
-**request:** `Merge.accounting.AuditTrailListRequest` - -
-
- -
-
- -**requestOptions:** `AuditTrail.RequestOptions` - -
-
- -
- - - -
- -## Accounting AvailableActions - -
client.accounting.availableActions.retrieve() -> Merge.AvailableActions -
-
- -#### 📝 Description - -
-
- -
-
- -Returns a list of models and actions available for an account. - -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```typescript -await client.accounting.availableActions.retrieve(); -``` - -
-
-
-
- -#### ⚙️ Parameters - -
-
+**request:** `Merge.accounting.BankFeedTransactionsListRequest` + +
+
-**requestOptions:** `AvailableActions.RequestOptions` +**requestOptions:** `BankFeedTransactions.RequestOptions`
@@ -23580,9 +24037,7 @@ await client.accounting.availableActions.retrieve();
-## Accounting BalanceSheets - -
client.accounting.balanceSheets.list({ ...params }) -> Merge.PaginatedBalanceSheetList +
client.accounting.bankFeedTransactions.create({ ...params }) -> Merge.BankFeedTransactionResponse
@@ -23594,7 +24049,7 @@ await client.accounting.availableActions.retrieve();
-Returns a list of `BalanceSheet` objects. +Creates a `BankFeedTransaction` object with the given values.
@@ -23610,7 +24065,9 @@ Returns a list of `BalanceSheet` objects.
```typescript -await client.accounting.balanceSheets.list(); +await client.accounting.bankFeedTransactions.create({ + model: {}, +}); ```
@@ -23626,7 +24083,7 @@ await client.accounting.balanceSheets.list();
-**request:** `Merge.accounting.BalanceSheetsListRequest` +**request:** `Merge.accounting.BankFeedTransactionEndpointRequest`
@@ -23634,7 +24091,7 @@ await client.accounting.balanceSheets.list();
-**requestOptions:** `BalanceSheets.RequestOptions` +**requestOptions:** `BankFeedTransactions.RequestOptions`
@@ -23645,7 +24102,7 @@ await client.accounting.balanceSheets.list();
-
client.accounting.balanceSheets.retrieve(id, { ...params }) -> Merge.BalanceSheet +
client.accounting.bankFeedTransactions.retrieve(id, { ...params }) -> Merge.BankFeedTransaction
@@ -23657,7 +24114,7 @@ await client.accounting.balanceSheets.list();
-Returns a `BalanceSheet` object with the given `id`. +Returns a `BankFeedTransaction` object with the given `id`.
@@ -23673,7 +24130,7 @@ Returns a `BalanceSheet` object with the given `id`.
```typescript -await client.accounting.balanceSheets.retrieve("id"); +await client.accounting.bankFeedTransactions.retrieve("id"); ```
@@ -23697,7 +24154,7 @@ await client.accounting.balanceSheets.retrieve("id");
-**request:** `Merge.accounting.BalanceSheetsRetrieveRequest` +**request:** `Merge.accounting.BankFeedTransactionsRetrieveRequest`
@@ -23705,7 +24162,7 @@ await client.accounting.balanceSheets.retrieve("id");
-**requestOptions:** `BalanceSheets.RequestOptions` +**requestOptions:** `BankFeedTransactions.RequestOptions`
@@ -23716,9 +24173,7 @@ await client.accounting.balanceSheets.retrieve("id");
-## Accounting BankFeedAccounts - -
client.accounting.bankFeedAccounts.list({ ...params }) -> Merge.PaginatedBankFeedAccountList +
client.accounting.bankFeedTransactions.metaPostRetrieve() -> Merge.MetaResponse
@@ -23730,7 +24185,7 @@ await client.accounting.balanceSheets.retrieve("id");
-Returns a list of `BankFeedAccount` objects. +Returns metadata for `BankFeedTransaction` POSTs.
@@ -23746,7 +24201,7 @@ Returns a list of `BankFeedAccount` objects.
```typescript -await client.accounting.bankFeedAccounts.list(); +await client.accounting.bankFeedTransactions.metaPostRetrieve(); ```
@@ -23762,15 +24217,7 @@ await client.accounting.bankFeedAccounts.list();
-**request:** `Merge.accounting.BankFeedAccountsListRequest` - -
-
- -
-
- -**requestOptions:** `BankFeedAccounts.RequestOptions` +**requestOptions:** `BankFeedTransactions.RequestOptions`
@@ -23781,7 +24228,9 @@ await client.accounting.bankFeedAccounts.list();
-
client.accounting.bankFeedAccounts.create({ ...params }) -> Merge.BankFeedAccountResponse +## Accounting CashFlowStatements + +
client.accounting.cashFlowStatements.list({ ...params }) -> Merge.PaginatedCashFlowStatementList
@@ -23793,7 +24242,7 @@ await client.accounting.bankFeedAccounts.list();
-Creates a `BankFeedAccount` object with the given values. +Returns a list of `CashFlowStatement` objects.
@@ -23809,9 +24258,7 @@ Creates a `BankFeedAccount` object with the given values.
```typescript -await client.accounting.bankFeedAccounts.create({ - model: {}, -}); +await client.accounting.cashFlowStatements.list(); ```
@@ -23827,7 +24274,7 @@ await client.accounting.bankFeedAccounts.create({
-**request:** `Merge.accounting.BankFeedAccountEndpointRequest` +**request:** `Merge.accounting.CashFlowStatementsListRequest`
@@ -23835,7 +24282,7 @@ await client.accounting.bankFeedAccounts.create({
-**requestOptions:** `BankFeedAccounts.RequestOptions` +**requestOptions:** `CashFlowStatements.RequestOptions`
@@ -23846,7 +24293,7 @@ await client.accounting.bankFeedAccounts.create({
-
client.accounting.bankFeedAccounts.retrieve(id, { ...params }) -> Merge.BankFeedAccount +
client.accounting.cashFlowStatements.retrieve(id, { ...params }) -> Merge.CashFlowStatement
@@ -23858,7 +24305,7 @@ await client.accounting.bankFeedAccounts.create({
-Returns a `BankFeedAccount` object with the given `id`. +Returns a `CashFlowStatement` object with the given `id`.
@@ -23874,7 +24321,7 @@ Returns a `BankFeedAccount` object with the given `id`.
```typescript -await client.accounting.bankFeedAccounts.retrieve("id"); +await client.accounting.cashFlowStatements.retrieve("id"); ```
@@ -23898,7 +24345,7 @@ await client.accounting.bankFeedAccounts.retrieve("id");
-**request:** `Merge.accounting.BankFeedAccountsRetrieveRequest` +**request:** `Merge.accounting.CashFlowStatementsRetrieveRequest`
@@ -23906,7 +24353,7 @@ await client.accounting.bankFeedAccounts.retrieve("id");
-**requestOptions:** `BankFeedAccounts.RequestOptions` +**requestOptions:** `CashFlowStatements.RequestOptions`
@@ -23917,7 +24364,9 @@ await client.accounting.bankFeedAccounts.retrieve("id");
-
client.accounting.bankFeedAccounts.metaPostRetrieve() -> Merge.MetaResponse +## Accounting CompanyInfo + +
client.accounting.companyInfo.list({ ...params }) -> Merge.PaginatedCompanyInfoList
@@ -23929,7 +24378,7 @@ await client.accounting.bankFeedAccounts.retrieve("id");
-Returns metadata for `BankFeedAccount` POSTs. +Returns a list of `CompanyInfo` objects.
@@ -23945,7 +24394,7 @@ Returns metadata for `BankFeedAccount` POSTs.
```typescript -await client.accounting.bankFeedAccounts.metaPostRetrieve(); +await client.accounting.companyInfo.list(); ```
@@ -23961,7 +24410,15 @@ await client.accounting.bankFeedAccounts.metaPostRetrieve();
-**requestOptions:** `BankFeedAccounts.RequestOptions` +**request:** `Merge.accounting.CompanyInfoListRequest` + +
+
+ +
+
+ +**requestOptions:** `CompanyInfo.RequestOptions`
@@ -23972,9 +24429,7 @@ await client.accounting.bankFeedAccounts.metaPostRetrieve();
-## Accounting BankFeedTransactions - -
client.accounting.bankFeedTransactions.list({ ...params }) -> Merge.PaginatedBankFeedTransactionList +
client.accounting.companyInfo.retrieve(id, { ...params }) -> Merge.CompanyInfo
@@ -23986,7 +24441,7 @@ await client.accounting.bankFeedAccounts.metaPostRetrieve();
-Returns a list of `BankFeedTransaction` objects. +Returns a `CompanyInfo` object with the given `id`.
@@ -24002,7 +24457,7 @@ Returns a list of `BankFeedTransaction` objects.
```typescript -await client.accounting.bankFeedTransactions.list(); +await client.accounting.companyInfo.retrieve("id"); ```
@@ -24018,7 +24473,7 @@ await client.accounting.bankFeedTransactions.list();
-**request:** `Merge.accounting.BankFeedTransactionsListRequest` +**id:** `string`
@@ -24026,7 +24481,15 @@ await client.accounting.bankFeedTransactions.list();
-**requestOptions:** `BankFeedTransactions.RequestOptions` +**request:** `Merge.accounting.CompanyInfoRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `CompanyInfo.RequestOptions`
@@ -24037,7 +24500,9 @@ await client.accounting.bankFeedTransactions.list();
-
client.accounting.bankFeedTransactions.create({ ...params }) -> Merge.BankFeedTransactionResponse +## Accounting Contacts + +
client.accounting.contacts.list({ ...params }) -> Merge.PaginatedContactList
@@ -24049,7 +24514,7 @@ await client.accounting.bankFeedTransactions.list();
-Creates a `BankFeedTransaction` object with the given values. +Returns a list of `Contact` objects.
@@ -24065,9 +24530,7 @@ Creates a `BankFeedTransaction` object with the given values.
```typescript -await client.accounting.bankFeedTransactions.create({ - model: {}, -}); +await client.accounting.contacts.list(); ```
@@ -24083,7 +24546,7 @@ await client.accounting.bankFeedTransactions.create({
-**request:** `Merge.accounting.BankFeedTransactionEndpointRequest` +**request:** `Merge.accounting.ContactsListRequest`
@@ -24091,7 +24554,7 @@ await client.accounting.bankFeedTransactions.create({
-**requestOptions:** `BankFeedTransactions.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -24102,7 +24565,7 @@ await client.accounting.bankFeedTransactions.create({
-
client.accounting.bankFeedTransactions.retrieve(id, { ...params }) -> Merge.BankFeedTransaction +
client.accounting.contacts.create({ ...params }) -> Merge.ContactResponse
@@ -24114,7 +24577,7 @@ await client.accounting.bankFeedTransactions.create({
-Returns a `BankFeedTransaction` object with the given `id`. +Creates a `Contact` object with the given values.
@@ -24130,7 +24593,9 @@ Returns a `BankFeedTransaction` object with the given `id`.
```typescript -await client.accounting.bankFeedTransactions.retrieve("id"); +await client.accounting.contacts.create({ + model: {}, +}); ```
@@ -24146,15 +24611,7 @@ await client.accounting.bankFeedTransactions.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.accounting.BankFeedTransactionsRetrieveRequest` +**request:** `Merge.accounting.ContactEndpointRequest`
@@ -24162,7 +24619,7 @@ await client.accounting.bankFeedTransactions.retrieve("id");
-**requestOptions:** `BankFeedTransactions.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -24173,7 +24630,7 @@ await client.accounting.bankFeedTransactions.retrieve("id");
-
client.accounting.bankFeedTransactions.metaPostRetrieve() -> Merge.MetaResponse +
client.accounting.contacts.retrieve(id, { ...params }) -> Merge.Contact
@@ -24185,7 +24642,7 @@ await client.accounting.bankFeedTransactions.retrieve("id");
-Returns metadata for `BankFeedTransaction` POSTs. +Returns a `Contact` object with the given `id`.
@@ -24201,7 +24658,7 @@ Returns metadata for `BankFeedTransaction` POSTs.
```typescript -await client.accounting.bankFeedTransactions.metaPostRetrieve(); +await client.accounting.contacts.retrieve("id"); ```
@@ -24217,7 +24674,23 @@ await client.accounting.bankFeedTransactions.metaPostRetrieve();
-**requestOptions:** `BankFeedTransactions.RequestOptions` +**id:** `string` + +
+
+ +
+
+ +**request:** `Merge.accounting.ContactsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions`
@@ -24228,9 +24701,7 @@ await client.accounting.bankFeedTransactions.metaPostRetrieve();
-## Accounting CashFlowStatements - -
client.accounting.cashFlowStatements.list({ ...params }) -> Merge.PaginatedCashFlowStatementList +
client.accounting.contacts.metaPostRetrieve() -> Merge.MetaResponse
@@ -24242,7 +24713,7 @@ await client.accounting.bankFeedTransactions.metaPostRetrieve();
-Returns a list of `CashFlowStatement` objects. +Returns metadata for `Contact` POSTs.
@@ -24258,7 +24729,7 @@ Returns a list of `CashFlowStatement` objects.
```typescript -await client.accounting.cashFlowStatements.list(); +await client.accounting.contacts.metaPostRetrieve(); ```
@@ -24274,15 +24745,7 @@ await client.accounting.cashFlowStatements.list();
-**request:** `Merge.accounting.CashFlowStatementsListRequest` - -
-
- -
-
- -**requestOptions:** `CashFlowStatements.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -24293,7 +24756,7 @@ await client.accounting.cashFlowStatements.list();
-
client.accounting.cashFlowStatements.retrieve(id, { ...params }) -> Merge.CashFlowStatement +
client.accounting.contacts.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -24305,7 +24768,7 @@ await client.accounting.cashFlowStatements.list();
-Returns a `CashFlowStatement` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -24321,7 +24784,7 @@ Returns a `CashFlowStatement` object with the given `id`.
```typescript -await client.accounting.cashFlowStatements.retrieve("id"); +await client.accounting.contacts.remoteFieldClassesList(); ```
@@ -24337,15 +24800,7 @@ await client.accounting.cashFlowStatements.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.accounting.CashFlowStatementsRetrieveRequest` +**request:** `Merge.accounting.ContactsRemoteFieldClassesListRequest`
@@ -24353,7 +24808,7 @@ await client.accounting.cashFlowStatements.retrieve("id");
-**requestOptions:** `CashFlowStatements.RequestOptions` +**requestOptions:** `Contacts.RequestOptions`
@@ -24364,9 +24819,9 @@ await client.accounting.cashFlowStatements.retrieve("id");
-## Accounting CompanyInfo +## Accounting CreditNotes -
client.accounting.companyInfo.list({ ...params }) -> Merge.PaginatedCompanyInfoList +
client.accounting.creditNotes.list({ ...params }) -> Merge.PaginatedCreditNoteList
@@ -24378,7 +24833,7 @@ await client.accounting.cashFlowStatements.retrieve("id");
-Returns a list of `CompanyInfo` objects. +Returns a list of `CreditNote` objects.
@@ -24394,7 +24849,7 @@ Returns a list of `CompanyInfo` objects.
```typescript -await client.accounting.companyInfo.list(); +await client.accounting.creditNotes.list(); ```
@@ -24410,7 +24865,7 @@ await client.accounting.companyInfo.list();
-**request:** `Merge.accounting.CompanyInfoListRequest` +**request:** `Merge.accounting.CreditNotesListRequest`
@@ -24418,7 +24873,7 @@ await client.accounting.companyInfo.list();
-**requestOptions:** `CompanyInfo.RequestOptions` +**requestOptions:** `CreditNotes.RequestOptions`
@@ -24429,7 +24884,7 @@ await client.accounting.companyInfo.list();
-
client.accounting.companyInfo.retrieve(id, { ...params }) -> Merge.CompanyInfo +
client.accounting.creditNotes.create({ ...params }) -> Merge.CreditNoteResponse
@@ -24441,7 +24896,7 @@ await client.accounting.companyInfo.list();
-Returns a `CompanyInfo` object with the given `id`. +Creates a `CreditNote` object with the given values.
@@ -24457,7 +24912,9 @@ Returns a `CompanyInfo` object with the given `id`.
```typescript -await client.accounting.companyInfo.retrieve("id"); +await client.accounting.creditNotes.create({ + model: {}, +}); ```
@@ -24473,15 +24930,7 @@ await client.accounting.companyInfo.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.accounting.CompanyInfoRetrieveRequest` +**request:** `Merge.accounting.CreditNoteEndpointRequest`
@@ -24489,7 +24938,7 @@ await client.accounting.companyInfo.retrieve("id");
-**requestOptions:** `CompanyInfo.RequestOptions` +**requestOptions:** `CreditNotes.RequestOptions`
@@ -24500,9 +24949,7 @@ await client.accounting.companyInfo.retrieve("id");
-## Accounting Contacts - -
client.accounting.contacts.list({ ...params }) -> Merge.PaginatedContactList +
client.accounting.creditNotes.retrieve(id, { ...params }) -> Merge.CreditNote
@@ -24514,7 +24961,7 @@ await client.accounting.companyInfo.retrieve("id");
-Returns a list of `Contact` objects. +Returns a `CreditNote` object with the given `id`.
@@ -24530,7 +24977,7 @@ Returns a list of `Contact` objects.
```typescript -await client.accounting.contacts.list(); +await client.accounting.creditNotes.retrieve("id"); ```
@@ -24546,7 +24993,7 @@ await client.accounting.contacts.list();
-**request:** `Merge.accounting.ContactsListRequest` +**id:** `string`
@@ -24554,7 +25001,15 @@ await client.accounting.contacts.list();
-**requestOptions:** `Contacts.RequestOptions` +**request:** `Merge.accounting.CreditNotesRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `CreditNotes.RequestOptions`
@@ -24565,7 +25020,7 @@ await client.accounting.contacts.list();
-
client.accounting.contacts.create({ ...params }) -> Merge.ContactResponse +
client.accounting.creditNotes.metaPostRetrieve() -> Merge.MetaResponse
@@ -24577,7 +25032,7 @@ await client.accounting.contacts.list();
-Creates a `Contact` object with the given values. +Returns metadata for `CreditNote` POSTs.
@@ -24593,9 +25048,7 @@ Creates a `Contact` object with the given values.
```typescript -await client.accounting.contacts.create({ - model: {}, -}); +await client.accounting.creditNotes.metaPostRetrieve(); ```
@@ -24611,15 +25064,7 @@ await client.accounting.contacts.create({
-**request:** `Merge.accounting.ContactEndpointRequest` - -
-
- -
-
- -**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `CreditNotes.RequestOptions`
@@ -24630,7 +25075,9 @@ await client.accounting.contacts.create({
-
client.accounting.contacts.retrieve(id, { ...params }) -> Merge.Contact +## Accounting Scopes + +
client.accounting.scopes.defaultScopesRetrieve() -> Merge.CommonModelScopeApi
@@ -24642,7 +25089,7 @@ await client.accounting.contacts.create({
-Returns a `Contact` object with the given `id`. +Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes).
@@ -24658,7 +25105,7 @@ Returns a `Contact` object with the given `id`.
```typescript -await client.accounting.contacts.retrieve("id"); +await client.accounting.scopes.defaultScopesRetrieve(); ```
@@ -24674,23 +25121,7 @@ await client.accounting.contacts.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.accounting.ContactsRetrieveRequest` - -
-
- -
-
- -**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Scopes.RequestOptions`
@@ -24701,7 +25132,7 @@ await client.accounting.contacts.retrieve("id");
-
client.accounting.contacts.metaPostRetrieve() -> Merge.MetaResponse +
client.accounting.scopes.linkedAccountScopesRetrieve() -> Merge.CommonModelScopeApi
@@ -24713,7 +25144,7 @@ await client.accounting.contacts.retrieve("id");
-Returns metadata for `Contact` POSTs. +Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes).
@@ -24729,7 +25160,7 @@ Returns metadata for `Contact` POSTs.
```typescript -await client.accounting.contacts.metaPostRetrieve(); +await client.accounting.scopes.linkedAccountScopesRetrieve(); ```
@@ -24745,7 +25176,7 @@ await client.accounting.contacts.metaPostRetrieve();
-**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Scopes.RequestOptions`
@@ -24756,7 +25187,7 @@ await client.accounting.contacts.metaPostRetrieve();
-
client.accounting.contacts.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList +
client.accounting.scopes.linkedAccountScopesCreate({ ...params }) -> Merge.CommonModelScopeApi
@@ -24768,7 +25199,7 @@ await client.accounting.contacts.metaPostRetrieve();
-Returns a list of `RemoteFieldClass` objects. +Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the default Scopes. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes)
@@ -24784,7 +25215,33 @@ Returns a list of `RemoteFieldClass` objects.
```typescript -await client.accounting.contacts.remoteFieldClassesList(); +await client.accounting.scopes.linkedAccountScopesCreate({ + commonModels: [ + { + modelName: "Employee", + modelPermissions: { + READ: { + isEnabled: true, + }, + WRITE: { + isEnabled: false, + }, + }, + fieldPermissions: { + enabledFields: ["avatar", "home_location"], + disabledFields: ["work_location"], + }, + }, + { + modelName: "Benefit", + modelPermissions: { + WRITE: { + isEnabled: false, + }, + }, + }, + ], +}); ```
@@ -24800,7 +25257,7 @@ await client.accounting.contacts.remoteFieldClassesList();
-**request:** `Merge.accounting.ContactsRemoteFieldClassesListRequest` +**request:** `Merge.accounting.LinkedAccountCommonModelScopeDeserializerRequest`
@@ -24808,7 +25265,7 @@ await client.accounting.contacts.remoteFieldClassesList();
-**requestOptions:** `Contacts.RequestOptions` +**requestOptions:** `Scopes.RequestOptions`
@@ -24819,9 +25276,9 @@ await client.accounting.contacts.remoteFieldClassesList();
-## Accounting CreditNotes +## Accounting DeleteAccount -
client.accounting.creditNotes.list({ ...params }) -> Merge.PaginatedCreditNoteList +
client.accounting.deleteAccount.delete() -> void
@@ -24833,7 +25290,7 @@ await client.accounting.contacts.remoteFieldClassesList();
-Returns a list of `CreditNote` objects. +Delete a linked account.
@@ -24849,7 +25306,7 @@ Returns a list of `CreditNote` objects.
```typescript -await client.accounting.creditNotes.list(); +await client.accounting.deleteAccount.delete(); ```
@@ -24865,15 +25322,7 @@ await client.accounting.creditNotes.list();
-**request:** `Merge.accounting.CreditNotesListRequest` - -
-
- -
-
- -**requestOptions:** `CreditNotes.RequestOptions` +**requestOptions:** `DeleteAccount.RequestOptions`
@@ -24884,7 +25333,9 @@ await client.accounting.creditNotes.list();
-
client.accounting.creditNotes.create({ ...params }) -> Merge.CreditNoteResponse +## Accounting Employees + +
client.accounting.employees.list({ ...params }) -> Merge.PaginatedEmployeeList
@@ -24896,7 +25347,7 @@ await client.accounting.creditNotes.list();
-Creates a `CreditNote` object with the given values. +Returns a list of `Employee` objects.
@@ -24912,9 +25363,7 @@ Creates a `CreditNote` object with the given values.
```typescript -await client.accounting.creditNotes.create({ - model: {}, -}); +await client.accounting.employees.list(); ```
@@ -24930,7 +25379,7 @@ await client.accounting.creditNotes.create({
-**request:** `Merge.accounting.CreditNoteEndpointRequest` +**request:** `Merge.accounting.EmployeesListRequest`
@@ -24938,7 +25387,7 @@ await client.accounting.creditNotes.create({
-**requestOptions:** `CreditNotes.RequestOptions` +**requestOptions:** `Employees.RequestOptions`
@@ -24949,7 +25398,7 @@ await client.accounting.creditNotes.create({
-
client.accounting.creditNotes.retrieve(id, { ...params }) -> Merge.CreditNote +
client.accounting.employees.retrieve(id, { ...params }) -> Merge.Employee
@@ -24961,7 +25410,7 @@ await client.accounting.creditNotes.create({
-Returns a `CreditNote` object with the given `id`. +Returns an `Employee` object with the given `id`.
@@ -24977,7 +25426,7 @@ Returns a `CreditNote` object with the given `id`.
```typescript -await client.accounting.creditNotes.retrieve("id"); +await client.accounting.employees.retrieve("id"); ```
@@ -25001,7 +25450,7 @@ await client.accounting.creditNotes.retrieve("id");
-**request:** `Merge.accounting.CreditNotesRetrieveRequest` +**request:** `Merge.accounting.EmployeesRetrieveRequest`
@@ -25009,7 +25458,7 @@ await client.accounting.creditNotes.retrieve("id");
-**requestOptions:** `CreditNotes.RequestOptions` +**requestOptions:** `Employees.RequestOptions`
@@ -25020,7 +25469,9 @@ await client.accounting.creditNotes.retrieve("id");
-
client.accounting.creditNotes.metaPostRetrieve() -> Merge.MetaResponse +## Accounting ExpenseReports + +
client.accounting.expenseReports.list({ ...params }) -> Merge.PaginatedExpenseReportList
@@ -25032,7 +25483,7 @@ await client.accounting.creditNotes.retrieve("id");
-Returns metadata for `CreditNote` POSTs. +Returns a list of `ExpenseReport` objects.
@@ -25048,7 +25499,7 @@ Returns metadata for `CreditNote` POSTs.
```typescript -await client.accounting.creditNotes.metaPostRetrieve(); +await client.accounting.expenseReports.list(); ```
@@ -25064,7 +25515,15 @@ await client.accounting.creditNotes.metaPostRetrieve();
-**requestOptions:** `CreditNotes.RequestOptions` +**request:** `Merge.accounting.ExpenseReportsListRequest` + +
+
+ +
+
+ +**requestOptions:** `ExpenseReports.RequestOptions`
@@ -25075,9 +25534,7 @@ await client.accounting.creditNotes.metaPostRetrieve();
-## Accounting Scopes - -
client.accounting.scopes.defaultScopesRetrieve() -> Merge.CommonModelScopeApi +
client.accounting.expenseReports.create({ ...params }) -> Merge.ExpenseReportResponse
@@ -25089,7 +25546,7 @@ await client.accounting.creditNotes.metaPostRetrieve();
-Get the default permissions for Merge Common Models and fields across all Linked Accounts of a given category. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). +Creates an `ExpenseReport` object with the given values.
@@ -25105,7 +25562,11 @@ Get the default permissions for Merge Common Models and fields across all Linked
```typescript -await client.accounting.scopes.defaultScopesRetrieve(); +await client.accounting.expenseReports.create({ + model: { + trackingCategories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"], + }, +}); ```
@@ -25121,7 +25582,15 @@ await client.accounting.scopes.defaultScopesRetrieve();
-**requestOptions:** `Scopes.RequestOptions` +**request:** `Merge.accounting.ExpenseReportEndpointRequest` + +
+
+ +
+
+ +**requestOptions:** `ExpenseReports.RequestOptions`
@@ -25132,7 +25601,7 @@ await client.accounting.scopes.defaultScopesRetrieve();
-
client.accounting.scopes.linkedAccountScopesRetrieve() -> Merge.CommonModelScopeApi +
client.accounting.expenseReports.linesList(expenseReportId, { ...params }) -> Merge.PaginatedExpenseReportLineList
@@ -25144,7 +25613,7 @@ await client.accounting.scopes.defaultScopesRetrieve();
-Get all available permissions for Merge Common Models and fields for a single Linked Account. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes). +Returns a list of `ExpenseReportLine` objects that point to a `ExpenseReport` with the given id.
@@ -25160,7 +25629,7 @@ Get all available permissions for Merge Common Models and fields for a single Li
```typescript -await client.accounting.scopes.linkedAccountScopesRetrieve(); +await client.accounting.expenseReports.linesList("expense_report_id"); ```
@@ -25176,7 +25645,23 @@ await client.accounting.scopes.linkedAccountScopesRetrieve();
-**requestOptions:** `Scopes.RequestOptions` +**expenseReportId:** `string` + +
+
+ +
+
+ +**request:** `Merge.accounting.ExpenseReportsLinesListRequest` + +
+
+ +
+
+ +**requestOptions:** `ExpenseReports.RequestOptions`
@@ -25187,7 +25672,7 @@ await client.accounting.scopes.linkedAccountScopesRetrieve();
-
client.accounting.scopes.linkedAccountScopesCreate({ ...params }) -> Merge.CommonModelScopeApi +
client.accounting.expenseReports.retrieve(id, { ...params }) -> Merge.ExpenseReport
@@ -25199,7 +25684,7 @@ await client.accounting.scopes.linkedAccountScopesRetrieve();
-Update permissions for any Common Model or field for a single Linked Account. Any Scopes not set in this POST request will inherit the default Scopes. [Learn more](https://help.merge.dev/en/articles/5950052-common-model-and-field-scopes) +Returns an `ExpenseReport` object with the given `id`.
@@ -25215,33 +25700,7 @@ Update permissions for any Common Model or field for a single Linked Account. An
```typescript -await client.accounting.scopes.linkedAccountScopesCreate({ - commonModels: [ - { - modelName: "Employee", - modelPermissions: { - READ: { - isEnabled: true, - }, - WRITE: { - isEnabled: false, - }, - }, - fieldPermissions: { - enabledFields: ["avatar", "home_location"], - disabledFields: ["work_location"], - }, - }, - { - modelName: "Benefit", - modelPermissions: { - WRITE: { - isEnabled: false, - }, - }, - }, - ], -}); +await client.accounting.expenseReports.retrieve("id"); ```
@@ -25257,7 +25716,7 @@ await client.accounting.scopes.linkedAccountScopesCreate({
-**request:** `Merge.accounting.LinkedAccountCommonModelScopeDeserializerRequest` +**id:** `string`
@@ -25265,7 +25724,15 @@ await client.accounting.scopes.linkedAccountScopesCreate({
-**requestOptions:** `Scopes.RequestOptions` +**request:** `Merge.accounting.ExpenseReportsRetrieveRequest` + +
+
+ +
+
+ +**requestOptions:** `ExpenseReports.RequestOptions`
@@ -25276,9 +25743,7 @@ await client.accounting.scopes.linkedAccountScopesCreate({
-## Accounting DeleteAccount - -
client.accounting.deleteAccount.delete() -> void +
client.accounting.expenseReports.linesRemoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -25290,7 +25755,7 @@ await client.accounting.scopes.linkedAccountScopesCreate({
-Delete a linked account. +Returns a list of `RemoteFieldClass` objects.
@@ -25306,7 +25771,7 @@ Delete a linked account.
```typescript -await client.accounting.deleteAccount.delete(); +await client.accounting.expenseReports.linesRemoteFieldClassesList(); ```
@@ -25322,7 +25787,15 @@ await client.accounting.deleteAccount.delete();
-**requestOptions:** `DeleteAccount.RequestOptions` +**request:** `Merge.accounting.ExpenseReportsLinesRemoteFieldClassesListRequest` + +
+
+ +
+
+ +**requestOptions:** `ExpenseReports.RequestOptions`
@@ -25333,9 +25806,7 @@ await client.accounting.deleteAccount.delete();
-## Accounting Employees - -
client.accounting.employees.list({ ...params }) -> Merge.PaginatedEmployeeList +
client.accounting.expenseReports.metaPostRetrieve() -> Merge.MetaResponse
@@ -25347,7 +25818,7 @@ await client.accounting.deleteAccount.delete();
-Returns a list of `Employee` objects. +Returns metadata for `ExpenseReport` POSTs.
@@ -25363,7 +25834,7 @@ Returns a list of `Employee` objects.
```typescript -await client.accounting.employees.list(); +await client.accounting.expenseReports.metaPostRetrieve(); ```
@@ -25379,15 +25850,7 @@ await client.accounting.employees.list();
-**request:** `Merge.accounting.EmployeesListRequest` - -
-
- -
-
- -**requestOptions:** `Employees.RequestOptions` +**requestOptions:** `ExpenseReports.RequestOptions`
@@ -25398,7 +25861,7 @@ await client.accounting.employees.list();
-
client.accounting.employees.retrieve(id, { ...params }) -> Merge.Employee +
client.accounting.expenseReports.remoteFieldClassesList({ ...params }) -> Merge.PaginatedRemoteFieldClassList
@@ -25410,7 +25873,7 @@ await client.accounting.employees.list();
-Returns an `Employee` object with the given `id`. +Returns a list of `RemoteFieldClass` objects.
@@ -25426,7 +25889,7 @@ Returns an `Employee` object with the given `id`.
```typescript -await client.accounting.employees.retrieve("id"); +await client.accounting.expenseReports.remoteFieldClassesList(); ```
@@ -25442,15 +25905,7 @@ await client.accounting.employees.retrieve("id");
-**id:** `string` - -
-
- -
-
- -**request:** `Merge.accounting.EmployeesRetrieveRequest` +**request:** `Merge.accounting.ExpenseReportsRemoteFieldClassesListRequest`
@@ -25458,7 +25913,7 @@ await client.accounting.employees.retrieve("id");
-**requestOptions:** `Employees.RequestOptions` +**requestOptions:** `ExpenseReports.RequestOptions`
diff --git a/src/Client.ts b/src/Client.ts index 4310f57d0..dfa55807e 100644 --- a/src/Client.ts +++ b/src/Client.ts @@ -8,8 +8,8 @@ import { mergeHeaders } from "./core/headers.js"; import { Filestorage } from "./api/resources/filestorage/client/Client"; import { Hris } from "./api/resources/hris/client/Client"; import { Ticketing } from "./api/resources/ticketing/client/Client"; -import { Crm } from "./api/resources/crm/client/Client"; import { Ats } from "./api/resources/ats/client/Client"; +import { Crm } from "./api/resources/crm/client/Client"; import { Accounting } from "./api/resources/accounting/client/Client"; export declare namespace MergeClient { @@ -44,8 +44,8 @@ export class MergeClient { protected _filestorage: Filestorage | undefined; protected _hris: Hris | undefined; protected _ticketing: Ticketing | undefined; - protected _crm: Crm | undefined; protected _ats: Ats | undefined; + protected _crm: Crm | undefined; protected _accounting: Accounting | undefined; constructor(_options: MergeClient.Options) { @@ -56,8 +56,8 @@ export class MergeClient { "X-Account-Token": _options?.accountToken, "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "@mergeapi/merge-node-client", - "X-Fern-SDK-Version": "2.0.1", - "User-Agent": "@mergeapi/merge-node-client/2.0.1", + "X-Fern-SDK-Version": "2.1.0", + "User-Agent": "@mergeapi/merge-node-client/2.1.0", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, }, @@ -78,14 +78,14 @@ export class MergeClient { return (this._ticketing ??= new Ticketing(this._options)); } - public get crm(): Crm { - return (this._crm ??= new Crm(this._options)); - } - public get ats(): Ats { return (this._ats ??= new Ats(this._options)); } + public get crm(): Crm { + return (this._crm ??= new Crm(this._options)); + } + public get accounting(): Accounting { return (this._accounting ??= new Accounting(this._options)); } diff --git a/src/api/resources/accounting/client/Client.ts b/src/api/resources/accounting/client/Client.ts index 24e12967b..7fad75d13 100644 --- a/src/api/resources/accounting/client/Client.ts +++ b/src/api/resources/accounting/client/Client.ts @@ -24,6 +24,7 @@ import { CreditNotes } from "../resources/creditNotes/client/Client"; import { Scopes } from "../resources/scopes/client/Client"; import { DeleteAccount } from "../resources/deleteAccount/client/Client"; import { Employees } from "../resources/employees/client/Client"; +import { ExpenseReports } from "../resources/expenseReports/client/Client"; import { Expenses } from "../resources/expenses/client/Client"; import { FieldMapping } from "../resources/fieldMapping/client/Client"; import { GeneralLedgerTransactions } from "../resources/generalLedgerTransactions/client/Client"; @@ -87,6 +88,7 @@ export class Accounting { protected _scopes: Scopes | undefined; protected _deleteAccount: DeleteAccount | undefined; protected _employees: Employees | undefined; + protected _expenseReports: ExpenseReports | undefined; protected _expenses: Expenses | undefined; protected _fieldMapping: FieldMapping | undefined; protected _generalLedgerTransactions: GeneralLedgerTransactions | undefined; @@ -198,6 +200,10 @@ export class Accounting { return (this._employees ??= new Employees(this._options)); } + public get expenseReports(): ExpenseReports { + return (this._expenseReports ??= new ExpenseReports(this._options)); + } + public get expenses(): Expenses { return (this._expenses ??= new Expenses(this._options)); } diff --git a/src/api/resources/accounting/resources/expenseReports/client/Client.ts b/src/api/resources/accounting/resources/expenseReports/client/Client.ts new file mode 100644 index 000000000..98fe8a5a2 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/Client.ts @@ -0,0 +1,842 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Merge from "../../../../../index"; +import * as serializers from "../../../../../../serialization/index"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace ExpenseReports { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + apiKey: core.Supplier; + /** Override the X-Account-Token header */ + accountToken?: core.Supplier; + /** Additional headers to include in requests. */ + headers?: Record | undefined>; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Override the X-Account-Token header */ + accountToken?: string | undefined; + /** Additional headers to include in the request. */ + headers?: Record | undefined>; + } +} + +export class ExpenseReports { + protected readonly _options: ExpenseReports.Options; + + constructor(_options: ExpenseReports.Options) { + this._options = _options; + } + + /** + * Returns a list of `ExpenseReport` objects. + * + * @param {Merge.accounting.ExpenseReportsListRequest} request + * @param {ExpenseReports.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.accounting.expenseReports.list() + */ + public list( + request: Merge.accounting.ExpenseReportsListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions)); + } + + private async __list( + request: Merge.accounting.ExpenseReportsListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): Promise> { + const { + companyId, + createdAfter, + createdBefore, + cursor, + expand, + includeDeletedData, + includeRemoteData, + includeRemoteFields, + includeShellData, + modifiedAfter, + modifiedBefore, + pageSize, + remoteId, + } = request; + const _queryParams: Record = {}; + if (companyId != null) { + _queryParams["company_id"] = companyId; + } + + if (createdAfter != null) { + _queryParams["created_after"] = createdAfter.toISOString(); + } + + if (createdBefore != null) { + _queryParams["created_before"] = createdBefore.toISOString(); + } + + if (cursor != null) { + _queryParams["cursor"] = cursor; + } + + if (expand != null) { + _queryParams["expand"] = serializers.accounting.ExpenseReportsListRequestExpand.jsonOrThrow(expand, { + unrecognizedObjectKeys: "strip", + }); + } + + if (includeDeletedData != null) { + _queryParams["include_deleted_data"] = includeDeletedData.toString(); + } + + if (includeRemoteData != null) { + _queryParams["include_remote_data"] = includeRemoteData.toString(); + } + + if (includeRemoteFields != null) { + _queryParams["include_remote_fields"] = includeRemoteFields.toString(); + } + + if (includeShellData != null) { + _queryParams["include_shell_data"] = includeShellData.toString(); + } + + if (modifiedAfter != null) { + _queryParams["modified_after"] = modifiedAfter.toISOString(); + } + + if (modifiedBefore != null) { + _queryParams["modified_before"] = modifiedBefore.toISOString(); + } + + if (pageSize != null) { + _queryParams["page_size"] = pageSize.toString(); + } + + if (remoteId != null) { + _queryParams["remote_id"] = remoteId; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.MergeEnvironment.Production, + "accounting/v1/expense-reports", + ), + method: "GET", + headers: mergeHeaders( + this._options?.headers, + mergeOnlyDefinedHeaders({ + Authorization: await this._getAuthorizationHeader(), + "X-Account-Token": requestOptions?.accountToken, + }), + requestOptions?.headers, + ), + queryParameters: _queryParams, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: serializers.accounting.PaginatedExpenseReportList.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }), + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.MergeTimeoutError("Timeout exceeded when calling GET /accounting/v1/expense-reports."); + case "unknown": + throw new errors.MergeError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Creates an `ExpenseReport` object with the given values. + * + * @param {Merge.accounting.ExpenseReportEndpointRequest} request + * @param {ExpenseReports.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.accounting.expenseReports.create({ + * model: { + * trackingCategories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"] + * } + * }) + */ + public create( + request: Merge.accounting.ExpenseReportEndpointRequest, + requestOptions?: ExpenseReports.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Merge.accounting.ExpenseReportEndpointRequest, + requestOptions?: ExpenseReports.RequestOptions, + ): Promise> { + const { isDebugMode, runAsync, ..._body } = request; + const _queryParams: Record = {}; + if (isDebugMode != null) { + _queryParams["is_debug_mode"] = isDebugMode.toString(); + } + + if (runAsync != null) { + _queryParams["run_async"] = runAsync.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.MergeEnvironment.Production, + "accounting/v1/expense-reports", + ), + method: "POST", + headers: mergeHeaders( + this._options?.headers, + mergeOnlyDefinedHeaders({ + Authorization: await this._getAuthorizationHeader(), + "X-Account-Token": requestOptions?.accountToken, + }), + requestOptions?.headers, + ), + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + body: serializers.accounting.ExpenseReportEndpointRequest.jsonOrThrow(_body, { + unrecognizedObjectKeys: "strip", + }), + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: serializers.accounting.ExpenseReportResponse.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }), + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.MergeTimeoutError( + "Timeout exceeded when calling POST /accounting/v1/expense-reports.", + ); + case "unknown": + throw new errors.MergeError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Returns a list of `ExpenseReportLine` objects that point to a `ExpenseReport` with the given id. + * + * @param {string} expenseReportId + * @param {Merge.accounting.ExpenseReportsLinesListRequest} request + * @param {ExpenseReports.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.accounting.expenseReports.linesList("expense_report_id") + */ + public linesList( + expenseReportId: string, + request: Merge.accounting.ExpenseReportsLinesListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__linesList(expenseReportId, request, requestOptions)); + } + + private async __linesList( + expenseReportId: string, + request: Merge.accounting.ExpenseReportsLinesListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): Promise> { + const { + cursor, + expand, + includeDeletedData, + includeRemoteData, + includeRemoteFields, + includeShellData, + pageSize, + } = request; + const _queryParams: Record = {}; + if (cursor != null) { + _queryParams["cursor"] = cursor; + } + + if (expand != null) { + _queryParams["expand"] = serializers.accounting.ExpenseReportsLinesListRequestExpand.jsonOrThrow(expand, { + unrecognizedObjectKeys: "strip", + }); + } + + if (includeDeletedData != null) { + _queryParams["include_deleted_data"] = includeDeletedData.toString(); + } + + if (includeRemoteData != null) { + _queryParams["include_remote_data"] = includeRemoteData.toString(); + } + + if (includeRemoteFields != null) { + _queryParams["include_remote_fields"] = includeRemoteFields.toString(); + } + + if (includeShellData != null) { + _queryParams["include_shell_data"] = includeShellData.toString(); + } + + if (pageSize != null) { + _queryParams["page_size"] = pageSize.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.MergeEnvironment.Production, + `accounting/v1/expense-reports/${encodeURIComponent(expenseReportId)}/lines`, + ), + method: "GET", + headers: mergeHeaders( + this._options?.headers, + mergeOnlyDefinedHeaders({ + Authorization: await this._getAuthorizationHeader(), + "X-Account-Token": requestOptions?.accountToken, + }), + requestOptions?.headers, + ), + queryParameters: _queryParams, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: serializers.accounting.PaginatedExpenseReportLineList.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }), + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.MergeTimeoutError( + "Timeout exceeded when calling GET /accounting/v1/expense-reports/{expense_report_id}/lines.", + ); + case "unknown": + throw new errors.MergeError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Returns an `ExpenseReport` object with the given `id`. + * + * @param {string} id + * @param {Merge.accounting.ExpenseReportsRetrieveRequest} request + * @param {ExpenseReports.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.accounting.expenseReports.retrieve("id") + */ + public retrieve( + id: string, + request: Merge.accounting.ExpenseReportsRetrieveRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieve(id, request, requestOptions)); + } + + private async __retrieve( + id: string, + request: Merge.accounting.ExpenseReportsRetrieveRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): Promise> { + const { expand, includeRemoteData, includeRemoteFields, includeShellData } = request; + const _queryParams: Record = {}; + if (expand != null) { + _queryParams["expand"] = serializers.accounting.ExpenseReportsRetrieveRequestExpand.jsonOrThrow(expand, { + unrecognizedObjectKeys: "strip", + }); + } + + if (includeRemoteData != null) { + _queryParams["include_remote_data"] = includeRemoteData.toString(); + } + + if (includeRemoteFields != null) { + _queryParams["include_remote_fields"] = includeRemoteFields.toString(); + } + + if (includeShellData != null) { + _queryParams["include_shell_data"] = includeShellData.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.MergeEnvironment.Production, + `accounting/v1/expense-reports/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: mergeHeaders( + this._options?.headers, + mergeOnlyDefinedHeaders({ + Authorization: await this._getAuthorizationHeader(), + "X-Account-Token": requestOptions?.accountToken, + }), + requestOptions?.headers, + ), + queryParameters: _queryParams, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: serializers.accounting.ExpenseReport.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }), + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.MergeTimeoutError( + "Timeout exceeded when calling GET /accounting/v1/expense-reports/{id}.", + ); + case "unknown": + throw new errors.MergeError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Returns a list of `RemoteFieldClass` objects. + * + * @param {Merge.accounting.ExpenseReportsLinesRemoteFieldClassesListRequest} request + * @param {ExpenseReports.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.accounting.expenseReports.linesRemoteFieldClassesList() + */ + public linesRemoteFieldClassesList( + request: Merge.accounting.ExpenseReportsLinesRemoteFieldClassesListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__linesRemoteFieldClassesList(request, requestOptions)); + } + + private async __linesRemoteFieldClassesList( + request: Merge.accounting.ExpenseReportsLinesRemoteFieldClassesListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): Promise> { + const { + cursor, + includeDeletedData, + includeRemoteData, + includeShellData, + isCommonModelField, + isCustom, + pageSize, + } = request; + const _queryParams: Record = {}; + if (cursor != null) { + _queryParams["cursor"] = cursor; + } + + if (includeDeletedData != null) { + _queryParams["include_deleted_data"] = includeDeletedData.toString(); + } + + if (includeRemoteData != null) { + _queryParams["include_remote_data"] = includeRemoteData.toString(); + } + + if (includeShellData != null) { + _queryParams["include_shell_data"] = includeShellData.toString(); + } + + if (isCommonModelField != null) { + _queryParams["is_common_model_field"] = isCommonModelField.toString(); + } + + if (isCustom != null) { + _queryParams["is_custom"] = isCustom.toString(); + } + + if (pageSize != null) { + _queryParams["page_size"] = pageSize.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.MergeEnvironment.Production, + "accounting/v1/expense-reports/lines/remote-field-classes", + ), + method: "GET", + headers: mergeHeaders( + this._options?.headers, + mergeOnlyDefinedHeaders({ + Authorization: await this._getAuthorizationHeader(), + "X-Account-Token": requestOptions?.accountToken, + }), + requestOptions?.headers, + ), + queryParameters: _queryParams, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: serializers.accounting.PaginatedRemoteFieldClassList.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }), + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.MergeTimeoutError( + "Timeout exceeded when calling GET /accounting/v1/expense-reports/lines/remote-field-classes.", + ); + case "unknown": + throw new errors.MergeError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Returns metadata for `ExpenseReport` POSTs. + * + * @param {ExpenseReports.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.accounting.expenseReports.metaPostRetrieve() + */ + public metaPostRetrieve( + requestOptions?: ExpenseReports.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__metaPostRetrieve(requestOptions)); + } + + private async __metaPostRetrieve( + requestOptions?: ExpenseReports.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.MergeEnvironment.Production, + "accounting/v1/expense-reports/meta/post", + ), + method: "GET", + headers: mergeHeaders( + this._options?.headers, + mergeOnlyDefinedHeaders({ + Authorization: await this._getAuthorizationHeader(), + "X-Account-Token": requestOptions?.accountToken, + }), + requestOptions?.headers, + ), + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: serializers.accounting.MetaResponse.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }), + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.MergeTimeoutError( + "Timeout exceeded when calling GET /accounting/v1/expense-reports/meta/post.", + ); + case "unknown": + throw new errors.MergeError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Returns a list of `RemoteFieldClass` objects. + * + * @param {Merge.accounting.ExpenseReportsRemoteFieldClassesListRequest} request + * @param {ExpenseReports.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.accounting.expenseReports.remoteFieldClassesList() + */ + public remoteFieldClassesList( + request: Merge.accounting.ExpenseReportsRemoteFieldClassesListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__remoteFieldClassesList(request, requestOptions)); + } + + private async __remoteFieldClassesList( + request: Merge.accounting.ExpenseReportsRemoteFieldClassesListRequest = {}, + requestOptions?: ExpenseReports.RequestOptions, + ): Promise> { + const { + cursor, + includeDeletedData, + includeRemoteData, + includeShellData, + isCommonModelField, + isCustom, + pageSize, + } = request; + const _queryParams: Record = {}; + if (cursor != null) { + _queryParams["cursor"] = cursor; + } + + if (includeDeletedData != null) { + _queryParams["include_deleted_data"] = includeDeletedData.toString(); + } + + if (includeRemoteData != null) { + _queryParams["include_remote_data"] = includeRemoteData.toString(); + } + + if (includeShellData != null) { + _queryParams["include_shell_data"] = includeShellData.toString(); + } + + if (isCommonModelField != null) { + _queryParams["is_common_model_field"] = isCommonModelField.toString(); + } + + if (isCustom != null) { + _queryParams["is_custom"] = isCustom.toString(); + } + + if (pageSize != null) { + _queryParams["page_size"] = pageSize.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.MergeEnvironment.Production, + "accounting/v1/expense-reports/remote-field-classes", + ), + method: "GET", + headers: mergeHeaders( + this._options?.headers, + mergeOnlyDefinedHeaders({ + Authorization: await this._getAuthorizationHeader(), + "X-Account-Token": requestOptions?.accountToken, + }), + requestOptions?.headers, + ), + queryParameters: _queryParams, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: serializers.accounting.PaginatedRemoteFieldClassList.parseOrThrow(_response.body, { + unrecognizedObjectKeys: "passthrough", + allowUnrecognizedUnionMembers: true, + allowUnrecognizedEnumValues: true, + skipValidation: true, + breadcrumbsPrefix: ["response"], + }), + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.MergeError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.MergeTimeoutError( + "Timeout exceeded when calling GET /accounting/v1/expense-reports/remote-field-classes.", + ); + case "unknown": + throw new errors.MergeError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + return `Bearer ${await core.Supplier.get(this._options.apiKey)}`; + } +} diff --git a/src/api/resources/accounting/resources/expenseReports/client/index.ts b/src/api/resources/accounting/resources/expenseReports/client/index.ts new file mode 100644 index 000000000..415726b7f --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts new file mode 100644 index 000000000..659b23c8b --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../../../../index"; + +/** + * @example + * { + * model: { + * trackingCategories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"] + * } + * } + */ +export interface ExpenseReportEndpointRequest { + /** + * Whether to include debug fields (such as log file links) in the response. + */ + isDebugMode?: boolean; + /** + * Whether or not third-party updates should be run asynchronously. + */ + runAsync?: boolean; + model: Merge.accounting.ExpenseReportRequest; +} diff --git a/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesListRequest.ts b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesListRequest.ts new file mode 100644 index 000000000..d8e2b6b83 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesListRequest.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../../../../index"; + +/** + * @example + * {} + */ +export interface ExpenseReportsLinesListRequest { + /** + * The pagination cursor value. + */ + cursor?: string; + /** + * Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces. + */ + expand?: Merge.accounting.ExpenseReportsLinesListRequestExpand; + /** + * Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/). + */ + includeDeletedData?: boolean; + /** + * Whether to include the original data Merge fetched from the third-party to produce these models. + */ + includeRemoteData?: boolean; + /** + * Whether to include all remote fields, including fields that Merge did not map to common models, in a normalized format. + */ + includeRemoteFields?: boolean; + /** + * Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null). + */ + includeShellData?: boolean; + /** + * Number of results to return per page. + */ + pageSize?: number; +} diff --git a/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesRemoteFieldClassesListRequest.ts b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesRemoteFieldClassesListRequest.ts new file mode 100644 index 000000000..4094a4689 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsLinesRemoteFieldClassesListRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ExpenseReportsLinesRemoteFieldClassesListRequest { + /** + * The pagination cursor value. + */ + cursor?: string; + /** + * Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/). + */ + includeDeletedData?: boolean; + /** + * Whether to include the original data Merge fetched from the third-party to produce these models. + */ + includeRemoteData?: boolean; + /** + * Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null). + */ + includeShellData?: boolean; + /** + * If provided, will only return remote field classes with this is_common_model_field value + */ + isCommonModelField?: boolean; + /** + * If provided, will only return remote fields classes with this is_custom value + */ + isCustom?: boolean; + /** + * Number of results to return per page. + */ + pageSize?: number; +} diff --git a/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsListRequest.ts b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsListRequest.ts new file mode 100644 index 000000000..69c707762 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsListRequest.ts @@ -0,0 +1,64 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../../../../index"; + +/** + * @example + * {} + */ +export interface ExpenseReportsListRequest { + /** + * If provided, will only return expense reports for this company. + */ + companyId?: string; + /** + * If provided, will only return objects created after this datetime. + */ + createdAfter?: Date; + /** + * If provided, will only return objects created before this datetime. + */ + createdBefore?: Date; + /** + * The pagination cursor value. + */ + cursor?: string; + /** + * Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces. + */ + expand?: Merge.accounting.ExpenseReportsListRequestExpand; + /** + * Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/). + */ + includeDeletedData?: boolean; + /** + * Whether to include the original data Merge fetched from the third-party to produce these models. + */ + includeRemoteData?: boolean; + /** + * Whether to include all remote fields, including fields that Merge did not map to common models, in a normalized format. + */ + includeRemoteFields?: boolean; + /** + * Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null). + */ + includeShellData?: boolean; + /** + * If provided, only objects synced by Merge after this date time will be returned. + */ + modifiedAfter?: Date; + /** + * If provided, only objects synced by Merge before this date time will be returned. + */ + modifiedBefore?: Date; + /** + * Number of results to return per page. + */ + pageSize?: number; + /** + * The API provider's ID for the given object. + */ + remoteId?: string; +} diff --git a/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRemoteFieldClassesListRequest.ts b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRemoteFieldClassesListRequest.ts new file mode 100644 index 000000000..bc48aef91 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRemoteFieldClassesListRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ExpenseReportsRemoteFieldClassesListRequest { + /** + * The pagination cursor value. + */ + cursor?: string; + /** + * Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/). + */ + includeDeletedData?: boolean; + /** + * Whether to include the original data Merge fetched from the third-party to produce these models. + */ + includeRemoteData?: boolean; + /** + * Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null). + */ + includeShellData?: boolean; + /** + * If provided, will only return remote field classes with this is_common_model_field value + */ + isCommonModelField?: boolean; + /** + * If provided, will only return remote fields classes with this is_custom value + */ + isCustom?: boolean; + /** + * Number of results to return per page. + */ + pageSize?: number; +} diff --git a/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRetrieveRequest.ts b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRetrieveRequest.ts new file mode 100644 index 000000000..c0f8435e0 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/requests/ExpenseReportsRetrieveRequest.ts @@ -0,0 +1,28 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../../../../index"; + +/** + * @example + * {} + */ +export interface ExpenseReportsRetrieveRequest { + /** + * Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces. + */ + expand?: Merge.accounting.ExpenseReportsRetrieveRequestExpand; + /** + * Whether to include the original data Merge fetched from the third-party to produce these models. + */ + includeRemoteData?: boolean; + /** + * Whether to include all remote fields, including fields that Merge did not map to common models, in a normalized format. + */ + includeRemoteFields?: boolean; + /** + * Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null). + */ + includeShellData?: boolean; +} diff --git a/src/api/resources/accounting/resources/expenseReports/client/requests/index.ts b/src/api/resources/accounting/resources/expenseReports/client/requests/index.ts new file mode 100644 index 000000000..c15c54f19 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/client/requests/index.ts @@ -0,0 +1,6 @@ +export { type ExpenseReportsListRequest } from "./ExpenseReportsListRequest"; +export { type ExpenseReportEndpointRequest } from "./ExpenseReportEndpointRequest"; +export { type ExpenseReportsLinesListRequest } from "./ExpenseReportsLinesListRequest"; +export { type ExpenseReportsRetrieveRequest } from "./ExpenseReportsRetrieveRequest"; +export { type ExpenseReportsLinesRemoteFieldClassesListRequest } from "./ExpenseReportsLinesRemoteFieldClassesListRequest"; +export { type ExpenseReportsRemoteFieldClassesListRequest } from "./ExpenseReportsRemoteFieldClassesListRequest"; diff --git a/src/api/resources/accounting/resources/expenseReports/index.ts b/src/api/resources/accounting/resources/expenseReports/index.ts new file mode 100644 index 000000000..c9240f83b --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts b/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts new file mode 100644 index 000000000..12780551c --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts @@ -0,0 +1,133 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type ExpenseReportsLinesListRequestExpand = + | "account" + | "account,company" + | "account,company,contact" + | "account,company,contact,tax_rate" + | "account,company,tax_rate" + | "account,contact" + | "account,contact,tax_rate" + | "account,employee" + | "account,employee,company" + | "account,employee,company,contact" + | "account,employee,company,contact,tax_rate" + | "account,employee,company,tax_rate" + | "account,employee,contact" + | "account,employee,contact,tax_rate" + | "account,employee,project" + | "account,employee,project,company" + | "account,employee,project,company,contact" + | "account,employee,project,company,contact,tax_rate" + | "account,employee,project,company,tax_rate" + | "account,employee,project,contact" + | "account,employee,project,contact,tax_rate" + | "account,employee,project,tax_rate" + | "account,employee,tax_rate" + | "account,project" + | "account,project,company" + | "account,project,company,contact" + | "account,project,company,contact,tax_rate" + | "account,project,company,tax_rate" + | "account,project,contact" + | "account,project,contact,tax_rate" + | "account,project,tax_rate" + | "account,tax_rate" + | "company" + | "company,contact" + | "company,contact,tax_rate" + | "company,tax_rate" + | "contact" + | "contact,tax_rate" + | "employee" + | "employee,company" + | "employee,company,contact" + | "employee,company,contact,tax_rate" + | "employee,company,tax_rate" + | "employee,contact" + | "employee,contact,tax_rate" + | "employee,project" + | "employee,project,company" + | "employee,project,company,contact" + | "employee,project,company,contact,tax_rate" + | "employee,project,company,tax_rate" + | "employee,project,contact" + | "employee,project,contact,tax_rate" + | "employee,project,tax_rate" + | "employee,tax_rate" + | "project" + | "project,company" + | "project,company,contact" + | "project,company,contact,tax_rate" + | "project,company,tax_rate" + | "project,contact" + | "project,contact,tax_rate" + | "project,tax_rate" + | "tax_rate"; +export const ExpenseReportsLinesListRequestExpand = { + Account: "account", + AccountCompany: "account,company", + AccountCompanyContact: "account,company,contact", + AccountCompanyContactTaxRate: "account,company,contact,tax_rate", + AccountCompanyTaxRate: "account,company,tax_rate", + AccountContact: "account,contact", + AccountContactTaxRate: "account,contact,tax_rate", + AccountEmployee: "account,employee", + AccountEmployeeCompany: "account,employee,company", + AccountEmployeeCompanyContact: "account,employee,company,contact", + AccountEmployeeCompanyContactTaxRate: "account,employee,company,contact,tax_rate", + AccountEmployeeCompanyTaxRate: "account,employee,company,tax_rate", + AccountEmployeeContact: "account,employee,contact", + AccountEmployeeContactTaxRate: "account,employee,contact,tax_rate", + AccountEmployeeProject: "account,employee,project", + AccountEmployeeProjectCompany: "account,employee,project,company", + AccountEmployeeProjectCompanyContact: "account,employee,project,company,contact", + AccountEmployeeProjectCompanyContactTaxRate: "account,employee,project,company,contact,tax_rate", + AccountEmployeeProjectCompanyTaxRate: "account,employee,project,company,tax_rate", + AccountEmployeeProjectContact: "account,employee,project,contact", + AccountEmployeeProjectContactTaxRate: "account,employee,project,contact,tax_rate", + AccountEmployeeProjectTaxRate: "account,employee,project,tax_rate", + AccountEmployeeTaxRate: "account,employee,tax_rate", + AccountProject: "account,project", + AccountProjectCompany: "account,project,company", + AccountProjectCompanyContact: "account,project,company,contact", + AccountProjectCompanyContactTaxRate: "account,project,company,contact,tax_rate", + AccountProjectCompanyTaxRate: "account,project,company,tax_rate", + AccountProjectContact: "account,project,contact", + AccountProjectContactTaxRate: "account,project,contact,tax_rate", + AccountProjectTaxRate: "account,project,tax_rate", + AccountTaxRate: "account,tax_rate", + Company: "company", + CompanyContact: "company,contact", + CompanyContactTaxRate: "company,contact,tax_rate", + CompanyTaxRate: "company,tax_rate", + Contact: "contact", + ContactTaxRate: "contact,tax_rate", + Employee: "employee", + EmployeeCompany: "employee,company", + EmployeeCompanyContact: "employee,company,contact", + EmployeeCompanyContactTaxRate: "employee,company,contact,tax_rate", + EmployeeCompanyTaxRate: "employee,company,tax_rate", + EmployeeContact: "employee,contact", + EmployeeContactTaxRate: "employee,contact,tax_rate", + EmployeeProject: "employee,project", + EmployeeProjectCompany: "employee,project,company", + EmployeeProjectCompanyContact: "employee,project,company,contact", + EmployeeProjectCompanyContactTaxRate: "employee,project,company,contact,tax_rate", + EmployeeProjectCompanyTaxRate: "employee,project,company,tax_rate", + EmployeeProjectContact: "employee,project,contact", + EmployeeProjectContactTaxRate: "employee,project,contact,tax_rate", + EmployeeProjectTaxRate: "employee,project,tax_rate", + EmployeeTaxRate: "employee,tax_rate", + Project: "project", + ProjectCompany: "project,company", + ProjectCompanyContact: "project,company,contact", + ProjectCompanyContactTaxRate: "project,company,contact,tax_rate", + ProjectCompanyTaxRate: "project,company,tax_rate", + ProjectContact: "project,contact", + ProjectContactTaxRate: "project,contact,tax_rate", + ProjectTaxRate: "project,tax_rate", + TaxRate: "tax_rate", +} as const; diff --git a/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts b/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts new file mode 100644 index 000000000..d916e2668 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type ExpenseReportsListRequestExpand = + | "accounting_period" + | "accounting_period,company" + | "company" + | "employee" + | "employee,accounting_period" + | "employee,accounting_period,company" + | "employee,company" + | "lines" + | "lines,accounting_period" + | "lines,accounting_period,company" + | "lines,company" + | "lines,employee" + | "lines,employee,accounting_period" + | "lines,employee,accounting_period,company" + | "lines,employee,company"; +export const ExpenseReportsListRequestExpand = { + AccountingPeriod: "accounting_period", + AccountingPeriodCompany: "accounting_period,company", + Company: "company", + Employee: "employee", + EmployeeAccountingPeriod: "employee,accounting_period", + EmployeeAccountingPeriodCompany: "employee,accounting_period,company", + EmployeeCompany: "employee,company", + Lines: "lines", + LinesAccountingPeriod: "lines,accounting_period", + LinesAccountingPeriodCompany: "lines,accounting_period,company", + LinesCompany: "lines,company", + LinesEmployee: "lines,employee", + LinesEmployeeAccountingPeriod: "lines,employee,accounting_period", + LinesEmployeeAccountingPeriodCompany: "lines,employee,accounting_period,company", + LinesEmployeeCompany: "lines,employee,company", +} as const; diff --git a/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts b/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts new file mode 100644 index 000000000..4341db383 --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type ExpenseReportsRetrieveRequestExpand = + | "accounting_period" + | "accounting_period,company" + | "company" + | "employee" + | "employee,accounting_period" + | "employee,accounting_period,company" + | "employee,company" + | "lines" + | "lines,accounting_period" + | "lines,accounting_period,company" + | "lines,company" + | "lines,employee" + | "lines,employee,accounting_period" + | "lines,employee,accounting_period,company" + | "lines,employee,company"; +export const ExpenseReportsRetrieveRequestExpand = { + AccountingPeriod: "accounting_period", + AccountingPeriodCompany: "accounting_period,company", + Company: "company", + Employee: "employee", + EmployeeAccountingPeriod: "employee,accounting_period", + EmployeeAccountingPeriodCompany: "employee,accounting_period,company", + EmployeeCompany: "employee,company", + Lines: "lines", + LinesAccountingPeriod: "lines,accounting_period", + LinesAccountingPeriodCompany: "lines,accounting_period,company", + LinesCompany: "lines,company", + LinesEmployee: "lines,employee", + LinesEmployeeAccountingPeriod: "lines,employee,accounting_period", + LinesEmployeeAccountingPeriodCompany: "lines,employee,accounting_period,company", + LinesEmployeeCompany: "lines,employee,company", +} as const; diff --git a/src/api/resources/accounting/resources/expenseReports/types/index.ts b/src/api/resources/accounting/resources/expenseReports/types/index.ts new file mode 100644 index 000000000..a338ac04a --- /dev/null +++ b/src/api/resources/accounting/resources/expenseReports/types/index.ts @@ -0,0 +1,3 @@ +export * from "./ExpenseReportsListRequestExpand"; +export * from "./ExpenseReportsLinesListRequestExpand"; +export * from "./ExpenseReportsRetrieveRequestExpand"; diff --git a/src/api/resources/accounting/resources/index.ts b/src/api/resources/accounting/resources/index.ts index 20fb035e2..7b18ca161 100644 --- a/src/api/resources/accounting/resources/index.ts +++ b/src/api/resources/accounting/resources/index.ts @@ -8,6 +8,8 @@ export * as contacts from "./contacts"; export * from "./contacts/types"; export * as creditNotes from "./creditNotes"; export * from "./creditNotes/types"; +export * as expenseReports from "./expenseReports"; +export * from "./expenseReports/types"; export * as expenses from "./expenses"; export * from "./expenses/types"; export * as generalLedgerTransactions from "./generalLedgerTransactions"; @@ -76,6 +78,7 @@ export * from "./contacts/client/requests"; export * from "./creditNotes/client/requests"; export * from "./scopes/client/requests"; export * from "./employees/client/requests"; +export * from "./expenseReports/client/requests"; export * from "./expenses/client/requests"; export * from "./fieldMapping/client/requests"; export * from "./generalLedgerTransactions/client/requests"; diff --git a/src/api/resources/accounting/types/ExpenseReport.ts b/src/api/resources/accounting/types/ExpenseReport.ts new file mode 100644 index 000000000..0c414df81 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReport.ts @@ -0,0 +1,366 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * # The ExpenseReport Object + * ### Description + * The `ExpenseReport` object represents a collection of expenses submitted for review and reimbursement. + * It includes details about the submitter, status, amounts, and associated metadata. + * + * ### Usage Example + * Fetch from the `GET ExpenseReport` endpoint to view details of expense reports and their line items. + */ +export interface ExpenseReport { + id?: string; + /** The third-party API ID of the matching object. */ + remoteId?: string; + /** The datetime that this object was created by Merge. */ + createdAt?: Date; + /** The datetime that this object was modified by Merge. */ + modifiedAt?: Date; + /** The date of the expense report. */ + reportDate?: Date; + /** Human-readable expense report identifier. */ + reportIdentifier?: string; + /** Identifier for the employee who submitted or is associated with the expense report */ + employee?: string; + /** + * Overall status of the expense report. One of DRAFT, SUBMITTED, APPROVED, REJECTED + * + * * `DRAFT` - DRAFT + * * `SUBMITTED` - SUBMITTED + * * `APPROVED` - APPROVED + * * `REJECTED` - REJECTED + */ + status?: Merge.accounting.ExpenseReportStatus; + /** Total amount of the expense report */ + totalAmount?: number; + lines?: Merge.accounting.ExpenseReportLine[]; + /** + * Currency code for the expense report + * + * * `XUA` - ADB Unit of Account + * * `AFN` - Afghan Afghani + * * `AFA` - Afghan Afghani (1927–2002) + * * `ALL` - Albanian Lek + * * `ALK` - Albanian Lek (1946–1965) + * * `DZD` - Algerian Dinar + * * `ADP` - Andorran Peseta + * * `AOA` - Angolan Kwanza + * * `AOK` - Angolan Kwanza (1977–1991) + * * `AON` - Angolan New Kwanza (1990–2000) + * * `AOR` - Angolan Readjusted Kwanza (1995–1999) + * * `ARA` - Argentine Austral + * * `ARS` - Argentine Peso + * * `ARM` - Argentine Peso (1881–1970) + * * `ARP` - Argentine Peso (1983–1985) + * * `ARL` - Argentine Peso Ley (1970–1983) + * * `AMD` - Armenian Dram + * * `AWG` - Aruban Florin + * * `AUD` - Australian Dollar + * * `ATS` - Austrian Schilling + * * `AZN` - Azerbaijani Manat + * * `AZM` - Azerbaijani Manat (1993–2006) + * * `BSD` - Bahamian Dollar + * * `BHD` - Bahraini Dinar + * * `BDT` - Bangladeshi Taka + * * `BBD` - Barbadian Dollar + * * `BYN` - Belarusian Ruble + * * `BYB` - Belarusian Ruble (1994–1999) + * * `BYR` - Belarusian Ruble (2000–2016) + * * `BEF` - Belgian Franc + * * `BEC` - Belgian Franc (convertible) + * * `BEL` - Belgian Franc (financial) + * * `BZD` - Belize Dollar + * * `BMD` - Bermudan Dollar + * * `BTN` - Bhutanese Ngultrum + * * `BOB` - Bolivian Boliviano + * * `BOL` - Bolivian Boliviano (1863–1963) + * * `BOV` - Bolivian Mvdol + * * `BOP` - Bolivian Peso + * * `BAM` - Bosnia-Herzegovina Convertible Mark + * * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + * * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + * * `BWP` - Botswanan Pula + * * `BRC` - Brazilian Cruzado (1986–1989) + * * `BRZ` - Brazilian Cruzeiro (1942–1967) + * * `BRE` - Brazilian Cruzeiro (1990–1993) + * * `BRR` - Brazilian Cruzeiro (1993–1994) + * * `BRN` - Brazilian New Cruzado (1989–1990) + * * `BRB` - Brazilian New Cruzeiro (1967–1986) + * * `BRL` - Brazilian Real + * * `GBP` - British Pound + * * `BND` - Brunei Dollar + * * `BGL` - Bulgarian Hard Lev + * * `BGN` - Bulgarian Lev + * * `BGO` - Bulgarian Lev (1879–1952) + * * `BGM` - Bulgarian Socialist Lev + * * `BUK` - Burmese Kyat + * * `BIF` - Burundian Franc + * * `XPF` - CFP Franc + * * `KHR` - Cambodian Riel + * * `CAD` - Canadian Dollar + * * `CVE` - Cape Verdean Escudo + * * `KYD` - Cayman Islands Dollar + * * `XAF` - Central African CFA Franc + * * `CLE` - Chilean Escudo + * * `CLP` - Chilean Peso + * * `CLF` - Chilean Unit of Account (UF) + * * `CNX` - Chinese People’s Bank Dollar + * * `CNY` - Chinese Yuan + * * `CNH` - Chinese Yuan (offshore) + * * `COP` - Colombian Peso + * * `COU` - Colombian Real Value Unit + * * `KMF` - Comorian Franc + * * `CDF` - Congolese Franc + * * `CRC` - Costa Rican Colón + * * `HRD` - Croatian Dinar + * * `HRK` - Croatian Kuna + * * `CUC` - Cuban Convertible Peso + * * `CUP` - Cuban Peso + * * `CYP` - Cypriot Pound + * * `CZK` - Czech Koruna + * * `CSK` - Czechoslovak Hard Koruna + * * `DKK` - Danish Krone + * * `DJF` - Djiboutian Franc + * * `DOP` - Dominican Peso + * * `NLG` - Dutch Guilder + * * `XCD` - East Caribbean Dollar + * * `DDM` - East German Mark + * * `ECS` - Ecuadorian Sucre + * * `ECV` - Ecuadorian Unit of Constant Value + * * `EGP` - Egyptian Pound + * * `GQE` - Equatorial Guinean Ekwele + * * `ERN` - Eritrean Nakfa + * * `EEK` - Estonian Kroon + * * `ETB` - Ethiopian Birr + * * `EUR` - Euro + * * `XBA` - European Composite Unit + * * `XEU` - European Currency Unit + * * `XBB` - European Monetary Unit + * * `XBC` - European Unit of Account (XBC) + * * `XBD` - European Unit of Account (XBD) + * * `FKP` - Falkland Islands Pound + * * `FJD` - Fijian Dollar + * * `FIM` - Finnish Markka + * * `FRF` - French Franc + * * `XFO` - French Gold Franc + * * `XFU` - French UIC-Franc + * * `GMD` - Gambian Dalasi + * * `GEK` - Georgian Kupon Larit + * * `GEL` - Georgian Lari + * * `DEM` - German Mark + * * `GHS` - Ghanaian Cedi + * * `GHC` - Ghanaian Cedi (1979–2007) + * * `GIP` - Gibraltar Pound + * * `XAU` - Gold + * * `GRD` - Greek Drachma + * * `GTQ` - Guatemalan Quetzal + * * `GWP` - Guinea-Bissau Peso + * * `GNF` - Guinean Franc + * * `GNS` - Guinean Syli + * * `GYD` - Guyanaese Dollar + * * `HTG` - Haitian Gourde + * * `HNL` - Honduran Lempira + * * `HKD` - Hong Kong Dollar + * * `HUF` - Hungarian Forint + * * `IMP` - IMP + * * `ISK` - Icelandic Króna + * * `ISJ` - Icelandic Króna (1918–1981) + * * `INR` - Indian Rupee + * * `IDR` - Indonesian Rupiah + * * `IRR` - Iranian Rial + * * `IQD` - Iraqi Dinar + * * `IEP` - Irish Pound + * * `ILS` - Israeli New Shekel + * * `ILP` - Israeli Pound + * * `ILR` - Israeli Shekel (1980–1985) + * * `ITL` - Italian Lira + * * `JMD` - Jamaican Dollar + * * `JPY` - Japanese Yen + * * `JOD` - Jordanian Dinar + * * `KZT` - Kazakhstani Tenge + * * `KES` - Kenyan Shilling + * * `KWD` - Kuwaiti Dinar + * * `KGS` - Kyrgystani Som + * * `LAK` - Laotian Kip + * * `LVL` - Latvian Lats + * * `LVR` - Latvian Ruble + * * `LBP` - Lebanese Pound + * * `LSL` - Lesotho Loti + * * `LRD` - Liberian Dollar + * * `LYD` - Libyan Dinar + * * `LTL` - Lithuanian Litas + * * `LTT` - Lithuanian Talonas + * * `LUL` - Luxembourg Financial Franc + * * `LUC` - Luxembourgian Convertible Franc + * * `LUF` - Luxembourgian Franc + * * `MOP` - Macanese Pataca + * * `MKD` - Macedonian Denar + * * `MKN` - Macedonian Denar (1992–1993) + * * `MGA` - Malagasy Ariary + * * `MGF` - Malagasy Franc + * * `MWK` - Malawian Kwacha + * * `MYR` - Malaysian Ringgit + * * `MVR` - Maldivian Rufiyaa + * * `MVP` - Maldivian Rupee (1947–1981) + * * `MLF` - Malian Franc + * * `MTL` - Maltese Lira + * * `MTP` - Maltese Pound + * * `MRU` - Mauritanian Ouguiya + * * `MRO` - Mauritanian Ouguiya (1973–2017) + * * `MUR` - Mauritian Rupee + * * `MXV` - Mexican Investment Unit + * * `MXN` - Mexican Peso + * * `MXP` - Mexican Silver Peso (1861–1992) + * * `MDC` - Moldovan Cupon + * * `MDL` - Moldovan Leu + * * `MCF` - Monegasque Franc + * * `MNT` - Mongolian Tugrik + * * `MAD` - Moroccan Dirham + * * `MAF` - Moroccan Franc + * * `MZE` - Mozambican Escudo + * * `MZN` - Mozambican Metical + * * `MZM` - Mozambican Metical (1980–2006) + * * `MMK` - Myanmar Kyat + * * `NAD` - Namibian Dollar + * * `NPR` - Nepalese Rupee + * * `ANG` - Netherlands Antillean Guilder + * * `TWD` - New Taiwan Dollar + * * `NZD` - New Zealand Dollar + * * `NIO` - Nicaraguan Córdoba + * * `NIC` - Nicaraguan Córdoba (1988–1991) + * * `NGN` - Nigerian Naira + * * `KPW` - North Korean Won + * * `NOK` - Norwegian Krone + * * `OMR` - Omani Rial + * * `PKR` - Pakistani Rupee + * * `XPD` - Palladium + * * `PAB` - Panamanian Balboa + * * `PGK` - Papua New Guinean Kina + * * `PYG` - Paraguayan Guarani + * * `PEI` - Peruvian Inti + * * `PEN` - Peruvian Sol + * * `PES` - Peruvian Sol (1863–1965) + * * `PHP` - Philippine Peso + * * `XPT` - Platinum + * * `PLN` - Polish Zloty + * * `PLZ` - Polish Zloty (1950–1995) + * * `PTE` - Portuguese Escudo + * * `GWE` - Portuguese Guinea Escudo + * * `QAR` - Qatari Rial + * * `XRE` - RINET Funds + * * `RHD` - Rhodesian Dollar + * * `RON` - Romanian Leu + * * `ROL` - Romanian Leu (1952–2006) + * * `RUB` - Russian Ruble + * * `RUR` - Russian Ruble (1991–1998) + * * `RWF` - Rwandan Franc + * * `SVC` - Salvadoran Colón + * * `WST` - Samoan Tala + * * `SAR` - Saudi Riyal + * * `RSD` - Serbian Dinar + * * `CSD` - Serbian Dinar (2002–2006) + * * `SCR` - Seychellois Rupee + * * `SLL` - Sierra Leonean Leone + * * `XAG` - Silver + * * `SGD` - Singapore Dollar + * * `SKK` - Slovak Koruna + * * `SIT` - Slovenian Tolar + * * `SBD` - Solomon Islands Dollar + * * `SOS` - Somali Shilling + * * `ZAR` - South African Rand + * * `ZAL` - South African Rand (financial) + * * `KRH` - South Korean Hwan (1953–1962) + * * `KRW` - South Korean Won + * * `KRO` - South Korean Won (1945–1953) + * * `SSP` - South Sudanese Pound + * * `SUR` - Soviet Rouble + * * `ESP` - Spanish Peseta + * * `ESA` - Spanish Peseta (A account) + * * `ESB` - Spanish Peseta (convertible account) + * * `XDR` - Special Drawing Rights + * * `LKR` - Sri Lankan Rupee + * * `SHP` - St. Helena Pound + * * `XSU` - Sucre + * * `SDD` - Sudanese Dinar (1992–2007) + * * `SDG` - Sudanese Pound + * * `SDP` - Sudanese Pound (1957–1998) + * * `SRD` - Surinamese Dollar + * * `SRG` - Surinamese Guilder + * * `SZL` - Swazi Lilangeni + * * `SEK` - Swedish Krona + * * `CHF` - Swiss Franc + * * `SYP` - Syrian Pound + * * `STN` - São Tomé & Príncipe Dobra + * * `STD` - São Tomé & Príncipe Dobra (1977–2017) + * * `TVD` - TVD + * * `TJR` - Tajikistani Ruble + * * `TJS` - Tajikistani Somoni + * * `TZS` - Tanzanian Shilling + * * `XTS` - Testing Currency Code + * * `THB` - Thai Baht + * * `XXX` - The codes assigned for transactions where no currency is involved + * * `TPE` - Timorese Escudo + * * `TOP` - Tongan Paʻanga + * * `TTD` - Trinidad & Tobago Dollar + * * `TND` - Tunisian Dinar + * * `TRY` - Turkish Lira + * * `TRL` - Turkish Lira (1922–2005) + * * `TMT` - Turkmenistani Manat + * * `TMM` - Turkmenistani Manat (1993–2009) + * * `USD` - US Dollar + * * `USN` - US Dollar (Next day) + * * `USS` - US Dollar (Same day) + * * `UGX` - Ugandan Shilling + * * `UGS` - Ugandan Shilling (1966–1987) + * * `UAH` - Ukrainian Hryvnia + * * `UAK` - Ukrainian Karbovanets + * * `AED` - United Arab Emirates Dirham + * * `UYW` - Uruguayan Nominal Wage Index Unit + * * `UYU` - Uruguayan Peso + * * `UYP` - Uruguayan Peso (1975–1993) + * * `UYI` - Uruguayan Peso (Indexed Units) + * * `UZS` - Uzbekistani Som + * * `VUV` - Vanuatu Vatu + * * `VES` - Venezuelan Bolívar + * * `VEB` - Venezuelan Bolívar (1871–2008) + * * `VEF` - Venezuelan Bolívar (2008–2018) + * * `VND` - Vietnamese Dong + * * `VNN` - Vietnamese Dong (1978–1985) + * * `CHE` - WIR Euro + * * `CHW` - WIR Franc + * * `XOF` - West African CFA Franc + * * `YDD` - Yemeni Dinar + * * `YER` - Yemeni Rial + * * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + * * `YUD` - Yugoslavian Hard Dinar (1966–1990) + * * `YUM` - Yugoslavian New Dinar (1994–2002) + * * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + * * `ZWN` - ZWN + * * `ZRN` - Zairean New Zaire (1993–1998) + * * `ZRZ` - Zairean Zaire (1971–1993) + * * `ZMW` - Zambian Kwacha + * * `ZMK` - Zambian Kwacha (1968–2012) + * * `ZWD` - Zimbabwean Dollar (1980–2008) + * * `ZWR` - Zimbabwean Dollar (2008) + * * `ZWL` - Zimbabwean Dollar (2009) + */ + currency?: Merge.accounting.TransactionCurrencyEnum; + /** A brief description or purpose for the expense report */ + description?: string; + /** The accounting period the report was posted in */ + accountingPeriod?: string; + /** The subsidiary that the expense report is created in */ + company?: Merge.accounting.ExpenseReportCompany; + /** The related tracking categories associated with the expense report */ + trackingCategories: string[]; + /** Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/). */ + remoteWasDeleted?: boolean; + fieldMappings?: Record; + remoteData?: Merge.accounting.RemoteData[]; + remoteFields?: Merge.accounting.RemoteField[]; +} diff --git a/src/api/resources/accounting/types/ExpenseReportCompany.ts b/src/api/resources/accounting/types/ExpenseReportCompany.ts new file mode 100644 index 000000000..cbd59c95d --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportCompany.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * The subsidiary that the expense report is created in + */ +export type ExpenseReportCompany = string | Merge.accounting.CompanyInfo; diff --git a/src/api/resources/accounting/types/ExpenseReportLine.ts b/src/api/resources/accounting/types/ExpenseReportLine.ts new file mode 100644 index 000000000..bf7c9ebfa --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLine.ts @@ -0,0 +1,368 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * # The ExpenseReportLine Object + * ### Description + * The `ExpenseReportLine` object represents an individual line item within an expense report, containing details about + * a specific expense such as amount, description, and associated metadata. + * + * ### Usage Example + * Fetch from the `GET ExpenseReport` endpoint and expand the lines field to view all line items in the expense report. + */ +export interface ExpenseReportLine { + id?: string; + /** The third-party API ID of the matching object. */ + remoteId?: string; + /** The datetime that this object was created by Merge. */ + createdAt?: Date; + /** The datetime that this object was modified by Merge. */ + modifiedAt?: Date; + account?: Merge.accounting.ExpenseReportLineAccount; + /** Description of the individual expense. */ + description?: string; + /** The date the individual expense was incurred. */ + expenseDate?: Date; + /** The amount of the expense for the line item. */ + amount?: number; + /** + * Currency of the expense line (if different from the report currency). + * + * * `XUA` - ADB Unit of Account + * * `AFN` - Afghan Afghani + * * `AFA` - Afghan Afghani (1927–2002) + * * `ALL` - Albanian Lek + * * `ALK` - Albanian Lek (1946–1965) + * * `DZD` - Algerian Dinar + * * `ADP` - Andorran Peseta + * * `AOA` - Angolan Kwanza + * * `AOK` - Angolan Kwanza (1977–1991) + * * `AON` - Angolan New Kwanza (1990–2000) + * * `AOR` - Angolan Readjusted Kwanza (1995–1999) + * * `ARA` - Argentine Austral + * * `ARS` - Argentine Peso + * * `ARM` - Argentine Peso (1881–1970) + * * `ARP` - Argentine Peso (1983–1985) + * * `ARL` - Argentine Peso Ley (1970–1983) + * * `AMD` - Armenian Dram + * * `AWG` - Aruban Florin + * * `AUD` - Australian Dollar + * * `ATS` - Austrian Schilling + * * `AZN` - Azerbaijani Manat + * * `AZM` - Azerbaijani Manat (1993–2006) + * * `BSD` - Bahamian Dollar + * * `BHD` - Bahraini Dinar + * * `BDT` - Bangladeshi Taka + * * `BBD` - Barbadian Dollar + * * `BYN` - Belarusian Ruble + * * `BYB` - Belarusian Ruble (1994–1999) + * * `BYR` - Belarusian Ruble (2000–2016) + * * `BEF` - Belgian Franc + * * `BEC` - Belgian Franc (convertible) + * * `BEL` - Belgian Franc (financial) + * * `BZD` - Belize Dollar + * * `BMD` - Bermudan Dollar + * * `BTN` - Bhutanese Ngultrum + * * `BOB` - Bolivian Boliviano + * * `BOL` - Bolivian Boliviano (1863–1963) + * * `BOV` - Bolivian Mvdol + * * `BOP` - Bolivian Peso + * * `BAM` - Bosnia-Herzegovina Convertible Mark + * * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + * * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + * * `BWP` - Botswanan Pula + * * `BRC` - Brazilian Cruzado (1986–1989) + * * `BRZ` - Brazilian Cruzeiro (1942–1967) + * * `BRE` - Brazilian Cruzeiro (1990–1993) + * * `BRR` - Brazilian Cruzeiro (1993–1994) + * * `BRN` - Brazilian New Cruzado (1989–1990) + * * `BRB` - Brazilian New Cruzeiro (1967–1986) + * * `BRL` - Brazilian Real + * * `GBP` - British Pound + * * `BND` - Brunei Dollar + * * `BGL` - Bulgarian Hard Lev + * * `BGN` - Bulgarian Lev + * * `BGO` - Bulgarian Lev (1879–1952) + * * `BGM` - Bulgarian Socialist Lev + * * `BUK` - Burmese Kyat + * * `BIF` - Burundian Franc + * * `XPF` - CFP Franc + * * `KHR` - Cambodian Riel + * * `CAD` - Canadian Dollar + * * `CVE` - Cape Verdean Escudo + * * `KYD` - Cayman Islands Dollar + * * `XAF` - Central African CFA Franc + * * `CLE` - Chilean Escudo + * * `CLP` - Chilean Peso + * * `CLF` - Chilean Unit of Account (UF) + * * `CNX` - Chinese People’s Bank Dollar + * * `CNY` - Chinese Yuan + * * `CNH` - Chinese Yuan (offshore) + * * `COP` - Colombian Peso + * * `COU` - Colombian Real Value Unit + * * `KMF` - Comorian Franc + * * `CDF` - Congolese Franc + * * `CRC` - Costa Rican Colón + * * `HRD` - Croatian Dinar + * * `HRK` - Croatian Kuna + * * `CUC` - Cuban Convertible Peso + * * `CUP` - Cuban Peso + * * `CYP` - Cypriot Pound + * * `CZK` - Czech Koruna + * * `CSK` - Czechoslovak Hard Koruna + * * `DKK` - Danish Krone + * * `DJF` - Djiboutian Franc + * * `DOP` - Dominican Peso + * * `NLG` - Dutch Guilder + * * `XCD` - East Caribbean Dollar + * * `DDM` - East German Mark + * * `ECS` - Ecuadorian Sucre + * * `ECV` - Ecuadorian Unit of Constant Value + * * `EGP` - Egyptian Pound + * * `GQE` - Equatorial Guinean Ekwele + * * `ERN` - Eritrean Nakfa + * * `EEK` - Estonian Kroon + * * `ETB` - Ethiopian Birr + * * `EUR` - Euro + * * `XBA` - European Composite Unit + * * `XEU` - European Currency Unit + * * `XBB` - European Monetary Unit + * * `XBC` - European Unit of Account (XBC) + * * `XBD` - European Unit of Account (XBD) + * * `FKP` - Falkland Islands Pound + * * `FJD` - Fijian Dollar + * * `FIM` - Finnish Markka + * * `FRF` - French Franc + * * `XFO` - French Gold Franc + * * `XFU` - French UIC-Franc + * * `GMD` - Gambian Dalasi + * * `GEK` - Georgian Kupon Larit + * * `GEL` - Georgian Lari + * * `DEM` - German Mark + * * `GHS` - Ghanaian Cedi + * * `GHC` - Ghanaian Cedi (1979–2007) + * * `GIP` - Gibraltar Pound + * * `XAU` - Gold + * * `GRD` - Greek Drachma + * * `GTQ` - Guatemalan Quetzal + * * `GWP` - Guinea-Bissau Peso + * * `GNF` - Guinean Franc + * * `GNS` - Guinean Syli + * * `GYD` - Guyanaese Dollar + * * `HTG` - Haitian Gourde + * * `HNL` - Honduran Lempira + * * `HKD` - Hong Kong Dollar + * * `HUF` - Hungarian Forint + * * `IMP` - IMP + * * `ISK` - Icelandic Króna + * * `ISJ` - Icelandic Króna (1918–1981) + * * `INR` - Indian Rupee + * * `IDR` - Indonesian Rupiah + * * `IRR` - Iranian Rial + * * `IQD` - Iraqi Dinar + * * `IEP` - Irish Pound + * * `ILS` - Israeli New Shekel + * * `ILP` - Israeli Pound + * * `ILR` - Israeli Shekel (1980–1985) + * * `ITL` - Italian Lira + * * `JMD` - Jamaican Dollar + * * `JPY` - Japanese Yen + * * `JOD` - Jordanian Dinar + * * `KZT` - Kazakhstani Tenge + * * `KES` - Kenyan Shilling + * * `KWD` - Kuwaiti Dinar + * * `KGS` - Kyrgystani Som + * * `LAK` - Laotian Kip + * * `LVL` - Latvian Lats + * * `LVR` - Latvian Ruble + * * `LBP` - Lebanese Pound + * * `LSL` - Lesotho Loti + * * `LRD` - Liberian Dollar + * * `LYD` - Libyan Dinar + * * `LTL` - Lithuanian Litas + * * `LTT` - Lithuanian Talonas + * * `LUL` - Luxembourg Financial Franc + * * `LUC` - Luxembourgian Convertible Franc + * * `LUF` - Luxembourgian Franc + * * `MOP` - Macanese Pataca + * * `MKD` - Macedonian Denar + * * `MKN` - Macedonian Denar (1992–1993) + * * `MGA` - Malagasy Ariary + * * `MGF` - Malagasy Franc + * * `MWK` - Malawian Kwacha + * * `MYR` - Malaysian Ringgit + * * `MVR` - Maldivian Rufiyaa + * * `MVP` - Maldivian Rupee (1947–1981) + * * `MLF` - Malian Franc + * * `MTL` - Maltese Lira + * * `MTP` - Maltese Pound + * * `MRU` - Mauritanian Ouguiya + * * `MRO` - Mauritanian Ouguiya (1973–2017) + * * `MUR` - Mauritian Rupee + * * `MXV` - Mexican Investment Unit + * * `MXN` - Mexican Peso + * * `MXP` - Mexican Silver Peso (1861–1992) + * * `MDC` - Moldovan Cupon + * * `MDL` - Moldovan Leu + * * `MCF` - Monegasque Franc + * * `MNT` - Mongolian Tugrik + * * `MAD` - Moroccan Dirham + * * `MAF` - Moroccan Franc + * * `MZE` - Mozambican Escudo + * * `MZN` - Mozambican Metical + * * `MZM` - Mozambican Metical (1980–2006) + * * `MMK` - Myanmar Kyat + * * `NAD` - Namibian Dollar + * * `NPR` - Nepalese Rupee + * * `ANG` - Netherlands Antillean Guilder + * * `TWD` - New Taiwan Dollar + * * `NZD` - New Zealand Dollar + * * `NIO` - Nicaraguan Córdoba + * * `NIC` - Nicaraguan Córdoba (1988–1991) + * * `NGN` - Nigerian Naira + * * `KPW` - North Korean Won + * * `NOK` - Norwegian Krone + * * `OMR` - Omani Rial + * * `PKR` - Pakistani Rupee + * * `XPD` - Palladium + * * `PAB` - Panamanian Balboa + * * `PGK` - Papua New Guinean Kina + * * `PYG` - Paraguayan Guarani + * * `PEI` - Peruvian Inti + * * `PEN` - Peruvian Sol + * * `PES` - Peruvian Sol (1863–1965) + * * `PHP` - Philippine Peso + * * `XPT` - Platinum + * * `PLN` - Polish Zloty + * * `PLZ` - Polish Zloty (1950–1995) + * * `PTE` - Portuguese Escudo + * * `GWE` - Portuguese Guinea Escudo + * * `QAR` - Qatari Rial + * * `XRE` - RINET Funds + * * `RHD` - Rhodesian Dollar + * * `RON` - Romanian Leu + * * `ROL` - Romanian Leu (1952–2006) + * * `RUB` - Russian Ruble + * * `RUR` - Russian Ruble (1991–1998) + * * `RWF` - Rwandan Franc + * * `SVC` - Salvadoran Colón + * * `WST` - Samoan Tala + * * `SAR` - Saudi Riyal + * * `RSD` - Serbian Dinar + * * `CSD` - Serbian Dinar (2002–2006) + * * `SCR` - Seychellois Rupee + * * `SLL` - Sierra Leonean Leone + * * `XAG` - Silver + * * `SGD` - Singapore Dollar + * * `SKK` - Slovak Koruna + * * `SIT` - Slovenian Tolar + * * `SBD` - Solomon Islands Dollar + * * `SOS` - Somali Shilling + * * `ZAR` - South African Rand + * * `ZAL` - South African Rand (financial) + * * `KRH` - South Korean Hwan (1953–1962) + * * `KRW` - South Korean Won + * * `KRO` - South Korean Won (1945–1953) + * * `SSP` - South Sudanese Pound + * * `SUR` - Soviet Rouble + * * `ESP` - Spanish Peseta + * * `ESA` - Spanish Peseta (A account) + * * `ESB` - Spanish Peseta (convertible account) + * * `XDR` - Special Drawing Rights + * * `LKR` - Sri Lankan Rupee + * * `SHP` - St. Helena Pound + * * `XSU` - Sucre + * * `SDD` - Sudanese Dinar (1992–2007) + * * `SDG` - Sudanese Pound + * * `SDP` - Sudanese Pound (1957–1998) + * * `SRD` - Surinamese Dollar + * * `SRG` - Surinamese Guilder + * * `SZL` - Swazi Lilangeni + * * `SEK` - Swedish Krona + * * `CHF` - Swiss Franc + * * `SYP` - Syrian Pound + * * `STN` - São Tomé & Príncipe Dobra + * * `STD` - São Tomé & Príncipe Dobra (1977–2017) + * * `TVD` - TVD + * * `TJR` - Tajikistani Ruble + * * `TJS` - Tajikistani Somoni + * * `TZS` - Tanzanian Shilling + * * `XTS` - Testing Currency Code + * * `THB` - Thai Baht + * * `XXX` - The codes assigned for transactions where no currency is involved + * * `TPE` - Timorese Escudo + * * `TOP` - Tongan Paʻanga + * * `TTD` - Trinidad & Tobago Dollar + * * `TND` - Tunisian Dinar + * * `TRY` - Turkish Lira + * * `TRL` - Turkish Lira (1922–2005) + * * `TMT` - Turkmenistani Manat + * * `TMM` - Turkmenistani Manat (1993–2009) + * * `USD` - US Dollar + * * `USN` - US Dollar (Next day) + * * `USS` - US Dollar (Same day) + * * `UGX` - Ugandan Shilling + * * `UGS` - Ugandan Shilling (1966–1987) + * * `UAH` - Ukrainian Hryvnia + * * `UAK` - Ukrainian Karbovanets + * * `AED` - United Arab Emirates Dirham + * * `UYW` - Uruguayan Nominal Wage Index Unit + * * `UYU` - Uruguayan Peso + * * `UYP` - Uruguayan Peso (1975–1993) + * * `UYI` - Uruguayan Peso (Indexed Units) + * * `UZS` - Uzbekistani Som + * * `VUV` - Vanuatu Vatu + * * `VES` - Venezuelan Bolívar + * * `VEB` - Venezuelan Bolívar (1871–2008) + * * `VEF` - Venezuelan Bolívar (2008–2018) + * * `VND` - Vietnamese Dong + * * `VNN` - Vietnamese Dong (1978–1985) + * * `CHE` - WIR Euro + * * `CHW` - WIR Franc + * * `XOF` - West African CFA Franc + * * `YDD` - Yemeni Dinar + * * `YER` - Yemeni Rial + * * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + * * `YUD` - Yugoslavian Hard Dinar (1966–1990) + * * `YUM` - Yugoslavian New Dinar (1994–2002) + * * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + * * `ZWN` - ZWN + * * `ZRN` - Zairean New Zaire (1993–1998) + * * `ZRZ` - Zairean Zaire (1971–1993) + * * `ZMW` - Zambian Kwacha + * * `ZMK` - Zambian Kwacha (1968–2012) + * * `ZWD` - Zimbabwean Dollar (1980–2008) + * * `ZWR` - Zimbabwean Dollar (2008) + * * `ZWL` - Zimbabwean Dollar (2009) + */ + currency?: Merge.accounting.TransactionCurrencyEnum; + /** Exchange rate used if the line item is in a foreign currency. */ + exchangeRate?: string; + /** Whether the expense line is billable to a client or project. */ + isBillable?: boolean; + /** The related tracking categories associated with the expense report (Department, Location, Class, Expense Category) */ + trackingCategories: string[]; + /** Identifier for the employee who submitted or is associated with the expense report */ + employee?: Merge.accounting.ExpenseReportLineEmployee; + project?: Merge.accounting.ExpenseReportLineProject; + /** The subsidiary that the expense report is created in */ + company?: Merge.accounting.ExpenseReportLineCompany; + contact?: Merge.accounting.ExpenseReportLineContact; + /** Quantity for the expense line (e.g., miles driven, items purchased). */ + quantity?: number; + /** Price per unit for the expense line (if applicable). */ + unitPrice?: number; + /** Whether the expense line is non-reimbursable (e.g., paid via company card). */ + nonReimbursable?: boolean; + /** Tax amount applicable for the line item. */ + taxAmount?: number; + /** Whether the amount is inclusive of tax. */ + inclusiveOfTax?: boolean; + taxRate?: Merge.accounting.ExpenseReportLineTaxRate; + /** Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/). */ + remoteWasDeleted?: boolean; + remoteFields?: Merge.accounting.RemoteField[]; +} diff --git a/src/api/resources/accounting/types/ExpenseReportLineAccount.ts b/src/api/resources/accounting/types/ExpenseReportLineAccount.ts new file mode 100644 index 000000000..df43f1721 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineAccount.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineAccount = string | Merge.accounting.Account; diff --git a/src/api/resources/accounting/types/ExpenseReportLineCompany.ts b/src/api/resources/accounting/types/ExpenseReportLineCompany.ts new file mode 100644 index 000000000..1a42d5572 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineCompany.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * The subsidiary that the expense report is created in + */ +export type ExpenseReportLineCompany = string | Merge.accounting.CompanyInfo; diff --git a/src/api/resources/accounting/types/ExpenseReportLineContact.ts b/src/api/resources/accounting/types/ExpenseReportLineContact.ts new file mode 100644 index 000000000..3fec4d451 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineContact.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineContact = string | Merge.accounting.Contact; diff --git a/src/api/resources/accounting/types/ExpenseReportLineEmployee.ts b/src/api/resources/accounting/types/ExpenseReportLineEmployee.ts new file mode 100644 index 000000000..dfdbe9cf1 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineEmployee.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * Identifier for the employee who submitted or is associated with the expense report + */ +export type ExpenseReportLineEmployee = string | Merge.accounting.Employee; diff --git a/src/api/resources/accounting/types/ExpenseReportLineProject.ts b/src/api/resources/accounting/types/ExpenseReportLineProject.ts new file mode 100644 index 000000000..371c131ca --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineProject.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineProject = string | Merge.accounting.Project; diff --git a/src/api/resources/accounting/types/ExpenseReportLineRequest.ts b/src/api/resources/accounting/types/ExpenseReportLineRequest.ts new file mode 100644 index 000000000..6c16e0fd6 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineRequest.ts @@ -0,0 +1,363 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * # The ExpenseReportLine Object + * ### Description + * The `ExpenseReportLine` object represents an individual line item within an expense report, containing details about + * a specific expense such as amount, description, and associated metadata. + * + * ### Usage Example + * Fetch from the `GET ExpenseReport` endpoint and expand the lines field to view all line items in the expense report. + */ +export interface ExpenseReportLineRequest { + /** The third-party API ID of the matching object. */ + remoteId?: string; + account?: Merge.accounting.ExpenseReportLineRequestAccount; + /** Description of the individual expense. */ + description?: string; + /** The date the individual expense was incurred. */ + expenseDate?: Date; + /** The amount of the expense for the line item. */ + amount?: number; + /** + * Currency of the expense line (if different from the report currency). + * + * * `XUA` - ADB Unit of Account + * * `AFN` - Afghan Afghani + * * `AFA` - Afghan Afghani (1927–2002) + * * `ALL` - Albanian Lek + * * `ALK` - Albanian Lek (1946–1965) + * * `DZD` - Algerian Dinar + * * `ADP` - Andorran Peseta + * * `AOA` - Angolan Kwanza + * * `AOK` - Angolan Kwanza (1977–1991) + * * `AON` - Angolan New Kwanza (1990–2000) + * * `AOR` - Angolan Readjusted Kwanza (1995–1999) + * * `ARA` - Argentine Austral + * * `ARS` - Argentine Peso + * * `ARM` - Argentine Peso (1881–1970) + * * `ARP` - Argentine Peso (1983–1985) + * * `ARL` - Argentine Peso Ley (1970–1983) + * * `AMD` - Armenian Dram + * * `AWG` - Aruban Florin + * * `AUD` - Australian Dollar + * * `ATS` - Austrian Schilling + * * `AZN` - Azerbaijani Manat + * * `AZM` - Azerbaijani Manat (1993–2006) + * * `BSD` - Bahamian Dollar + * * `BHD` - Bahraini Dinar + * * `BDT` - Bangladeshi Taka + * * `BBD` - Barbadian Dollar + * * `BYN` - Belarusian Ruble + * * `BYB` - Belarusian Ruble (1994–1999) + * * `BYR` - Belarusian Ruble (2000–2016) + * * `BEF` - Belgian Franc + * * `BEC` - Belgian Franc (convertible) + * * `BEL` - Belgian Franc (financial) + * * `BZD` - Belize Dollar + * * `BMD` - Bermudan Dollar + * * `BTN` - Bhutanese Ngultrum + * * `BOB` - Bolivian Boliviano + * * `BOL` - Bolivian Boliviano (1863–1963) + * * `BOV` - Bolivian Mvdol + * * `BOP` - Bolivian Peso + * * `BAM` - Bosnia-Herzegovina Convertible Mark + * * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + * * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + * * `BWP` - Botswanan Pula + * * `BRC` - Brazilian Cruzado (1986–1989) + * * `BRZ` - Brazilian Cruzeiro (1942–1967) + * * `BRE` - Brazilian Cruzeiro (1990–1993) + * * `BRR` - Brazilian Cruzeiro (1993–1994) + * * `BRN` - Brazilian New Cruzado (1989–1990) + * * `BRB` - Brazilian New Cruzeiro (1967–1986) + * * `BRL` - Brazilian Real + * * `GBP` - British Pound + * * `BND` - Brunei Dollar + * * `BGL` - Bulgarian Hard Lev + * * `BGN` - Bulgarian Lev + * * `BGO` - Bulgarian Lev (1879–1952) + * * `BGM` - Bulgarian Socialist Lev + * * `BUK` - Burmese Kyat + * * `BIF` - Burundian Franc + * * `XPF` - CFP Franc + * * `KHR` - Cambodian Riel + * * `CAD` - Canadian Dollar + * * `CVE` - Cape Verdean Escudo + * * `KYD` - Cayman Islands Dollar + * * `XAF` - Central African CFA Franc + * * `CLE` - Chilean Escudo + * * `CLP` - Chilean Peso + * * `CLF` - Chilean Unit of Account (UF) + * * `CNX` - Chinese People’s Bank Dollar + * * `CNY` - Chinese Yuan + * * `CNH` - Chinese Yuan (offshore) + * * `COP` - Colombian Peso + * * `COU` - Colombian Real Value Unit + * * `KMF` - Comorian Franc + * * `CDF` - Congolese Franc + * * `CRC` - Costa Rican Colón + * * `HRD` - Croatian Dinar + * * `HRK` - Croatian Kuna + * * `CUC` - Cuban Convertible Peso + * * `CUP` - Cuban Peso + * * `CYP` - Cypriot Pound + * * `CZK` - Czech Koruna + * * `CSK` - Czechoslovak Hard Koruna + * * `DKK` - Danish Krone + * * `DJF` - Djiboutian Franc + * * `DOP` - Dominican Peso + * * `NLG` - Dutch Guilder + * * `XCD` - East Caribbean Dollar + * * `DDM` - East German Mark + * * `ECS` - Ecuadorian Sucre + * * `ECV` - Ecuadorian Unit of Constant Value + * * `EGP` - Egyptian Pound + * * `GQE` - Equatorial Guinean Ekwele + * * `ERN` - Eritrean Nakfa + * * `EEK` - Estonian Kroon + * * `ETB` - Ethiopian Birr + * * `EUR` - Euro + * * `XBA` - European Composite Unit + * * `XEU` - European Currency Unit + * * `XBB` - European Monetary Unit + * * `XBC` - European Unit of Account (XBC) + * * `XBD` - European Unit of Account (XBD) + * * `FKP` - Falkland Islands Pound + * * `FJD` - Fijian Dollar + * * `FIM` - Finnish Markka + * * `FRF` - French Franc + * * `XFO` - French Gold Franc + * * `XFU` - French UIC-Franc + * * `GMD` - Gambian Dalasi + * * `GEK` - Georgian Kupon Larit + * * `GEL` - Georgian Lari + * * `DEM` - German Mark + * * `GHS` - Ghanaian Cedi + * * `GHC` - Ghanaian Cedi (1979–2007) + * * `GIP` - Gibraltar Pound + * * `XAU` - Gold + * * `GRD` - Greek Drachma + * * `GTQ` - Guatemalan Quetzal + * * `GWP` - Guinea-Bissau Peso + * * `GNF` - Guinean Franc + * * `GNS` - Guinean Syli + * * `GYD` - Guyanaese Dollar + * * `HTG` - Haitian Gourde + * * `HNL` - Honduran Lempira + * * `HKD` - Hong Kong Dollar + * * `HUF` - Hungarian Forint + * * `IMP` - IMP + * * `ISK` - Icelandic Króna + * * `ISJ` - Icelandic Króna (1918–1981) + * * `INR` - Indian Rupee + * * `IDR` - Indonesian Rupiah + * * `IRR` - Iranian Rial + * * `IQD` - Iraqi Dinar + * * `IEP` - Irish Pound + * * `ILS` - Israeli New Shekel + * * `ILP` - Israeli Pound + * * `ILR` - Israeli Shekel (1980–1985) + * * `ITL` - Italian Lira + * * `JMD` - Jamaican Dollar + * * `JPY` - Japanese Yen + * * `JOD` - Jordanian Dinar + * * `KZT` - Kazakhstani Tenge + * * `KES` - Kenyan Shilling + * * `KWD` - Kuwaiti Dinar + * * `KGS` - Kyrgystani Som + * * `LAK` - Laotian Kip + * * `LVL` - Latvian Lats + * * `LVR` - Latvian Ruble + * * `LBP` - Lebanese Pound + * * `LSL` - Lesotho Loti + * * `LRD` - Liberian Dollar + * * `LYD` - Libyan Dinar + * * `LTL` - Lithuanian Litas + * * `LTT` - Lithuanian Talonas + * * `LUL` - Luxembourg Financial Franc + * * `LUC` - Luxembourgian Convertible Franc + * * `LUF` - Luxembourgian Franc + * * `MOP` - Macanese Pataca + * * `MKD` - Macedonian Denar + * * `MKN` - Macedonian Denar (1992–1993) + * * `MGA` - Malagasy Ariary + * * `MGF` - Malagasy Franc + * * `MWK` - Malawian Kwacha + * * `MYR` - Malaysian Ringgit + * * `MVR` - Maldivian Rufiyaa + * * `MVP` - Maldivian Rupee (1947–1981) + * * `MLF` - Malian Franc + * * `MTL` - Maltese Lira + * * `MTP` - Maltese Pound + * * `MRU` - Mauritanian Ouguiya + * * `MRO` - Mauritanian Ouguiya (1973–2017) + * * `MUR` - Mauritian Rupee + * * `MXV` - Mexican Investment Unit + * * `MXN` - Mexican Peso + * * `MXP` - Mexican Silver Peso (1861–1992) + * * `MDC` - Moldovan Cupon + * * `MDL` - Moldovan Leu + * * `MCF` - Monegasque Franc + * * `MNT` - Mongolian Tugrik + * * `MAD` - Moroccan Dirham + * * `MAF` - Moroccan Franc + * * `MZE` - Mozambican Escudo + * * `MZN` - Mozambican Metical + * * `MZM` - Mozambican Metical (1980–2006) + * * `MMK` - Myanmar Kyat + * * `NAD` - Namibian Dollar + * * `NPR` - Nepalese Rupee + * * `ANG` - Netherlands Antillean Guilder + * * `TWD` - New Taiwan Dollar + * * `NZD` - New Zealand Dollar + * * `NIO` - Nicaraguan Córdoba + * * `NIC` - Nicaraguan Córdoba (1988–1991) + * * `NGN` - Nigerian Naira + * * `KPW` - North Korean Won + * * `NOK` - Norwegian Krone + * * `OMR` - Omani Rial + * * `PKR` - Pakistani Rupee + * * `XPD` - Palladium + * * `PAB` - Panamanian Balboa + * * `PGK` - Papua New Guinean Kina + * * `PYG` - Paraguayan Guarani + * * `PEI` - Peruvian Inti + * * `PEN` - Peruvian Sol + * * `PES` - Peruvian Sol (1863–1965) + * * `PHP` - Philippine Peso + * * `XPT` - Platinum + * * `PLN` - Polish Zloty + * * `PLZ` - Polish Zloty (1950–1995) + * * `PTE` - Portuguese Escudo + * * `GWE` - Portuguese Guinea Escudo + * * `QAR` - Qatari Rial + * * `XRE` - RINET Funds + * * `RHD` - Rhodesian Dollar + * * `RON` - Romanian Leu + * * `ROL` - Romanian Leu (1952–2006) + * * `RUB` - Russian Ruble + * * `RUR` - Russian Ruble (1991–1998) + * * `RWF` - Rwandan Franc + * * `SVC` - Salvadoran Colón + * * `WST` - Samoan Tala + * * `SAR` - Saudi Riyal + * * `RSD` - Serbian Dinar + * * `CSD` - Serbian Dinar (2002–2006) + * * `SCR` - Seychellois Rupee + * * `SLL` - Sierra Leonean Leone + * * `XAG` - Silver + * * `SGD` - Singapore Dollar + * * `SKK` - Slovak Koruna + * * `SIT` - Slovenian Tolar + * * `SBD` - Solomon Islands Dollar + * * `SOS` - Somali Shilling + * * `ZAR` - South African Rand + * * `ZAL` - South African Rand (financial) + * * `KRH` - South Korean Hwan (1953–1962) + * * `KRW` - South Korean Won + * * `KRO` - South Korean Won (1945–1953) + * * `SSP` - South Sudanese Pound + * * `SUR` - Soviet Rouble + * * `ESP` - Spanish Peseta + * * `ESA` - Spanish Peseta (A account) + * * `ESB` - Spanish Peseta (convertible account) + * * `XDR` - Special Drawing Rights + * * `LKR` - Sri Lankan Rupee + * * `SHP` - St. Helena Pound + * * `XSU` - Sucre + * * `SDD` - Sudanese Dinar (1992–2007) + * * `SDG` - Sudanese Pound + * * `SDP` - Sudanese Pound (1957–1998) + * * `SRD` - Surinamese Dollar + * * `SRG` - Surinamese Guilder + * * `SZL` - Swazi Lilangeni + * * `SEK` - Swedish Krona + * * `CHF` - Swiss Franc + * * `SYP` - Syrian Pound + * * `STN` - São Tomé & Príncipe Dobra + * * `STD` - São Tomé & Príncipe Dobra (1977–2017) + * * `TVD` - TVD + * * `TJR` - Tajikistani Ruble + * * `TJS` - Tajikistani Somoni + * * `TZS` - Tanzanian Shilling + * * `XTS` - Testing Currency Code + * * `THB` - Thai Baht + * * `XXX` - The codes assigned for transactions where no currency is involved + * * `TPE` - Timorese Escudo + * * `TOP` - Tongan Paʻanga + * * `TTD` - Trinidad & Tobago Dollar + * * `TND` - Tunisian Dinar + * * `TRY` - Turkish Lira + * * `TRL` - Turkish Lira (1922–2005) + * * `TMT` - Turkmenistani Manat + * * `TMM` - Turkmenistani Manat (1993–2009) + * * `USD` - US Dollar + * * `USN` - US Dollar (Next day) + * * `USS` - US Dollar (Same day) + * * `UGX` - Ugandan Shilling + * * `UGS` - Ugandan Shilling (1966–1987) + * * `UAH` - Ukrainian Hryvnia + * * `UAK` - Ukrainian Karbovanets + * * `AED` - United Arab Emirates Dirham + * * `UYW` - Uruguayan Nominal Wage Index Unit + * * `UYU` - Uruguayan Peso + * * `UYP` - Uruguayan Peso (1975–1993) + * * `UYI` - Uruguayan Peso (Indexed Units) + * * `UZS` - Uzbekistani Som + * * `VUV` - Vanuatu Vatu + * * `VES` - Venezuelan Bolívar + * * `VEB` - Venezuelan Bolívar (1871–2008) + * * `VEF` - Venezuelan Bolívar (2008–2018) + * * `VND` - Vietnamese Dong + * * `VNN` - Vietnamese Dong (1978–1985) + * * `CHE` - WIR Euro + * * `CHW` - WIR Franc + * * `XOF` - West African CFA Franc + * * `YDD` - Yemeni Dinar + * * `YER` - Yemeni Rial + * * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + * * `YUD` - Yugoslavian Hard Dinar (1966–1990) + * * `YUM` - Yugoslavian New Dinar (1994–2002) + * * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + * * `ZWN` - ZWN + * * `ZRN` - Zairean New Zaire (1993–1998) + * * `ZRZ` - Zairean Zaire (1971–1993) + * * `ZMW` - Zambian Kwacha + * * `ZMK` - Zambian Kwacha (1968–2012) + * * `ZWD` - Zimbabwean Dollar (1980–2008) + * * `ZWR` - Zimbabwean Dollar (2008) + * * `ZWL` - Zimbabwean Dollar (2009) + */ + currency?: Merge.accounting.TransactionCurrencyEnum; + /** Exchange rate used if the line item is in a foreign currency. */ + exchangeRate?: string; + /** Whether the expense line is billable to a client or project. */ + isBillable?: boolean; + /** The related tracking categories associated with the expense report (Department, Location, Class, Expense Category) */ + trackingCategories: string[]; + /** Identifier for the employee who submitted or is associated with the expense report */ + employee?: Merge.accounting.ExpenseReportLineRequestEmployee; + project?: Merge.accounting.ExpenseReportLineRequestProject; + /** The subsidiary that the expense report is created in */ + company?: Merge.accounting.ExpenseReportLineRequestCompany; + contact?: Merge.accounting.ExpenseReportLineRequestContact; + /** Quantity for the expense line (e.g., miles driven, items purchased). */ + quantity?: number; + /** Price per unit for the expense line (if applicable). */ + unitPrice?: number; + /** Whether the expense line is non-reimbursable (e.g., paid via company card). */ + nonReimbursable?: boolean; + /** Tax amount applicable for the line item. */ + taxAmount?: number; + /** Whether the amount is inclusive of tax. */ + inclusiveOfTax?: boolean; + taxRate?: Merge.accounting.ExpenseReportLineRequestTaxRate; + integrationParams?: Record; + linkedAccountParams?: Record; + remoteFields?: Merge.accounting.RemoteFieldRequest[]; +} diff --git a/src/api/resources/accounting/types/ExpenseReportLineRequestAccount.ts b/src/api/resources/accounting/types/ExpenseReportLineRequestAccount.ts new file mode 100644 index 000000000..ffd9d642b --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineRequestAccount.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineRequestAccount = string | Merge.accounting.Account; diff --git a/src/api/resources/accounting/types/ExpenseReportLineRequestCompany.ts b/src/api/resources/accounting/types/ExpenseReportLineRequestCompany.ts new file mode 100644 index 000000000..67a21523f --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineRequestCompany.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * The subsidiary that the expense report is created in + */ +export type ExpenseReportLineRequestCompany = string | Merge.accounting.CompanyInfo; diff --git a/src/api/resources/accounting/types/ExpenseReportLineRequestContact.ts b/src/api/resources/accounting/types/ExpenseReportLineRequestContact.ts new file mode 100644 index 000000000..98f3ee597 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineRequestContact.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineRequestContact = string | Merge.accounting.Contact; diff --git a/src/api/resources/accounting/types/ExpenseReportLineRequestEmployee.ts b/src/api/resources/accounting/types/ExpenseReportLineRequestEmployee.ts new file mode 100644 index 000000000..7cd4e07a7 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineRequestEmployee.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * Identifier for the employee who submitted or is associated with the expense report + */ +export type ExpenseReportLineRequestEmployee = string | Merge.accounting.Employee; diff --git a/src/api/resources/accounting/types/ExpenseReportLineRequestProject.ts b/src/api/resources/accounting/types/ExpenseReportLineRequestProject.ts new file mode 100644 index 000000000..bb3bb1f99 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineRequestProject.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineRequestProject = string | Merge.accounting.Project; diff --git a/src/api/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts b/src/api/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts new file mode 100644 index 000000000..3c5d47768 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineRequestTaxRate = string | Merge.accounting.TaxRate; diff --git a/src/api/resources/accounting/types/ExpenseReportLineTaxRate.ts b/src/api/resources/accounting/types/ExpenseReportLineTaxRate.ts new file mode 100644 index 000000000..621eafc8a --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportLineTaxRate.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export type ExpenseReportLineTaxRate = string | Merge.accounting.TaxRate; diff --git a/src/api/resources/accounting/types/ExpenseReportRequest.ts b/src/api/resources/accounting/types/ExpenseReportRequest.ts new file mode 100644 index 000000000..d42f20894 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportRequest.ts @@ -0,0 +1,356 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * # The ExpenseReport Object + * ### Description + * The `ExpenseReport` object represents a collection of expenses submitted for review and reimbursement. + * It includes details about the submitter, status, amounts, and associated metadata. + * + * ### Usage Example + * Fetch from the `GET ExpenseReport` endpoint to view details of expense reports and their line items. + */ +export interface ExpenseReportRequest { + /** The date of the expense report. */ + reportDate?: Date; + /** Human-readable expense report identifier. */ + reportIdentifier?: string; + /** Identifier for the employee who submitted or is associated with the expense report */ + employee?: Merge.accounting.ExpenseReportRequestEmployee; + /** + * Overall status of the expense report. One of DRAFT, SUBMITTED, APPROVED, REJECTED + * + * * `DRAFT` - DRAFT + * * `SUBMITTED` - SUBMITTED + * * `APPROVED` - APPROVED + * * `REJECTED` - REJECTED + */ + status?: Merge.accounting.ExpenseReportStatusEnum; + /** Total amount of the expense report */ + totalAmount?: number; + /** + * Currency code for the expense report + * + * * `XUA` - ADB Unit of Account + * * `AFN` - Afghan Afghani + * * `AFA` - Afghan Afghani (1927–2002) + * * `ALL` - Albanian Lek + * * `ALK` - Albanian Lek (1946–1965) + * * `DZD` - Algerian Dinar + * * `ADP` - Andorran Peseta + * * `AOA` - Angolan Kwanza + * * `AOK` - Angolan Kwanza (1977–1991) + * * `AON` - Angolan New Kwanza (1990–2000) + * * `AOR` - Angolan Readjusted Kwanza (1995–1999) + * * `ARA` - Argentine Austral + * * `ARS` - Argentine Peso + * * `ARM` - Argentine Peso (1881–1970) + * * `ARP` - Argentine Peso (1983–1985) + * * `ARL` - Argentine Peso Ley (1970–1983) + * * `AMD` - Armenian Dram + * * `AWG` - Aruban Florin + * * `AUD` - Australian Dollar + * * `ATS` - Austrian Schilling + * * `AZN` - Azerbaijani Manat + * * `AZM` - Azerbaijani Manat (1993–2006) + * * `BSD` - Bahamian Dollar + * * `BHD` - Bahraini Dinar + * * `BDT` - Bangladeshi Taka + * * `BBD` - Barbadian Dollar + * * `BYN` - Belarusian Ruble + * * `BYB` - Belarusian Ruble (1994–1999) + * * `BYR` - Belarusian Ruble (2000–2016) + * * `BEF` - Belgian Franc + * * `BEC` - Belgian Franc (convertible) + * * `BEL` - Belgian Franc (financial) + * * `BZD` - Belize Dollar + * * `BMD` - Bermudan Dollar + * * `BTN` - Bhutanese Ngultrum + * * `BOB` - Bolivian Boliviano + * * `BOL` - Bolivian Boliviano (1863–1963) + * * `BOV` - Bolivian Mvdol + * * `BOP` - Bolivian Peso + * * `BAM` - Bosnia-Herzegovina Convertible Mark + * * `BAD` - Bosnia-Herzegovina Dinar (1992–1994) + * * `BAN` - Bosnia-Herzegovina New Dinar (1994–1997) + * * `BWP` - Botswanan Pula + * * `BRC` - Brazilian Cruzado (1986–1989) + * * `BRZ` - Brazilian Cruzeiro (1942–1967) + * * `BRE` - Brazilian Cruzeiro (1990–1993) + * * `BRR` - Brazilian Cruzeiro (1993–1994) + * * `BRN` - Brazilian New Cruzado (1989–1990) + * * `BRB` - Brazilian New Cruzeiro (1967–1986) + * * `BRL` - Brazilian Real + * * `GBP` - British Pound + * * `BND` - Brunei Dollar + * * `BGL` - Bulgarian Hard Lev + * * `BGN` - Bulgarian Lev + * * `BGO` - Bulgarian Lev (1879–1952) + * * `BGM` - Bulgarian Socialist Lev + * * `BUK` - Burmese Kyat + * * `BIF` - Burundian Franc + * * `XPF` - CFP Franc + * * `KHR` - Cambodian Riel + * * `CAD` - Canadian Dollar + * * `CVE` - Cape Verdean Escudo + * * `KYD` - Cayman Islands Dollar + * * `XAF` - Central African CFA Franc + * * `CLE` - Chilean Escudo + * * `CLP` - Chilean Peso + * * `CLF` - Chilean Unit of Account (UF) + * * `CNX` - Chinese People’s Bank Dollar + * * `CNY` - Chinese Yuan + * * `CNH` - Chinese Yuan (offshore) + * * `COP` - Colombian Peso + * * `COU` - Colombian Real Value Unit + * * `KMF` - Comorian Franc + * * `CDF` - Congolese Franc + * * `CRC` - Costa Rican Colón + * * `HRD` - Croatian Dinar + * * `HRK` - Croatian Kuna + * * `CUC` - Cuban Convertible Peso + * * `CUP` - Cuban Peso + * * `CYP` - Cypriot Pound + * * `CZK` - Czech Koruna + * * `CSK` - Czechoslovak Hard Koruna + * * `DKK` - Danish Krone + * * `DJF` - Djiboutian Franc + * * `DOP` - Dominican Peso + * * `NLG` - Dutch Guilder + * * `XCD` - East Caribbean Dollar + * * `DDM` - East German Mark + * * `ECS` - Ecuadorian Sucre + * * `ECV` - Ecuadorian Unit of Constant Value + * * `EGP` - Egyptian Pound + * * `GQE` - Equatorial Guinean Ekwele + * * `ERN` - Eritrean Nakfa + * * `EEK` - Estonian Kroon + * * `ETB` - Ethiopian Birr + * * `EUR` - Euro + * * `XBA` - European Composite Unit + * * `XEU` - European Currency Unit + * * `XBB` - European Monetary Unit + * * `XBC` - European Unit of Account (XBC) + * * `XBD` - European Unit of Account (XBD) + * * `FKP` - Falkland Islands Pound + * * `FJD` - Fijian Dollar + * * `FIM` - Finnish Markka + * * `FRF` - French Franc + * * `XFO` - French Gold Franc + * * `XFU` - French UIC-Franc + * * `GMD` - Gambian Dalasi + * * `GEK` - Georgian Kupon Larit + * * `GEL` - Georgian Lari + * * `DEM` - German Mark + * * `GHS` - Ghanaian Cedi + * * `GHC` - Ghanaian Cedi (1979–2007) + * * `GIP` - Gibraltar Pound + * * `XAU` - Gold + * * `GRD` - Greek Drachma + * * `GTQ` - Guatemalan Quetzal + * * `GWP` - Guinea-Bissau Peso + * * `GNF` - Guinean Franc + * * `GNS` - Guinean Syli + * * `GYD` - Guyanaese Dollar + * * `HTG` - Haitian Gourde + * * `HNL` - Honduran Lempira + * * `HKD` - Hong Kong Dollar + * * `HUF` - Hungarian Forint + * * `IMP` - IMP + * * `ISK` - Icelandic Króna + * * `ISJ` - Icelandic Króna (1918–1981) + * * `INR` - Indian Rupee + * * `IDR` - Indonesian Rupiah + * * `IRR` - Iranian Rial + * * `IQD` - Iraqi Dinar + * * `IEP` - Irish Pound + * * `ILS` - Israeli New Shekel + * * `ILP` - Israeli Pound + * * `ILR` - Israeli Shekel (1980–1985) + * * `ITL` - Italian Lira + * * `JMD` - Jamaican Dollar + * * `JPY` - Japanese Yen + * * `JOD` - Jordanian Dinar + * * `KZT` - Kazakhstani Tenge + * * `KES` - Kenyan Shilling + * * `KWD` - Kuwaiti Dinar + * * `KGS` - Kyrgystani Som + * * `LAK` - Laotian Kip + * * `LVL` - Latvian Lats + * * `LVR` - Latvian Ruble + * * `LBP` - Lebanese Pound + * * `LSL` - Lesotho Loti + * * `LRD` - Liberian Dollar + * * `LYD` - Libyan Dinar + * * `LTL` - Lithuanian Litas + * * `LTT` - Lithuanian Talonas + * * `LUL` - Luxembourg Financial Franc + * * `LUC` - Luxembourgian Convertible Franc + * * `LUF` - Luxembourgian Franc + * * `MOP` - Macanese Pataca + * * `MKD` - Macedonian Denar + * * `MKN` - Macedonian Denar (1992–1993) + * * `MGA` - Malagasy Ariary + * * `MGF` - Malagasy Franc + * * `MWK` - Malawian Kwacha + * * `MYR` - Malaysian Ringgit + * * `MVR` - Maldivian Rufiyaa + * * `MVP` - Maldivian Rupee (1947–1981) + * * `MLF` - Malian Franc + * * `MTL` - Maltese Lira + * * `MTP` - Maltese Pound + * * `MRU` - Mauritanian Ouguiya + * * `MRO` - Mauritanian Ouguiya (1973–2017) + * * `MUR` - Mauritian Rupee + * * `MXV` - Mexican Investment Unit + * * `MXN` - Mexican Peso + * * `MXP` - Mexican Silver Peso (1861–1992) + * * `MDC` - Moldovan Cupon + * * `MDL` - Moldovan Leu + * * `MCF` - Monegasque Franc + * * `MNT` - Mongolian Tugrik + * * `MAD` - Moroccan Dirham + * * `MAF` - Moroccan Franc + * * `MZE` - Mozambican Escudo + * * `MZN` - Mozambican Metical + * * `MZM` - Mozambican Metical (1980–2006) + * * `MMK` - Myanmar Kyat + * * `NAD` - Namibian Dollar + * * `NPR` - Nepalese Rupee + * * `ANG` - Netherlands Antillean Guilder + * * `TWD` - New Taiwan Dollar + * * `NZD` - New Zealand Dollar + * * `NIO` - Nicaraguan Córdoba + * * `NIC` - Nicaraguan Córdoba (1988–1991) + * * `NGN` - Nigerian Naira + * * `KPW` - North Korean Won + * * `NOK` - Norwegian Krone + * * `OMR` - Omani Rial + * * `PKR` - Pakistani Rupee + * * `XPD` - Palladium + * * `PAB` - Panamanian Balboa + * * `PGK` - Papua New Guinean Kina + * * `PYG` - Paraguayan Guarani + * * `PEI` - Peruvian Inti + * * `PEN` - Peruvian Sol + * * `PES` - Peruvian Sol (1863–1965) + * * `PHP` - Philippine Peso + * * `XPT` - Platinum + * * `PLN` - Polish Zloty + * * `PLZ` - Polish Zloty (1950–1995) + * * `PTE` - Portuguese Escudo + * * `GWE` - Portuguese Guinea Escudo + * * `QAR` - Qatari Rial + * * `XRE` - RINET Funds + * * `RHD` - Rhodesian Dollar + * * `RON` - Romanian Leu + * * `ROL` - Romanian Leu (1952–2006) + * * `RUB` - Russian Ruble + * * `RUR` - Russian Ruble (1991–1998) + * * `RWF` - Rwandan Franc + * * `SVC` - Salvadoran Colón + * * `WST` - Samoan Tala + * * `SAR` - Saudi Riyal + * * `RSD` - Serbian Dinar + * * `CSD` - Serbian Dinar (2002–2006) + * * `SCR` - Seychellois Rupee + * * `SLL` - Sierra Leonean Leone + * * `XAG` - Silver + * * `SGD` - Singapore Dollar + * * `SKK` - Slovak Koruna + * * `SIT` - Slovenian Tolar + * * `SBD` - Solomon Islands Dollar + * * `SOS` - Somali Shilling + * * `ZAR` - South African Rand + * * `ZAL` - South African Rand (financial) + * * `KRH` - South Korean Hwan (1953–1962) + * * `KRW` - South Korean Won + * * `KRO` - South Korean Won (1945–1953) + * * `SSP` - South Sudanese Pound + * * `SUR` - Soviet Rouble + * * `ESP` - Spanish Peseta + * * `ESA` - Spanish Peseta (A account) + * * `ESB` - Spanish Peseta (convertible account) + * * `XDR` - Special Drawing Rights + * * `LKR` - Sri Lankan Rupee + * * `SHP` - St. Helena Pound + * * `XSU` - Sucre + * * `SDD` - Sudanese Dinar (1992–2007) + * * `SDG` - Sudanese Pound + * * `SDP` - Sudanese Pound (1957–1998) + * * `SRD` - Surinamese Dollar + * * `SRG` - Surinamese Guilder + * * `SZL` - Swazi Lilangeni + * * `SEK` - Swedish Krona + * * `CHF` - Swiss Franc + * * `SYP` - Syrian Pound + * * `STN` - São Tomé & Príncipe Dobra + * * `STD` - São Tomé & Príncipe Dobra (1977–2017) + * * `TVD` - TVD + * * `TJR` - Tajikistani Ruble + * * `TJS` - Tajikistani Somoni + * * `TZS` - Tanzanian Shilling + * * `XTS` - Testing Currency Code + * * `THB` - Thai Baht + * * `XXX` - The codes assigned for transactions where no currency is involved + * * `TPE` - Timorese Escudo + * * `TOP` - Tongan Paʻanga + * * `TTD` - Trinidad & Tobago Dollar + * * `TND` - Tunisian Dinar + * * `TRY` - Turkish Lira + * * `TRL` - Turkish Lira (1922–2005) + * * `TMT` - Turkmenistani Manat + * * `TMM` - Turkmenistani Manat (1993–2009) + * * `USD` - US Dollar + * * `USN` - US Dollar (Next day) + * * `USS` - US Dollar (Same day) + * * `UGX` - Ugandan Shilling + * * `UGS` - Ugandan Shilling (1966–1987) + * * `UAH` - Ukrainian Hryvnia + * * `UAK` - Ukrainian Karbovanets + * * `AED` - United Arab Emirates Dirham + * * `UYW` - Uruguayan Nominal Wage Index Unit + * * `UYU` - Uruguayan Peso + * * `UYP` - Uruguayan Peso (1975–1993) + * * `UYI` - Uruguayan Peso (Indexed Units) + * * `UZS` - Uzbekistani Som + * * `VUV` - Vanuatu Vatu + * * `VES` - Venezuelan Bolívar + * * `VEB` - Venezuelan Bolívar (1871–2008) + * * `VEF` - Venezuelan Bolívar (2008–2018) + * * `VND` - Vietnamese Dong + * * `VNN` - Vietnamese Dong (1978–1985) + * * `CHE` - WIR Euro + * * `CHW` - WIR Franc + * * `XOF` - West African CFA Franc + * * `YDD` - Yemeni Dinar + * * `YER` - Yemeni Rial + * * `YUN` - Yugoslavian Convertible Dinar (1990–1992) + * * `YUD` - Yugoslavian Hard Dinar (1966–1990) + * * `YUM` - Yugoslavian New Dinar (1994–2002) + * * `YUR` - Yugoslavian Reformed Dinar (1992–1993) + * * `ZWN` - ZWN + * * `ZRN` - Zairean New Zaire (1993–1998) + * * `ZRZ` - Zairean Zaire (1971–1993) + * * `ZMW` - Zambian Kwacha + * * `ZMK` - Zambian Kwacha (1968–2012) + * * `ZWD` - Zimbabwean Dollar (1980–2008) + * * `ZWR` - Zimbabwean Dollar (2008) + * * `ZWL` - Zimbabwean Dollar (2009) + */ + currency?: Merge.accounting.TransactionCurrencyEnum; + /** A brief description or purpose for the expense report */ + description?: string; + /** The accounting period the report was posted in */ + accountingPeriod?: Merge.accounting.ExpenseReportRequestAccountingPeriod; + /** The subsidiary that the expense report is created in */ + company?: Merge.accounting.ExpenseReportRequestCompany; + /** The related tracking categories associated with the expense report */ + trackingCategories: string[]; + integrationParams?: Record; + linkedAccountParams?: Record; + remoteFields?: Merge.accounting.RemoteFieldRequest[]; +} diff --git a/src/api/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts b/src/api/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts new file mode 100644 index 000000000..a4457f43b --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * The accounting period the report was posted in + */ +export type ExpenseReportRequestAccountingPeriod = string | Merge.accounting.AccountingPeriod; diff --git a/src/api/resources/accounting/types/ExpenseReportRequestCompany.ts b/src/api/resources/accounting/types/ExpenseReportRequestCompany.ts new file mode 100644 index 000000000..c58209ba2 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportRequestCompany.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * The subsidiary that the expense report is created in + */ +export type ExpenseReportRequestCompany = string | Merge.accounting.CompanyInfo; diff --git a/src/api/resources/accounting/types/ExpenseReportRequestEmployee.ts b/src/api/resources/accounting/types/ExpenseReportRequestEmployee.ts new file mode 100644 index 000000000..5bb8571ae --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportRequestEmployee.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * Identifier for the employee who submitted or is associated with the expense report + */ +export type ExpenseReportRequestEmployee = string | Merge.accounting.Employee; diff --git a/src/api/resources/accounting/types/ExpenseReportResponse.ts b/src/api/resources/accounting/types/ExpenseReportResponse.ts new file mode 100644 index 000000000..6b7818ee8 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportResponse.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export interface ExpenseReportResponse { + model: Merge.accounting.ExpenseReport; + warnings: Merge.accounting.WarningValidationProblem[]; + errors: Merge.accounting.ErrorValidationProblem[]; + logs?: Merge.accounting.DebugModeLog[]; +} diff --git a/src/api/resources/accounting/types/ExpenseReportStatus.ts b/src/api/resources/accounting/types/ExpenseReportStatus.ts new file mode 100644 index 000000000..bbf6ac634 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportStatus.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * Overall status of the expense report. One of DRAFT, SUBMITTED, APPROVED, REJECTED + * + * * `DRAFT` - DRAFT + * * `SUBMITTED` - SUBMITTED + * * `APPROVED` - APPROVED + * * `REJECTED` - REJECTED + */ +export type ExpenseReportStatus = Merge.accounting.ExpenseReportStatusEnum | string; diff --git a/src/api/resources/accounting/types/ExpenseReportStatusEnum.ts b/src/api/resources/accounting/types/ExpenseReportStatusEnum.ts new file mode 100644 index 000000000..925b38851 --- /dev/null +++ b/src/api/resources/accounting/types/ExpenseReportStatusEnum.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * * `DRAFT` - DRAFT + * * `SUBMITTED` - SUBMITTED + * * `APPROVED` - APPROVED + * * `REJECTED` - REJECTED + */ +export type ExpenseReportStatusEnum = "DRAFT" | "SUBMITTED" | "APPROVED" | "REJECTED"; +export const ExpenseReportStatusEnum = { + Draft: "DRAFT", + Submitted: "SUBMITTED", + Approved: "APPROVED", + Rejected: "REJECTED", +} as const; diff --git a/src/api/resources/accounting/types/ExternalTargetFieldApiResponse.ts b/src/api/resources/accounting/types/ExternalTargetFieldApiResponse.ts index f09bf386a..3b09f8c41 100644 --- a/src/api/resources/accounting/types/ExternalTargetFieldApiResponse.ts +++ b/src/api/resources/accounting/types/ExternalTargetFieldApiResponse.ts @@ -15,6 +15,7 @@ export interface ExternalTargetFieldApiResponse { creditNote?: Merge.accounting.ExternalTargetFieldApi[]; item?: Merge.accounting.ExternalTargetFieldApi[]; purchaseOrder?: Merge.accounting.ExternalTargetFieldApi[]; + expenseReport?: Merge.accounting.ExternalTargetFieldApi[]; trackingCategory?: Merge.accounting.ExternalTargetFieldApi[]; journalEntry?: Merge.accounting.ExternalTargetFieldApi[]; taxRate?: Merge.accounting.ExternalTargetFieldApi[]; diff --git a/src/api/resources/accounting/types/FieldMappingApiInstanceResponse.ts b/src/api/resources/accounting/types/FieldMappingApiInstanceResponse.ts index bdba87996..15b1e860d 100644 --- a/src/api/resources/accounting/types/FieldMappingApiInstanceResponse.ts +++ b/src/api/resources/accounting/types/FieldMappingApiInstanceResponse.ts @@ -15,6 +15,7 @@ export interface FieldMappingApiInstanceResponse { creditNote?: Merge.accounting.FieldMappingApiInstance[]; item?: Merge.accounting.FieldMappingApiInstance[]; purchaseOrder?: Merge.accounting.FieldMappingApiInstance[]; + expenseReport?: Merge.accounting.FieldMappingApiInstance[]; trackingCategory?: Merge.accounting.FieldMappingApiInstance[]; journalEntry?: Merge.accounting.FieldMappingApiInstance[]; taxRate?: Merge.accounting.FieldMappingApiInstance[]; diff --git a/src/api/resources/accounting/types/Item.ts b/src/api/resources/accounting/types/Item.ts index 5ab51ce0d..eaa81851b 100644 --- a/src/api/resources/accounting/types/Item.ts +++ b/src/api/resources/accounting/types/Item.ts @@ -29,6 +29,15 @@ export interface Item { * * `ARCHIVED` - ARCHIVED */ status?: Merge.accounting.ItemStatus; + /** + * The item's type. + * + * * `INVENTORY` - INVENTORY + * * `NON_INVENTORY` - NON_INVENTORY + * * `SERVICE` - SERVICE + * * `UNKNOWN` - UNKNOWN + */ + type?: Merge.accounting.ItemType; /** The item's unit price. */ unitPrice?: number; /** The price at which the item is purchased from a vendor. */ diff --git a/src/api/resources/accounting/types/ItemType.ts b/src/api/resources/accounting/types/ItemType.ts new file mode 100644 index 000000000..5303acd29 --- /dev/null +++ b/src/api/resources/accounting/types/ItemType.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +/** + * The item's type. + * + * * `INVENTORY` - INVENTORY + * * `NON_INVENTORY` - NON_INVENTORY + * * `SERVICE` - SERVICE + * * `UNKNOWN` - UNKNOWN + */ +export type ItemType = Merge.accounting.Type2BbEnum | string; diff --git a/src/api/resources/accounting/types/PaginatedExpenseReportLineList.ts b/src/api/resources/accounting/types/PaginatedExpenseReportLineList.ts new file mode 100644 index 000000000..46b870d37 --- /dev/null +++ b/src/api/resources/accounting/types/PaginatedExpenseReportLineList.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export interface PaginatedExpenseReportLineList { + next?: string; + previous?: string; + results?: Merge.accounting.ExpenseReportLine[]; +} diff --git a/src/api/resources/accounting/types/PaginatedExpenseReportList.ts b/src/api/resources/accounting/types/PaginatedExpenseReportList.ts new file mode 100644 index 000000000..ab9060aab --- /dev/null +++ b/src/api/resources/accounting/types/PaginatedExpenseReportList.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Merge from "../../../index"; + +export interface PaginatedExpenseReportList { + next?: string; + previous?: string; + results?: Merge.accounting.ExpenseReport[]; +} diff --git a/src/api/resources/accounting/types/index.ts b/src/api/resources/accounting/types/index.ts index ed233c5d8..e19fdfe80 100644 --- a/src/api/resources/accounting/types/index.ts +++ b/src/api/resources/accounting/types/index.ts @@ -159,6 +159,29 @@ export * from "./ExpenseLineRequestAccount"; export * from "./ExpenseLineRequestContact"; export * from "./ExpenseLineRequestProject"; export * from "./ExpenseLineRequest"; +export * from "./ExpenseReportStatus"; +export * from "./ExpenseReportCompany"; +export * from "./ExpenseReport"; +export * from "./ExpenseReportLineAccount"; +export * from "./ExpenseReportLineEmployee"; +export * from "./ExpenseReportLineProject"; +export * from "./ExpenseReportLineCompany"; +export * from "./ExpenseReportLineContact"; +export * from "./ExpenseReportLineTaxRate"; +export * from "./ExpenseReportLine"; +export * from "./ExpenseReportLineRequestAccount"; +export * from "./ExpenseReportLineRequestEmployee"; +export * from "./ExpenseReportLineRequestProject"; +export * from "./ExpenseReportLineRequestCompany"; +export * from "./ExpenseReportLineRequestContact"; +export * from "./ExpenseReportLineRequestTaxRate"; +export * from "./ExpenseReportLineRequest"; +export * from "./ExpenseReportRequestEmployee"; +export * from "./ExpenseReportRequestAccountingPeriod"; +export * from "./ExpenseReportRequestCompany"; +export * from "./ExpenseReportRequest"; +export * from "./ExpenseReportResponse"; +export * from "./ExpenseReportStatusEnum"; export * from "./ExpenseRequestAccount"; export * from "./ExpenseRequestContact"; export * from "./ExpenseRequestCurrency"; @@ -253,6 +276,7 @@ export * from "./IssueStatus"; export * from "./Issue"; export * from "./IssueStatusEnum"; export * from "./ItemStatus"; +export * from "./ItemType"; export * from "./ItemPurchaseAccount"; export * from "./ItemSalesAccount"; export * from "./ItemCompany"; @@ -324,6 +348,8 @@ export * from "./PaginatedContactList"; export * from "./PaginatedCreditNoteList"; export * from "./PaginatedEmployeeList"; export * from "./PaginatedExpenseList"; +export * from "./PaginatedExpenseReportLineList"; +export * from "./PaginatedExpenseReportList"; export * from "./PaginatedGeneralLedgerTransactionList"; export * from "./PaginatedIncomeStatementList"; export * from "./PaginatedInvoiceList"; diff --git a/src/api/resources/index.ts b/src/api/resources/index.ts index 00e3bf2a9..b51bb2714 100644 --- a/src/api/resources/index.ts +++ b/src/api/resources/index.ts @@ -1,6 +1,6 @@ export * as filestorage from "./filestorage"; export * as hris from "./hris"; export * as ticketing from "./ticketing"; -export * as crm from "./crm"; export * as ats from "./ats"; +export * as crm from "./crm"; export * as accounting from "./accounting"; diff --git a/src/serialization/resources/accounting/resources/expenseReports/client/index.ts b/src/serialization/resources/accounting/resources/expenseReports/client/index.ts new file mode 100644 index 000000000..415726b7f --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/serialization/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts b/src/serialization/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts new file mode 100644 index 000000000..138a5e55d --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/client/requests/ExpenseReportEndpointRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../../../../index"; +import * as Merge from "../../../../../../../api/index"; +import * as core from "../../../../../../../core"; +import { ExpenseReportRequest } from "../../../../types/ExpenseReportRequest"; + +export const ExpenseReportEndpointRequest: core.serialization.Schema< + serializers.accounting.ExpenseReportEndpointRequest.Raw, + Omit +> = core.serialization.object({ + model: ExpenseReportRequest, +}); + +export declare namespace ExpenseReportEndpointRequest { + export interface Raw { + model: ExpenseReportRequest.Raw; + } +} diff --git a/src/serialization/resources/accounting/resources/expenseReports/client/requests/index.ts b/src/serialization/resources/accounting/resources/expenseReports/client/requests/index.ts new file mode 100644 index 000000000..86f81d85a --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/client/requests/index.ts @@ -0,0 +1 @@ +export { ExpenseReportEndpointRequest } from "./ExpenseReportEndpointRequest"; diff --git a/src/serialization/resources/accounting/resources/expenseReports/index.ts b/src/serialization/resources/accounting/resources/expenseReports/index.ts new file mode 100644 index 000000000..c9240f83b --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts b/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts new file mode 100644 index 000000000..3db161835 --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsLinesListRequestExpand.ts @@ -0,0 +1,143 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../../../index"; +import * as Merge from "../../../../../../api/index"; +import * as core from "../../../../../../core"; + +export const ExpenseReportsLinesListRequestExpand: core.serialization.Schema< + serializers.accounting.ExpenseReportsLinesListRequestExpand.Raw, + Merge.accounting.ExpenseReportsLinesListRequestExpand +> = core.serialization.enum_([ + "account", + "account,company", + "account,company,contact", + "account,company,contact,tax_rate", + "account,company,tax_rate", + "account,contact", + "account,contact,tax_rate", + "account,employee", + "account,employee,company", + "account,employee,company,contact", + "account,employee,company,contact,tax_rate", + "account,employee,company,tax_rate", + "account,employee,contact", + "account,employee,contact,tax_rate", + "account,employee,project", + "account,employee,project,company", + "account,employee,project,company,contact", + "account,employee,project,company,contact,tax_rate", + "account,employee,project,company,tax_rate", + "account,employee,project,contact", + "account,employee,project,contact,tax_rate", + "account,employee,project,tax_rate", + "account,employee,tax_rate", + "account,project", + "account,project,company", + "account,project,company,contact", + "account,project,company,contact,tax_rate", + "account,project,company,tax_rate", + "account,project,contact", + "account,project,contact,tax_rate", + "account,project,tax_rate", + "account,tax_rate", + "company", + "company,contact", + "company,contact,tax_rate", + "company,tax_rate", + "contact", + "contact,tax_rate", + "employee", + "employee,company", + "employee,company,contact", + "employee,company,contact,tax_rate", + "employee,company,tax_rate", + "employee,contact", + "employee,contact,tax_rate", + "employee,project", + "employee,project,company", + "employee,project,company,contact", + "employee,project,company,contact,tax_rate", + "employee,project,company,tax_rate", + "employee,project,contact", + "employee,project,contact,tax_rate", + "employee,project,tax_rate", + "employee,tax_rate", + "project", + "project,company", + "project,company,contact", + "project,company,contact,tax_rate", + "project,company,tax_rate", + "project,contact", + "project,contact,tax_rate", + "project,tax_rate", + "tax_rate", +]); + +export declare namespace ExpenseReportsLinesListRequestExpand { + export type Raw = + | "account" + | "account,company" + | "account,company,contact" + | "account,company,contact,tax_rate" + | "account,company,tax_rate" + | "account,contact" + | "account,contact,tax_rate" + | "account,employee" + | "account,employee,company" + | "account,employee,company,contact" + | "account,employee,company,contact,tax_rate" + | "account,employee,company,tax_rate" + | "account,employee,contact" + | "account,employee,contact,tax_rate" + | "account,employee,project" + | "account,employee,project,company" + | "account,employee,project,company,contact" + | "account,employee,project,company,contact,tax_rate" + | "account,employee,project,company,tax_rate" + | "account,employee,project,contact" + | "account,employee,project,contact,tax_rate" + | "account,employee,project,tax_rate" + | "account,employee,tax_rate" + | "account,project" + | "account,project,company" + | "account,project,company,contact" + | "account,project,company,contact,tax_rate" + | "account,project,company,tax_rate" + | "account,project,contact" + | "account,project,contact,tax_rate" + | "account,project,tax_rate" + | "account,tax_rate" + | "company" + | "company,contact" + | "company,contact,tax_rate" + | "company,tax_rate" + | "contact" + | "contact,tax_rate" + | "employee" + | "employee,company" + | "employee,company,contact" + | "employee,company,contact,tax_rate" + | "employee,company,tax_rate" + | "employee,contact" + | "employee,contact,tax_rate" + | "employee,project" + | "employee,project,company" + | "employee,project,company,contact" + | "employee,project,company,contact,tax_rate" + | "employee,project,company,tax_rate" + | "employee,project,contact" + | "employee,project,contact,tax_rate" + | "employee,project,tax_rate" + | "employee,tax_rate" + | "project" + | "project,company" + | "project,company,contact" + | "project,company,contact,tax_rate" + | "project,company,tax_rate" + | "project,contact" + | "project,contact,tax_rate" + | "project,tax_rate" + | "tax_rate"; +} diff --git a/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts b/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts new file mode 100644 index 000000000..6c224b29b --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsListRequestExpand.ts @@ -0,0 +1,47 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../../../index"; +import * as Merge from "../../../../../../api/index"; +import * as core from "../../../../../../core"; + +export const ExpenseReportsListRequestExpand: core.serialization.Schema< + serializers.accounting.ExpenseReportsListRequestExpand.Raw, + Merge.accounting.ExpenseReportsListRequestExpand +> = core.serialization.enum_([ + "accounting_period", + "accounting_period,company", + "company", + "employee", + "employee,accounting_period", + "employee,accounting_period,company", + "employee,company", + "lines", + "lines,accounting_period", + "lines,accounting_period,company", + "lines,company", + "lines,employee", + "lines,employee,accounting_period", + "lines,employee,accounting_period,company", + "lines,employee,company", +]); + +export declare namespace ExpenseReportsListRequestExpand { + export type Raw = + | "accounting_period" + | "accounting_period,company" + | "company" + | "employee" + | "employee,accounting_period" + | "employee,accounting_period,company" + | "employee,company" + | "lines" + | "lines,accounting_period" + | "lines,accounting_period,company" + | "lines,company" + | "lines,employee" + | "lines,employee,accounting_period" + | "lines,employee,accounting_period,company" + | "lines,employee,company"; +} diff --git a/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts b/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts new file mode 100644 index 000000000..733390b5f --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/types/ExpenseReportsRetrieveRequestExpand.ts @@ -0,0 +1,47 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../../../index"; +import * as Merge from "../../../../../../api/index"; +import * as core from "../../../../../../core"; + +export const ExpenseReportsRetrieveRequestExpand: core.serialization.Schema< + serializers.accounting.ExpenseReportsRetrieveRequestExpand.Raw, + Merge.accounting.ExpenseReportsRetrieveRequestExpand +> = core.serialization.enum_([ + "accounting_period", + "accounting_period,company", + "company", + "employee", + "employee,accounting_period", + "employee,accounting_period,company", + "employee,company", + "lines", + "lines,accounting_period", + "lines,accounting_period,company", + "lines,company", + "lines,employee", + "lines,employee,accounting_period", + "lines,employee,accounting_period,company", + "lines,employee,company", +]); + +export declare namespace ExpenseReportsRetrieveRequestExpand { + export type Raw = + | "accounting_period" + | "accounting_period,company" + | "company" + | "employee" + | "employee,accounting_period" + | "employee,accounting_period,company" + | "employee,company" + | "lines" + | "lines,accounting_period" + | "lines,accounting_period,company" + | "lines,company" + | "lines,employee" + | "lines,employee,accounting_period" + | "lines,employee,accounting_period,company" + | "lines,employee,company"; +} diff --git a/src/serialization/resources/accounting/resources/expenseReports/types/index.ts b/src/serialization/resources/accounting/resources/expenseReports/types/index.ts new file mode 100644 index 000000000..a338ac04a --- /dev/null +++ b/src/serialization/resources/accounting/resources/expenseReports/types/index.ts @@ -0,0 +1,3 @@ +export * from "./ExpenseReportsListRequestExpand"; +export * from "./ExpenseReportsLinesListRequestExpand"; +export * from "./ExpenseReportsRetrieveRequestExpand"; diff --git a/src/serialization/resources/accounting/resources/index.ts b/src/serialization/resources/accounting/resources/index.ts index 7c4d72d59..0145fd11e 100644 --- a/src/serialization/resources/accounting/resources/index.ts +++ b/src/serialization/resources/accounting/resources/index.ts @@ -8,6 +8,8 @@ export * as contacts from "./contacts"; export * from "./contacts/types"; export * as creditNotes from "./creditNotes"; export * from "./creditNotes/types"; +export * as expenseReports from "./expenseReports"; +export * from "./expenseReports/types"; export * as expenses from "./expenses"; export * from "./expenses/types"; export * as generalLedgerTransactions from "./generalLedgerTransactions"; @@ -47,6 +49,7 @@ export * from "./contacts/client/requests"; export * from "./creditNotes/client/requests"; export * as scopes from "./scopes"; export * from "./scopes/client/requests"; +export * from "./expenseReports/client/requests"; export * from "./expenses/client/requests"; export * as fieldMapping from "./fieldMapping"; export * from "./fieldMapping/client/requests"; diff --git a/src/serialization/resources/accounting/types/ExpenseReport.ts b/src/serialization/resources/accounting/types/ExpenseReport.ts new file mode 100644 index 000000000..785230520 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReport.ts @@ -0,0 +1,68 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReportStatus } from "./ExpenseReportStatus"; +import { ExpenseReportLine } from "./ExpenseReportLine"; +import { TransactionCurrencyEnum } from "./TransactionCurrencyEnum"; +import { ExpenseReportCompany } from "./ExpenseReportCompany"; +import { RemoteData } from "./RemoteData"; +import { RemoteField } from "./RemoteField"; + +export const ExpenseReport: core.serialization.ObjectSchema< + serializers.accounting.ExpenseReport.Raw, + Merge.accounting.ExpenseReport +> = core.serialization.object({ + id: core.serialization.string().optional(), + remoteId: core.serialization.property("remote_id", core.serialization.string().optional()), + createdAt: core.serialization.property("created_at", core.serialization.date().optional()), + modifiedAt: core.serialization.property("modified_at", core.serialization.date().optional()), + reportDate: core.serialization.property("report_date", core.serialization.date().optional()), + reportIdentifier: core.serialization.property("report_identifier", core.serialization.string().optional()), + employee: core.serialization.string().optional(), + status: ExpenseReportStatus.optional(), + totalAmount: core.serialization.property("total_amount", core.serialization.number().optional()), + lines: core.serialization.list(ExpenseReportLine).optional(), + currency: TransactionCurrencyEnum.optional(), + description: core.serialization.string().optional(), + accountingPeriod: core.serialization.property("accounting_period", core.serialization.string().optional()), + company: ExpenseReportCompany.optional(), + trackingCategories: core.serialization.property( + "tracking_categories", + core.serialization.list(core.serialization.string()), + ), + remoteWasDeleted: core.serialization.property("remote_was_deleted", core.serialization.boolean().optional()), + fieldMappings: core.serialization.property( + "field_mappings", + core.serialization.record(core.serialization.string(), core.serialization.unknown()).optional(), + ), + remoteData: core.serialization.property("remote_data", core.serialization.list(RemoteData).optional()), + remoteFields: core.serialization.property("remote_fields", core.serialization.list(RemoteField).optional()), +}); + +export declare namespace ExpenseReport { + export interface Raw { + id?: string | null; + remote_id?: string | null; + created_at?: string | null; + modified_at?: string | null; + report_date?: string | null; + report_identifier?: string | null; + employee?: string | null; + status?: ExpenseReportStatus.Raw | null; + total_amount?: number | null; + lines?: ExpenseReportLine.Raw[] | null; + currency?: TransactionCurrencyEnum.Raw | null; + description?: string | null; + accounting_period?: string | null; + company?: ExpenseReportCompany.Raw | null; + tracking_categories: string[]; + remote_was_deleted?: boolean | null; + field_mappings?: Record | null; + remote_data?: RemoteData.Raw[] | null; + remote_fields?: RemoteField.Raw[] | null; + } +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportCompany.ts b/src/serialization/resources/accounting/types/ExpenseReportCompany.ts new file mode 100644 index 000000000..dc4b45b5b --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportCompany.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { CompanyInfo } from "./CompanyInfo"; + +export const ExpenseReportCompany: core.serialization.Schema< + serializers.accounting.ExpenseReportCompany.Raw, + Merge.accounting.ExpenseReportCompany +> = core.serialization.undiscriminatedUnion([core.serialization.string(), CompanyInfo]); + +export declare namespace ExpenseReportCompany { + export type Raw = string | CompanyInfo.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLine.ts b/src/serialization/resources/accounting/types/ExpenseReportLine.ts new file mode 100644 index 000000000..0a77f3892 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLine.ts @@ -0,0 +1,77 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReportLineAccount } from "./ExpenseReportLineAccount"; +import { TransactionCurrencyEnum } from "./TransactionCurrencyEnum"; +import { ExpenseReportLineEmployee } from "./ExpenseReportLineEmployee"; +import { ExpenseReportLineProject } from "./ExpenseReportLineProject"; +import { ExpenseReportLineCompany } from "./ExpenseReportLineCompany"; +import { ExpenseReportLineContact } from "./ExpenseReportLineContact"; +import { ExpenseReportLineTaxRate } from "./ExpenseReportLineTaxRate"; +import { RemoteField } from "./RemoteField"; + +export const ExpenseReportLine: core.serialization.ObjectSchema< + serializers.accounting.ExpenseReportLine.Raw, + Merge.accounting.ExpenseReportLine +> = core.serialization.object({ + id: core.serialization.string().optional(), + remoteId: core.serialization.property("remote_id", core.serialization.string().optional()), + createdAt: core.serialization.property("created_at", core.serialization.date().optional()), + modifiedAt: core.serialization.property("modified_at", core.serialization.date().optional()), + account: ExpenseReportLineAccount.optional(), + description: core.serialization.string().optional(), + expenseDate: core.serialization.property("expense_date", core.serialization.date().optional()), + amount: core.serialization.number().optional(), + currency: TransactionCurrencyEnum.optional(), + exchangeRate: core.serialization.property("exchange_rate", core.serialization.string().optional()), + isBillable: core.serialization.property("is_billable", core.serialization.boolean().optional()), + trackingCategories: core.serialization.property( + "tracking_categories", + core.serialization.list(core.serialization.string()), + ), + employee: ExpenseReportLineEmployee.optional(), + project: ExpenseReportLineProject.optional(), + company: ExpenseReportLineCompany.optional(), + contact: ExpenseReportLineContact.optional(), + quantity: core.serialization.number().optional(), + unitPrice: core.serialization.property("unit_price", core.serialization.number().optional()), + nonReimbursable: core.serialization.property("non_reimbursable", core.serialization.boolean().optional()), + taxAmount: core.serialization.property("tax_amount", core.serialization.number().optional()), + inclusiveOfTax: core.serialization.property("inclusive_of_tax", core.serialization.boolean().optional()), + taxRate: core.serialization.property("tax_rate", ExpenseReportLineTaxRate.optional()), + remoteWasDeleted: core.serialization.property("remote_was_deleted", core.serialization.boolean().optional()), + remoteFields: core.serialization.property("remote_fields", core.serialization.list(RemoteField).optional()), +}); + +export declare namespace ExpenseReportLine { + export interface Raw { + id?: string | null; + remote_id?: string | null; + created_at?: string | null; + modified_at?: string | null; + account?: ExpenseReportLineAccount.Raw | null; + description?: string | null; + expense_date?: string | null; + amount?: number | null; + currency?: TransactionCurrencyEnum.Raw | null; + exchange_rate?: string | null; + is_billable?: boolean | null; + tracking_categories: string[]; + employee?: ExpenseReportLineEmployee.Raw | null; + project?: ExpenseReportLineProject.Raw | null; + company?: ExpenseReportLineCompany.Raw | null; + contact?: ExpenseReportLineContact.Raw | null; + quantity?: number | null; + unit_price?: number | null; + non_reimbursable?: boolean | null; + tax_amount?: number | null; + inclusive_of_tax?: boolean | null; + tax_rate?: ExpenseReportLineTaxRate.Raw | null; + remote_was_deleted?: boolean | null; + remote_fields?: RemoteField.Raw[] | null; + } +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineAccount.ts b/src/serialization/resources/accounting/types/ExpenseReportLineAccount.ts new file mode 100644 index 000000000..ba8a525e4 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineAccount.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Account } from "./Account"; + +export const ExpenseReportLineAccount: core.serialization.Schema< + serializers.accounting.ExpenseReportLineAccount.Raw, + Merge.accounting.ExpenseReportLineAccount +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Account]); + +export declare namespace ExpenseReportLineAccount { + export type Raw = string | Account.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineCompany.ts b/src/serialization/resources/accounting/types/ExpenseReportLineCompany.ts new file mode 100644 index 000000000..529bf83df --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineCompany.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { CompanyInfo } from "./CompanyInfo"; + +export const ExpenseReportLineCompany: core.serialization.Schema< + serializers.accounting.ExpenseReportLineCompany.Raw, + Merge.accounting.ExpenseReportLineCompany +> = core.serialization.undiscriminatedUnion([core.serialization.string(), CompanyInfo]); + +export declare namespace ExpenseReportLineCompany { + export type Raw = string | CompanyInfo.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineContact.ts b/src/serialization/resources/accounting/types/ExpenseReportLineContact.ts new file mode 100644 index 000000000..aa404da5b --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineContact.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Contact } from "./Contact"; + +export const ExpenseReportLineContact: core.serialization.Schema< + serializers.accounting.ExpenseReportLineContact.Raw, + Merge.accounting.ExpenseReportLineContact +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Contact]); + +export declare namespace ExpenseReportLineContact { + export type Raw = string | Contact.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineEmployee.ts b/src/serialization/resources/accounting/types/ExpenseReportLineEmployee.ts new file mode 100644 index 000000000..16a182182 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineEmployee.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Employee } from "./Employee"; + +export const ExpenseReportLineEmployee: core.serialization.Schema< + serializers.accounting.ExpenseReportLineEmployee.Raw, + Merge.accounting.ExpenseReportLineEmployee +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Employee]); + +export declare namespace ExpenseReportLineEmployee { + export type Raw = string | Employee.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineProject.ts b/src/serialization/resources/accounting/types/ExpenseReportLineProject.ts new file mode 100644 index 000000000..4c6f3c31f --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineProject.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Project } from "./Project"; + +export const ExpenseReportLineProject: core.serialization.Schema< + serializers.accounting.ExpenseReportLineProject.Raw, + Merge.accounting.ExpenseReportLineProject +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Project]); + +export declare namespace ExpenseReportLineProject { + export type Raw = string | Project.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineRequest.ts b/src/serialization/resources/accounting/types/ExpenseReportLineRequest.ts new file mode 100644 index 000000000..195a13ed7 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineRequest.ts @@ -0,0 +1,79 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReportLineRequestAccount } from "./ExpenseReportLineRequestAccount"; +import { TransactionCurrencyEnum } from "./TransactionCurrencyEnum"; +import { ExpenseReportLineRequestEmployee } from "./ExpenseReportLineRequestEmployee"; +import { ExpenseReportLineRequestProject } from "./ExpenseReportLineRequestProject"; +import { ExpenseReportLineRequestCompany } from "./ExpenseReportLineRequestCompany"; +import { ExpenseReportLineRequestContact } from "./ExpenseReportLineRequestContact"; +import { ExpenseReportLineRequestTaxRate } from "./ExpenseReportLineRequestTaxRate"; +import { RemoteFieldRequest } from "./RemoteFieldRequest"; + +export const ExpenseReportLineRequest: core.serialization.ObjectSchema< + serializers.accounting.ExpenseReportLineRequest.Raw, + Merge.accounting.ExpenseReportLineRequest +> = core.serialization.object({ + remoteId: core.serialization.property("remote_id", core.serialization.string().optional()), + account: ExpenseReportLineRequestAccount.optional(), + description: core.serialization.string().optional(), + expenseDate: core.serialization.property("expense_date", core.serialization.date().optional()), + amount: core.serialization.number().optional(), + currency: TransactionCurrencyEnum.optional(), + exchangeRate: core.serialization.property("exchange_rate", core.serialization.string().optional()), + isBillable: core.serialization.property("is_billable", core.serialization.boolean().optional()), + trackingCategories: core.serialization.property( + "tracking_categories", + core.serialization.list(core.serialization.string()), + ), + employee: ExpenseReportLineRequestEmployee.optional(), + project: ExpenseReportLineRequestProject.optional(), + company: ExpenseReportLineRequestCompany.optional(), + contact: ExpenseReportLineRequestContact.optional(), + quantity: core.serialization.number().optional(), + unitPrice: core.serialization.property("unit_price", core.serialization.number().optional()), + nonReimbursable: core.serialization.property("non_reimbursable", core.serialization.boolean().optional()), + taxAmount: core.serialization.property("tax_amount", core.serialization.number().optional()), + inclusiveOfTax: core.serialization.property("inclusive_of_tax", core.serialization.boolean().optional()), + taxRate: core.serialization.property("tax_rate", ExpenseReportLineRequestTaxRate.optional()), + integrationParams: core.serialization.property( + "integration_params", + core.serialization.record(core.serialization.string(), core.serialization.unknown()).optional(), + ), + linkedAccountParams: core.serialization.property( + "linked_account_params", + core.serialization.record(core.serialization.string(), core.serialization.unknown()).optional(), + ), + remoteFields: core.serialization.property("remote_fields", core.serialization.list(RemoteFieldRequest).optional()), +}); + +export declare namespace ExpenseReportLineRequest { + export interface Raw { + remote_id?: string | null; + account?: ExpenseReportLineRequestAccount.Raw | null; + description?: string | null; + expense_date?: string | null; + amount?: number | null; + currency?: TransactionCurrencyEnum.Raw | null; + exchange_rate?: string | null; + is_billable?: boolean | null; + tracking_categories: string[]; + employee?: ExpenseReportLineRequestEmployee.Raw | null; + project?: ExpenseReportLineRequestProject.Raw | null; + company?: ExpenseReportLineRequestCompany.Raw | null; + contact?: ExpenseReportLineRequestContact.Raw | null; + quantity?: number | null; + unit_price?: number | null; + non_reimbursable?: boolean | null; + tax_amount?: number | null; + inclusive_of_tax?: boolean | null; + tax_rate?: ExpenseReportLineRequestTaxRate.Raw | null; + integration_params?: Record | null; + linked_account_params?: Record | null; + remote_fields?: RemoteFieldRequest.Raw[] | null; + } +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineRequestAccount.ts b/src/serialization/resources/accounting/types/ExpenseReportLineRequestAccount.ts new file mode 100644 index 000000000..731d66764 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineRequestAccount.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Account } from "./Account"; + +export const ExpenseReportLineRequestAccount: core.serialization.Schema< + serializers.accounting.ExpenseReportLineRequestAccount.Raw, + Merge.accounting.ExpenseReportLineRequestAccount +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Account]); + +export declare namespace ExpenseReportLineRequestAccount { + export type Raw = string | Account.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineRequestCompany.ts b/src/serialization/resources/accounting/types/ExpenseReportLineRequestCompany.ts new file mode 100644 index 000000000..4442d9773 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineRequestCompany.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { CompanyInfo } from "./CompanyInfo"; + +export const ExpenseReportLineRequestCompany: core.serialization.Schema< + serializers.accounting.ExpenseReportLineRequestCompany.Raw, + Merge.accounting.ExpenseReportLineRequestCompany +> = core.serialization.undiscriminatedUnion([core.serialization.string(), CompanyInfo]); + +export declare namespace ExpenseReportLineRequestCompany { + export type Raw = string | CompanyInfo.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineRequestContact.ts b/src/serialization/resources/accounting/types/ExpenseReportLineRequestContact.ts new file mode 100644 index 000000000..c3ecd876c --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineRequestContact.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Contact } from "./Contact"; + +export const ExpenseReportLineRequestContact: core.serialization.Schema< + serializers.accounting.ExpenseReportLineRequestContact.Raw, + Merge.accounting.ExpenseReportLineRequestContact +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Contact]); + +export declare namespace ExpenseReportLineRequestContact { + export type Raw = string | Contact.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineRequestEmployee.ts b/src/serialization/resources/accounting/types/ExpenseReportLineRequestEmployee.ts new file mode 100644 index 000000000..5602c3d17 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineRequestEmployee.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Employee } from "./Employee"; + +export const ExpenseReportLineRequestEmployee: core.serialization.Schema< + serializers.accounting.ExpenseReportLineRequestEmployee.Raw, + Merge.accounting.ExpenseReportLineRequestEmployee +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Employee]); + +export declare namespace ExpenseReportLineRequestEmployee { + export type Raw = string | Employee.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineRequestProject.ts b/src/serialization/resources/accounting/types/ExpenseReportLineRequestProject.ts new file mode 100644 index 000000000..eba7e4729 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineRequestProject.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Project } from "./Project"; + +export const ExpenseReportLineRequestProject: core.serialization.Schema< + serializers.accounting.ExpenseReportLineRequestProject.Raw, + Merge.accounting.ExpenseReportLineRequestProject +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Project]); + +export declare namespace ExpenseReportLineRequestProject { + export type Raw = string | Project.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts b/src/serialization/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts new file mode 100644 index 000000000..5dc10bd58 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineRequestTaxRate.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { TaxRate } from "./TaxRate"; + +export const ExpenseReportLineRequestTaxRate: core.serialization.Schema< + serializers.accounting.ExpenseReportLineRequestTaxRate.Raw, + Merge.accounting.ExpenseReportLineRequestTaxRate +> = core.serialization.undiscriminatedUnion([core.serialization.string(), TaxRate]); + +export declare namespace ExpenseReportLineRequestTaxRate { + export type Raw = string | TaxRate.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportLineTaxRate.ts b/src/serialization/resources/accounting/types/ExpenseReportLineTaxRate.ts new file mode 100644 index 000000000..5cd30b1cd --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportLineTaxRate.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { TaxRate } from "./TaxRate"; + +export const ExpenseReportLineTaxRate: core.serialization.Schema< + serializers.accounting.ExpenseReportLineTaxRate.Raw, + Merge.accounting.ExpenseReportLineTaxRate +> = core.serialization.undiscriminatedUnion([core.serialization.string(), TaxRate]); + +export declare namespace ExpenseReportLineTaxRate { + export type Raw = string | TaxRate.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportRequest.ts b/src/serialization/resources/accounting/types/ExpenseReportRequest.ts new file mode 100644 index 000000000..0ea3f3448 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportRequest.ts @@ -0,0 +1,59 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReportRequestEmployee } from "./ExpenseReportRequestEmployee"; +import { ExpenseReportStatusEnum } from "./ExpenseReportStatusEnum"; +import { TransactionCurrencyEnum } from "./TransactionCurrencyEnum"; +import { ExpenseReportRequestAccountingPeriod } from "./ExpenseReportRequestAccountingPeriod"; +import { ExpenseReportRequestCompany } from "./ExpenseReportRequestCompany"; +import { RemoteFieldRequest } from "./RemoteFieldRequest"; + +export const ExpenseReportRequest: core.serialization.ObjectSchema< + serializers.accounting.ExpenseReportRequest.Raw, + Merge.accounting.ExpenseReportRequest +> = core.serialization.object({ + reportDate: core.serialization.property("report_date", core.serialization.date().optional()), + reportIdentifier: core.serialization.property("report_identifier", core.serialization.string().optional()), + employee: ExpenseReportRequestEmployee.optional(), + status: ExpenseReportStatusEnum.optional(), + totalAmount: core.serialization.property("total_amount", core.serialization.number().optional()), + currency: TransactionCurrencyEnum.optional(), + description: core.serialization.string().optional(), + accountingPeriod: core.serialization.property("accounting_period", ExpenseReportRequestAccountingPeriod.optional()), + company: ExpenseReportRequestCompany.optional(), + trackingCategories: core.serialization.property( + "tracking_categories", + core.serialization.list(core.serialization.string()), + ), + integrationParams: core.serialization.property( + "integration_params", + core.serialization.record(core.serialization.string(), core.serialization.unknown()).optional(), + ), + linkedAccountParams: core.serialization.property( + "linked_account_params", + core.serialization.record(core.serialization.string(), core.serialization.unknown()).optional(), + ), + remoteFields: core.serialization.property("remote_fields", core.serialization.list(RemoteFieldRequest).optional()), +}); + +export declare namespace ExpenseReportRequest { + export interface Raw { + report_date?: string | null; + report_identifier?: string | null; + employee?: ExpenseReportRequestEmployee.Raw | null; + status?: ExpenseReportStatusEnum.Raw | null; + total_amount?: number | null; + currency?: TransactionCurrencyEnum.Raw | null; + description?: string | null; + accounting_period?: ExpenseReportRequestAccountingPeriod.Raw | null; + company?: ExpenseReportRequestCompany.Raw | null; + tracking_categories: string[]; + integration_params?: Record | null; + linked_account_params?: Record | null; + remote_fields?: RemoteFieldRequest.Raw[] | null; + } +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts b/src/serialization/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts new file mode 100644 index 000000000..123e8c1a7 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportRequestAccountingPeriod.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { AccountingPeriod } from "./AccountingPeriod"; + +export const ExpenseReportRequestAccountingPeriod: core.serialization.Schema< + serializers.accounting.ExpenseReportRequestAccountingPeriod.Raw, + Merge.accounting.ExpenseReportRequestAccountingPeriod +> = core.serialization.undiscriminatedUnion([core.serialization.string(), AccountingPeriod]); + +export declare namespace ExpenseReportRequestAccountingPeriod { + export type Raw = string | AccountingPeriod.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportRequestCompany.ts b/src/serialization/resources/accounting/types/ExpenseReportRequestCompany.ts new file mode 100644 index 000000000..11cbbec5c --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportRequestCompany.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { CompanyInfo } from "./CompanyInfo"; + +export const ExpenseReportRequestCompany: core.serialization.Schema< + serializers.accounting.ExpenseReportRequestCompany.Raw, + Merge.accounting.ExpenseReportRequestCompany +> = core.serialization.undiscriminatedUnion([core.serialization.string(), CompanyInfo]); + +export declare namespace ExpenseReportRequestCompany { + export type Raw = string | CompanyInfo.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportRequestEmployee.ts b/src/serialization/resources/accounting/types/ExpenseReportRequestEmployee.ts new file mode 100644 index 000000000..8881c9b85 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportRequestEmployee.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { Employee } from "./Employee"; + +export const ExpenseReportRequestEmployee: core.serialization.Schema< + serializers.accounting.ExpenseReportRequestEmployee.Raw, + Merge.accounting.ExpenseReportRequestEmployee +> = core.serialization.undiscriminatedUnion([core.serialization.string(), Employee]); + +export declare namespace ExpenseReportRequestEmployee { + export type Raw = string | Employee.Raw; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportResponse.ts b/src/serialization/resources/accounting/types/ExpenseReportResponse.ts new file mode 100644 index 000000000..2b49c9dc7 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportResponse.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReport } from "./ExpenseReport"; +import { WarningValidationProblem } from "./WarningValidationProblem"; +import { ErrorValidationProblem } from "./ErrorValidationProblem"; +import { DebugModeLog } from "./DebugModeLog"; + +export const ExpenseReportResponse: core.serialization.ObjectSchema< + serializers.accounting.ExpenseReportResponse.Raw, + Merge.accounting.ExpenseReportResponse +> = core.serialization.object({ + model: ExpenseReport, + warnings: core.serialization.list(WarningValidationProblem), + errors: core.serialization.list(ErrorValidationProblem), + logs: core.serialization.list(DebugModeLog).optional(), +}); + +export declare namespace ExpenseReportResponse { + export interface Raw { + model: ExpenseReport.Raw; + warnings: WarningValidationProblem.Raw[]; + errors: ErrorValidationProblem.Raw[]; + logs?: DebugModeLog.Raw[] | null; + } +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportStatus.ts b/src/serialization/resources/accounting/types/ExpenseReportStatus.ts new file mode 100644 index 000000000..af650c3f4 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportStatus.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReportStatusEnum } from "./ExpenseReportStatusEnum"; + +export const ExpenseReportStatus: core.serialization.Schema< + serializers.accounting.ExpenseReportStatus.Raw, + Merge.accounting.ExpenseReportStatus +> = core.serialization.undiscriminatedUnion([ExpenseReportStatusEnum, core.serialization.string()]); + +export declare namespace ExpenseReportStatus { + export type Raw = ExpenseReportStatusEnum.Raw | string; +} diff --git a/src/serialization/resources/accounting/types/ExpenseReportStatusEnum.ts b/src/serialization/resources/accounting/types/ExpenseReportStatusEnum.ts new file mode 100644 index 000000000..ed7305760 --- /dev/null +++ b/src/serialization/resources/accounting/types/ExpenseReportStatusEnum.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; + +export const ExpenseReportStatusEnum: core.serialization.Schema< + serializers.accounting.ExpenseReportStatusEnum.Raw, + Merge.accounting.ExpenseReportStatusEnum +> = core.serialization.enum_(["DRAFT", "SUBMITTED", "APPROVED", "REJECTED"]); + +export declare namespace ExpenseReportStatusEnum { + export type Raw = "DRAFT" | "SUBMITTED" | "APPROVED" | "REJECTED"; +} diff --git a/src/serialization/resources/accounting/types/ExternalTargetFieldApiResponse.ts b/src/serialization/resources/accounting/types/ExternalTargetFieldApiResponse.ts index 31cfdd4ff..fc10d13fd 100644 --- a/src/serialization/resources/accounting/types/ExternalTargetFieldApiResponse.ts +++ b/src/serialization/resources/accounting/types/ExternalTargetFieldApiResponse.ts @@ -36,6 +36,10 @@ export const ExternalTargetFieldApiResponse: core.serialization.ObjectSchema< "PurchaseOrder", core.serialization.list(ExternalTargetFieldApi).optional(), ), + expenseReport: core.serialization.property( + "ExpenseReport", + core.serialization.list(ExternalTargetFieldApi).optional(), + ), trackingCategory: core.serialization.property( "TrackingCategory", core.serialization.list(ExternalTargetFieldApi).optional(), @@ -86,6 +90,7 @@ export declare namespace ExternalTargetFieldApiResponse { CreditNote?: ExternalTargetFieldApi.Raw[] | null; Item?: ExternalTargetFieldApi.Raw[] | null; PurchaseOrder?: ExternalTargetFieldApi.Raw[] | null; + ExpenseReport?: ExternalTargetFieldApi.Raw[] | null; TrackingCategory?: ExternalTargetFieldApi.Raw[] | null; JournalEntry?: ExternalTargetFieldApi.Raw[] | null; TaxRate?: ExternalTargetFieldApi.Raw[] | null; diff --git a/src/serialization/resources/accounting/types/FieldMappingApiInstanceResponse.ts b/src/serialization/resources/accounting/types/FieldMappingApiInstanceResponse.ts index f8bb39830..919f9155c 100644 --- a/src/serialization/resources/accounting/types/FieldMappingApiInstanceResponse.ts +++ b/src/serialization/resources/accounting/types/FieldMappingApiInstanceResponse.ts @@ -39,6 +39,10 @@ export const FieldMappingApiInstanceResponse: core.serialization.ObjectSchema< "PurchaseOrder", core.serialization.list(FieldMappingApiInstance).optional(), ), + expenseReport: core.serialization.property( + "ExpenseReport", + core.serialization.list(FieldMappingApiInstance).optional(), + ), trackingCategory: core.serialization.property( "TrackingCategory", core.serialization.list(FieldMappingApiInstance).optional(), @@ -95,6 +99,7 @@ export declare namespace FieldMappingApiInstanceResponse { CreditNote?: FieldMappingApiInstance.Raw[] | null; Item?: FieldMappingApiInstance.Raw[] | null; PurchaseOrder?: FieldMappingApiInstance.Raw[] | null; + ExpenseReport?: FieldMappingApiInstance.Raw[] | null; TrackingCategory?: FieldMappingApiInstance.Raw[] | null; JournalEntry?: FieldMappingApiInstance.Raw[] | null; TaxRate?: FieldMappingApiInstance.Raw[] | null; diff --git a/src/serialization/resources/accounting/types/Item.ts b/src/serialization/resources/accounting/types/Item.ts index f1aa58059..f061078b6 100644 --- a/src/serialization/resources/accounting/types/Item.ts +++ b/src/serialization/resources/accounting/types/Item.ts @@ -6,6 +6,7 @@ import * as serializers from "../../../index"; import * as Merge from "../../../../api/index"; import * as core from "../../../../core"; import { ItemStatus } from "./ItemStatus"; +import { ItemType } from "./ItemType"; import { ItemPurchaseAccount } from "./ItemPurchaseAccount"; import { ItemSalesAccount } from "./ItemSalesAccount"; import { ItemCompany } from "./ItemCompany"; @@ -21,6 +22,7 @@ export const Item: core.serialization.ObjectSchema = + core.serialization.undiscriminatedUnion([Type2BbEnum, core.serialization.string()]); + +export declare namespace ItemType { + export type Raw = Type2BbEnum.Raw | string; +} diff --git a/src/serialization/resources/accounting/types/PaginatedExpenseReportLineList.ts b/src/serialization/resources/accounting/types/PaginatedExpenseReportLineList.ts new file mode 100644 index 000000000..2298e59c3 --- /dev/null +++ b/src/serialization/resources/accounting/types/PaginatedExpenseReportLineList.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReportLine } from "./ExpenseReportLine"; + +export const PaginatedExpenseReportLineList: core.serialization.ObjectSchema< + serializers.accounting.PaginatedExpenseReportLineList.Raw, + Merge.accounting.PaginatedExpenseReportLineList +> = core.serialization.object({ + next: core.serialization.string().optional(), + previous: core.serialization.string().optional(), + results: core.serialization.list(ExpenseReportLine).optional(), +}); + +export declare namespace PaginatedExpenseReportLineList { + export interface Raw { + next?: string | null; + previous?: string | null; + results?: ExpenseReportLine.Raw[] | null; + } +} diff --git a/src/serialization/resources/accounting/types/PaginatedExpenseReportList.ts b/src/serialization/resources/accounting/types/PaginatedExpenseReportList.ts new file mode 100644 index 000000000..96ce28577 --- /dev/null +++ b/src/serialization/resources/accounting/types/PaginatedExpenseReportList.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as Merge from "../../../../api/index"; +import * as core from "../../../../core"; +import { ExpenseReport } from "./ExpenseReport"; + +export const PaginatedExpenseReportList: core.serialization.ObjectSchema< + serializers.accounting.PaginatedExpenseReportList.Raw, + Merge.accounting.PaginatedExpenseReportList +> = core.serialization.object({ + next: core.serialization.string().optional(), + previous: core.serialization.string().optional(), + results: core.serialization.list(ExpenseReport).optional(), +}); + +export declare namespace PaginatedExpenseReportList { + export interface Raw { + next?: string | null; + previous?: string | null; + results?: ExpenseReport.Raw[] | null; + } +} diff --git a/src/serialization/resources/accounting/types/index.ts b/src/serialization/resources/accounting/types/index.ts index ed233c5d8..e19fdfe80 100644 --- a/src/serialization/resources/accounting/types/index.ts +++ b/src/serialization/resources/accounting/types/index.ts @@ -159,6 +159,29 @@ export * from "./ExpenseLineRequestAccount"; export * from "./ExpenseLineRequestContact"; export * from "./ExpenseLineRequestProject"; export * from "./ExpenseLineRequest"; +export * from "./ExpenseReportStatus"; +export * from "./ExpenseReportCompany"; +export * from "./ExpenseReport"; +export * from "./ExpenseReportLineAccount"; +export * from "./ExpenseReportLineEmployee"; +export * from "./ExpenseReportLineProject"; +export * from "./ExpenseReportLineCompany"; +export * from "./ExpenseReportLineContact"; +export * from "./ExpenseReportLineTaxRate"; +export * from "./ExpenseReportLine"; +export * from "./ExpenseReportLineRequestAccount"; +export * from "./ExpenseReportLineRequestEmployee"; +export * from "./ExpenseReportLineRequestProject"; +export * from "./ExpenseReportLineRequestCompany"; +export * from "./ExpenseReportLineRequestContact"; +export * from "./ExpenseReportLineRequestTaxRate"; +export * from "./ExpenseReportLineRequest"; +export * from "./ExpenseReportRequestEmployee"; +export * from "./ExpenseReportRequestAccountingPeriod"; +export * from "./ExpenseReportRequestCompany"; +export * from "./ExpenseReportRequest"; +export * from "./ExpenseReportResponse"; +export * from "./ExpenseReportStatusEnum"; export * from "./ExpenseRequestAccount"; export * from "./ExpenseRequestContact"; export * from "./ExpenseRequestCurrency"; @@ -253,6 +276,7 @@ export * from "./IssueStatus"; export * from "./Issue"; export * from "./IssueStatusEnum"; export * from "./ItemStatus"; +export * from "./ItemType"; export * from "./ItemPurchaseAccount"; export * from "./ItemSalesAccount"; export * from "./ItemCompany"; @@ -324,6 +348,8 @@ export * from "./PaginatedContactList"; export * from "./PaginatedCreditNoteList"; export * from "./PaginatedEmployeeList"; export * from "./PaginatedExpenseList"; +export * from "./PaginatedExpenseReportLineList"; +export * from "./PaginatedExpenseReportList"; export * from "./PaginatedGeneralLedgerTransactionList"; export * from "./PaginatedIncomeStatementList"; export * from "./PaginatedInvoiceList"; diff --git a/src/serialization/resources/index.ts b/src/serialization/resources/index.ts index 00e3bf2a9..b51bb2714 100644 --- a/src/serialization/resources/index.ts +++ b/src/serialization/resources/index.ts @@ -1,6 +1,6 @@ export * as filestorage from "./filestorage"; export * as hris from "./hris"; export * as ticketing from "./ticketing"; -export * as crm from "./crm"; export * as ats from "./ats"; +export * as crm from "./crm"; export * as accounting from "./accounting"; diff --git a/src/version.ts b/src/version.ts index 85cbd4ff5..58b4ee6cb 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "2.0.1"; +export const SDK_VERSION = "2.1.0"; diff --git a/tests/wire/accounting/expenseReports.test.ts b/tests/wire/accounting/expenseReports.test.ts new file mode 100644 index 000000000..77428e9d4 --- /dev/null +++ b/tests/wire/accounting/expenseReports.test.ts @@ -0,0 +1,1087 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import { mockServerPool } from "../../mock-server/MockServerPool.js"; +import { MergeClient } from "../../../src/Client"; + +describe("ExpenseReports", () => { + test("list", async () => { + const server = mockServerPool.createServer(); + const client = new MergeClient({ apiKey: "test", accountToken: "test", environment: server.baseUrl }); + + const rawResponseBody = { + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "123e4567-e89b-12d3-a456-426614174000", + remote_id: "exp_123e4567-e89b-12d3-a456-426614174000", + created_at: "2024-01-31T12:00:00Z", + modified_at: "2024-01-31T14:30:00Z", + report_date: "2024-01-31T00:00:00Z", + report_identifier: "EXP-2024-001", + employee: "b9a9b824-6172-4d63-9d90-1c8a86c4f3b1", + status: "DRAFT", + total_amount: 150, + lines: [ + { + id: "1234", + remote_id: "abcd-1234", + created_at: "2021-09-15T00:00:00Z", + modified_at: "2021-10-16T00:00:00Z", + account: "acc-1234", + description: "Client lunch meeting", + expense_date: "2024-01-15T00:00:00Z", + amount: 50, + currency: "USD", + exchange_rate: "exchange_rate", + is_billable: true, + tracking_categories: ["cat-1", "cat-2"], + employee: "emp-1234", + project: "proj-5678", + company: "comp-1234", + contact: "cont-5678", + quantity: 1, + unit_price: 50, + non_reimbursable: false, + tax_amount: 5, + inclusive_of_tax: false, + tax_rate: "tax-1234", + remote_was_deleted: false, + }, + ], + currency: "XUA", + description: "January 2024 Travel Expenses", + accounting_period: "7d793c67-9f72-4a6b-9256-3936f237b0d9", + company: "company", + tracking_categories: [ + "a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", + "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p", + ], + remote_was_deleted: true, + field_mappings: { + organization_defined_targets: { custom_key: "custom_value" }, + linked_account_defined_targets: { custom_key: "custom_value" }, + }, + remote_data: [{ path: "/actions", data: ["Varies by platform"] }], + remote_fields: [{ remote_field_class: "remote_field_class" }], + }, + ], + }; + server + .mockEndpoint() + .get("/accounting/v1/expense-reports") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.accounting.expenseReports.list(); + expect(response).toEqual({ + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "123e4567-e89b-12d3-a456-426614174000", + remoteId: "exp_123e4567-e89b-12d3-a456-426614174000", + createdAt: new Date("2024-01-31T12:00:00.000Z"), + modifiedAt: new Date("2024-01-31T14:30:00.000Z"), + reportDate: new Date("2024-01-31T00:00:00.000Z"), + reportIdentifier: "EXP-2024-001", + employee: "b9a9b824-6172-4d63-9d90-1c8a86c4f3b1", + status: "DRAFT", + totalAmount: 150, + lines: [ + { + id: "1234", + remoteId: "abcd-1234", + createdAt: new Date("2021-09-15T00:00:00.000Z"), + modifiedAt: new Date("2021-10-16T00:00:00.000Z"), + account: "acc-1234", + description: "Client lunch meeting", + expenseDate: new Date("2024-01-15T00:00:00.000Z"), + amount: 50, + currency: "USD", + exchangeRate: "exchange_rate", + isBillable: true, + trackingCategories: ["cat-1", "cat-2"], + employee: "emp-1234", + project: "proj-5678", + company: "comp-1234", + contact: "cont-5678", + quantity: 1, + unitPrice: 50, + nonReimbursable: false, + taxAmount: 5, + inclusiveOfTax: false, + taxRate: "tax-1234", + remoteWasDeleted: false, + }, + ], + currency: "XUA", + description: "January 2024 Travel Expenses", + accountingPeriod: "7d793c67-9f72-4a6b-9256-3936f237b0d9", + company: "company", + trackingCategories: [ + "a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", + "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p", + ], + remoteWasDeleted: true, + fieldMappings: { + organization_defined_targets: { + custom_key: "custom_value", + }, + linked_account_defined_targets: { + custom_key: "custom_value", + }, + }, + remoteData: [ + { + path: "/actions", + data: ["Varies by platform"], + }, + ], + remoteFields: [ + { + remoteFieldClass: "remote_field_class", + }, + ], + }, + ], + }); + }); + + test("create", async () => { + const server = mockServerPool.createServer(); + const client = new MergeClient({ apiKey: "test", accountToken: "test", environment: server.baseUrl }); + const rawRequestBody = { + model: { + tracking_categories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"], + }, + }; + const rawResponseBody = { + model: { + id: "123e4567-e89b-12d3-a456-426614174000", + remote_id: "exp_123e4567-e89b-12d3-a456-426614174000", + created_at: "2024-01-31T12:00:00Z", + modified_at: "2024-01-31T14:30:00Z", + report_date: "2024-01-31T00:00:00Z", + report_identifier: "EXP-2024-001", + employee: "b9a9b824-6172-4d63-9d90-1c8a86c4f3b1", + status: "DRAFT", + total_amount: 150, + lines: [ + { + id: "1234", + remote_id: "abcd-1234", + created_at: "2021-09-15T00:00:00Z", + modified_at: "2021-10-16T00:00:00Z", + account: "acc-1234", + description: "Client lunch meeting", + expense_date: "2024-01-15T00:00:00Z", + amount: 50, + currency: "USD", + exchange_rate: "exchange_rate", + is_billable: true, + tracking_categories: ["cat-1", "cat-2"], + employee: "emp-1234", + project: "proj-5678", + company: "comp-1234", + contact: "cont-5678", + quantity: 1, + unit_price: 50, + non_reimbursable: false, + tax_amount: 5, + inclusive_of_tax: false, + tax_rate: "tax-1234", + remote_was_deleted: false, + }, + ], + currency: "XUA", + description: "January 2024 Travel Expenses", + accounting_period: "7d793c67-9f72-4a6b-9256-3936f237b0d9", + company: "company", + tracking_categories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"], + remote_was_deleted: true, + field_mappings: { + organization_defined_targets: { custom_key: "custom_value" }, + linked_account_defined_targets: { custom_key: "custom_value" }, + }, + remote_data: [{ path: "/actions", data: ["Varies by platform"] }], + remote_fields: [{ remote_field_class: "remote_field_class" }], + }, + warnings: [ + { + source: { pointer: "pointer" }, + title: "Unrecognized Field", + detail: "An unrecognized field, age, was passed in with request data.", + problem_type: "UNRECOGNIZED_FIELD", + }, + ], + errors: [ + { + source: { pointer: "pointer" }, + title: "Missing Required Field", + detail: "custom_fields is a required field on model.", + problem_type: "MISSING_REQUIRED_FIELD", + }, + ], + logs: [ + { + log_id: "99433219-8017-4acd-bb3c-ceb23d663832", + dashboard_view: "https://app.merge.dev/logs/99433219-8017-4acd-bb3c-ceb23d663832", + log_summary: { + url: "www.exampleintegration.com/api/v1/exampleapi", + method: "POST", + status_code: 200, + }, + }, + ], + }; + server + .mockEndpoint() + .post("/accounting/v1/expense-reports") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.accounting.expenseReports.create({ + model: { + trackingCategories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"], + }, + }); + expect(response).toEqual({ + model: { + id: "123e4567-e89b-12d3-a456-426614174000", + remoteId: "exp_123e4567-e89b-12d3-a456-426614174000", + createdAt: new Date("2024-01-31T12:00:00.000Z"), + modifiedAt: new Date("2024-01-31T14:30:00.000Z"), + reportDate: new Date("2024-01-31T00:00:00.000Z"), + reportIdentifier: "EXP-2024-001", + employee: "b9a9b824-6172-4d63-9d90-1c8a86c4f3b1", + status: "DRAFT", + totalAmount: 150, + lines: [ + { + id: "1234", + remoteId: "abcd-1234", + createdAt: new Date("2021-09-15T00:00:00.000Z"), + modifiedAt: new Date("2021-10-16T00:00:00.000Z"), + account: "acc-1234", + description: "Client lunch meeting", + expenseDate: new Date("2024-01-15T00:00:00.000Z"), + amount: 50, + currency: "USD", + exchangeRate: "exchange_rate", + isBillable: true, + trackingCategories: ["cat-1", "cat-2"], + employee: "emp-1234", + project: "proj-5678", + company: "comp-1234", + contact: "cont-5678", + quantity: 1, + unitPrice: 50, + nonReimbursable: false, + taxAmount: 5, + inclusiveOfTax: false, + taxRate: "tax-1234", + remoteWasDeleted: false, + }, + ], + currency: "XUA", + description: "January 2024 Travel Expenses", + accountingPeriod: "7d793c67-9f72-4a6b-9256-3936f237b0d9", + company: "company", + trackingCategories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"], + remoteWasDeleted: true, + fieldMappings: { + organization_defined_targets: { + custom_key: "custom_value", + }, + linked_account_defined_targets: { + custom_key: "custom_value", + }, + }, + remoteData: [ + { + path: "/actions", + data: ["Varies by platform"], + }, + ], + remoteFields: [ + { + remoteFieldClass: "remote_field_class", + }, + ], + }, + warnings: [ + { + source: { + pointer: "pointer", + }, + title: "Unrecognized Field", + detail: "An unrecognized field, age, was passed in with request data.", + problemType: "UNRECOGNIZED_FIELD", + }, + ], + errors: [ + { + source: { + pointer: "pointer", + }, + title: "Missing Required Field", + detail: "custom_fields is a required field on model.", + problemType: "MISSING_REQUIRED_FIELD", + }, + ], + logs: [ + { + logId: "99433219-8017-4acd-bb3c-ceb23d663832", + dashboardView: "https://app.merge.dev/logs/99433219-8017-4acd-bb3c-ceb23d663832", + logSummary: { + url: "www.exampleintegration.com/api/v1/exampleapi", + method: "POST", + statusCode: 200, + }, + }, + ], + }); + }); + + test("linesList", async () => { + const server = mockServerPool.createServer(); + const client = new MergeClient({ apiKey: "test", accountToken: "test", environment: server.baseUrl }); + + const rawResponseBody = { + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "1234", + remote_id: "abcd-1234", + created_at: "2021-09-15T00:00:00Z", + modified_at: "2021-10-16T00:00:00Z", + account: "account", + description: "Client lunch meeting", + expense_date: "2024-01-15T00:00:00Z", + amount: 50, + currency: "XUA", + exchange_rate: "exchange_rate", + is_billable: true, + tracking_categories: ["cat-1", "cat-2"], + employee: "employee", + project: "project", + company: "company", + contact: "contact", + quantity: 1, + unit_price: 50, + non_reimbursable: true, + tax_amount: 5, + inclusive_of_tax: true, + tax_rate: "tax_rate", + remote_was_deleted: true, + remote_fields: [{ remote_field_class: "remote_field_class" }], + }, + ], + }; + server + .mockEndpoint() + .get("/accounting/v1/expense-reports/expense_report_id/lines") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.accounting.expenseReports.linesList("expense_report_id"); + expect(response).toEqual({ + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "1234", + remoteId: "abcd-1234", + createdAt: new Date("2021-09-15T00:00:00.000Z"), + modifiedAt: new Date("2021-10-16T00:00:00.000Z"), + account: "account", + description: "Client lunch meeting", + expenseDate: new Date("2024-01-15T00:00:00.000Z"), + amount: 50, + currency: "XUA", + exchangeRate: "exchange_rate", + isBillable: true, + trackingCategories: ["cat-1", "cat-2"], + employee: "employee", + project: "project", + company: "company", + contact: "contact", + quantity: 1, + unitPrice: 50, + nonReimbursable: true, + taxAmount: 5, + inclusiveOfTax: true, + taxRate: "tax_rate", + remoteWasDeleted: true, + remoteFields: [ + { + remoteFieldClass: "remote_field_class", + }, + ], + }, + ], + }); + }); + + test("retrieve", async () => { + const server = mockServerPool.createServer(); + const client = new MergeClient({ apiKey: "test", accountToken: "test", environment: server.baseUrl }); + + const rawResponseBody = { + id: "123e4567-e89b-12d3-a456-426614174000", + remote_id: "exp_123e4567-e89b-12d3-a456-426614174000", + created_at: "2024-01-31T12:00:00Z", + modified_at: "2024-01-31T14:30:00Z", + report_date: "2024-01-31T00:00:00Z", + report_identifier: "EXP-2024-001", + employee: "b9a9b824-6172-4d63-9d90-1c8a86c4f3b1", + status: "DRAFT", + total_amount: 150, + lines: [ + { + id: "1234", + remote_id: "abcd-1234", + created_at: "2021-09-15T00:00:00Z", + modified_at: "2021-10-16T00:00:00Z", + account: "acc-1234", + description: "Client lunch meeting", + expense_date: "2024-01-15T00:00:00Z", + amount: 50, + currency: "USD", + exchange_rate: "exchange_rate", + is_billable: true, + tracking_categories: ["cat-1", "cat-2"], + employee: "emp-1234", + project: "proj-5678", + company: "comp-1234", + contact: "cont-5678", + quantity: 1, + unit_price: 50, + non_reimbursable: false, + tax_amount: 5, + inclusive_of_tax: false, + tax_rate: "tax-1234", + remote_was_deleted: false, + remote_fields: [{ remote_field_class: "remote_field_class" }], + }, + ], + currency: "XUA", + description: "January 2024 Travel Expenses", + accounting_period: "7d793c67-9f72-4a6b-9256-3936f237b0d9", + company: "company", + tracking_categories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"], + remote_was_deleted: true, + field_mappings: { + organization_defined_targets: { custom_key: "custom_value" }, + linked_account_defined_targets: { custom_key: "custom_value" }, + }, + remote_data: [{ path: "/actions", data: ["Varies by platform"] }], + remote_fields: [{ remote_field_class: "remote_field_class", value: { key: "value" } }], + }; + server + .mockEndpoint() + .get("/accounting/v1/expense-reports/id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.accounting.expenseReports.retrieve("id"); + expect(response).toEqual({ + id: "123e4567-e89b-12d3-a456-426614174000", + remoteId: "exp_123e4567-e89b-12d3-a456-426614174000", + createdAt: new Date("2024-01-31T12:00:00.000Z"), + modifiedAt: new Date("2024-01-31T14:30:00.000Z"), + reportDate: new Date("2024-01-31T00:00:00.000Z"), + reportIdentifier: "EXP-2024-001", + employee: "b9a9b824-6172-4d63-9d90-1c8a86c4f3b1", + status: "DRAFT", + totalAmount: 150, + lines: [ + { + id: "1234", + remoteId: "abcd-1234", + createdAt: new Date("2021-09-15T00:00:00.000Z"), + modifiedAt: new Date("2021-10-16T00:00:00.000Z"), + account: "acc-1234", + description: "Client lunch meeting", + expenseDate: new Date("2024-01-15T00:00:00.000Z"), + amount: 50, + currency: "USD", + exchangeRate: "exchange_rate", + isBillable: true, + trackingCategories: ["cat-1", "cat-2"], + employee: "emp-1234", + project: "proj-5678", + company: "comp-1234", + contact: "cont-5678", + quantity: 1, + unitPrice: 50, + nonReimbursable: false, + taxAmount: 5, + inclusiveOfTax: false, + taxRate: "tax-1234", + remoteWasDeleted: false, + remoteFields: [ + { + remoteFieldClass: "remote_field_class", + }, + ], + }, + ], + currency: "XUA", + description: "January 2024 Travel Expenses", + accountingPeriod: "7d793c67-9f72-4a6b-9256-3936f237b0d9", + company: "company", + trackingCategories: ["a1b2c3d4-e5f6-4a5b-9c3d-2e1f0a9b8c7d", "d4c3b2a1-9e8f-7g6h-5i4j-3k2l1m0n9o8p"], + remoteWasDeleted: true, + fieldMappings: { + organization_defined_targets: { + custom_key: "custom_value", + }, + linked_account_defined_targets: { + custom_key: "custom_value", + }, + }, + remoteData: [ + { + path: "/actions", + data: ["Varies by platform"], + }, + ], + remoteFields: [ + { + remoteFieldClass: "remote_field_class", + value: { + key: "value", + }, + }, + ], + }); + }); + + test("linesRemoteFieldClassesList", async () => { + const server = mockServerPool.createServer(); + const client = new MergeClient({ apiKey: "test", accountToken: "test", environment: server.baseUrl }); + + const rawResponseBody = { + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "id", + display_name: "display_name", + remote_key_name: "remote_key_name", + description: "description", + is_custom: true, + is_required: true, + field_type: "string", + field_format: "string", + field_choices: ["field_choices"], + }, + ], + }; + server + .mockEndpoint() + .get("/accounting/v1/expense-reports/lines/remote-field-classes") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.accounting.expenseReports.linesRemoteFieldClassesList(); + expect(response).toEqual({ + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "id", + displayName: "display_name", + remoteKeyName: "remote_key_name", + description: "description", + isCustom: true, + isRequired: true, + fieldType: "string", + fieldFormat: "string", + fieldChoices: ["field_choices"], + }, + ], + }); + }); + + test("metaPostRetrieve", async () => { + const server = mockServerPool.createServer(); + const client = new MergeClient({ apiKey: "test", accountToken: "test", environment: server.baseUrl }); + + const rawResponseBody = { + request_schema: { + type: "object", + properties: { + model: { + type: "object", + required: [ + "last_name", + "first_name", + "merge_categories", + "new_york_city_neighborhood", + "favorite_tv_shows", + "favorite_watch", + ], + properties: { + email_addresses: { + type: "array", + items: { + type: "object", + properties: { + value: { type: "string", title: "value" }, + email_address_type: { type: "string", title: "email_address_type" }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "email_addresses", + description: "Array of email_addresses objects", + }, + urls: { + type: "array", + items: { + type: "object", + properties: { + value: { type: "string", title: "value" }, + url_type: { type: "string", title: "url_type" }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "urls", + description: "Array of urls objects", + }, + first_name: { type: "string", title: "first_name", description: "The first name." }, + last_name: { type: "string", title: "last_name", description: "The last name." }, + phone_numbers: { + type: "array", + items: { + type: "object", + properties: { + value: { type: "string", title: "value" }, + phone_number_type: { type: "string", title: "phone_number_type" }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "phone_numbers", + description: "Array of phone_numbers objects", + }, + tags: { + type: "array", + items: { type: "string", format: "uuid" }, + title: "tags", + description: "Array of tags names", + }, + attachments: { + type: "array", + items: { + type: "object", + properties: { + id: { type: "string", title: "id" }, + file_url: { type: "string", title: "file_url" }, + file_name: { type: "string", title: "file_name" }, + attachment_type: { type: "string", title: "attachment_type" }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "attachments", + description: "Array of attachments objects ", + }, + merge_categories: { + type: "array", + categories: { + type: "string", + enum: [ + "HRIS", + "ATS", + "Accounting", + "Ticketing", + "File Storage", + "CRM", + "Marketing Automation", + ], + enum_information: [ + { value: "HRIS", description: "Merge HRIS Category" }, + { value: "ATS", description: "Merge ATS Category" }, + { value: "Accounting", description: "Merge Accounting Category" }, + { value: "Ticketing", description: "Merge Ticketing Category" }, + { value: "File Storage", description: "Merge File Storage Category" }, + { value: "CRM", description: "Merge CRM Category" }, + { + value: "Marketing Automation", + description: "Merge Marketing Automation Category", + }, + ], + }, + title: "Merge Categories", + description: "Array of Merge's Unified API Categories", + }, + new_york_city_neighborhood: { + type: "string", + title: "Borough", + description: "One of the 5 Boroughs of New York City", + }, + favorite_tv_shows: { + type: "array", + items: { type: "string", format: "uuid" }, + title: "Favorite TV Shows", + description: "Array of TV Show objects on merge.tv_shows", + }, + favorite_watch: { + type: "string", + title: "Favorite Watch", + description: "Favorite watch of all time", + }, + }, + }, + }, + }, + remote_field_classes: { key: "value" }, + status: { linked_account_status: "linked_account_status", can_make_request: true }, + has_conditional_params: true, + has_required_linked_account_params: true, + }; + server + .mockEndpoint() + .get("/accounting/v1/expense-reports/meta/post") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.accounting.expenseReports.metaPostRetrieve(); + expect(response).toEqual({ + requestSchema: { + type: "object", + properties: { + model: { + type: "object", + required: [ + "last_name", + "first_name", + "merge_categories", + "new_york_city_neighborhood", + "favorite_tv_shows", + "favorite_watch", + ], + properties: { + email_addresses: { + type: "array", + items: { + type: "object", + properties: { + value: { + type: "string", + title: "value", + }, + email_address_type: { + type: "string", + title: "email_address_type", + }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "email_addresses", + description: "Array of email_addresses objects", + }, + urls: { + type: "array", + items: { + type: "object", + properties: { + value: { + type: "string", + title: "value", + }, + url_type: { + type: "string", + title: "url_type", + }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "urls", + description: "Array of urls objects", + }, + first_name: { + type: "string", + title: "first_name", + description: "The first name.", + }, + last_name: { + type: "string", + title: "last_name", + description: "The last name.", + }, + phone_numbers: { + type: "array", + items: { + type: "object", + properties: { + value: { + type: "string", + title: "value", + }, + phone_number_type: { + type: "string", + title: "phone_number_type", + }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "phone_numbers", + description: "Array of phone_numbers objects", + }, + tags: { + type: "array", + items: { + type: "string", + format: "uuid", + }, + title: "tags", + description: "Array of tags names", + }, + attachments: { + type: "array", + items: { + type: "object", + properties: { + id: { + type: "string", + title: "id", + }, + file_url: { + type: "string", + title: "file_url", + }, + file_name: { + type: "string", + title: "file_name", + }, + attachment_type: { + type: "string", + title: "attachment_type", + }, + integration_params: { + type: "object", + title: "integration_params", + properties: {}, + }, + linked_account_params: { + type: "object", + title: "linked_account_params", + properties: {}, + }, + }, + }, + title: "attachments", + description: "Array of attachments objects ", + }, + merge_categories: { + type: "array", + categories: { + type: "string", + enum: [ + "HRIS", + "ATS", + "Accounting", + "Ticketing", + "File Storage", + "CRM", + "Marketing Automation", + ], + enum_information: [ + { + value: "HRIS", + description: "Merge HRIS Category", + }, + { + value: "ATS", + description: "Merge ATS Category", + }, + { + value: "Accounting", + description: "Merge Accounting Category", + }, + { + value: "Ticketing", + description: "Merge Ticketing Category", + }, + { + value: "File Storage", + description: "Merge File Storage Category", + }, + { + value: "CRM", + description: "Merge CRM Category", + }, + { + value: "Marketing Automation", + description: "Merge Marketing Automation Category", + }, + ], + }, + title: "Merge Categories", + description: "Array of Merge's Unified API Categories", + }, + new_york_city_neighborhood: { + type: "string", + title: "Borough", + description: "One of the 5 Boroughs of New York City", + }, + favorite_tv_shows: { + type: "array", + items: { + type: "string", + format: "uuid", + }, + title: "Favorite TV Shows", + description: "Array of TV Show objects on merge.tv_shows", + }, + favorite_watch: { + type: "string", + title: "Favorite Watch", + description: "Favorite watch of all time", + }, + }, + }, + }, + }, + remoteFieldClasses: { + key: "value", + }, + status: { + linkedAccountStatus: "linked_account_status", + canMakeRequest: true, + }, + hasConditionalParams: true, + hasRequiredLinkedAccountParams: true, + }); + }); + + test("remoteFieldClassesList", async () => { + const server = mockServerPool.createServer(); + const client = new MergeClient({ apiKey: "test", accountToken: "test", environment: server.baseUrl }); + + const rawResponseBody = { + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "id", + display_name: "display_name", + remote_key_name: "remote_key_name", + description: "description", + is_custom: true, + is_required: true, + field_type: "string", + field_format: "string", + field_choices: ["field_choices"], + }, + ], + }; + server + .mockEndpoint() + .get("/accounting/v1/expense-reports/remote-field-classes") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.accounting.expenseReports.remoteFieldClassesList(); + expect(response).toEqual({ + next: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw", + previous: "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ", + results: [ + { + id: "id", + displayName: "display_name", + remoteKeyName: "remote_key_name", + description: "description", + isCustom: true, + isRequired: true, + fieldType: "string", + fieldFormat: "string", + fieldChoices: ["field_choices"], + }, + ], + }); + }); +}); diff --git a/tests/wire/accounting/fieldMapping.test.ts b/tests/wire/accounting/fieldMapping.test.ts index 2d2d3ce2f..9800aa692 100644 --- a/tests/wire/accounting/fieldMapping.test.ts +++ b/tests/wire/accounting/fieldMapping.test.ts @@ -211,6 +211,26 @@ describe("FieldMapping", () => { }, }, ], + ExpenseReport: [ + { + id: "3fa85f64-5717-4562-b3fc-2c963f66afa6", + is_integration_wide: true, + target_field: { + name: "example_target_field_name", + description: "this is a example description of a target field", + is_organization_wide: true, + }, + remote_field: { + remote_key_name: "example_remote_field_key", + schema: { type: "string" }, + remote_endpoint_info: { + method: "GET", + url_path: "/example-url-path", + field_traversal_path: ["example_remote_field_key"], + }, + }, + }, + ], TrackingCategory: [ { id: "3fa85f64-5717-4562-b3fc-2c963f66afa6", @@ -742,6 +762,28 @@ describe("FieldMapping", () => { }, }, ], + expenseReport: [ + { + id: "3fa85f64-5717-4562-b3fc-2c963f66afa6", + isIntegrationWide: true, + targetField: { + name: "example_target_field_name", + description: "this is a example description of a target field", + isOrganizationWide: true, + }, + remoteField: { + remoteKeyName: "example_remote_field_key", + schema: { + type: "string", + }, + remoteEndpointInfo: { + method: "GET", + urlPath: "/example-url-path", + fieldTraversalPath: ["example_remote_field_key"], + }, + }, + }, + ], trackingCategory: [ { id: "3fa85f64-5717-4562-b3fc-2c963f66afa6", @@ -2330,6 +2372,13 @@ describe("FieldMapping", () => { is_mapped: "is_mapped", }, ], + ExpenseReport: [ + { + name: "example_target_field_name", + description: "this is a example description of a target field", + is_mapped: "is_mapped", + }, + ], TrackingCategory: [ { name: "example_target_field_name", @@ -2516,6 +2565,13 @@ describe("FieldMapping", () => { isMapped: "is_mapped", }, ], + expenseReport: [ + { + name: "example_target_field_name", + description: "this is a example description of a target field", + isMapped: "is_mapped", + }, + ], trackingCategory: [ { name: "example_target_field_name", diff --git a/tests/wire/accounting/items.test.ts b/tests/wire/accounting/items.test.ts index 65975d1a1..fcaab5420 100644 --- a/tests/wire/accounting/items.test.ts +++ b/tests/wire/accounting/items.test.ts @@ -21,6 +21,7 @@ describe("Items", () => { modified_at: "2021-10-16T00:00:00Z", name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unit_price: 10, purchase_price: 25, purchase_account: "purchase_account", @@ -58,6 +59,7 @@ describe("Items", () => { modifiedAt: new Date("2021-10-16T00:00:00.000Z"), name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unitPrice: 10, purchasePrice: 25, purchaseAccount: "purchase_account", @@ -98,6 +100,7 @@ describe("Items", () => { modified_at: "2021-10-16T00:00:00Z", name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unit_price: 10, purchase_price: 25, purchase_account: "purchase_account", @@ -161,6 +164,7 @@ describe("Items", () => { modifiedAt: new Date("2021-10-16T00:00:00.000Z"), name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unitPrice: 10, purchasePrice: 25, purchaseAccount: "purchase_account", @@ -230,6 +234,7 @@ describe("Items", () => { modified_at: "2021-10-16T00:00:00Z", name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unit_price: 10, purchase_price: 25, purchase_account: "purchase_account", @@ -261,6 +266,7 @@ describe("Items", () => { modifiedAt: new Date("2021-10-16T00:00:00.000Z"), name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unitPrice: 10, purchasePrice: 25, purchaseAccount: "purchase_account", @@ -299,6 +305,7 @@ describe("Items", () => { modified_at: "2021-10-16T00:00:00Z", name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unit_price: 10, purchase_price: 25, purchase_account: "purchase_account", @@ -362,6 +369,7 @@ describe("Items", () => { modifiedAt: new Date("2021-10-16T00:00:00.000Z"), name: "Pickleball Paddle", status: "ACTIVE", + type: "INVENTORY", unitPrice: 10, purchasePrice: 25, purchaseAccount: "purchase_account", diff --git a/tests/wire/accounting/payments.test.ts b/tests/wire/accounting/payments.test.ts index cc4d24a2c..0648c9d76 100644 --- a/tests/wire/accounting/payments.test.ts +++ b/tests/wire/accounting/payments.test.ts @@ -40,7 +40,7 @@ describe("Payments", () => { remote_id: "234", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "a47e11b6-c73b-4a0c-be31-130fc48177fa", related_object_type: "INVOICE", @@ -50,7 +50,7 @@ describe("Payments", () => { remote_id: "235", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "9b96a886-29a5-452b-8733-2a1e03497cf4", related_object_type: "CREDIT_NOTE", @@ -106,7 +106,7 @@ describe("Payments", () => { remoteId: "234", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "a47e11b6-c73b-4a0c-be31-130fc48177fa", relatedObjectType: "INVOICE", @@ -116,7 +116,7 @@ describe("Payments", () => { remoteId: "235", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "9b96a886-29a5-452b-8733-2a1e03497cf4", relatedObjectType: "CREDIT_NOTE", @@ -179,7 +179,7 @@ describe("Payments", () => { remote_id: "234", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "a47e11b6-c73b-4a0c-be31-130fc48177fa", related_object_type: "INVOICE", @@ -189,7 +189,7 @@ describe("Payments", () => { remote_id: "235", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "9b96a886-29a5-452b-8733-2a1e03497cf4", related_object_type: "CREDIT_NOTE", @@ -271,7 +271,7 @@ describe("Payments", () => { remoteId: "234", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "a47e11b6-c73b-4a0c-be31-130fc48177fa", relatedObjectType: "INVOICE", @@ -281,7 +281,7 @@ describe("Payments", () => { remoteId: "235", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "9b96a886-29a5-452b-8733-2a1e03497cf4", relatedObjectType: "CREDIT_NOTE", @@ -373,7 +373,7 @@ describe("Payments", () => { remote_id: "234", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "a47e11b6-c73b-4a0c-be31-130fc48177fa", related_object_type: "INVOICE", @@ -383,7 +383,7 @@ describe("Payments", () => { remote_id: "235", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "9b96a886-29a5-452b-8733-2a1e03497cf4", related_object_type: "CREDIT_NOTE", @@ -433,7 +433,7 @@ describe("Payments", () => { remoteId: "234", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "a47e11b6-c73b-4a0c-be31-130fc48177fa", relatedObjectType: "INVOICE", @@ -443,7 +443,7 @@ describe("Payments", () => { remoteId: "235", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "9b96a886-29a5-452b-8733-2a1e03497cf4", relatedObjectType: "CREDIT_NOTE", @@ -507,7 +507,7 @@ describe("Payments", () => { remote_id: "234", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "a47e11b6-c73b-4a0c-be31-130fc48177fa", related_object_type: "INVOICE", @@ -517,7 +517,7 @@ describe("Payments", () => { remote_id: "235", created_at: "2021-09-15T00:00:00Z", modified_at: "2021-10-16T00:00:00Z", - applied_amount: "applied_amount", + applied_amount: "25", applied_date: "2020-03-31T00:00:00Z", related_object_id: "9b96a886-29a5-452b-8733-2a1e03497cf4", related_object_type: "CREDIT_NOTE", @@ -599,7 +599,7 @@ describe("Payments", () => { remoteId: "234", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "a47e11b6-c73b-4a0c-be31-130fc48177fa", relatedObjectType: "INVOICE", @@ -609,7 +609,7 @@ describe("Payments", () => { remoteId: "235", createdAt: new Date("2021-09-15T00:00:00.000Z"), modifiedAt: new Date("2021-10-16T00:00:00.000Z"), - appliedAmount: "applied_amount", + appliedAmount: "25", appliedDate: new Date("2020-03-31T00:00:00.000Z"), relatedObjectId: "9b96a886-29a5-452b-8733-2a1e03497cf4", relatedObjectType: "CREDIT_NOTE", diff --git a/yarn.lock b/yarn.lock index 0b4f8680a..da6673547 100644 --- a/yarn.lock +++ b/yarn.lock @@ -20,40 +20,40 @@ picocolors "^1.1.1" "@babel/compat-data@^7.27.2": - version "7.27.7" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.27.7.tgz#7fd698e531050cce432b073ab64857b99e0f3804" - integrity sha512-xgu/ySj2mTiUFmdE9yCMfBxLp4DHd5DwmbbD05YAuICfodYT3VvRxbrh81LGQ/8UpSdtMdfKMn3KouYDX59DGQ== + version "7.28.0" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.28.0.tgz#9fc6fd58c2a6a15243cd13983224968392070790" + integrity sha512-60X7qkglvrap8mn1lh2ebxXdZYtUcpd7gsmy9kLaBJ4i/WdY8PqTSdxyA8qraikqKQK5C1KRBKXqznrVapyNaw== "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.23.9": - version "7.27.7" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.27.7.tgz#0ddeab1e7b17317dad8c3c3a887716f66b5c4428" - integrity sha512-BU2f9tlKQ5CAthiMIgpzAh4eDTLWo1mqi9jqE2OxMG0E/OM199VJt2q8BztTxpnSW0i1ymdwLXRJnYzvDM5r2w== + version "7.28.0" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.28.0.tgz#55dad808d5bf3445a108eefc88ea3fdf034749a4" + integrity sha512-UlLAnTPrFdNGoFtbSXwcGFQBtQZJCNjaN6hQNP3UPvuNXT1i82N26KL3dZeIpNalWywr9IuQuncaAfUaS1g6sQ== dependencies: "@ampproject/remapping" "^2.2.0" "@babel/code-frame" "^7.27.1" - "@babel/generator" "^7.27.5" + "@babel/generator" "^7.28.0" "@babel/helper-compilation-targets" "^7.27.2" "@babel/helper-module-transforms" "^7.27.3" "@babel/helpers" "^7.27.6" - "@babel/parser" "^7.27.7" + "@babel/parser" "^7.28.0" "@babel/template" "^7.27.2" - "@babel/traverse" "^7.27.7" - "@babel/types" "^7.27.7" + "@babel/traverse" "^7.28.0" + "@babel/types" "^7.28.0" convert-source-map "^2.0.0" debug "^4.1.0" gensync "^1.0.0-beta.2" json5 "^2.2.3" semver "^6.3.1" -"@babel/generator@^7.27.5", "@babel/generator@^7.7.2": - version "7.27.5" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.27.5.tgz#3eb01866b345ba261b04911020cbe22dd4be8c8c" - integrity sha512-ZGhA37l0e/g2s1Cnzdix0O3aLYm66eF8aufiVteOgnwxgnRP8GoyMj7VWsgWnQbVKXyge7hqrFh2K2TQM6t1Hw== +"@babel/generator@^7.28.0", "@babel/generator@^7.7.2": + version "7.28.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.28.0.tgz#9cc2f7bd6eb054d77dc66c2664148a0c5118acd2" + integrity sha512-lJjzvrbEeWrhB4P3QBsH7tey117PjLZnDbLiQEKjQ/fNJTjuq4HSqgFA+UNSwZT8D7dxxbnuSBMsa1lrWzKlQg== dependencies: - "@babel/parser" "^7.27.5" - "@babel/types" "^7.27.3" - "@jridgewell/gen-mapping" "^0.3.5" - "@jridgewell/trace-mapping" "^0.3.25" + "@babel/parser" "^7.28.0" + "@babel/types" "^7.28.0" + "@jridgewell/gen-mapping" "^0.3.12" + "@jridgewell/trace-mapping" "^0.3.28" jsesc "^3.0.2" "@babel/helper-compilation-targets@^7.27.2": @@ -67,6 +67,11 @@ lru-cache "^5.1.1" semver "^6.3.1" +"@babel/helper-globals@^7.28.0": + version "7.28.0" + resolved "https://registry.yarnpkg.com/@babel/helper-globals/-/helper-globals-7.28.0.tgz#b9430df2aa4e17bc28665eadeae8aa1d985e6674" + integrity sha512-+W6cISkXFa1jXsDEdYA8HeevQT/FULhxzR99pxphltZcVaugps53THCeiWA8SguxxpSp3gKPiuYfSWopkLQ4hw== + "@babel/helper-module-imports@^7.27.1": version "7.27.1" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.27.1.tgz#7ef769a323e2655e126673bb6d2d6913bbead204" @@ -112,12 +117,12 @@ "@babel/template" "^7.27.2" "@babel/types" "^7.27.6" -"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.27.2", "@babel/parser@^7.27.5", "@babel/parser@^7.27.7": - version "7.27.7" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.27.7.tgz#1687f5294b45039c159730e3b9c1f1b242e425e9" - integrity sha512-qnzXzDXdr/po3bOTbTIQZ7+TxNKxpkN5IifVLXS+r7qwynkZfPyjZfE7hCXbo7IoO9TNcSyibgONsf2HauUd3Q== +"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.27.2", "@babel/parser@^7.28.0": + version "7.28.0" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.28.0.tgz#979829fbab51a29e13901e5a80713dbcb840825e" + integrity sha512-jVZGvOxOuNSsuQuLRTh13nU0AogFlw32w/MT+LV6D3sP5WdbW61E77RnkbaO2dUvmPAYrBDJXGn5gGS6tH4j8g== dependencies: - "@babel/types" "^7.27.7" + "@babel/types" "^7.28.0" "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" @@ -247,23 +252,23 @@ "@babel/parser" "^7.27.2" "@babel/types" "^7.27.1" -"@babel/traverse@^7.27.1", "@babel/traverse@^7.27.3", "@babel/traverse@^7.27.7": - version "7.27.7" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.27.7.tgz#8355c39be6818362eace058cf7f3e25ac2ec3b55" - integrity sha512-X6ZlfR/O/s5EQ/SnUSLzr+6kGnkg8HXGMzpgsMsrJVcfDtH1vIp6ctCN4eZ1LS5c0+te5Cb6Y514fASjMRJ1nw== +"@babel/traverse@^7.27.1", "@babel/traverse@^7.27.3", "@babel/traverse@^7.28.0": + version "7.28.0" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.28.0.tgz#518aa113359b062042379e333db18380b537e34b" + integrity sha512-mGe7UK5wWyh0bKRfupsUchrQGqvDbZDbKJw+kcRGSmdHVYrv+ltd0pnpDTVpiTqnaBru9iEvA8pz8W46v0Amwg== dependencies: "@babel/code-frame" "^7.27.1" - "@babel/generator" "^7.27.5" - "@babel/parser" "^7.27.7" + "@babel/generator" "^7.28.0" + "@babel/helper-globals" "^7.28.0" + "@babel/parser" "^7.28.0" "@babel/template" "^7.27.2" - "@babel/types" "^7.27.7" + "@babel/types" "^7.28.0" debug "^4.3.1" - globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.27.1", "@babel/types@^7.27.3", "@babel/types@^7.27.6", "@babel/types@^7.27.7", "@babel/types@^7.3.3": - version "7.27.7" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.27.7.tgz#40eabd562049b2ee1a205fa589e629f945dce20f" - integrity sha512-8OLQgDScAOHXnAz2cV+RfzzNMipuLVBz2biuAJFMV9bfkNf393je3VM8CLkjQodW5+iWsSJdSgSWT6rsZoXHPw== +"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.27.1", "@babel/types@^7.27.6", "@babel/types@^7.28.0", "@babel/types@^7.3.3": + version "7.28.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.28.0.tgz#2fd0159a6dc7353933920c43136335a9b264d950" + integrity sha512-jYnje+JyZG5YThjHiF28oT4SIZLnYOcSBb6+SDaFIyzDVSkXQmQQYclJ2R+YxcdmK0AX6x1E5OQNtuh3jHDrUg== dependencies: "@babel/helper-string-parser" "^7.27.1" "@babel/helper-validator-identifier" "^7.27.1" @@ -535,7 +540,7 @@ "@types/yargs" "^17.0.8" chalk "^4.0.0" -"@jridgewell/gen-mapping@^0.3.5": +"@jridgewell/gen-mapping@^0.3.12", "@jridgewell/gen-mapping@^0.3.5": version "0.3.12" resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.12.tgz#2234ce26c62889f03db3d7fea43c1932ab3e927b" integrity sha512-OuLGC46TjB5BbN1dH8JULVVZY4WTdkF7tV9Ys6wLL1rubZnCMstOhNHueU5bLCrnRuDhKPDM4g6sw4Bel5Gzqg== @@ -561,7 +566,7 @@ resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.4.tgz#7358043433b2e5da569aa02cbc4c121da3af27d7" integrity sha512-VT2+G1VQs/9oz078bLrYbecdZKs912zQlkelYpuf+SXF+QvZDYJlbx/LSx+meSAwdDFnF8FVXW92AVjjkVmgFw== -"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.18", "@jridgewell/trace-mapping@^0.3.24", "@jridgewell/trace-mapping@^0.3.25": +"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.18", "@jridgewell/trace-mapping@^0.3.24", "@jridgewell/trace-mapping@^0.3.25", "@jridgewell/trace-mapping@^0.3.28": version "0.3.29" resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.29.tgz#a58d31eaadaf92c6695680b2e1d464a9b8fbf7fc" integrity sha512-uw6guiW/gcAGPDhLmd77/6lW8QLeiV5RUTsAX46Db6oLhGaVj4lhnPwb184s1bkc8kdVg/+h988dro8GRDpmYQ== @@ -1407,9 +1412,9 @@ ejs@^3.1.10: jake "^10.8.5" electron-to-chromium@^1.5.173: - version "1.5.178" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.178.tgz#6fc4d69eb5275bb13068931448fd822458901fbb" - integrity sha512-wObbz/ar3Bc6e4X5vf0iO8xTN8YAjN/tgiAOJLr7yjYFtP9wAjq8Mb5h0yn6kResir+VYx2DXBj9NNobs0ETSA== + version "1.5.179" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.179.tgz#453d53f360014a2604d40ccd41c4ea0a6e31b99a" + integrity sha512-UWKi/EbBopgfFsc5k61wFpV7WrnnSlSzW/e2XcBmS6qKYTivZlLtoll5/rdqRTxGglGHkmkW0j0pFNJG10EUIQ== emittery@^0.13.1: version "0.13.1" @@ -1706,11 +1711,6 @@ glob@^7.1.3, glob@^7.1.4: once "^1.3.0" path-is-absolute "^1.0.0" -globals@^11.1.0: - version "11.12.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" - integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== - gopd@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.2.0.tgz#89f56b8217bdbc8802bd299df6d7f1081d7e51a1"