@unified-api/typescript-sdk 2.75.3 → 2.76.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -0
- package/docs/sdks/accounting/README.md +482 -0
- package/docs/sdks/expense/README.md +489 -0
- package/examples/package-lock.json +1 -1
- package/funcs/accountingCreateAccountingExpense.d.ts +15 -0
- package/funcs/accountingCreateAccountingExpense.d.ts.map +1 -0
- package/funcs/accountingCreateAccountingExpense.js +122 -0
- package/funcs/accountingCreateAccountingExpense.js.map +1 -0
- package/funcs/accountingGetAccountingExpense.d.ts +15 -0
- package/funcs/accountingGetAccountingExpense.d.ts.map +1 -0
- package/funcs/accountingGetAccountingExpense.js +125 -0
- package/funcs/accountingGetAccountingExpense.js.map +1 -0
- package/funcs/accountingListAccountingExpenses.d.ts +15 -0
- package/funcs/accountingListAccountingExpenses.d.ts.map +1 -0
- package/funcs/accountingListAccountingExpenses.js +129 -0
- package/funcs/accountingListAccountingExpenses.js.map +1 -0
- package/funcs/accountingPatchAccountingExpense.d.ts +15 -0
- package/funcs/accountingPatchAccountingExpense.d.ts.map +1 -0
- package/funcs/accountingPatchAccountingExpense.js +126 -0
- package/funcs/accountingPatchAccountingExpense.js.map +1 -0
- package/funcs/accountingRemoveAccountingExpense.d.ts +14 -0
- package/funcs/accountingRemoveAccountingExpense.d.ts.map +1 -0
- package/funcs/accountingRemoveAccountingExpense.js +122 -0
- package/funcs/accountingRemoveAccountingExpense.js.map +1 -0
- package/funcs/accountingUpdateAccountingExpense.d.ts +15 -0
- package/funcs/accountingUpdateAccountingExpense.d.ts.map +1 -0
- package/funcs/accountingUpdateAccountingExpense.js +126 -0
- package/funcs/accountingUpdateAccountingExpense.js.map +1 -0
- package/funcs/messagingListMessagingMessages.js +1 -0
- package/funcs/messagingListMessagingMessages.js.map +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/lib/config.js.map +1 -1
- package/package.json +1 -1
- package/sdk/accounting.d.ts +24 -0
- package/sdk/accounting.d.ts.map +1 -1
- package/sdk/accounting.js +42 -0
- package/sdk/accounting.js.map +1 -1
- package/sdk/expense.d.ts +30 -0
- package/sdk/expense.d.ts.map +1 -0
- package/sdk/expense.js +54 -0
- package/sdk/expense.js.map +1 -0
- package/sdk/models/operations/createaccountingexpense.d.ts +45 -0
- package/sdk/models/operations/createaccountingexpense.d.ts.map +1 -0
- package/sdk/models/operations/createaccountingexpense.js +87 -0
- package/sdk/models/operations/createaccountingexpense.js.map +1 -0
- package/sdk/models/operations/getaccountingexpense.d.ts +47 -0
- package/sdk/models/operations/getaccountingexpense.d.ts.map +1 -0
- package/sdk/models/operations/getaccountingexpense.js +84 -0
- package/sdk/models/operations/getaccountingexpense.js.map +1 -0
- package/sdk/models/operations/index.d.ts +6 -0
- package/sdk/models/operations/index.d.ts.map +1 -1
- package/sdk/models/operations/index.js +6 -0
- package/sdk/models/operations/index.js.map +1 -1
- package/sdk/models/operations/listaccountingexpenses.d.ts +65 -0
- package/sdk/models/operations/listaccountingexpenses.d.ts.map +1 -0
- package/sdk/models/operations/listaccountingexpenses.js +100 -0
- package/sdk/models/operations/listaccountingexpenses.js.map +1 -0
- package/sdk/models/operations/listmessagingmessages.d.ts +5 -0
- package/sdk/models/operations/listmessagingmessages.d.ts.map +1 -1
- package/sdk/models/operations/listmessagingmessages.js +4 -0
- package/sdk/models/operations/listmessagingmessages.js.map +1 -1
- package/sdk/models/operations/patchaccountingexpense.d.ts +50 -0
- package/sdk/models/operations/patchaccountingexpense.d.ts.map +1 -0
- package/sdk/models/operations/patchaccountingexpense.js +89 -0
- package/sdk/models/operations/patchaccountingexpense.js.map +1 -0
- package/sdk/models/operations/removeaccountingexpense.d.ts +66 -0
- package/sdk/models/operations/removeaccountingexpense.d.ts.map +1 -0
- package/sdk/models/operations/removeaccountingexpense.js +115 -0
- package/sdk/models/operations/removeaccountingexpense.js.map +1 -0
- package/sdk/models/operations/updateaccountingexpense.d.ts +50 -0
- package/sdk/models/operations/updateaccountingexpense.d.ts.map +1 -0
- package/sdk/models/operations/updateaccountingexpense.js +89 -0
- package/sdk/models/operations/updateaccountingexpense.js.map +1 -0
- package/sdk/models/shared/accountingexpense.d.ts +60 -0
- package/sdk/models/shared/accountingexpense.d.ts.map +1 -0
- package/sdk/models/shared/accountingexpense.js +124 -0
- package/sdk/models/shared/accountingexpense.js.map +1 -0
- package/sdk/models/shared/index.d.ts +1 -0
- package/sdk/models/shared/index.d.ts.map +1 -1
- package/sdk/models/shared/index.js +1 -0
- package/sdk/models/shared/index.js.map +1 -1
- package/sdk/models/shared/propertyconnectionpermissions.d.ts +2 -0
- package/sdk/models/shared/propertyconnectionpermissions.d.ts.map +1 -1
- package/sdk/models/shared/propertyconnectionpermissions.js +2 -0
- package/sdk/models/shared/propertyconnectionpermissions.js.map +1 -1
- package/sdk/models/shared/webhook.d.ts +1 -0
- package/sdk/models/shared/webhook.d.ts.map +1 -1
- package/sdk/models/shared/webhook.js +1 -0
- package/sdk/models/shared/webhook.js.map +1 -1
- package/sdk/sdk.d.ts +3 -0
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +4 -0
- package/sdk/sdk.js.map +1 -1
- package/src/funcs/accountingCreateAccountingExpense.ts +171 -0
- package/src/funcs/accountingGetAccountingExpense.ts +176 -0
- package/src/funcs/accountingListAccountingExpenses.ts +178 -0
- package/src/funcs/accountingPatchAccountingExpense.ts +177 -0
- package/src/funcs/accountingRemoveAccountingExpense.ts +181 -0
- package/src/funcs/accountingUpdateAccountingExpense.ts +177 -0
- package/src/funcs/messagingListMessagingMessages.ts +1 -0
- package/src/lib/config.ts +3 -3
- package/src/sdk/accounting.ts +90 -0
- package/src/sdk/expense.ts +100 -0
- package/src/sdk/models/operations/createaccountingexpense.ts +101 -0
- package/src/sdk/models/operations/getaccountingexpense.ts +101 -0
- package/src/sdk/models/operations/index.ts +6 -0
- package/src/sdk/models/operations/listaccountingexpenses.ts +135 -0
- package/src/sdk/models/operations/listmessagingmessages.ts +9 -0
- package/src/sdk/models/operations/patchaccountingexpense.ts +108 -0
- package/src/sdk/models/operations/removeaccountingexpense.ts +155 -0
- package/src/sdk/models/operations/updateaccountingexpense.ts +108 -0
- package/src/sdk/models/shared/accountingexpense.ts +154 -0
- package/src/sdk/models/shared/index.ts +1 -0
- package/src/sdk/models/shared/propertyconnectionpermissions.ts +2 -0
- package/src/sdk/models/shared/webhook.ts +1 -0
- package/src/sdk/sdk.ts +6 -0
package/README.md
CHANGED
|
@@ -452,6 +452,8 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
|
|
|
452
452
|
- [`accountingCreateAccountingContact`](docs/sdks/contact/README.md#createaccountingcontact) - Create a contact
|
|
453
453
|
- [`accountingCreateAccountingCreditmemo`](docs/sdks/accounting/README.md#createaccountingcreditmemo) - Create a creditmemo
|
|
454
454
|
- [`accountingCreateAccountingCreditmemo`](docs/sdks/creditmemo/README.md#createaccountingcreditmemo) - Create a creditmemo
|
|
455
|
+
- [`accountingCreateAccountingExpense`](docs/sdks/accounting/README.md#createaccountingexpense) - Create an expense
|
|
456
|
+
- [`accountingCreateAccountingExpense`](docs/sdks/expense/README.md#createaccountingexpense) - Create an expense
|
|
455
457
|
- [`accountingCreateAccountingInvoice`](docs/sdks/accounting/README.md#createaccountinginvoice) - Create an invoice
|
|
456
458
|
- [`accountingCreateAccountingInvoice`](docs/sdks/invoice/README.md#createaccountinginvoice) - Create an invoice
|
|
457
459
|
- [`accountingCreateAccountingJournal`](docs/sdks/accounting/README.md#createaccountingjournal) - Create a journal
|
|
@@ -478,6 +480,8 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
|
|
|
478
480
|
- [`accountingGetAccountingContact`](docs/sdks/contact/README.md#getaccountingcontact) - Retrieve a contact
|
|
479
481
|
- [`accountingGetAccountingCreditmemo`](docs/sdks/accounting/README.md#getaccountingcreditmemo) - Retrieve a creditmemo
|
|
480
482
|
- [`accountingGetAccountingCreditmemo`](docs/sdks/creditmemo/README.md#getaccountingcreditmemo) - Retrieve a creditmemo
|
|
483
|
+
- [`accountingGetAccountingExpense`](docs/sdks/accounting/README.md#getaccountingexpense) - Retrieve an expense
|
|
484
|
+
- [`accountingGetAccountingExpense`](docs/sdks/expense/README.md#getaccountingexpense) - Retrieve an expense
|
|
481
485
|
- [`accountingGetAccountingInvoice`](docs/sdks/accounting/README.md#getaccountinginvoice) - Retrieve an invoice
|
|
482
486
|
- [`accountingGetAccountingInvoice`](docs/sdks/invoice/README.md#getaccountinginvoice) - Retrieve an invoice
|
|
483
487
|
- [`accountingGetAccountingJournal`](docs/sdks/accounting/README.md#getaccountingjournal) - Retrieve a journal
|
|
@@ -512,6 +516,8 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
|
|
|
512
516
|
- [`accountingListAccountingContacts`](docs/sdks/contact/README.md#listaccountingcontacts) - List all contacts
|
|
513
517
|
- [`accountingListAccountingCreditmemoes`](docs/sdks/accounting/README.md#listaccountingcreditmemoes) - List all creditmemoes
|
|
514
518
|
- [`accountingListAccountingCreditmemoes`](docs/sdks/creditmemo/README.md#listaccountingcreditmemoes) - List all creditmemoes
|
|
519
|
+
- [`accountingListAccountingExpenses`](docs/sdks/accounting/README.md#listaccountingexpenses) - List all expenses
|
|
520
|
+
- [`accountingListAccountingExpenses`](docs/sdks/expense/README.md#listaccountingexpenses) - List all expenses
|
|
515
521
|
- [`accountingListAccountingInvoices`](docs/sdks/accounting/README.md#listaccountinginvoices) - List all invoices
|
|
516
522
|
- [`accountingListAccountingInvoices`](docs/sdks/invoice/README.md#listaccountinginvoices) - List all invoices
|
|
517
523
|
- [`accountingListAccountingJournals`](docs/sdks/accounting/README.md#listaccountingjournals) - List all journals
|
|
@@ -544,6 +550,8 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
|
|
|
544
550
|
- [`accountingPatchAccountingContact`](docs/sdks/contact/README.md#patchaccountingcontact) - Update a contact
|
|
545
551
|
- [`accountingPatchAccountingCreditmemo`](docs/sdks/accounting/README.md#patchaccountingcreditmemo) - Update a creditmemo
|
|
546
552
|
- [`accountingPatchAccountingCreditmemo`](docs/sdks/creditmemo/README.md#patchaccountingcreditmemo) - Update a creditmemo
|
|
553
|
+
- [`accountingPatchAccountingExpense`](docs/sdks/accounting/README.md#patchaccountingexpense) - Update an expense
|
|
554
|
+
- [`accountingPatchAccountingExpense`](docs/sdks/expense/README.md#patchaccountingexpense) - Update an expense
|
|
547
555
|
- [`accountingPatchAccountingInvoice`](docs/sdks/accounting/README.md#patchaccountinginvoice) - Update an invoice
|
|
548
556
|
- [`accountingPatchAccountingInvoice`](docs/sdks/invoice/README.md#patchaccountinginvoice) - Update an invoice
|
|
549
557
|
- [`accountingPatchAccountingJournal`](docs/sdks/accounting/README.md#patchaccountingjournal) - Update a journal
|
|
@@ -568,6 +576,8 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
|
|
|
568
576
|
- [`accountingRemoveAccountingContact`](docs/sdks/contact/README.md#removeaccountingcontact) - Remove a contact
|
|
569
577
|
- [`accountingRemoveAccountingCreditmemo`](docs/sdks/accounting/README.md#removeaccountingcreditmemo) - Remove a creditmemo
|
|
570
578
|
- [`accountingRemoveAccountingCreditmemo`](docs/sdks/creditmemo/README.md#removeaccountingcreditmemo) - Remove a creditmemo
|
|
579
|
+
- [`accountingRemoveAccountingExpense`](docs/sdks/accounting/README.md#removeaccountingexpense) - Remove an expense
|
|
580
|
+
- [`accountingRemoveAccountingExpense`](docs/sdks/expense/README.md#removeaccountingexpense) - Remove an expense
|
|
571
581
|
- [`accountingRemoveAccountingInvoice`](docs/sdks/accounting/README.md#removeaccountinginvoice) - Remove an invoice
|
|
572
582
|
- [`accountingRemoveAccountingInvoice`](docs/sdks/invoice/README.md#removeaccountinginvoice) - Remove an invoice
|
|
573
583
|
- [`accountingRemoveAccountingJournal`](docs/sdks/accounting/README.md#removeaccountingjournal) - Remove a journal
|
|
@@ -592,6 +602,8 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
|
|
|
592
602
|
- [`accountingUpdateAccountingContact`](docs/sdks/contact/README.md#updateaccountingcontact) - Update a contact
|
|
593
603
|
- [`accountingUpdateAccountingCreditmemo`](docs/sdks/accounting/README.md#updateaccountingcreditmemo) - Update a creditmemo
|
|
594
604
|
- [`accountingUpdateAccountingCreditmemo`](docs/sdks/creditmemo/README.md#updateaccountingcreditmemo) - Update a creditmemo
|
|
605
|
+
- [`accountingUpdateAccountingExpense`](docs/sdks/accounting/README.md#updateaccountingexpense) - Update an expense
|
|
606
|
+
- [`accountingUpdateAccountingExpense`](docs/sdks/expense/README.md#updateaccountingexpense) - Update an expense
|
|
595
607
|
- [`accountingUpdateAccountingInvoice`](docs/sdks/accounting/README.md#updateaccountinginvoice) - Update an invoice
|
|
596
608
|
- [`accountingUpdateAccountingInvoice`](docs/sdks/invoice/README.md#updateaccountinginvoice) - Update an invoice
|
|
597
609
|
- [`accountingUpdateAccountingJournal`](docs/sdks/accounting/README.md#updateaccountingjournal) - Update a journal
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* [createAccountingCategory](#createaccountingcategory) - Create a category
|
|
11
11
|
* [createAccountingContact](#createaccountingcontact) - Create a contact
|
|
12
12
|
* [createAccountingCreditmemo](#createaccountingcreditmemo) - Create a creditmemo
|
|
13
|
+
* [createAccountingExpense](#createaccountingexpense) - Create an expense
|
|
13
14
|
* [createAccountingInvoice](#createaccountinginvoice) - Create an invoice
|
|
14
15
|
* [createAccountingJournal](#createaccountingjournal) - Create a journal
|
|
15
16
|
* [createAccountingOrder](#createaccountingorder) - Create an order
|
|
@@ -23,6 +24,7 @@
|
|
|
23
24
|
* [getAccountingCategory](#getaccountingcategory) - Retrieve a category
|
|
24
25
|
* [getAccountingContact](#getaccountingcontact) - Retrieve a contact
|
|
25
26
|
* [getAccountingCreditmemo](#getaccountingcreditmemo) - Retrieve a creditmemo
|
|
27
|
+
* [getAccountingExpense](#getaccountingexpense) - Retrieve an expense
|
|
26
28
|
* [getAccountingInvoice](#getaccountinginvoice) - Retrieve an invoice
|
|
27
29
|
* [getAccountingJournal](#getaccountingjournal) - Retrieve a journal
|
|
28
30
|
* [getAccountingOrder](#getaccountingorder) - Retrieve an order
|
|
@@ -40,6 +42,7 @@
|
|
|
40
42
|
* [listAccountingCategories](#listaccountingcategories) - List all categories
|
|
41
43
|
* [listAccountingContacts](#listaccountingcontacts) - List all contacts
|
|
42
44
|
* [listAccountingCreditmemoes](#listaccountingcreditmemoes) - List all creditmemoes
|
|
45
|
+
* [listAccountingExpenses](#listaccountingexpenses) - List all expenses
|
|
43
46
|
* [listAccountingInvoices](#listaccountinginvoices) - List all invoices
|
|
44
47
|
* [listAccountingJournals](#listaccountingjournals) - List all journals
|
|
45
48
|
* [listAccountingOrders](#listaccountingorders) - List all orders
|
|
@@ -56,6 +59,7 @@
|
|
|
56
59
|
* [patchAccountingCategory](#patchaccountingcategory) - Update a category
|
|
57
60
|
* [patchAccountingContact](#patchaccountingcontact) - Update a contact
|
|
58
61
|
* [patchAccountingCreditmemo](#patchaccountingcreditmemo) - Update a creditmemo
|
|
62
|
+
* [patchAccountingExpense](#patchaccountingexpense) - Update an expense
|
|
59
63
|
* [patchAccountingInvoice](#patchaccountinginvoice) - Update an invoice
|
|
60
64
|
* [patchAccountingJournal](#patchaccountingjournal) - Update a journal
|
|
61
65
|
* [patchAccountingOrder](#patchaccountingorder) - Update an order
|
|
@@ -68,6 +72,7 @@
|
|
|
68
72
|
* [removeAccountingCategory](#removeaccountingcategory) - Remove a category
|
|
69
73
|
* [removeAccountingContact](#removeaccountingcontact) - Remove a contact
|
|
70
74
|
* [removeAccountingCreditmemo](#removeaccountingcreditmemo) - Remove a creditmemo
|
|
75
|
+
* [removeAccountingExpense](#removeaccountingexpense) - Remove an expense
|
|
71
76
|
* [removeAccountingInvoice](#removeaccountinginvoice) - Remove an invoice
|
|
72
77
|
* [removeAccountingJournal](#removeaccountingjournal) - Remove a journal
|
|
73
78
|
* [removeAccountingOrder](#removeaccountingorder) - Remove an order
|
|
@@ -80,6 +85,7 @@
|
|
|
80
85
|
* [updateAccountingCategory](#updateaccountingcategory) - Update a category
|
|
81
86
|
* [updateAccountingContact](#updateaccountingcontact) - Update a contact
|
|
82
87
|
* [updateAccountingCreditmemo](#updateaccountingcreditmemo) - Update a creditmemo
|
|
88
|
+
* [updateAccountingExpense](#updateaccountingexpense) - Update an expense
|
|
83
89
|
* [updateAccountingInvoice](#updateaccountinginvoice) - Update an invoice
|
|
84
90
|
* [updateAccountingJournal](#updateaccountingjournal) - Update a journal
|
|
85
91
|
* [updateAccountingOrder](#updateaccountingorder) - Update an order
|
|
@@ -483,6 +489,85 @@ run();
|
|
|
483
489
|
| --------------- | --------------- | --------------- |
|
|
484
490
|
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
485
491
|
|
|
492
|
+
## createAccountingExpense
|
|
493
|
+
|
|
494
|
+
Create an expense
|
|
495
|
+
|
|
496
|
+
### Example Usage
|
|
497
|
+
|
|
498
|
+
<!-- UsageSnippet language="typescript" operationID="createAccountingExpense" method="post" path="/accounting/{connection_id}/expense" -->
|
|
499
|
+
```typescript
|
|
500
|
+
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
501
|
+
|
|
502
|
+
const unifiedTo = new UnifiedTo({
|
|
503
|
+
security: {
|
|
504
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
505
|
+
},
|
|
506
|
+
});
|
|
507
|
+
|
|
508
|
+
async function run() {
|
|
509
|
+
const result = await unifiedTo.accounting.createAccountingExpense({
|
|
510
|
+
accountingExpense: {},
|
|
511
|
+
connectionId: "<id>",
|
|
512
|
+
});
|
|
513
|
+
|
|
514
|
+
console.log(result);
|
|
515
|
+
}
|
|
516
|
+
|
|
517
|
+
run();
|
|
518
|
+
```
|
|
519
|
+
|
|
520
|
+
### Standalone function
|
|
521
|
+
|
|
522
|
+
The standalone function version of this method:
|
|
523
|
+
|
|
524
|
+
```typescript
|
|
525
|
+
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
526
|
+
import { accountingCreateAccountingExpense } from "@unified-api/typescript-sdk/funcs/accountingCreateAccountingExpense.js";
|
|
527
|
+
|
|
528
|
+
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
529
|
+
// You can create one instance of it to use across an application.
|
|
530
|
+
const unifiedTo = new UnifiedToCore({
|
|
531
|
+
security: {
|
|
532
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
533
|
+
},
|
|
534
|
+
});
|
|
535
|
+
|
|
536
|
+
async function run() {
|
|
537
|
+
const res = await accountingCreateAccountingExpense(unifiedTo, {
|
|
538
|
+
accountingExpense: {},
|
|
539
|
+
connectionId: "<id>",
|
|
540
|
+
});
|
|
541
|
+
if (res.ok) {
|
|
542
|
+
const { value: result } = res;
|
|
543
|
+
console.log(result);
|
|
544
|
+
} else {
|
|
545
|
+
console.log("accountingCreateAccountingExpense failed:", res.error);
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
run();
|
|
550
|
+
```
|
|
551
|
+
|
|
552
|
+
### Parameters
|
|
553
|
+
|
|
554
|
+
| Parameter | Type | Required | Description |
|
|
555
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
556
|
+
| `request` | [operations.CreateAccountingExpenseRequest](../../sdk/models/operations/createaccountingexpenserequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
557
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
558
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
559
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
560
|
+
|
|
561
|
+
### Response
|
|
562
|
+
|
|
563
|
+
**Promise\<[shared.AccountingExpense](../../sdk/models/shared/accountingexpense.md)\>**
|
|
564
|
+
|
|
565
|
+
### Errors
|
|
566
|
+
|
|
567
|
+
| Error Type | Status Code | Content Type |
|
|
568
|
+
| --------------- | --------------- | --------------- |
|
|
569
|
+
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
570
|
+
|
|
486
571
|
## createAccountingInvoice
|
|
487
572
|
|
|
488
573
|
Create an invoice
|
|
@@ -1510,6 +1595,85 @@ run();
|
|
|
1510
1595
|
| --------------- | --------------- | --------------- |
|
|
1511
1596
|
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1512
1597
|
|
|
1598
|
+
## getAccountingExpense
|
|
1599
|
+
|
|
1600
|
+
Retrieve an expense
|
|
1601
|
+
|
|
1602
|
+
### Example Usage
|
|
1603
|
+
|
|
1604
|
+
<!-- UsageSnippet language="typescript" operationID="getAccountingExpense" method="get" path="/accounting/{connection_id}/expense/{id}" -->
|
|
1605
|
+
```typescript
|
|
1606
|
+
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1607
|
+
|
|
1608
|
+
const unifiedTo = new UnifiedTo({
|
|
1609
|
+
security: {
|
|
1610
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
1611
|
+
},
|
|
1612
|
+
});
|
|
1613
|
+
|
|
1614
|
+
async function run() {
|
|
1615
|
+
const result = await unifiedTo.accounting.getAccountingExpense({
|
|
1616
|
+
connectionId: "<id>",
|
|
1617
|
+
id: "<id>",
|
|
1618
|
+
});
|
|
1619
|
+
|
|
1620
|
+
console.log(result);
|
|
1621
|
+
}
|
|
1622
|
+
|
|
1623
|
+
run();
|
|
1624
|
+
```
|
|
1625
|
+
|
|
1626
|
+
### Standalone function
|
|
1627
|
+
|
|
1628
|
+
The standalone function version of this method:
|
|
1629
|
+
|
|
1630
|
+
```typescript
|
|
1631
|
+
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1632
|
+
import { accountingGetAccountingExpense } from "@unified-api/typescript-sdk/funcs/accountingGetAccountingExpense.js";
|
|
1633
|
+
|
|
1634
|
+
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1635
|
+
// You can create one instance of it to use across an application.
|
|
1636
|
+
const unifiedTo = new UnifiedToCore({
|
|
1637
|
+
security: {
|
|
1638
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
1639
|
+
},
|
|
1640
|
+
});
|
|
1641
|
+
|
|
1642
|
+
async function run() {
|
|
1643
|
+
const res = await accountingGetAccountingExpense(unifiedTo, {
|
|
1644
|
+
connectionId: "<id>",
|
|
1645
|
+
id: "<id>",
|
|
1646
|
+
});
|
|
1647
|
+
if (res.ok) {
|
|
1648
|
+
const { value: result } = res;
|
|
1649
|
+
console.log(result);
|
|
1650
|
+
} else {
|
|
1651
|
+
console.log("accountingGetAccountingExpense failed:", res.error);
|
|
1652
|
+
}
|
|
1653
|
+
}
|
|
1654
|
+
|
|
1655
|
+
run();
|
|
1656
|
+
```
|
|
1657
|
+
|
|
1658
|
+
### Parameters
|
|
1659
|
+
|
|
1660
|
+
| Parameter | Type | Required | Description |
|
|
1661
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1662
|
+
| `request` | [operations.GetAccountingExpenseRequest](../../sdk/models/operations/getaccountingexpenserequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1663
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1664
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
1665
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1666
|
+
|
|
1667
|
+
### Response
|
|
1668
|
+
|
|
1669
|
+
**Promise\<[shared.AccountingExpense](../../sdk/models/shared/accountingexpense.md)\>**
|
|
1670
|
+
|
|
1671
|
+
### Errors
|
|
1672
|
+
|
|
1673
|
+
| Error Type | Status Code | Content Type |
|
|
1674
|
+
| --------------- | --------------- | --------------- |
|
|
1675
|
+
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1676
|
+
|
|
1513
1677
|
## getAccountingInvoice
|
|
1514
1678
|
|
|
1515
1679
|
Retrieve an invoice
|
|
@@ -2841,6 +3005,83 @@ run();
|
|
|
2841
3005
|
| --------------- | --------------- | --------------- |
|
|
2842
3006
|
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2843
3007
|
|
|
3008
|
+
## listAccountingExpenses
|
|
3009
|
+
|
|
3010
|
+
List all expenses
|
|
3011
|
+
|
|
3012
|
+
### Example Usage
|
|
3013
|
+
|
|
3014
|
+
<!-- UsageSnippet language="typescript" operationID="listAccountingExpenses" method="get" path="/accounting/{connection_id}/expense" -->
|
|
3015
|
+
```typescript
|
|
3016
|
+
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
3017
|
+
|
|
3018
|
+
const unifiedTo = new UnifiedTo({
|
|
3019
|
+
security: {
|
|
3020
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
3021
|
+
},
|
|
3022
|
+
});
|
|
3023
|
+
|
|
3024
|
+
async function run() {
|
|
3025
|
+
const result = await unifiedTo.accounting.listAccountingExpenses({
|
|
3026
|
+
connectionId: "<id>",
|
|
3027
|
+
});
|
|
3028
|
+
|
|
3029
|
+
console.log(result);
|
|
3030
|
+
}
|
|
3031
|
+
|
|
3032
|
+
run();
|
|
3033
|
+
```
|
|
3034
|
+
|
|
3035
|
+
### Standalone function
|
|
3036
|
+
|
|
3037
|
+
The standalone function version of this method:
|
|
3038
|
+
|
|
3039
|
+
```typescript
|
|
3040
|
+
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
3041
|
+
import { accountingListAccountingExpenses } from "@unified-api/typescript-sdk/funcs/accountingListAccountingExpenses.js";
|
|
3042
|
+
|
|
3043
|
+
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
3044
|
+
// You can create one instance of it to use across an application.
|
|
3045
|
+
const unifiedTo = new UnifiedToCore({
|
|
3046
|
+
security: {
|
|
3047
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
3048
|
+
},
|
|
3049
|
+
});
|
|
3050
|
+
|
|
3051
|
+
async function run() {
|
|
3052
|
+
const res = await accountingListAccountingExpenses(unifiedTo, {
|
|
3053
|
+
connectionId: "<id>",
|
|
3054
|
+
});
|
|
3055
|
+
if (res.ok) {
|
|
3056
|
+
const { value: result } = res;
|
|
3057
|
+
console.log(result);
|
|
3058
|
+
} else {
|
|
3059
|
+
console.log("accountingListAccountingExpenses failed:", res.error);
|
|
3060
|
+
}
|
|
3061
|
+
}
|
|
3062
|
+
|
|
3063
|
+
run();
|
|
3064
|
+
```
|
|
3065
|
+
|
|
3066
|
+
### Parameters
|
|
3067
|
+
|
|
3068
|
+
| Parameter | Type | Required | Description |
|
|
3069
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
3070
|
+
| `request` | [operations.ListAccountingExpensesRequest](../../sdk/models/operations/listaccountingexpensesrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
3071
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
3072
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
3073
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
3074
|
+
|
|
3075
|
+
### Response
|
|
3076
|
+
|
|
3077
|
+
**Promise\<[shared.AccountingExpense[]](../../models/.md)\>**
|
|
3078
|
+
|
|
3079
|
+
### Errors
|
|
3080
|
+
|
|
3081
|
+
| Error Type | Status Code | Content Type |
|
|
3082
|
+
| --------------- | --------------- | --------------- |
|
|
3083
|
+
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
3084
|
+
|
|
2844
3085
|
## listAccountingInvoices
|
|
2845
3086
|
|
|
2846
3087
|
List all invoices
|
|
@@ -4093,6 +4334,87 @@ run();
|
|
|
4093
4334
|
| --------------- | --------------- | --------------- |
|
|
4094
4335
|
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
4095
4336
|
|
|
4337
|
+
## patchAccountingExpense
|
|
4338
|
+
|
|
4339
|
+
Update an expense
|
|
4340
|
+
|
|
4341
|
+
### Example Usage
|
|
4342
|
+
|
|
4343
|
+
<!-- UsageSnippet language="typescript" operationID="patchAccountingExpense" method="patch" path="/accounting/{connection_id}/expense/{id}" -->
|
|
4344
|
+
```typescript
|
|
4345
|
+
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
4346
|
+
|
|
4347
|
+
const unifiedTo = new UnifiedTo({
|
|
4348
|
+
security: {
|
|
4349
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
4350
|
+
},
|
|
4351
|
+
});
|
|
4352
|
+
|
|
4353
|
+
async function run() {
|
|
4354
|
+
const result = await unifiedTo.accounting.patchAccountingExpense({
|
|
4355
|
+
accountingExpense: {},
|
|
4356
|
+
connectionId: "<id>",
|
|
4357
|
+
id: "<id>",
|
|
4358
|
+
});
|
|
4359
|
+
|
|
4360
|
+
console.log(result);
|
|
4361
|
+
}
|
|
4362
|
+
|
|
4363
|
+
run();
|
|
4364
|
+
```
|
|
4365
|
+
|
|
4366
|
+
### Standalone function
|
|
4367
|
+
|
|
4368
|
+
The standalone function version of this method:
|
|
4369
|
+
|
|
4370
|
+
```typescript
|
|
4371
|
+
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
4372
|
+
import { accountingPatchAccountingExpense } from "@unified-api/typescript-sdk/funcs/accountingPatchAccountingExpense.js";
|
|
4373
|
+
|
|
4374
|
+
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
4375
|
+
// You can create one instance of it to use across an application.
|
|
4376
|
+
const unifiedTo = new UnifiedToCore({
|
|
4377
|
+
security: {
|
|
4378
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
4379
|
+
},
|
|
4380
|
+
});
|
|
4381
|
+
|
|
4382
|
+
async function run() {
|
|
4383
|
+
const res = await accountingPatchAccountingExpense(unifiedTo, {
|
|
4384
|
+
accountingExpense: {},
|
|
4385
|
+
connectionId: "<id>",
|
|
4386
|
+
id: "<id>",
|
|
4387
|
+
});
|
|
4388
|
+
if (res.ok) {
|
|
4389
|
+
const { value: result } = res;
|
|
4390
|
+
console.log(result);
|
|
4391
|
+
} else {
|
|
4392
|
+
console.log("accountingPatchAccountingExpense failed:", res.error);
|
|
4393
|
+
}
|
|
4394
|
+
}
|
|
4395
|
+
|
|
4396
|
+
run();
|
|
4397
|
+
```
|
|
4398
|
+
|
|
4399
|
+
### Parameters
|
|
4400
|
+
|
|
4401
|
+
| Parameter | Type | Required | Description |
|
|
4402
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
4403
|
+
| `request` | [operations.PatchAccountingExpenseRequest](../../sdk/models/operations/patchaccountingexpenserequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
4404
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
4405
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
4406
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
4407
|
+
|
|
4408
|
+
### Response
|
|
4409
|
+
|
|
4410
|
+
**Promise\<[shared.AccountingExpense](../../sdk/models/shared/accountingexpense.md)\>**
|
|
4411
|
+
|
|
4412
|
+
### Errors
|
|
4413
|
+
|
|
4414
|
+
| Error Type | Status Code | Content Type |
|
|
4415
|
+
| --------------- | --------------- | --------------- |
|
|
4416
|
+
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
4417
|
+
|
|
4096
4418
|
## patchAccountingInvoice
|
|
4097
4419
|
|
|
4098
4420
|
Update an invoice
|
|
@@ -5055,6 +5377,85 @@ run();
|
|
|
5055
5377
|
| --------------- | --------------- | --------------- |
|
|
5056
5378
|
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
5057
5379
|
|
|
5380
|
+
## removeAccountingExpense
|
|
5381
|
+
|
|
5382
|
+
Remove an expense
|
|
5383
|
+
|
|
5384
|
+
### Example Usage
|
|
5385
|
+
|
|
5386
|
+
<!-- UsageSnippet language="typescript" operationID="removeAccountingExpense" method="delete" path="/accounting/{connection_id}/expense/{id}" -->
|
|
5387
|
+
```typescript
|
|
5388
|
+
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
5389
|
+
|
|
5390
|
+
const unifiedTo = new UnifiedTo({
|
|
5391
|
+
security: {
|
|
5392
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
5393
|
+
},
|
|
5394
|
+
});
|
|
5395
|
+
|
|
5396
|
+
async function run() {
|
|
5397
|
+
const result = await unifiedTo.accounting.removeAccountingExpense({
|
|
5398
|
+
connectionId: "<id>",
|
|
5399
|
+
id: "<id>",
|
|
5400
|
+
});
|
|
5401
|
+
|
|
5402
|
+
console.log(result);
|
|
5403
|
+
}
|
|
5404
|
+
|
|
5405
|
+
run();
|
|
5406
|
+
```
|
|
5407
|
+
|
|
5408
|
+
### Standalone function
|
|
5409
|
+
|
|
5410
|
+
The standalone function version of this method:
|
|
5411
|
+
|
|
5412
|
+
```typescript
|
|
5413
|
+
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
5414
|
+
import { accountingRemoveAccountingExpense } from "@unified-api/typescript-sdk/funcs/accountingRemoveAccountingExpense.js";
|
|
5415
|
+
|
|
5416
|
+
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
5417
|
+
// You can create one instance of it to use across an application.
|
|
5418
|
+
const unifiedTo = new UnifiedToCore({
|
|
5419
|
+
security: {
|
|
5420
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
5421
|
+
},
|
|
5422
|
+
});
|
|
5423
|
+
|
|
5424
|
+
async function run() {
|
|
5425
|
+
const res = await accountingRemoveAccountingExpense(unifiedTo, {
|
|
5426
|
+
connectionId: "<id>",
|
|
5427
|
+
id: "<id>",
|
|
5428
|
+
});
|
|
5429
|
+
if (res.ok) {
|
|
5430
|
+
const { value: result } = res;
|
|
5431
|
+
console.log(result);
|
|
5432
|
+
} else {
|
|
5433
|
+
console.log("accountingRemoveAccountingExpense failed:", res.error);
|
|
5434
|
+
}
|
|
5435
|
+
}
|
|
5436
|
+
|
|
5437
|
+
run();
|
|
5438
|
+
```
|
|
5439
|
+
|
|
5440
|
+
### Parameters
|
|
5441
|
+
|
|
5442
|
+
| Parameter | Type | Required | Description |
|
|
5443
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
5444
|
+
| `request` | [operations.RemoveAccountingExpenseRequest](../../sdk/models/operations/removeaccountingexpenserequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
5445
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
5446
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
5447
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
5448
|
+
|
|
5449
|
+
### Response
|
|
5450
|
+
|
|
5451
|
+
**Promise\<[operations.RemoveAccountingExpenseResponse](../../sdk/models/operations/removeaccountingexpenseresponse.md)\>**
|
|
5452
|
+
|
|
5453
|
+
### Errors
|
|
5454
|
+
|
|
5455
|
+
| Error Type | Status Code | Content Type |
|
|
5456
|
+
| --------------- | --------------- | --------------- |
|
|
5457
|
+
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
5458
|
+
|
|
5058
5459
|
## removeAccountingInvoice
|
|
5059
5460
|
|
|
5060
5461
|
Remove an invoice
|
|
@@ -6013,6 +6414,87 @@ run();
|
|
|
6013
6414
|
| --------------- | --------------- | --------------- |
|
|
6014
6415
|
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
6015
6416
|
|
|
6417
|
+
## updateAccountingExpense
|
|
6418
|
+
|
|
6419
|
+
Update an expense
|
|
6420
|
+
|
|
6421
|
+
### Example Usage
|
|
6422
|
+
|
|
6423
|
+
<!-- UsageSnippet language="typescript" operationID="updateAccountingExpense" method="put" path="/accounting/{connection_id}/expense/{id}" -->
|
|
6424
|
+
```typescript
|
|
6425
|
+
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
6426
|
+
|
|
6427
|
+
const unifiedTo = new UnifiedTo({
|
|
6428
|
+
security: {
|
|
6429
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
6430
|
+
},
|
|
6431
|
+
});
|
|
6432
|
+
|
|
6433
|
+
async function run() {
|
|
6434
|
+
const result = await unifiedTo.accounting.updateAccountingExpense({
|
|
6435
|
+
accountingExpense: {},
|
|
6436
|
+
connectionId: "<id>",
|
|
6437
|
+
id: "<id>",
|
|
6438
|
+
});
|
|
6439
|
+
|
|
6440
|
+
console.log(result);
|
|
6441
|
+
}
|
|
6442
|
+
|
|
6443
|
+
run();
|
|
6444
|
+
```
|
|
6445
|
+
|
|
6446
|
+
### Standalone function
|
|
6447
|
+
|
|
6448
|
+
The standalone function version of this method:
|
|
6449
|
+
|
|
6450
|
+
```typescript
|
|
6451
|
+
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
6452
|
+
import { accountingUpdateAccountingExpense } from "@unified-api/typescript-sdk/funcs/accountingUpdateAccountingExpense.js";
|
|
6453
|
+
|
|
6454
|
+
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
6455
|
+
// You can create one instance of it to use across an application.
|
|
6456
|
+
const unifiedTo = new UnifiedToCore({
|
|
6457
|
+
security: {
|
|
6458
|
+
jwt: "<YOUR_API_KEY_HERE>",
|
|
6459
|
+
},
|
|
6460
|
+
});
|
|
6461
|
+
|
|
6462
|
+
async function run() {
|
|
6463
|
+
const res = await accountingUpdateAccountingExpense(unifiedTo, {
|
|
6464
|
+
accountingExpense: {},
|
|
6465
|
+
connectionId: "<id>",
|
|
6466
|
+
id: "<id>",
|
|
6467
|
+
});
|
|
6468
|
+
if (res.ok) {
|
|
6469
|
+
const { value: result } = res;
|
|
6470
|
+
console.log(result);
|
|
6471
|
+
} else {
|
|
6472
|
+
console.log("accountingUpdateAccountingExpense failed:", res.error);
|
|
6473
|
+
}
|
|
6474
|
+
}
|
|
6475
|
+
|
|
6476
|
+
run();
|
|
6477
|
+
```
|
|
6478
|
+
|
|
6479
|
+
### Parameters
|
|
6480
|
+
|
|
6481
|
+
| Parameter | Type | Required | Description |
|
|
6482
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
6483
|
+
| `request` | [operations.UpdateAccountingExpenseRequest](../../sdk/models/operations/updateaccountingexpenserequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
6484
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
6485
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
6486
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
6487
|
+
|
|
6488
|
+
### Response
|
|
6489
|
+
|
|
6490
|
+
**Promise\<[shared.AccountingExpense](../../sdk/models/shared/accountingexpense.md)\>**
|
|
6491
|
+
|
|
6492
|
+
### Errors
|
|
6493
|
+
|
|
6494
|
+
| Error Type | Status Code | Content Type |
|
|
6495
|
+
| --------------- | --------------- | --------------- |
|
|
6496
|
+
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
6497
|
+
|
|
6016
6498
|
## updateAccountingInvoice
|
|
6017
6499
|
|
|
6018
6500
|
Update an invoice
|