@unified-api/typescript-sdk 2.79.0 → 2.80.1
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/examples/package-lock.json +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/package.json +1 -1
- package/sdk/models/shared/calendareventrecurrence.d.ts +2 -5
- package/sdk/models/shared/calendareventrecurrence.d.ts.map +1 -1
- package/sdk/models/shared/calendareventrecurrence.js +2 -2
- package/sdk/models/shared/calendareventrecurrence.js.map +1 -1
- package/sdk/models/shared/index.d.ts +5 -0
- package/sdk/models/shared/index.d.ts.map +1 -1
- package/sdk/models/shared/index.js +5 -0
- package/sdk/models/shared/index.js.map +1 -1
- package/sdk/models/shared/integration.d.ts +3 -2
- package/sdk/models/shared/integration.d.ts.map +1 -1
- package/sdk/models/shared/integration.js +3 -2
- package/sdk/models/shared/integration.js.map +1 -1
- package/sdk/models/shared/integrationsupport.d.ts +2410 -0
- package/sdk/models/shared/integrationsupport.d.ts.map +1 -0
- package/sdk/models/shared/integrationsupport.js +3440 -0
- package/sdk/models/shared/integrationsupport.js.map +1 -0
- package/sdk/models/shared/kmspage.d.ts +2 -0
- package/sdk/models/shared/kmspage.d.ts.map +1 -1
- package/sdk/models/shared/kmspage.js +4 -0
- package/sdk/models/shared/kmspage.js.map +1 -1
- package/sdk/models/shared/propertyintegrationsupportwebhookevents.d.ts +36 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookevents.d.ts.map +1 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookevents.js +79 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookevents.js.map +1 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventscreated.d.ts +22 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventscreated.d.ts.map +1 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventscreated.js +68 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventscreated.js.map +1 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsdeleted.d.ts +22 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsdeleted.d.ts.map +1 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsdeleted.js +68 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsdeleted.js.map +1 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsupdated.d.ts +22 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsupdated.d.ts.map +1 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsupdated.js +68 -0
- package/sdk/models/shared/propertyintegrationsupportwebhookeventsupdated.js.map +1 -0
- package/sdk/models/shared/webhook.d.ts +2 -2
- package/sdk/models/shared/webhook.d.ts.map +1 -1
- package/sdk/models/shared/webhook.js +2 -2
- package/sdk/models/shared/webhook.js.map +1 -1
- package/src/lib/config.ts +3 -3
- package/src/sdk/models/shared/calendareventrecurrence.ts +4 -7
- package/src/sdk/models/shared/index.ts +5 -0
- package/src/sdk/models/shared/integration.ts +10 -4
- package/src/sdk/models/shared/integrationsupport.ts +4969 -0
- package/src/sdk/models/shared/kmspage.ts +6 -0
- package/src/sdk/models/shared/propertyintegrationsupportwebhookevents.ts +109 -0
- package/src/sdk/models/shared/propertyintegrationsupportwebhookeventscreated.ts +54 -0
- package/src/sdk/models/shared/propertyintegrationsupportwebhookeventsdeleted.ts +54 -0
- package/src/sdk/models/shared/propertyintegrationsupportwebhookeventsupdated.ts +54 -0
- package/src/sdk/models/shared/webhook.ts +4 -4
- package/docs/sdks/account/README.md +0 -489
- package/docs/sdks/accounting/README.md +0 -7221
- package/docs/sdks/activity/README.md +0 -489
- package/docs/sdks/apicall/README.md +0 -159
- package/docs/sdks/application/README.md +0 -489
- package/docs/sdks/applicationstatus/README.md +0 -85
- package/docs/sdks/ats/README.md +0 -3953
- package/docs/sdks/auth/README.md +0 -167
- package/docs/sdks/balancesheet/README.md +0 -165
- package/docs/sdks/bill/README.md +0 -489
- package/docs/sdks/branch/README.md +0 -507
- package/docs/sdks/busy/README.md +0 -85
- package/docs/sdks/calendar/README.md +0 -1713
- package/docs/sdks/call/README.md +0 -85
- package/docs/sdks/candidate/README.md +0 -489
- package/docs/sdks/cashflow/README.md +0 -165
- package/docs/sdks/category/README.md +0 -971
- package/docs/sdks/change/README.md +0 -165
- package/docs/sdks/channel/README.md +0 -165
- package/docs/sdks/class/README.md +0 -507
- package/docs/sdks/collection/README.md +0 -501
- package/docs/sdks/comment/README.md +0 -1495
- package/docs/sdks/commerce/README.md +0 -2465
- package/docs/sdks/commit/README.md +0 -501
- package/docs/sdks/company/README.md +0 -1543
- package/docs/sdks/connection/README.md +0 -513
- package/docs/sdks/contact/README.md +0 -1453
- package/docs/sdks/course/README.md +0 -501
- package/docs/sdks/creditmemo/README.md +0 -489
- package/docs/sdks/crm/README.md +0 -2899
- package/docs/sdks/customer/README.md +0 -489
- package/docs/sdks/deal/README.md +0 -489
- package/docs/sdks/device/README.md +0 -501
- package/docs/sdks/document/README.md +0 -489
- package/docs/sdks/embedding/README.md +0 -87
- package/docs/sdks/employee/README.md +0 -489
- package/docs/sdks/enrich/README.md +0 -163
- package/docs/sdks/event/README.md +0 -971
- package/docs/sdks/expense/README.md +0 -489
- package/docs/sdks/file/README.md +0 -489
- package/docs/sdks/genai/README.md +0 -325
- package/docs/sdks/group/README.md +0 -983
- package/docs/sdks/hris/README.md +0 -3251
- package/docs/sdks/instructor/README.md +0 -489
- package/docs/sdks/integration/README.md +0 -239
- package/docs/sdks/interview/README.md +0 -489
- package/docs/sdks/inventory/README.md +0 -501
- package/docs/sdks/invoice/README.md +0 -489
- package/docs/sdks/issue/README.md +0 -159
- package/docs/sdks/item/README.md +0 -489
- package/docs/sdks/job/README.md +0 -489
- package/docs/sdks/journal/README.md +0 -489
- package/docs/sdks/kms/README.md +0 -1495
- package/docs/sdks/lead/README.md +0 -489
- package/docs/sdks/link/README.md +0 -983
- package/docs/sdks/list/README.md +0 -489
- package/docs/sdks/lms/README.md +0 -1965
- package/docs/sdks/location/README.md +0 -983
- package/docs/sdks/login/README.md +0 -87
- package/docs/sdks/martech/README.md +0 -971
- package/docs/sdks/member/README.md +0 -489
- package/docs/sdks/message/README.md +0 -489
- package/docs/sdks/messaging/README.md +0 -647
- package/docs/sdks/metadata/README.md +0 -507
- package/docs/sdks/model/README.md +0 -165
- package/docs/sdks/note/README.md +0 -489
- package/docs/sdks/order/README.md +0 -489
- package/docs/sdks/organization/README.md +0 -647
- package/docs/sdks/package/README.md +0 -165
- package/docs/sdks/page/README.md +0 -507
- package/docs/sdks/passthrough/README.md +0 -647
- package/docs/sdks/payment/README.md +0 -1769
- package/docs/sdks/payout/README.md +0 -165
- package/docs/sdks/payslip/README.md +0 -165
- package/docs/sdks/person/README.md +0 -85
- package/docs/sdks/pipeline/README.md +0 -489
- package/docs/sdks/profitloss/README.md +0 -165
- package/docs/sdks/project/README.md +0 -489
- package/docs/sdks/prompt/README.md +0 -87
- package/docs/sdks/pullrequest/README.md +0 -489
- package/docs/sdks/purchaseorder/README.md +0 -489
- package/docs/sdks/recording/README.md +0 -647
- package/docs/sdks/refund/README.md +0 -165
- package/docs/sdks/repo/README.md +0 -2459
- package/docs/sdks/report/README.md +0 -165
- package/docs/sdks/repository/README.md +0 -501
- package/docs/sdks/request/README.md +0 -489
- package/docs/sdks/review/README.md +0 -501
- package/docs/sdks/salesorder/README.md +0 -489
- package/docs/sdks/scim/README.md +0 -983
- package/docs/sdks/scorecard/README.md +0 -489
- package/docs/sdks/space/README.md +0 -501
- package/docs/sdks/storage/README.md +0 -489
- package/docs/sdks/student/README.md +0 -489
- package/docs/sdks/subscription/README.md +0 -489
- package/docs/sdks/task/README.md +0 -1629
- package/docs/sdks/taxrate/README.md +0 -489
- package/docs/sdks/ticket/README.md +0 -489
- package/docs/sdks/ticketing/README.md +0 -1935
- package/docs/sdks/timeoff/README.md +0 -165
- package/docs/sdks/timeshift/README.md +0 -513
- package/docs/sdks/transaction/README.md +0 -489
- package/docs/sdks/trialbalance/README.md +0 -165
- package/docs/sdks/uc/README.md +0 -1543
- package/docs/sdks/unified/README.md +0 -1697
- package/docs/sdks/user/README.md +0 -489
- package/docs/sdks/verification/README.md +0 -647
- package/docs/sdks/webhook/README.md +0 -655
- package/examples/README.md +0 -31
package/docs/sdks/crm/README.md
DELETED
|
@@ -1,2899 +0,0 @@
|
|
|
1
|
-
# Crm
|
|
2
|
-
(*crm*)
|
|
3
|
-
|
|
4
|
-
## Overview
|
|
5
|
-
|
|
6
|
-
### Available Operations
|
|
7
|
-
|
|
8
|
-
* [createCrmCompany](#createcrmcompany) - Create a company
|
|
9
|
-
* [createCrmContact](#createcrmcontact) - Create a contact
|
|
10
|
-
* [createCrmDeal](#createcrmdeal) - Create a deal
|
|
11
|
-
* [createCrmEvent](#createcrmevent) - Create an event
|
|
12
|
-
* [createCrmLead](#createcrmlead) - Create a lead
|
|
13
|
-
* [createCrmPipeline](#createcrmpipeline) - Create a pipeline
|
|
14
|
-
* [getCrmCompany](#getcrmcompany) - Retrieve a company
|
|
15
|
-
* [getCrmContact](#getcrmcontact) - Retrieve a contact
|
|
16
|
-
* [getCrmDeal](#getcrmdeal) - Retrieve a deal
|
|
17
|
-
* [getCrmEvent](#getcrmevent) - Retrieve an event
|
|
18
|
-
* [getCrmLead](#getcrmlead) - Retrieve a lead
|
|
19
|
-
* [getCrmPipeline](#getcrmpipeline) - Retrieve a pipeline
|
|
20
|
-
* [listCrmCompanies](#listcrmcompanies) - List all companies
|
|
21
|
-
* [listCrmContacts](#listcrmcontacts) - List all contacts
|
|
22
|
-
* [listCrmDeals](#listcrmdeals) - List all deals
|
|
23
|
-
* [listCrmEvents](#listcrmevents) - List all events
|
|
24
|
-
* [listCrmLeads](#listcrmleads) - List all leads
|
|
25
|
-
* [listCrmPipelines](#listcrmpipelines) - List all pipelines
|
|
26
|
-
* [patchCrmCompany](#patchcrmcompany) - Update a company
|
|
27
|
-
* [patchCrmContact](#patchcrmcontact) - Update a contact
|
|
28
|
-
* [patchCrmDeal](#patchcrmdeal) - Update a deal
|
|
29
|
-
* [patchCrmEvent](#patchcrmevent) - Update an event
|
|
30
|
-
* [patchCrmLead](#patchcrmlead) - Update a lead
|
|
31
|
-
* [patchCrmPipeline](#patchcrmpipeline) - Update a pipeline
|
|
32
|
-
* [removeCrmCompany](#removecrmcompany) - Remove a company
|
|
33
|
-
* [removeCrmContact](#removecrmcontact) - Remove a contact
|
|
34
|
-
* [removeCrmDeal](#removecrmdeal) - Remove a deal
|
|
35
|
-
* [removeCrmEvent](#removecrmevent) - Remove an event
|
|
36
|
-
* [removeCrmLead](#removecrmlead) - Remove a lead
|
|
37
|
-
* [removeCrmPipeline](#removecrmpipeline) - Remove a pipeline
|
|
38
|
-
* [updateCrmCompany](#updatecrmcompany) - Update a company
|
|
39
|
-
* [updateCrmContact](#updatecrmcontact) - Update a contact
|
|
40
|
-
* [updateCrmDeal](#updatecrmdeal) - Update a deal
|
|
41
|
-
* [updateCrmEvent](#updatecrmevent) - Update an event
|
|
42
|
-
* [updateCrmLead](#updatecrmlead) - Update a lead
|
|
43
|
-
* [updateCrmPipeline](#updatecrmpipeline) - Update a pipeline
|
|
44
|
-
|
|
45
|
-
## createCrmCompany
|
|
46
|
-
|
|
47
|
-
Create a company
|
|
48
|
-
|
|
49
|
-
### Example Usage
|
|
50
|
-
|
|
51
|
-
<!-- UsageSnippet language="typescript" operationID="createCrmCompany" method="post" path="/crm/{connection_id}/company" -->
|
|
52
|
-
```typescript
|
|
53
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
54
|
-
|
|
55
|
-
const unifiedTo = new UnifiedTo({
|
|
56
|
-
security: {
|
|
57
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
58
|
-
},
|
|
59
|
-
});
|
|
60
|
-
|
|
61
|
-
async function run() {
|
|
62
|
-
const result = await unifiedTo.crm.createCrmCompany({
|
|
63
|
-
crmCompany: {},
|
|
64
|
-
connectionId: "<id>",
|
|
65
|
-
});
|
|
66
|
-
|
|
67
|
-
console.log(result);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
run();
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
### Standalone function
|
|
74
|
-
|
|
75
|
-
The standalone function version of this method:
|
|
76
|
-
|
|
77
|
-
```typescript
|
|
78
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
79
|
-
import { companyCreateCrmCompany } from "@unified-api/typescript-sdk/funcs/companyCreateCrmCompany.js";
|
|
80
|
-
|
|
81
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
82
|
-
// You can create one instance of it to use across an application.
|
|
83
|
-
const unifiedTo = new UnifiedToCore({
|
|
84
|
-
security: {
|
|
85
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
86
|
-
},
|
|
87
|
-
});
|
|
88
|
-
|
|
89
|
-
async function run() {
|
|
90
|
-
const res = await companyCreateCrmCompany(unifiedTo, {
|
|
91
|
-
crmCompany: {},
|
|
92
|
-
connectionId: "<id>",
|
|
93
|
-
});
|
|
94
|
-
if (res.ok) {
|
|
95
|
-
const { value: result } = res;
|
|
96
|
-
console.log(result);
|
|
97
|
-
} else {
|
|
98
|
-
console.log("companyCreateCrmCompany failed:", res.error);
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
run();
|
|
103
|
-
```
|
|
104
|
-
|
|
105
|
-
### Parameters
|
|
106
|
-
|
|
107
|
-
| Parameter | Type | Required | Description |
|
|
108
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
109
|
-
| `request` | [operations.CreateCrmCompanyRequest](../../sdk/models/operations/createcrmcompanyrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
110
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
111
|
-
| `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. |
|
|
112
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
113
|
-
|
|
114
|
-
### Response
|
|
115
|
-
|
|
116
|
-
**Promise\<[shared.CrmCompany](../../sdk/models/shared/crmcompany.md)\>**
|
|
117
|
-
|
|
118
|
-
### Errors
|
|
119
|
-
|
|
120
|
-
| Error Type | Status Code | Content Type |
|
|
121
|
-
| --------------- | --------------- | --------------- |
|
|
122
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
123
|
-
|
|
124
|
-
## createCrmContact
|
|
125
|
-
|
|
126
|
-
Create a contact
|
|
127
|
-
|
|
128
|
-
### Example Usage
|
|
129
|
-
|
|
130
|
-
<!-- UsageSnippet language="typescript" operationID="createCrmContact" method="post" path="/crm/{connection_id}/contact" -->
|
|
131
|
-
```typescript
|
|
132
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
133
|
-
|
|
134
|
-
const unifiedTo = new UnifiedTo({
|
|
135
|
-
security: {
|
|
136
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
137
|
-
},
|
|
138
|
-
});
|
|
139
|
-
|
|
140
|
-
async function run() {
|
|
141
|
-
const result = await unifiedTo.crm.createCrmContact({
|
|
142
|
-
crmContact: {},
|
|
143
|
-
connectionId: "<id>",
|
|
144
|
-
});
|
|
145
|
-
|
|
146
|
-
console.log(result);
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
run();
|
|
150
|
-
```
|
|
151
|
-
|
|
152
|
-
### Standalone function
|
|
153
|
-
|
|
154
|
-
The standalone function version of this method:
|
|
155
|
-
|
|
156
|
-
```typescript
|
|
157
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
158
|
-
import { contactCreateCrmContact } from "@unified-api/typescript-sdk/funcs/contactCreateCrmContact.js";
|
|
159
|
-
|
|
160
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
161
|
-
// You can create one instance of it to use across an application.
|
|
162
|
-
const unifiedTo = new UnifiedToCore({
|
|
163
|
-
security: {
|
|
164
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
165
|
-
},
|
|
166
|
-
});
|
|
167
|
-
|
|
168
|
-
async function run() {
|
|
169
|
-
const res = await contactCreateCrmContact(unifiedTo, {
|
|
170
|
-
crmContact: {},
|
|
171
|
-
connectionId: "<id>",
|
|
172
|
-
});
|
|
173
|
-
if (res.ok) {
|
|
174
|
-
const { value: result } = res;
|
|
175
|
-
console.log(result);
|
|
176
|
-
} else {
|
|
177
|
-
console.log("contactCreateCrmContact failed:", res.error);
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
run();
|
|
182
|
-
```
|
|
183
|
-
|
|
184
|
-
### Parameters
|
|
185
|
-
|
|
186
|
-
| Parameter | Type | Required | Description |
|
|
187
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
188
|
-
| `request` | [operations.CreateCrmContactRequest](../../sdk/models/operations/createcrmcontactrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
189
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
190
|
-
| `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. |
|
|
191
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
192
|
-
|
|
193
|
-
### Response
|
|
194
|
-
|
|
195
|
-
**Promise\<[shared.CrmContact](../../sdk/models/shared/crmcontact.md)\>**
|
|
196
|
-
|
|
197
|
-
### Errors
|
|
198
|
-
|
|
199
|
-
| Error Type | Status Code | Content Type |
|
|
200
|
-
| --------------- | --------------- | --------------- |
|
|
201
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
202
|
-
|
|
203
|
-
## createCrmDeal
|
|
204
|
-
|
|
205
|
-
Create a deal
|
|
206
|
-
|
|
207
|
-
### Example Usage
|
|
208
|
-
|
|
209
|
-
<!-- UsageSnippet language="typescript" operationID="createCrmDeal" method="post" path="/crm/{connection_id}/deal" -->
|
|
210
|
-
```typescript
|
|
211
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
212
|
-
|
|
213
|
-
const unifiedTo = new UnifiedTo({
|
|
214
|
-
security: {
|
|
215
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
216
|
-
},
|
|
217
|
-
});
|
|
218
|
-
|
|
219
|
-
async function run() {
|
|
220
|
-
const result = await unifiedTo.crm.createCrmDeal({
|
|
221
|
-
crmDeal: {},
|
|
222
|
-
connectionId: "<id>",
|
|
223
|
-
});
|
|
224
|
-
|
|
225
|
-
console.log(result);
|
|
226
|
-
}
|
|
227
|
-
|
|
228
|
-
run();
|
|
229
|
-
```
|
|
230
|
-
|
|
231
|
-
### Standalone function
|
|
232
|
-
|
|
233
|
-
The standalone function version of this method:
|
|
234
|
-
|
|
235
|
-
```typescript
|
|
236
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
237
|
-
import { crmCreateCrmDeal } from "@unified-api/typescript-sdk/funcs/crmCreateCrmDeal.js";
|
|
238
|
-
|
|
239
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
240
|
-
// You can create one instance of it to use across an application.
|
|
241
|
-
const unifiedTo = new UnifiedToCore({
|
|
242
|
-
security: {
|
|
243
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
244
|
-
},
|
|
245
|
-
});
|
|
246
|
-
|
|
247
|
-
async function run() {
|
|
248
|
-
const res = await crmCreateCrmDeal(unifiedTo, {
|
|
249
|
-
crmDeal: {},
|
|
250
|
-
connectionId: "<id>",
|
|
251
|
-
});
|
|
252
|
-
if (res.ok) {
|
|
253
|
-
const { value: result } = res;
|
|
254
|
-
console.log(result);
|
|
255
|
-
} else {
|
|
256
|
-
console.log("crmCreateCrmDeal failed:", res.error);
|
|
257
|
-
}
|
|
258
|
-
}
|
|
259
|
-
|
|
260
|
-
run();
|
|
261
|
-
```
|
|
262
|
-
|
|
263
|
-
### Parameters
|
|
264
|
-
|
|
265
|
-
| Parameter | Type | Required | Description |
|
|
266
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
267
|
-
| `request` | [operations.CreateCrmDealRequest](../../sdk/models/operations/createcrmdealrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
268
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
269
|
-
| `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. |
|
|
270
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
271
|
-
|
|
272
|
-
### Response
|
|
273
|
-
|
|
274
|
-
**Promise\<[shared.CrmDeal](../../sdk/models/shared/crmdeal.md)\>**
|
|
275
|
-
|
|
276
|
-
### Errors
|
|
277
|
-
|
|
278
|
-
| Error Type | Status Code | Content Type |
|
|
279
|
-
| --------------- | --------------- | --------------- |
|
|
280
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
281
|
-
|
|
282
|
-
## createCrmEvent
|
|
283
|
-
|
|
284
|
-
Create an event
|
|
285
|
-
|
|
286
|
-
### Example Usage
|
|
287
|
-
|
|
288
|
-
<!-- UsageSnippet language="typescript" operationID="createCrmEvent" method="post" path="/crm/{connection_id}/event" -->
|
|
289
|
-
```typescript
|
|
290
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
291
|
-
|
|
292
|
-
const unifiedTo = new UnifiedTo({
|
|
293
|
-
security: {
|
|
294
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
295
|
-
},
|
|
296
|
-
});
|
|
297
|
-
|
|
298
|
-
async function run() {
|
|
299
|
-
const result = await unifiedTo.crm.createCrmEvent({
|
|
300
|
-
crmEvent: {},
|
|
301
|
-
connectionId: "<id>",
|
|
302
|
-
});
|
|
303
|
-
|
|
304
|
-
console.log(result);
|
|
305
|
-
}
|
|
306
|
-
|
|
307
|
-
run();
|
|
308
|
-
```
|
|
309
|
-
|
|
310
|
-
### Standalone function
|
|
311
|
-
|
|
312
|
-
The standalone function version of this method:
|
|
313
|
-
|
|
314
|
-
```typescript
|
|
315
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
316
|
-
import { eventCreateCrmEvent } from "@unified-api/typescript-sdk/funcs/eventCreateCrmEvent.js";
|
|
317
|
-
|
|
318
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
319
|
-
// You can create one instance of it to use across an application.
|
|
320
|
-
const unifiedTo = new UnifiedToCore({
|
|
321
|
-
security: {
|
|
322
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
323
|
-
},
|
|
324
|
-
});
|
|
325
|
-
|
|
326
|
-
async function run() {
|
|
327
|
-
const res = await eventCreateCrmEvent(unifiedTo, {
|
|
328
|
-
crmEvent: {},
|
|
329
|
-
connectionId: "<id>",
|
|
330
|
-
});
|
|
331
|
-
if (res.ok) {
|
|
332
|
-
const { value: result } = res;
|
|
333
|
-
console.log(result);
|
|
334
|
-
} else {
|
|
335
|
-
console.log("eventCreateCrmEvent failed:", res.error);
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
run();
|
|
340
|
-
```
|
|
341
|
-
|
|
342
|
-
### Parameters
|
|
343
|
-
|
|
344
|
-
| Parameter | Type | Required | Description |
|
|
345
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
346
|
-
| `request` | [operations.CreateCrmEventRequest](../../sdk/models/operations/createcrmeventrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
347
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
348
|
-
| `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. |
|
|
349
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
350
|
-
|
|
351
|
-
### Response
|
|
352
|
-
|
|
353
|
-
**Promise\<[shared.CrmEvent](../../sdk/models/shared/crmevent.md)\>**
|
|
354
|
-
|
|
355
|
-
### Errors
|
|
356
|
-
|
|
357
|
-
| Error Type | Status Code | Content Type |
|
|
358
|
-
| --------------- | --------------- | --------------- |
|
|
359
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
360
|
-
|
|
361
|
-
## createCrmLead
|
|
362
|
-
|
|
363
|
-
Create a lead
|
|
364
|
-
|
|
365
|
-
### Example Usage
|
|
366
|
-
|
|
367
|
-
<!-- UsageSnippet language="typescript" operationID="createCrmLead" method="post" path="/crm/{connection_id}/lead" -->
|
|
368
|
-
```typescript
|
|
369
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
370
|
-
|
|
371
|
-
const unifiedTo = new UnifiedTo({
|
|
372
|
-
security: {
|
|
373
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
374
|
-
},
|
|
375
|
-
});
|
|
376
|
-
|
|
377
|
-
async function run() {
|
|
378
|
-
const result = await unifiedTo.crm.createCrmLead({
|
|
379
|
-
crmLead: {},
|
|
380
|
-
connectionId: "<id>",
|
|
381
|
-
});
|
|
382
|
-
|
|
383
|
-
console.log(result);
|
|
384
|
-
}
|
|
385
|
-
|
|
386
|
-
run();
|
|
387
|
-
```
|
|
388
|
-
|
|
389
|
-
### Standalone function
|
|
390
|
-
|
|
391
|
-
The standalone function version of this method:
|
|
392
|
-
|
|
393
|
-
```typescript
|
|
394
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
395
|
-
import { crmCreateCrmLead } from "@unified-api/typescript-sdk/funcs/crmCreateCrmLead.js";
|
|
396
|
-
|
|
397
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
398
|
-
// You can create one instance of it to use across an application.
|
|
399
|
-
const unifiedTo = new UnifiedToCore({
|
|
400
|
-
security: {
|
|
401
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
402
|
-
},
|
|
403
|
-
});
|
|
404
|
-
|
|
405
|
-
async function run() {
|
|
406
|
-
const res = await crmCreateCrmLead(unifiedTo, {
|
|
407
|
-
crmLead: {},
|
|
408
|
-
connectionId: "<id>",
|
|
409
|
-
});
|
|
410
|
-
if (res.ok) {
|
|
411
|
-
const { value: result } = res;
|
|
412
|
-
console.log(result);
|
|
413
|
-
} else {
|
|
414
|
-
console.log("crmCreateCrmLead failed:", res.error);
|
|
415
|
-
}
|
|
416
|
-
}
|
|
417
|
-
|
|
418
|
-
run();
|
|
419
|
-
```
|
|
420
|
-
|
|
421
|
-
### Parameters
|
|
422
|
-
|
|
423
|
-
| Parameter | Type | Required | Description |
|
|
424
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
425
|
-
| `request` | [operations.CreateCrmLeadRequest](../../sdk/models/operations/createcrmleadrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
426
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
427
|
-
| `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. |
|
|
428
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
429
|
-
|
|
430
|
-
### Response
|
|
431
|
-
|
|
432
|
-
**Promise\<[shared.CrmLead](../../sdk/models/shared/crmlead.md)\>**
|
|
433
|
-
|
|
434
|
-
### Errors
|
|
435
|
-
|
|
436
|
-
| Error Type | Status Code | Content Type |
|
|
437
|
-
| --------------- | --------------- | --------------- |
|
|
438
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
439
|
-
|
|
440
|
-
## createCrmPipeline
|
|
441
|
-
|
|
442
|
-
Create a pipeline
|
|
443
|
-
|
|
444
|
-
### Example Usage
|
|
445
|
-
|
|
446
|
-
<!-- UsageSnippet language="typescript" operationID="createCrmPipeline" method="post" path="/crm/{connection_id}/pipeline" -->
|
|
447
|
-
```typescript
|
|
448
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
449
|
-
|
|
450
|
-
const unifiedTo = new UnifiedTo({
|
|
451
|
-
security: {
|
|
452
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
453
|
-
},
|
|
454
|
-
});
|
|
455
|
-
|
|
456
|
-
async function run() {
|
|
457
|
-
const result = await unifiedTo.crm.createCrmPipeline({
|
|
458
|
-
crmPipeline: {},
|
|
459
|
-
connectionId: "<id>",
|
|
460
|
-
});
|
|
461
|
-
|
|
462
|
-
console.log(result);
|
|
463
|
-
}
|
|
464
|
-
|
|
465
|
-
run();
|
|
466
|
-
```
|
|
467
|
-
|
|
468
|
-
### Standalone function
|
|
469
|
-
|
|
470
|
-
The standalone function version of this method:
|
|
471
|
-
|
|
472
|
-
```typescript
|
|
473
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
474
|
-
import { crmCreateCrmPipeline } from "@unified-api/typescript-sdk/funcs/crmCreateCrmPipeline.js";
|
|
475
|
-
|
|
476
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
477
|
-
// You can create one instance of it to use across an application.
|
|
478
|
-
const unifiedTo = new UnifiedToCore({
|
|
479
|
-
security: {
|
|
480
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
481
|
-
},
|
|
482
|
-
});
|
|
483
|
-
|
|
484
|
-
async function run() {
|
|
485
|
-
const res = await crmCreateCrmPipeline(unifiedTo, {
|
|
486
|
-
crmPipeline: {},
|
|
487
|
-
connectionId: "<id>",
|
|
488
|
-
});
|
|
489
|
-
if (res.ok) {
|
|
490
|
-
const { value: result } = res;
|
|
491
|
-
console.log(result);
|
|
492
|
-
} else {
|
|
493
|
-
console.log("crmCreateCrmPipeline failed:", res.error);
|
|
494
|
-
}
|
|
495
|
-
}
|
|
496
|
-
|
|
497
|
-
run();
|
|
498
|
-
```
|
|
499
|
-
|
|
500
|
-
### Parameters
|
|
501
|
-
|
|
502
|
-
| Parameter | Type | Required | Description |
|
|
503
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
504
|
-
| `request` | [operations.CreateCrmPipelineRequest](../../sdk/models/operations/createcrmpipelinerequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
505
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
506
|
-
| `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. |
|
|
507
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
508
|
-
|
|
509
|
-
### Response
|
|
510
|
-
|
|
511
|
-
**Promise\<[shared.CrmPipeline](../../sdk/models/shared/crmpipeline.md)\>**
|
|
512
|
-
|
|
513
|
-
### Errors
|
|
514
|
-
|
|
515
|
-
| Error Type | Status Code | Content Type |
|
|
516
|
-
| --------------- | --------------- | --------------- |
|
|
517
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
518
|
-
|
|
519
|
-
## getCrmCompany
|
|
520
|
-
|
|
521
|
-
Retrieve a company
|
|
522
|
-
|
|
523
|
-
### Example Usage
|
|
524
|
-
|
|
525
|
-
<!-- UsageSnippet language="typescript" operationID="getCrmCompany" method="get" path="/crm/{connection_id}/company/{id}" -->
|
|
526
|
-
```typescript
|
|
527
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
528
|
-
|
|
529
|
-
const unifiedTo = new UnifiedTo({
|
|
530
|
-
security: {
|
|
531
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
532
|
-
},
|
|
533
|
-
});
|
|
534
|
-
|
|
535
|
-
async function run() {
|
|
536
|
-
const result = await unifiedTo.crm.getCrmCompany({
|
|
537
|
-
connectionId: "<id>",
|
|
538
|
-
id: "<id>",
|
|
539
|
-
});
|
|
540
|
-
|
|
541
|
-
console.log(result);
|
|
542
|
-
}
|
|
543
|
-
|
|
544
|
-
run();
|
|
545
|
-
```
|
|
546
|
-
|
|
547
|
-
### Standalone function
|
|
548
|
-
|
|
549
|
-
The standalone function version of this method:
|
|
550
|
-
|
|
551
|
-
```typescript
|
|
552
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
553
|
-
import { companyGetCrmCompany } from "@unified-api/typescript-sdk/funcs/companyGetCrmCompany.js";
|
|
554
|
-
|
|
555
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
556
|
-
// You can create one instance of it to use across an application.
|
|
557
|
-
const unifiedTo = new UnifiedToCore({
|
|
558
|
-
security: {
|
|
559
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
560
|
-
},
|
|
561
|
-
});
|
|
562
|
-
|
|
563
|
-
async function run() {
|
|
564
|
-
const res = await companyGetCrmCompany(unifiedTo, {
|
|
565
|
-
connectionId: "<id>",
|
|
566
|
-
id: "<id>",
|
|
567
|
-
});
|
|
568
|
-
if (res.ok) {
|
|
569
|
-
const { value: result } = res;
|
|
570
|
-
console.log(result);
|
|
571
|
-
} else {
|
|
572
|
-
console.log("companyGetCrmCompany failed:", res.error);
|
|
573
|
-
}
|
|
574
|
-
}
|
|
575
|
-
|
|
576
|
-
run();
|
|
577
|
-
```
|
|
578
|
-
|
|
579
|
-
### Parameters
|
|
580
|
-
|
|
581
|
-
| Parameter | Type | Required | Description |
|
|
582
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
583
|
-
| `request` | [operations.GetCrmCompanyRequest](../../sdk/models/operations/getcrmcompanyrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
584
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
585
|
-
| `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. |
|
|
586
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
587
|
-
|
|
588
|
-
### Response
|
|
589
|
-
|
|
590
|
-
**Promise\<[shared.CrmCompany](../../sdk/models/shared/crmcompany.md)\>**
|
|
591
|
-
|
|
592
|
-
### Errors
|
|
593
|
-
|
|
594
|
-
| Error Type | Status Code | Content Type |
|
|
595
|
-
| --------------- | --------------- | --------------- |
|
|
596
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
597
|
-
|
|
598
|
-
## getCrmContact
|
|
599
|
-
|
|
600
|
-
Retrieve a contact
|
|
601
|
-
|
|
602
|
-
### Example Usage
|
|
603
|
-
|
|
604
|
-
<!-- UsageSnippet language="typescript" operationID="getCrmContact" method="get" path="/crm/{connection_id}/contact/{id}" -->
|
|
605
|
-
```typescript
|
|
606
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
607
|
-
|
|
608
|
-
const unifiedTo = new UnifiedTo({
|
|
609
|
-
security: {
|
|
610
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
611
|
-
},
|
|
612
|
-
});
|
|
613
|
-
|
|
614
|
-
async function run() {
|
|
615
|
-
const result = await unifiedTo.crm.getCrmContact({
|
|
616
|
-
connectionId: "<id>",
|
|
617
|
-
id: "<id>",
|
|
618
|
-
});
|
|
619
|
-
|
|
620
|
-
console.log(result);
|
|
621
|
-
}
|
|
622
|
-
|
|
623
|
-
run();
|
|
624
|
-
```
|
|
625
|
-
|
|
626
|
-
### Standalone function
|
|
627
|
-
|
|
628
|
-
The standalone function version of this method:
|
|
629
|
-
|
|
630
|
-
```typescript
|
|
631
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
632
|
-
import { contactGetCrmContact } from "@unified-api/typescript-sdk/funcs/contactGetCrmContact.js";
|
|
633
|
-
|
|
634
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
635
|
-
// You can create one instance of it to use across an application.
|
|
636
|
-
const unifiedTo = new UnifiedToCore({
|
|
637
|
-
security: {
|
|
638
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
639
|
-
},
|
|
640
|
-
});
|
|
641
|
-
|
|
642
|
-
async function run() {
|
|
643
|
-
const res = await contactGetCrmContact(unifiedTo, {
|
|
644
|
-
connectionId: "<id>",
|
|
645
|
-
id: "<id>",
|
|
646
|
-
});
|
|
647
|
-
if (res.ok) {
|
|
648
|
-
const { value: result } = res;
|
|
649
|
-
console.log(result);
|
|
650
|
-
} else {
|
|
651
|
-
console.log("contactGetCrmContact failed:", res.error);
|
|
652
|
-
}
|
|
653
|
-
}
|
|
654
|
-
|
|
655
|
-
run();
|
|
656
|
-
```
|
|
657
|
-
|
|
658
|
-
### Parameters
|
|
659
|
-
|
|
660
|
-
| Parameter | Type | Required | Description |
|
|
661
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
662
|
-
| `request` | [operations.GetCrmContactRequest](../../sdk/models/operations/getcrmcontactrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
663
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
664
|
-
| `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. |
|
|
665
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
666
|
-
|
|
667
|
-
### Response
|
|
668
|
-
|
|
669
|
-
**Promise\<[shared.CrmContact](../../sdk/models/shared/crmcontact.md)\>**
|
|
670
|
-
|
|
671
|
-
### Errors
|
|
672
|
-
|
|
673
|
-
| Error Type | Status Code | Content Type |
|
|
674
|
-
| --------------- | --------------- | --------------- |
|
|
675
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
676
|
-
|
|
677
|
-
## getCrmDeal
|
|
678
|
-
|
|
679
|
-
Retrieve a deal
|
|
680
|
-
|
|
681
|
-
### Example Usage
|
|
682
|
-
|
|
683
|
-
<!-- UsageSnippet language="typescript" operationID="getCrmDeal" method="get" path="/crm/{connection_id}/deal/{id}" -->
|
|
684
|
-
```typescript
|
|
685
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
686
|
-
|
|
687
|
-
const unifiedTo = new UnifiedTo({
|
|
688
|
-
security: {
|
|
689
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
690
|
-
},
|
|
691
|
-
});
|
|
692
|
-
|
|
693
|
-
async function run() {
|
|
694
|
-
const result = await unifiedTo.crm.getCrmDeal({
|
|
695
|
-
connectionId: "<id>",
|
|
696
|
-
id: "<id>",
|
|
697
|
-
});
|
|
698
|
-
|
|
699
|
-
console.log(result);
|
|
700
|
-
}
|
|
701
|
-
|
|
702
|
-
run();
|
|
703
|
-
```
|
|
704
|
-
|
|
705
|
-
### Standalone function
|
|
706
|
-
|
|
707
|
-
The standalone function version of this method:
|
|
708
|
-
|
|
709
|
-
```typescript
|
|
710
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
711
|
-
import { crmGetCrmDeal } from "@unified-api/typescript-sdk/funcs/crmGetCrmDeal.js";
|
|
712
|
-
|
|
713
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
714
|
-
// You can create one instance of it to use across an application.
|
|
715
|
-
const unifiedTo = new UnifiedToCore({
|
|
716
|
-
security: {
|
|
717
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
718
|
-
},
|
|
719
|
-
});
|
|
720
|
-
|
|
721
|
-
async function run() {
|
|
722
|
-
const res = await crmGetCrmDeal(unifiedTo, {
|
|
723
|
-
connectionId: "<id>",
|
|
724
|
-
id: "<id>",
|
|
725
|
-
});
|
|
726
|
-
if (res.ok) {
|
|
727
|
-
const { value: result } = res;
|
|
728
|
-
console.log(result);
|
|
729
|
-
} else {
|
|
730
|
-
console.log("crmGetCrmDeal failed:", res.error);
|
|
731
|
-
}
|
|
732
|
-
}
|
|
733
|
-
|
|
734
|
-
run();
|
|
735
|
-
```
|
|
736
|
-
|
|
737
|
-
### Parameters
|
|
738
|
-
|
|
739
|
-
| Parameter | Type | Required | Description |
|
|
740
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
741
|
-
| `request` | [operations.GetCrmDealRequest](../../sdk/models/operations/getcrmdealrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
742
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
743
|
-
| `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. |
|
|
744
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
745
|
-
|
|
746
|
-
### Response
|
|
747
|
-
|
|
748
|
-
**Promise\<[shared.CrmDeal](../../sdk/models/shared/crmdeal.md)\>**
|
|
749
|
-
|
|
750
|
-
### Errors
|
|
751
|
-
|
|
752
|
-
| Error Type | Status Code | Content Type |
|
|
753
|
-
| --------------- | --------------- | --------------- |
|
|
754
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
755
|
-
|
|
756
|
-
## getCrmEvent
|
|
757
|
-
|
|
758
|
-
Retrieve an event
|
|
759
|
-
|
|
760
|
-
### Example Usage
|
|
761
|
-
|
|
762
|
-
<!-- UsageSnippet language="typescript" operationID="getCrmEvent" method="get" path="/crm/{connection_id}/event/{id}" -->
|
|
763
|
-
```typescript
|
|
764
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
765
|
-
|
|
766
|
-
const unifiedTo = new UnifiedTo({
|
|
767
|
-
security: {
|
|
768
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
769
|
-
},
|
|
770
|
-
});
|
|
771
|
-
|
|
772
|
-
async function run() {
|
|
773
|
-
const result = await unifiedTo.crm.getCrmEvent({
|
|
774
|
-
connectionId: "<id>",
|
|
775
|
-
id: "<id>",
|
|
776
|
-
});
|
|
777
|
-
|
|
778
|
-
console.log(result);
|
|
779
|
-
}
|
|
780
|
-
|
|
781
|
-
run();
|
|
782
|
-
```
|
|
783
|
-
|
|
784
|
-
### Standalone function
|
|
785
|
-
|
|
786
|
-
The standalone function version of this method:
|
|
787
|
-
|
|
788
|
-
```typescript
|
|
789
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
790
|
-
import { eventGetCrmEvent } from "@unified-api/typescript-sdk/funcs/eventGetCrmEvent.js";
|
|
791
|
-
|
|
792
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
793
|
-
// You can create one instance of it to use across an application.
|
|
794
|
-
const unifiedTo = new UnifiedToCore({
|
|
795
|
-
security: {
|
|
796
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
797
|
-
},
|
|
798
|
-
});
|
|
799
|
-
|
|
800
|
-
async function run() {
|
|
801
|
-
const res = await eventGetCrmEvent(unifiedTo, {
|
|
802
|
-
connectionId: "<id>",
|
|
803
|
-
id: "<id>",
|
|
804
|
-
});
|
|
805
|
-
if (res.ok) {
|
|
806
|
-
const { value: result } = res;
|
|
807
|
-
console.log(result);
|
|
808
|
-
} else {
|
|
809
|
-
console.log("eventGetCrmEvent failed:", res.error);
|
|
810
|
-
}
|
|
811
|
-
}
|
|
812
|
-
|
|
813
|
-
run();
|
|
814
|
-
```
|
|
815
|
-
|
|
816
|
-
### Parameters
|
|
817
|
-
|
|
818
|
-
| Parameter | Type | Required | Description |
|
|
819
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
820
|
-
| `request` | [operations.GetCrmEventRequest](../../sdk/models/operations/getcrmeventrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
821
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
822
|
-
| `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. |
|
|
823
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
824
|
-
|
|
825
|
-
### Response
|
|
826
|
-
|
|
827
|
-
**Promise\<[shared.CrmEvent](../../sdk/models/shared/crmevent.md)\>**
|
|
828
|
-
|
|
829
|
-
### Errors
|
|
830
|
-
|
|
831
|
-
| Error Type | Status Code | Content Type |
|
|
832
|
-
| --------------- | --------------- | --------------- |
|
|
833
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
834
|
-
|
|
835
|
-
## getCrmLead
|
|
836
|
-
|
|
837
|
-
Retrieve a lead
|
|
838
|
-
|
|
839
|
-
### Example Usage
|
|
840
|
-
|
|
841
|
-
<!-- UsageSnippet language="typescript" operationID="getCrmLead" method="get" path="/crm/{connection_id}/lead/{id}" -->
|
|
842
|
-
```typescript
|
|
843
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
844
|
-
|
|
845
|
-
const unifiedTo = new UnifiedTo({
|
|
846
|
-
security: {
|
|
847
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
848
|
-
},
|
|
849
|
-
});
|
|
850
|
-
|
|
851
|
-
async function run() {
|
|
852
|
-
const result = await unifiedTo.crm.getCrmLead({
|
|
853
|
-
connectionId: "<id>",
|
|
854
|
-
id: "<id>",
|
|
855
|
-
});
|
|
856
|
-
|
|
857
|
-
console.log(result);
|
|
858
|
-
}
|
|
859
|
-
|
|
860
|
-
run();
|
|
861
|
-
```
|
|
862
|
-
|
|
863
|
-
### Standalone function
|
|
864
|
-
|
|
865
|
-
The standalone function version of this method:
|
|
866
|
-
|
|
867
|
-
```typescript
|
|
868
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
869
|
-
import { crmGetCrmLead } from "@unified-api/typescript-sdk/funcs/crmGetCrmLead.js";
|
|
870
|
-
|
|
871
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
872
|
-
// You can create one instance of it to use across an application.
|
|
873
|
-
const unifiedTo = new UnifiedToCore({
|
|
874
|
-
security: {
|
|
875
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
876
|
-
},
|
|
877
|
-
});
|
|
878
|
-
|
|
879
|
-
async function run() {
|
|
880
|
-
const res = await crmGetCrmLead(unifiedTo, {
|
|
881
|
-
connectionId: "<id>",
|
|
882
|
-
id: "<id>",
|
|
883
|
-
});
|
|
884
|
-
if (res.ok) {
|
|
885
|
-
const { value: result } = res;
|
|
886
|
-
console.log(result);
|
|
887
|
-
} else {
|
|
888
|
-
console.log("crmGetCrmLead failed:", res.error);
|
|
889
|
-
}
|
|
890
|
-
}
|
|
891
|
-
|
|
892
|
-
run();
|
|
893
|
-
```
|
|
894
|
-
|
|
895
|
-
### Parameters
|
|
896
|
-
|
|
897
|
-
| Parameter | Type | Required | Description |
|
|
898
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
899
|
-
| `request` | [operations.GetCrmLeadRequest](../../sdk/models/operations/getcrmleadrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
900
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
901
|
-
| `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. |
|
|
902
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
903
|
-
|
|
904
|
-
### Response
|
|
905
|
-
|
|
906
|
-
**Promise\<[shared.CrmLead](../../sdk/models/shared/crmlead.md)\>**
|
|
907
|
-
|
|
908
|
-
### Errors
|
|
909
|
-
|
|
910
|
-
| Error Type | Status Code | Content Type |
|
|
911
|
-
| --------------- | --------------- | --------------- |
|
|
912
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
913
|
-
|
|
914
|
-
## getCrmPipeline
|
|
915
|
-
|
|
916
|
-
Retrieve a pipeline
|
|
917
|
-
|
|
918
|
-
### Example Usage
|
|
919
|
-
|
|
920
|
-
<!-- UsageSnippet language="typescript" operationID="getCrmPipeline" method="get" path="/crm/{connection_id}/pipeline/{id}" -->
|
|
921
|
-
```typescript
|
|
922
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
923
|
-
|
|
924
|
-
const unifiedTo = new UnifiedTo({
|
|
925
|
-
security: {
|
|
926
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
927
|
-
},
|
|
928
|
-
});
|
|
929
|
-
|
|
930
|
-
async function run() {
|
|
931
|
-
const result = await unifiedTo.crm.getCrmPipeline({
|
|
932
|
-
connectionId: "<id>",
|
|
933
|
-
id: "<id>",
|
|
934
|
-
});
|
|
935
|
-
|
|
936
|
-
console.log(result);
|
|
937
|
-
}
|
|
938
|
-
|
|
939
|
-
run();
|
|
940
|
-
```
|
|
941
|
-
|
|
942
|
-
### Standalone function
|
|
943
|
-
|
|
944
|
-
The standalone function version of this method:
|
|
945
|
-
|
|
946
|
-
```typescript
|
|
947
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
948
|
-
import { crmGetCrmPipeline } from "@unified-api/typescript-sdk/funcs/crmGetCrmPipeline.js";
|
|
949
|
-
|
|
950
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
951
|
-
// You can create one instance of it to use across an application.
|
|
952
|
-
const unifiedTo = new UnifiedToCore({
|
|
953
|
-
security: {
|
|
954
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
955
|
-
},
|
|
956
|
-
});
|
|
957
|
-
|
|
958
|
-
async function run() {
|
|
959
|
-
const res = await crmGetCrmPipeline(unifiedTo, {
|
|
960
|
-
connectionId: "<id>",
|
|
961
|
-
id: "<id>",
|
|
962
|
-
});
|
|
963
|
-
if (res.ok) {
|
|
964
|
-
const { value: result } = res;
|
|
965
|
-
console.log(result);
|
|
966
|
-
} else {
|
|
967
|
-
console.log("crmGetCrmPipeline failed:", res.error);
|
|
968
|
-
}
|
|
969
|
-
}
|
|
970
|
-
|
|
971
|
-
run();
|
|
972
|
-
```
|
|
973
|
-
|
|
974
|
-
### Parameters
|
|
975
|
-
|
|
976
|
-
| Parameter | Type | Required | Description |
|
|
977
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
978
|
-
| `request` | [operations.GetCrmPipelineRequest](../../sdk/models/operations/getcrmpipelinerequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
979
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
980
|
-
| `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. |
|
|
981
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
982
|
-
|
|
983
|
-
### Response
|
|
984
|
-
|
|
985
|
-
**Promise\<[shared.CrmPipeline](../../sdk/models/shared/crmpipeline.md)\>**
|
|
986
|
-
|
|
987
|
-
### Errors
|
|
988
|
-
|
|
989
|
-
| Error Type | Status Code | Content Type |
|
|
990
|
-
| --------------- | --------------- | --------------- |
|
|
991
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
992
|
-
|
|
993
|
-
## listCrmCompanies
|
|
994
|
-
|
|
995
|
-
List all companies
|
|
996
|
-
|
|
997
|
-
### Example Usage
|
|
998
|
-
|
|
999
|
-
<!-- UsageSnippet language="typescript" operationID="listCrmCompanies" method="get" path="/crm/{connection_id}/company" -->
|
|
1000
|
-
```typescript
|
|
1001
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1002
|
-
|
|
1003
|
-
const unifiedTo = new UnifiedTo({
|
|
1004
|
-
security: {
|
|
1005
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1006
|
-
},
|
|
1007
|
-
});
|
|
1008
|
-
|
|
1009
|
-
async function run() {
|
|
1010
|
-
const result = await unifiedTo.crm.listCrmCompanies({
|
|
1011
|
-
connectionId: "<id>",
|
|
1012
|
-
});
|
|
1013
|
-
|
|
1014
|
-
console.log(result);
|
|
1015
|
-
}
|
|
1016
|
-
|
|
1017
|
-
run();
|
|
1018
|
-
```
|
|
1019
|
-
|
|
1020
|
-
### Standalone function
|
|
1021
|
-
|
|
1022
|
-
The standalone function version of this method:
|
|
1023
|
-
|
|
1024
|
-
```typescript
|
|
1025
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1026
|
-
import { companyListCrmCompanies } from "@unified-api/typescript-sdk/funcs/companyListCrmCompanies.js";
|
|
1027
|
-
|
|
1028
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1029
|
-
// You can create one instance of it to use across an application.
|
|
1030
|
-
const unifiedTo = new UnifiedToCore({
|
|
1031
|
-
security: {
|
|
1032
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1033
|
-
},
|
|
1034
|
-
});
|
|
1035
|
-
|
|
1036
|
-
async function run() {
|
|
1037
|
-
const res = await companyListCrmCompanies(unifiedTo, {
|
|
1038
|
-
connectionId: "<id>",
|
|
1039
|
-
});
|
|
1040
|
-
if (res.ok) {
|
|
1041
|
-
const { value: result } = res;
|
|
1042
|
-
console.log(result);
|
|
1043
|
-
} else {
|
|
1044
|
-
console.log("companyListCrmCompanies failed:", res.error);
|
|
1045
|
-
}
|
|
1046
|
-
}
|
|
1047
|
-
|
|
1048
|
-
run();
|
|
1049
|
-
```
|
|
1050
|
-
|
|
1051
|
-
### Parameters
|
|
1052
|
-
|
|
1053
|
-
| Parameter | Type | Required | Description |
|
|
1054
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1055
|
-
| `request` | [operations.ListCrmCompaniesRequest](../../sdk/models/operations/listcrmcompaniesrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1056
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1057
|
-
| `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. |
|
|
1058
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1059
|
-
|
|
1060
|
-
### Response
|
|
1061
|
-
|
|
1062
|
-
**Promise\<[shared.CrmCompany[]](../../models/.md)\>**
|
|
1063
|
-
|
|
1064
|
-
### Errors
|
|
1065
|
-
|
|
1066
|
-
| Error Type | Status Code | Content Type |
|
|
1067
|
-
| --------------- | --------------- | --------------- |
|
|
1068
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1069
|
-
|
|
1070
|
-
## listCrmContacts
|
|
1071
|
-
|
|
1072
|
-
List all contacts
|
|
1073
|
-
|
|
1074
|
-
### Example Usage
|
|
1075
|
-
|
|
1076
|
-
<!-- UsageSnippet language="typescript" operationID="listCrmContacts" method="get" path="/crm/{connection_id}/contact" -->
|
|
1077
|
-
```typescript
|
|
1078
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1079
|
-
|
|
1080
|
-
const unifiedTo = new UnifiedTo({
|
|
1081
|
-
security: {
|
|
1082
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1083
|
-
},
|
|
1084
|
-
});
|
|
1085
|
-
|
|
1086
|
-
async function run() {
|
|
1087
|
-
const result = await unifiedTo.crm.listCrmContacts({
|
|
1088
|
-
connectionId: "<id>",
|
|
1089
|
-
});
|
|
1090
|
-
|
|
1091
|
-
console.log(result);
|
|
1092
|
-
}
|
|
1093
|
-
|
|
1094
|
-
run();
|
|
1095
|
-
```
|
|
1096
|
-
|
|
1097
|
-
### Standalone function
|
|
1098
|
-
|
|
1099
|
-
The standalone function version of this method:
|
|
1100
|
-
|
|
1101
|
-
```typescript
|
|
1102
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1103
|
-
import { contactListCrmContacts } from "@unified-api/typescript-sdk/funcs/contactListCrmContacts.js";
|
|
1104
|
-
|
|
1105
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1106
|
-
// You can create one instance of it to use across an application.
|
|
1107
|
-
const unifiedTo = new UnifiedToCore({
|
|
1108
|
-
security: {
|
|
1109
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1110
|
-
},
|
|
1111
|
-
});
|
|
1112
|
-
|
|
1113
|
-
async function run() {
|
|
1114
|
-
const res = await contactListCrmContacts(unifiedTo, {
|
|
1115
|
-
connectionId: "<id>",
|
|
1116
|
-
});
|
|
1117
|
-
if (res.ok) {
|
|
1118
|
-
const { value: result } = res;
|
|
1119
|
-
console.log(result);
|
|
1120
|
-
} else {
|
|
1121
|
-
console.log("contactListCrmContacts failed:", res.error);
|
|
1122
|
-
}
|
|
1123
|
-
}
|
|
1124
|
-
|
|
1125
|
-
run();
|
|
1126
|
-
```
|
|
1127
|
-
|
|
1128
|
-
### Parameters
|
|
1129
|
-
|
|
1130
|
-
| Parameter | Type | Required | Description |
|
|
1131
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1132
|
-
| `request` | [operations.ListCrmContactsRequest](../../sdk/models/operations/listcrmcontactsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1133
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1134
|
-
| `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. |
|
|
1135
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1136
|
-
|
|
1137
|
-
### Response
|
|
1138
|
-
|
|
1139
|
-
**Promise\<[shared.CrmContact[]](../../models/.md)\>**
|
|
1140
|
-
|
|
1141
|
-
### Errors
|
|
1142
|
-
|
|
1143
|
-
| Error Type | Status Code | Content Type |
|
|
1144
|
-
| --------------- | --------------- | --------------- |
|
|
1145
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1146
|
-
|
|
1147
|
-
## listCrmDeals
|
|
1148
|
-
|
|
1149
|
-
List all deals
|
|
1150
|
-
|
|
1151
|
-
### Example Usage
|
|
1152
|
-
|
|
1153
|
-
<!-- UsageSnippet language="typescript" operationID="listCrmDeals" method="get" path="/crm/{connection_id}/deal" -->
|
|
1154
|
-
```typescript
|
|
1155
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1156
|
-
|
|
1157
|
-
const unifiedTo = new UnifiedTo({
|
|
1158
|
-
security: {
|
|
1159
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1160
|
-
},
|
|
1161
|
-
});
|
|
1162
|
-
|
|
1163
|
-
async function run() {
|
|
1164
|
-
const result = await unifiedTo.crm.listCrmDeals({
|
|
1165
|
-
connectionId: "<id>",
|
|
1166
|
-
});
|
|
1167
|
-
|
|
1168
|
-
console.log(result);
|
|
1169
|
-
}
|
|
1170
|
-
|
|
1171
|
-
run();
|
|
1172
|
-
```
|
|
1173
|
-
|
|
1174
|
-
### Standalone function
|
|
1175
|
-
|
|
1176
|
-
The standalone function version of this method:
|
|
1177
|
-
|
|
1178
|
-
```typescript
|
|
1179
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1180
|
-
import { crmListCrmDeals } from "@unified-api/typescript-sdk/funcs/crmListCrmDeals.js";
|
|
1181
|
-
|
|
1182
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1183
|
-
// You can create one instance of it to use across an application.
|
|
1184
|
-
const unifiedTo = new UnifiedToCore({
|
|
1185
|
-
security: {
|
|
1186
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1187
|
-
},
|
|
1188
|
-
});
|
|
1189
|
-
|
|
1190
|
-
async function run() {
|
|
1191
|
-
const res = await crmListCrmDeals(unifiedTo, {
|
|
1192
|
-
connectionId: "<id>",
|
|
1193
|
-
});
|
|
1194
|
-
if (res.ok) {
|
|
1195
|
-
const { value: result } = res;
|
|
1196
|
-
console.log(result);
|
|
1197
|
-
} else {
|
|
1198
|
-
console.log("crmListCrmDeals failed:", res.error);
|
|
1199
|
-
}
|
|
1200
|
-
}
|
|
1201
|
-
|
|
1202
|
-
run();
|
|
1203
|
-
```
|
|
1204
|
-
|
|
1205
|
-
### Parameters
|
|
1206
|
-
|
|
1207
|
-
| Parameter | Type | Required | Description |
|
|
1208
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1209
|
-
| `request` | [operations.ListCrmDealsRequest](../../sdk/models/operations/listcrmdealsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1210
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1211
|
-
| `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. |
|
|
1212
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1213
|
-
|
|
1214
|
-
### Response
|
|
1215
|
-
|
|
1216
|
-
**Promise\<[shared.CrmDeal[]](../../models/.md)\>**
|
|
1217
|
-
|
|
1218
|
-
### Errors
|
|
1219
|
-
|
|
1220
|
-
| Error Type | Status Code | Content Type |
|
|
1221
|
-
| --------------- | --------------- | --------------- |
|
|
1222
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1223
|
-
|
|
1224
|
-
## listCrmEvents
|
|
1225
|
-
|
|
1226
|
-
List all events
|
|
1227
|
-
|
|
1228
|
-
### Example Usage
|
|
1229
|
-
|
|
1230
|
-
<!-- UsageSnippet language="typescript" operationID="listCrmEvents" method="get" path="/crm/{connection_id}/event" -->
|
|
1231
|
-
```typescript
|
|
1232
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1233
|
-
|
|
1234
|
-
const unifiedTo = new UnifiedTo({
|
|
1235
|
-
security: {
|
|
1236
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1237
|
-
},
|
|
1238
|
-
});
|
|
1239
|
-
|
|
1240
|
-
async function run() {
|
|
1241
|
-
const result = await unifiedTo.crm.listCrmEvents({
|
|
1242
|
-
connectionId: "<id>",
|
|
1243
|
-
});
|
|
1244
|
-
|
|
1245
|
-
console.log(result);
|
|
1246
|
-
}
|
|
1247
|
-
|
|
1248
|
-
run();
|
|
1249
|
-
```
|
|
1250
|
-
|
|
1251
|
-
### Standalone function
|
|
1252
|
-
|
|
1253
|
-
The standalone function version of this method:
|
|
1254
|
-
|
|
1255
|
-
```typescript
|
|
1256
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1257
|
-
import { eventListCrmEvents } from "@unified-api/typescript-sdk/funcs/eventListCrmEvents.js";
|
|
1258
|
-
|
|
1259
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1260
|
-
// You can create one instance of it to use across an application.
|
|
1261
|
-
const unifiedTo = new UnifiedToCore({
|
|
1262
|
-
security: {
|
|
1263
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1264
|
-
},
|
|
1265
|
-
});
|
|
1266
|
-
|
|
1267
|
-
async function run() {
|
|
1268
|
-
const res = await eventListCrmEvents(unifiedTo, {
|
|
1269
|
-
connectionId: "<id>",
|
|
1270
|
-
});
|
|
1271
|
-
if (res.ok) {
|
|
1272
|
-
const { value: result } = res;
|
|
1273
|
-
console.log(result);
|
|
1274
|
-
} else {
|
|
1275
|
-
console.log("eventListCrmEvents failed:", res.error);
|
|
1276
|
-
}
|
|
1277
|
-
}
|
|
1278
|
-
|
|
1279
|
-
run();
|
|
1280
|
-
```
|
|
1281
|
-
|
|
1282
|
-
### Parameters
|
|
1283
|
-
|
|
1284
|
-
| Parameter | Type | Required | Description |
|
|
1285
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1286
|
-
| `request` | [operations.ListCrmEventsRequest](../../sdk/models/operations/listcrmeventsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1287
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1288
|
-
| `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. |
|
|
1289
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1290
|
-
|
|
1291
|
-
### Response
|
|
1292
|
-
|
|
1293
|
-
**Promise\<[shared.CrmEvent[]](../../models/.md)\>**
|
|
1294
|
-
|
|
1295
|
-
### Errors
|
|
1296
|
-
|
|
1297
|
-
| Error Type | Status Code | Content Type |
|
|
1298
|
-
| --------------- | --------------- | --------------- |
|
|
1299
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1300
|
-
|
|
1301
|
-
## listCrmLeads
|
|
1302
|
-
|
|
1303
|
-
List all leads
|
|
1304
|
-
|
|
1305
|
-
### Example Usage
|
|
1306
|
-
|
|
1307
|
-
<!-- UsageSnippet language="typescript" operationID="listCrmLeads" method="get" path="/crm/{connection_id}/lead" -->
|
|
1308
|
-
```typescript
|
|
1309
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1310
|
-
|
|
1311
|
-
const unifiedTo = new UnifiedTo({
|
|
1312
|
-
security: {
|
|
1313
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1314
|
-
},
|
|
1315
|
-
});
|
|
1316
|
-
|
|
1317
|
-
async function run() {
|
|
1318
|
-
const result = await unifiedTo.crm.listCrmLeads({
|
|
1319
|
-
connectionId: "<id>",
|
|
1320
|
-
});
|
|
1321
|
-
|
|
1322
|
-
console.log(result);
|
|
1323
|
-
}
|
|
1324
|
-
|
|
1325
|
-
run();
|
|
1326
|
-
```
|
|
1327
|
-
|
|
1328
|
-
### Standalone function
|
|
1329
|
-
|
|
1330
|
-
The standalone function version of this method:
|
|
1331
|
-
|
|
1332
|
-
```typescript
|
|
1333
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1334
|
-
import { crmListCrmLeads } from "@unified-api/typescript-sdk/funcs/crmListCrmLeads.js";
|
|
1335
|
-
|
|
1336
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1337
|
-
// You can create one instance of it to use across an application.
|
|
1338
|
-
const unifiedTo = new UnifiedToCore({
|
|
1339
|
-
security: {
|
|
1340
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1341
|
-
},
|
|
1342
|
-
});
|
|
1343
|
-
|
|
1344
|
-
async function run() {
|
|
1345
|
-
const res = await crmListCrmLeads(unifiedTo, {
|
|
1346
|
-
connectionId: "<id>",
|
|
1347
|
-
});
|
|
1348
|
-
if (res.ok) {
|
|
1349
|
-
const { value: result } = res;
|
|
1350
|
-
console.log(result);
|
|
1351
|
-
} else {
|
|
1352
|
-
console.log("crmListCrmLeads failed:", res.error);
|
|
1353
|
-
}
|
|
1354
|
-
}
|
|
1355
|
-
|
|
1356
|
-
run();
|
|
1357
|
-
```
|
|
1358
|
-
|
|
1359
|
-
### Parameters
|
|
1360
|
-
|
|
1361
|
-
| Parameter | Type | Required | Description |
|
|
1362
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1363
|
-
| `request` | [operations.ListCrmLeadsRequest](../../sdk/models/operations/listcrmleadsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1364
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1365
|
-
| `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. |
|
|
1366
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1367
|
-
|
|
1368
|
-
### Response
|
|
1369
|
-
|
|
1370
|
-
**Promise\<[shared.CrmLead[]](../../models/.md)\>**
|
|
1371
|
-
|
|
1372
|
-
### Errors
|
|
1373
|
-
|
|
1374
|
-
| Error Type | Status Code | Content Type |
|
|
1375
|
-
| --------------- | --------------- | --------------- |
|
|
1376
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1377
|
-
|
|
1378
|
-
## listCrmPipelines
|
|
1379
|
-
|
|
1380
|
-
List all pipelines
|
|
1381
|
-
|
|
1382
|
-
### Example Usage
|
|
1383
|
-
|
|
1384
|
-
<!-- UsageSnippet language="typescript" operationID="listCrmPipelines" method="get" path="/crm/{connection_id}/pipeline" -->
|
|
1385
|
-
```typescript
|
|
1386
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1387
|
-
|
|
1388
|
-
const unifiedTo = new UnifiedTo({
|
|
1389
|
-
security: {
|
|
1390
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1391
|
-
},
|
|
1392
|
-
});
|
|
1393
|
-
|
|
1394
|
-
async function run() {
|
|
1395
|
-
const result = await unifiedTo.crm.listCrmPipelines({
|
|
1396
|
-
connectionId: "<id>",
|
|
1397
|
-
});
|
|
1398
|
-
|
|
1399
|
-
console.log(result);
|
|
1400
|
-
}
|
|
1401
|
-
|
|
1402
|
-
run();
|
|
1403
|
-
```
|
|
1404
|
-
|
|
1405
|
-
### Standalone function
|
|
1406
|
-
|
|
1407
|
-
The standalone function version of this method:
|
|
1408
|
-
|
|
1409
|
-
```typescript
|
|
1410
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1411
|
-
import { crmListCrmPipelines } from "@unified-api/typescript-sdk/funcs/crmListCrmPipelines.js";
|
|
1412
|
-
|
|
1413
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1414
|
-
// You can create one instance of it to use across an application.
|
|
1415
|
-
const unifiedTo = new UnifiedToCore({
|
|
1416
|
-
security: {
|
|
1417
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1418
|
-
},
|
|
1419
|
-
});
|
|
1420
|
-
|
|
1421
|
-
async function run() {
|
|
1422
|
-
const res = await crmListCrmPipelines(unifiedTo, {
|
|
1423
|
-
connectionId: "<id>",
|
|
1424
|
-
});
|
|
1425
|
-
if (res.ok) {
|
|
1426
|
-
const { value: result } = res;
|
|
1427
|
-
console.log(result);
|
|
1428
|
-
} else {
|
|
1429
|
-
console.log("crmListCrmPipelines failed:", res.error);
|
|
1430
|
-
}
|
|
1431
|
-
}
|
|
1432
|
-
|
|
1433
|
-
run();
|
|
1434
|
-
```
|
|
1435
|
-
|
|
1436
|
-
### Parameters
|
|
1437
|
-
|
|
1438
|
-
| Parameter | Type | Required | Description |
|
|
1439
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1440
|
-
| `request` | [operations.ListCrmPipelinesRequest](../../sdk/models/operations/listcrmpipelinesrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1441
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1442
|
-
| `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. |
|
|
1443
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1444
|
-
|
|
1445
|
-
### Response
|
|
1446
|
-
|
|
1447
|
-
**Promise\<[shared.CrmPipeline[]](../../models/.md)\>**
|
|
1448
|
-
|
|
1449
|
-
### Errors
|
|
1450
|
-
|
|
1451
|
-
| Error Type | Status Code | Content Type |
|
|
1452
|
-
| --------------- | --------------- | --------------- |
|
|
1453
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1454
|
-
|
|
1455
|
-
## patchCrmCompany
|
|
1456
|
-
|
|
1457
|
-
Update a company
|
|
1458
|
-
|
|
1459
|
-
### Example Usage
|
|
1460
|
-
|
|
1461
|
-
<!-- UsageSnippet language="typescript" operationID="patchCrmCompany" method="patch" path="/crm/{connection_id}/company/{id}" -->
|
|
1462
|
-
```typescript
|
|
1463
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1464
|
-
|
|
1465
|
-
const unifiedTo = new UnifiedTo({
|
|
1466
|
-
security: {
|
|
1467
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1468
|
-
},
|
|
1469
|
-
});
|
|
1470
|
-
|
|
1471
|
-
async function run() {
|
|
1472
|
-
const result = await unifiedTo.crm.patchCrmCompany({
|
|
1473
|
-
crmCompany: {},
|
|
1474
|
-
connectionId: "<id>",
|
|
1475
|
-
id: "<id>",
|
|
1476
|
-
});
|
|
1477
|
-
|
|
1478
|
-
console.log(result);
|
|
1479
|
-
}
|
|
1480
|
-
|
|
1481
|
-
run();
|
|
1482
|
-
```
|
|
1483
|
-
|
|
1484
|
-
### Standalone function
|
|
1485
|
-
|
|
1486
|
-
The standalone function version of this method:
|
|
1487
|
-
|
|
1488
|
-
```typescript
|
|
1489
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1490
|
-
import { companyPatchCrmCompany } from "@unified-api/typescript-sdk/funcs/companyPatchCrmCompany.js";
|
|
1491
|
-
|
|
1492
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1493
|
-
// You can create one instance of it to use across an application.
|
|
1494
|
-
const unifiedTo = new UnifiedToCore({
|
|
1495
|
-
security: {
|
|
1496
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1497
|
-
},
|
|
1498
|
-
});
|
|
1499
|
-
|
|
1500
|
-
async function run() {
|
|
1501
|
-
const res = await companyPatchCrmCompany(unifiedTo, {
|
|
1502
|
-
crmCompany: {},
|
|
1503
|
-
connectionId: "<id>",
|
|
1504
|
-
id: "<id>",
|
|
1505
|
-
});
|
|
1506
|
-
if (res.ok) {
|
|
1507
|
-
const { value: result } = res;
|
|
1508
|
-
console.log(result);
|
|
1509
|
-
} else {
|
|
1510
|
-
console.log("companyPatchCrmCompany failed:", res.error);
|
|
1511
|
-
}
|
|
1512
|
-
}
|
|
1513
|
-
|
|
1514
|
-
run();
|
|
1515
|
-
```
|
|
1516
|
-
|
|
1517
|
-
### Parameters
|
|
1518
|
-
|
|
1519
|
-
| Parameter | Type | Required | Description |
|
|
1520
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1521
|
-
| `request` | [operations.PatchCrmCompanyRequest](../../sdk/models/operations/patchcrmcompanyrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1522
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1523
|
-
| `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. |
|
|
1524
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1525
|
-
|
|
1526
|
-
### Response
|
|
1527
|
-
|
|
1528
|
-
**Promise\<[shared.CrmCompany](../../sdk/models/shared/crmcompany.md)\>**
|
|
1529
|
-
|
|
1530
|
-
### Errors
|
|
1531
|
-
|
|
1532
|
-
| Error Type | Status Code | Content Type |
|
|
1533
|
-
| --------------- | --------------- | --------------- |
|
|
1534
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1535
|
-
|
|
1536
|
-
## patchCrmContact
|
|
1537
|
-
|
|
1538
|
-
Update a contact
|
|
1539
|
-
|
|
1540
|
-
### Example Usage
|
|
1541
|
-
|
|
1542
|
-
<!-- UsageSnippet language="typescript" operationID="patchCrmContact" method="patch" path="/crm/{connection_id}/contact/{id}" -->
|
|
1543
|
-
```typescript
|
|
1544
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1545
|
-
|
|
1546
|
-
const unifiedTo = new UnifiedTo({
|
|
1547
|
-
security: {
|
|
1548
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1549
|
-
},
|
|
1550
|
-
});
|
|
1551
|
-
|
|
1552
|
-
async function run() {
|
|
1553
|
-
const result = await unifiedTo.crm.patchCrmContact({
|
|
1554
|
-
crmContact: {},
|
|
1555
|
-
connectionId: "<id>",
|
|
1556
|
-
id: "<id>",
|
|
1557
|
-
});
|
|
1558
|
-
|
|
1559
|
-
console.log(result);
|
|
1560
|
-
}
|
|
1561
|
-
|
|
1562
|
-
run();
|
|
1563
|
-
```
|
|
1564
|
-
|
|
1565
|
-
### Standalone function
|
|
1566
|
-
|
|
1567
|
-
The standalone function version of this method:
|
|
1568
|
-
|
|
1569
|
-
```typescript
|
|
1570
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1571
|
-
import { contactPatchCrmContact } from "@unified-api/typescript-sdk/funcs/contactPatchCrmContact.js";
|
|
1572
|
-
|
|
1573
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1574
|
-
// You can create one instance of it to use across an application.
|
|
1575
|
-
const unifiedTo = new UnifiedToCore({
|
|
1576
|
-
security: {
|
|
1577
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1578
|
-
},
|
|
1579
|
-
});
|
|
1580
|
-
|
|
1581
|
-
async function run() {
|
|
1582
|
-
const res = await contactPatchCrmContact(unifiedTo, {
|
|
1583
|
-
crmContact: {},
|
|
1584
|
-
connectionId: "<id>",
|
|
1585
|
-
id: "<id>",
|
|
1586
|
-
});
|
|
1587
|
-
if (res.ok) {
|
|
1588
|
-
const { value: result } = res;
|
|
1589
|
-
console.log(result);
|
|
1590
|
-
} else {
|
|
1591
|
-
console.log("contactPatchCrmContact failed:", res.error);
|
|
1592
|
-
}
|
|
1593
|
-
}
|
|
1594
|
-
|
|
1595
|
-
run();
|
|
1596
|
-
```
|
|
1597
|
-
|
|
1598
|
-
### Parameters
|
|
1599
|
-
|
|
1600
|
-
| Parameter | Type | Required | Description |
|
|
1601
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1602
|
-
| `request` | [operations.PatchCrmContactRequest](../../sdk/models/operations/patchcrmcontactrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1603
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1604
|
-
| `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. |
|
|
1605
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1606
|
-
|
|
1607
|
-
### Response
|
|
1608
|
-
|
|
1609
|
-
**Promise\<[shared.CrmContact](../../sdk/models/shared/crmcontact.md)\>**
|
|
1610
|
-
|
|
1611
|
-
### Errors
|
|
1612
|
-
|
|
1613
|
-
| Error Type | Status Code | Content Type |
|
|
1614
|
-
| --------------- | --------------- | --------------- |
|
|
1615
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1616
|
-
|
|
1617
|
-
## patchCrmDeal
|
|
1618
|
-
|
|
1619
|
-
Update a deal
|
|
1620
|
-
|
|
1621
|
-
### Example Usage
|
|
1622
|
-
|
|
1623
|
-
<!-- UsageSnippet language="typescript" operationID="patchCrmDeal" method="patch" path="/crm/{connection_id}/deal/{id}" -->
|
|
1624
|
-
```typescript
|
|
1625
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1626
|
-
|
|
1627
|
-
const unifiedTo = new UnifiedTo({
|
|
1628
|
-
security: {
|
|
1629
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1630
|
-
},
|
|
1631
|
-
});
|
|
1632
|
-
|
|
1633
|
-
async function run() {
|
|
1634
|
-
const result = await unifiedTo.crm.patchCrmDeal({
|
|
1635
|
-
crmDeal: {},
|
|
1636
|
-
connectionId: "<id>",
|
|
1637
|
-
id: "<id>",
|
|
1638
|
-
});
|
|
1639
|
-
|
|
1640
|
-
console.log(result);
|
|
1641
|
-
}
|
|
1642
|
-
|
|
1643
|
-
run();
|
|
1644
|
-
```
|
|
1645
|
-
|
|
1646
|
-
### Standalone function
|
|
1647
|
-
|
|
1648
|
-
The standalone function version of this method:
|
|
1649
|
-
|
|
1650
|
-
```typescript
|
|
1651
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1652
|
-
import { crmPatchCrmDeal } from "@unified-api/typescript-sdk/funcs/crmPatchCrmDeal.js";
|
|
1653
|
-
|
|
1654
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1655
|
-
// You can create one instance of it to use across an application.
|
|
1656
|
-
const unifiedTo = new UnifiedToCore({
|
|
1657
|
-
security: {
|
|
1658
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1659
|
-
},
|
|
1660
|
-
});
|
|
1661
|
-
|
|
1662
|
-
async function run() {
|
|
1663
|
-
const res = await crmPatchCrmDeal(unifiedTo, {
|
|
1664
|
-
crmDeal: {},
|
|
1665
|
-
connectionId: "<id>",
|
|
1666
|
-
id: "<id>",
|
|
1667
|
-
});
|
|
1668
|
-
if (res.ok) {
|
|
1669
|
-
const { value: result } = res;
|
|
1670
|
-
console.log(result);
|
|
1671
|
-
} else {
|
|
1672
|
-
console.log("crmPatchCrmDeal failed:", res.error);
|
|
1673
|
-
}
|
|
1674
|
-
}
|
|
1675
|
-
|
|
1676
|
-
run();
|
|
1677
|
-
```
|
|
1678
|
-
|
|
1679
|
-
### Parameters
|
|
1680
|
-
|
|
1681
|
-
| Parameter | Type | Required | Description |
|
|
1682
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1683
|
-
| `request` | [operations.PatchCrmDealRequest](../../sdk/models/operations/patchcrmdealrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1684
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1685
|
-
| `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. |
|
|
1686
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1687
|
-
|
|
1688
|
-
### Response
|
|
1689
|
-
|
|
1690
|
-
**Promise\<[shared.CrmDeal](../../sdk/models/shared/crmdeal.md)\>**
|
|
1691
|
-
|
|
1692
|
-
### Errors
|
|
1693
|
-
|
|
1694
|
-
| Error Type | Status Code | Content Type |
|
|
1695
|
-
| --------------- | --------------- | --------------- |
|
|
1696
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1697
|
-
|
|
1698
|
-
## patchCrmEvent
|
|
1699
|
-
|
|
1700
|
-
Update an event
|
|
1701
|
-
|
|
1702
|
-
### Example Usage
|
|
1703
|
-
|
|
1704
|
-
<!-- UsageSnippet language="typescript" operationID="patchCrmEvent" method="patch" path="/crm/{connection_id}/event/{id}" -->
|
|
1705
|
-
```typescript
|
|
1706
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1707
|
-
|
|
1708
|
-
const unifiedTo = new UnifiedTo({
|
|
1709
|
-
security: {
|
|
1710
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1711
|
-
},
|
|
1712
|
-
});
|
|
1713
|
-
|
|
1714
|
-
async function run() {
|
|
1715
|
-
const result = await unifiedTo.crm.patchCrmEvent({
|
|
1716
|
-
crmEvent: {},
|
|
1717
|
-
connectionId: "<id>",
|
|
1718
|
-
id: "<id>",
|
|
1719
|
-
});
|
|
1720
|
-
|
|
1721
|
-
console.log(result);
|
|
1722
|
-
}
|
|
1723
|
-
|
|
1724
|
-
run();
|
|
1725
|
-
```
|
|
1726
|
-
|
|
1727
|
-
### Standalone function
|
|
1728
|
-
|
|
1729
|
-
The standalone function version of this method:
|
|
1730
|
-
|
|
1731
|
-
```typescript
|
|
1732
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1733
|
-
import { eventPatchCrmEvent } from "@unified-api/typescript-sdk/funcs/eventPatchCrmEvent.js";
|
|
1734
|
-
|
|
1735
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1736
|
-
// You can create one instance of it to use across an application.
|
|
1737
|
-
const unifiedTo = new UnifiedToCore({
|
|
1738
|
-
security: {
|
|
1739
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1740
|
-
},
|
|
1741
|
-
});
|
|
1742
|
-
|
|
1743
|
-
async function run() {
|
|
1744
|
-
const res = await eventPatchCrmEvent(unifiedTo, {
|
|
1745
|
-
crmEvent: {},
|
|
1746
|
-
connectionId: "<id>",
|
|
1747
|
-
id: "<id>",
|
|
1748
|
-
});
|
|
1749
|
-
if (res.ok) {
|
|
1750
|
-
const { value: result } = res;
|
|
1751
|
-
console.log(result);
|
|
1752
|
-
} else {
|
|
1753
|
-
console.log("eventPatchCrmEvent failed:", res.error);
|
|
1754
|
-
}
|
|
1755
|
-
}
|
|
1756
|
-
|
|
1757
|
-
run();
|
|
1758
|
-
```
|
|
1759
|
-
|
|
1760
|
-
### Parameters
|
|
1761
|
-
|
|
1762
|
-
| Parameter | Type | Required | Description |
|
|
1763
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1764
|
-
| `request` | [operations.PatchCrmEventRequest](../../sdk/models/operations/patchcrmeventrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1765
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1766
|
-
| `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. |
|
|
1767
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1768
|
-
|
|
1769
|
-
### Response
|
|
1770
|
-
|
|
1771
|
-
**Promise\<[shared.CrmEvent](../../sdk/models/shared/crmevent.md)\>**
|
|
1772
|
-
|
|
1773
|
-
### Errors
|
|
1774
|
-
|
|
1775
|
-
| Error Type | Status Code | Content Type |
|
|
1776
|
-
| --------------- | --------------- | --------------- |
|
|
1777
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1778
|
-
|
|
1779
|
-
## patchCrmLead
|
|
1780
|
-
|
|
1781
|
-
Update a lead
|
|
1782
|
-
|
|
1783
|
-
### Example Usage
|
|
1784
|
-
|
|
1785
|
-
<!-- UsageSnippet language="typescript" operationID="patchCrmLead" method="patch" path="/crm/{connection_id}/lead/{id}" -->
|
|
1786
|
-
```typescript
|
|
1787
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1788
|
-
|
|
1789
|
-
const unifiedTo = new UnifiedTo({
|
|
1790
|
-
security: {
|
|
1791
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1792
|
-
},
|
|
1793
|
-
});
|
|
1794
|
-
|
|
1795
|
-
async function run() {
|
|
1796
|
-
const result = await unifiedTo.crm.patchCrmLead({
|
|
1797
|
-
crmLead: {},
|
|
1798
|
-
connectionId: "<id>",
|
|
1799
|
-
id: "<id>",
|
|
1800
|
-
});
|
|
1801
|
-
|
|
1802
|
-
console.log(result);
|
|
1803
|
-
}
|
|
1804
|
-
|
|
1805
|
-
run();
|
|
1806
|
-
```
|
|
1807
|
-
|
|
1808
|
-
### Standalone function
|
|
1809
|
-
|
|
1810
|
-
The standalone function version of this method:
|
|
1811
|
-
|
|
1812
|
-
```typescript
|
|
1813
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1814
|
-
import { crmPatchCrmLead } from "@unified-api/typescript-sdk/funcs/crmPatchCrmLead.js";
|
|
1815
|
-
|
|
1816
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1817
|
-
// You can create one instance of it to use across an application.
|
|
1818
|
-
const unifiedTo = new UnifiedToCore({
|
|
1819
|
-
security: {
|
|
1820
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1821
|
-
},
|
|
1822
|
-
});
|
|
1823
|
-
|
|
1824
|
-
async function run() {
|
|
1825
|
-
const res = await crmPatchCrmLead(unifiedTo, {
|
|
1826
|
-
crmLead: {},
|
|
1827
|
-
connectionId: "<id>",
|
|
1828
|
-
id: "<id>",
|
|
1829
|
-
});
|
|
1830
|
-
if (res.ok) {
|
|
1831
|
-
const { value: result } = res;
|
|
1832
|
-
console.log(result);
|
|
1833
|
-
} else {
|
|
1834
|
-
console.log("crmPatchCrmLead failed:", res.error);
|
|
1835
|
-
}
|
|
1836
|
-
}
|
|
1837
|
-
|
|
1838
|
-
run();
|
|
1839
|
-
```
|
|
1840
|
-
|
|
1841
|
-
### Parameters
|
|
1842
|
-
|
|
1843
|
-
| Parameter | Type | Required | Description |
|
|
1844
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1845
|
-
| `request` | [operations.PatchCrmLeadRequest](../../sdk/models/operations/patchcrmleadrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1846
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1847
|
-
| `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. |
|
|
1848
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1849
|
-
|
|
1850
|
-
### Response
|
|
1851
|
-
|
|
1852
|
-
**Promise\<[shared.CrmLead](../../sdk/models/shared/crmlead.md)\>**
|
|
1853
|
-
|
|
1854
|
-
### Errors
|
|
1855
|
-
|
|
1856
|
-
| Error Type | Status Code | Content Type |
|
|
1857
|
-
| --------------- | --------------- | --------------- |
|
|
1858
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1859
|
-
|
|
1860
|
-
## patchCrmPipeline
|
|
1861
|
-
|
|
1862
|
-
Update a pipeline
|
|
1863
|
-
|
|
1864
|
-
### Example Usage
|
|
1865
|
-
|
|
1866
|
-
<!-- UsageSnippet language="typescript" operationID="patchCrmPipeline" method="patch" path="/crm/{connection_id}/pipeline/{id}" -->
|
|
1867
|
-
```typescript
|
|
1868
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1869
|
-
|
|
1870
|
-
const unifiedTo = new UnifiedTo({
|
|
1871
|
-
security: {
|
|
1872
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1873
|
-
},
|
|
1874
|
-
});
|
|
1875
|
-
|
|
1876
|
-
async function run() {
|
|
1877
|
-
const result = await unifiedTo.crm.patchCrmPipeline({
|
|
1878
|
-
crmPipeline: {},
|
|
1879
|
-
connectionId: "<id>",
|
|
1880
|
-
id: "<id>",
|
|
1881
|
-
});
|
|
1882
|
-
|
|
1883
|
-
console.log(result);
|
|
1884
|
-
}
|
|
1885
|
-
|
|
1886
|
-
run();
|
|
1887
|
-
```
|
|
1888
|
-
|
|
1889
|
-
### Standalone function
|
|
1890
|
-
|
|
1891
|
-
The standalone function version of this method:
|
|
1892
|
-
|
|
1893
|
-
```typescript
|
|
1894
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1895
|
-
import { crmPatchCrmPipeline } from "@unified-api/typescript-sdk/funcs/crmPatchCrmPipeline.js";
|
|
1896
|
-
|
|
1897
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1898
|
-
// You can create one instance of it to use across an application.
|
|
1899
|
-
const unifiedTo = new UnifiedToCore({
|
|
1900
|
-
security: {
|
|
1901
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1902
|
-
},
|
|
1903
|
-
});
|
|
1904
|
-
|
|
1905
|
-
async function run() {
|
|
1906
|
-
const res = await crmPatchCrmPipeline(unifiedTo, {
|
|
1907
|
-
crmPipeline: {},
|
|
1908
|
-
connectionId: "<id>",
|
|
1909
|
-
id: "<id>",
|
|
1910
|
-
});
|
|
1911
|
-
if (res.ok) {
|
|
1912
|
-
const { value: result } = res;
|
|
1913
|
-
console.log(result);
|
|
1914
|
-
} else {
|
|
1915
|
-
console.log("crmPatchCrmPipeline failed:", res.error);
|
|
1916
|
-
}
|
|
1917
|
-
}
|
|
1918
|
-
|
|
1919
|
-
run();
|
|
1920
|
-
```
|
|
1921
|
-
|
|
1922
|
-
### Parameters
|
|
1923
|
-
|
|
1924
|
-
| Parameter | Type | Required | Description |
|
|
1925
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
1926
|
-
| `request` | [operations.PatchCrmPipelineRequest](../../sdk/models/operations/patchcrmpipelinerequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
1927
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
1928
|
-
| `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. |
|
|
1929
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
1930
|
-
|
|
1931
|
-
### Response
|
|
1932
|
-
|
|
1933
|
-
**Promise\<[shared.CrmPipeline](../../sdk/models/shared/crmpipeline.md)\>**
|
|
1934
|
-
|
|
1935
|
-
### Errors
|
|
1936
|
-
|
|
1937
|
-
| Error Type | Status Code | Content Type |
|
|
1938
|
-
| --------------- | --------------- | --------------- |
|
|
1939
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
1940
|
-
|
|
1941
|
-
## removeCrmCompany
|
|
1942
|
-
|
|
1943
|
-
Remove a company
|
|
1944
|
-
|
|
1945
|
-
### Example Usage
|
|
1946
|
-
|
|
1947
|
-
<!-- UsageSnippet language="typescript" operationID="removeCrmCompany" method="delete" path="/crm/{connection_id}/company/{id}" -->
|
|
1948
|
-
```typescript
|
|
1949
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
1950
|
-
|
|
1951
|
-
const unifiedTo = new UnifiedTo({
|
|
1952
|
-
security: {
|
|
1953
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1954
|
-
},
|
|
1955
|
-
});
|
|
1956
|
-
|
|
1957
|
-
async function run() {
|
|
1958
|
-
const result = await unifiedTo.crm.removeCrmCompany({
|
|
1959
|
-
connectionId: "<id>",
|
|
1960
|
-
id: "<id>",
|
|
1961
|
-
});
|
|
1962
|
-
|
|
1963
|
-
console.log(result);
|
|
1964
|
-
}
|
|
1965
|
-
|
|
1966
|
-
run();
|
|
1967
|
-
```
|
|
1968
|
-
|
|
1969
|
-
### Standalone function
|
|
1970
|
-
|
|
1971
|
-
The standalone function version of this method:
|
|
1972
|
-
|
|
1973
|
-
```typescript
|
|
1974
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
1975
|
-
import { companyRemoveCrmCompany } from "@unified-api/typescript-sdk/funcs/companyRemoveCrmCompany.js";
|
|
1976
|
-
|
|
1977
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
1978
|
-
// You can create one instance of it to use across an application.
|
|
1979
|
-
const unifiedTo = new UnifiedToCore({
|
|
1980
|
-
security: {
|
|
1981
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
1982
|
-
},
|
|
1983
|
-
});
|
|
1984
|
-
|
|
1985
|
-
async function run() {
|
|
1986
|
-
const res = await companyRemoveCrmCompany(unifiedTo, {
|
|
1987
|
-
connectionId: "<id>",
|
|
1988
|
-
id: "<id>",
|
|
1989
|
-
});
|
|
1990
|
-
if (res.ok) {
|
|
1991
|
-
const { value: result } = res;
|
|
1992
|
-
console.log(result);
|
|
1993
|
-
} else {
|
|
1994
|
-
console.log("companyRemoveCrmCompany failed:", res.error);
|
|
1995
|
-
}
|
|
1996
|
-
}
|
|
1997
|
-
|
|
1998
|
-
run();
|
|
1999
|
-
```
|
|
2000
|
-
|
|
2001
|
-
### Parameters
|
|
2002
|
-
|
|
2003
|
-
| Parameter | Type | Required | Description |
|
|
2004
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2005
|
-
| `request` | [operations.RemoveCrmCompanyRequest](../../sdk/models/operations/removecrmcompanyrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2006
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2007
|
-
| `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. |
|
|
2008
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2009
|
-
|
|
2010
|
-
### Response
|
|
2011
|
-
|
|
2012
|
-
**Promise\<[operations.RemoveCrmCompanyResponse](../../sdk/models/operations/removecrmcompanyresponse.md)\>**
|
|
2013
|
-
|
|
2014
|
-
### Errors
|
|
2015
|
-
|
|
2016
|
-
| Error Type | Status Code | Content Type |
|
|
2017
|
-
| --------------- | --------------- | --------------- |
|
|
2018
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2019
|
-
|
|
2020
|
-
## removeCrmContact
|
|
2021
|
-
|
|
2022
|
-
Remove a contact
|
|
2023
|
-
|
|
2024
|
-
### Example Usage
|
|
2025
|
-
|
|
2026
|
-
<!-- UsageSnippet language="typescript" operationID="removeCrmContact" method="delete" path="/crm/{connection_id}/contact/{id}" -->
|
|
2027
|
-
```typescript
|
|
2028
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2029
|
-
|
|
2030
|
-
const unifiedTo = new UnifiedTo({
|
|
2031
|
-
security: {
|
|
2032
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2033
|
-
},
|
|
2034
|
-
});
|
|
2035
|
-
|
|
2036
|
-
async function run() {
|
|
2037
|
-
const result = await unifiedTo.crm.removeCrmContact({
|
|
2038
|
-
connectionId: "<id>",
|
|
2039
|
-
id: "<id>",
|
|
2040
|
-
});
|
|
2041
|
-
|
|
2042
|
-
console.log(result);
|
|
2043
|
-
}
|
|
2044
|
-
|
|
2045
|
-
run();
|
|
2046
|
-
```
|
|
2047
|
-
|
|
2048
|
-
### Standalone function
|
|
2049
|
-
|
|
2050
|
-
The standalone function version of this method:
|
|
2051
|
-
|
|
2052
|
-
```typescript
|
|
2053
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2054
|
-
import { contactRemoveCrmContact } from "@unified-api/typescript-sdk/funcs/contactRemoveCrmContact.js";
|
|
2055
|
-
|
|
2056
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2057
|
-
// You can create one instance of it to use across an application.
|
|
2058
|
-
const unifiedTo = new UnifiedToCore({
|
|
2059
|
-
security: {
|
|
2060
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2061
|
-
},
|
|
2062
|
-
});
|
|
2063
|
-
|
|
2064
|
-
async function run() {
|
|
2065
|
-
const res = await contactRemoveCrmContact(unifiedTo, {
|
|
2066
|
-
connectionId: "<id>",
|
|
2067
|
-
id: "<id>",
|
|
2068
|
-
});
|
|
2069
|
-
if (res.ok) {
|
|
2070
|
-
const { value: result } = res;
|
|
2071
|
-
console.log(result);
|
|
2072
|
-
} else {
|
|
2073
|
-
console.log("contactRemoveCrmContact failed:", res.error);
|
|
2074
|
-
}
|
|
2075
|
-
}
|
|
2076
|
-
|
|
2077
|
-
run();
|
|
2078
|
-
```
|
|
2079
|
-
|
|
2080
|
-
### Parameters
|
|
2081
|
-
|
|
2082
|
-
| Parameter | Type | Required | Description |
|
|
2083
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2084
|
-
| `request` | [operations.RemoveCrmContactRequest](../../sdk/models/operations/removecrmcontactrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2085
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2086
|
-
| `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. |
|
|
2087
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2088
|
-
|
|
2089
|
-
### Response
|
|
2090
|
-
|
|
2091
|
-
**Promise\<[operations.RemoveCrmContactResponse](../../sdk/models/operations/removecrmcontactresponse.md)\>**
|
|
2092
|
-
|
|
2093
|
-
### Errors
|
|
2094
|
-
|
|
2095
|
-
| Error Type | Status Code | Content Type |
|
|
2096
|
-
| --------------- | --------------- | --------------- |
|
|
2097
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2098
|
-
|
|
2099
|
-
## removeCrmDeal
|
|
2100
|
-
|
|
2101
|
-
Remove a deal
|
|
2102
|
-
|
|
2103
|
-
### Example Usage
|
|
2104
|
-
|
|
2105
|
-
<!-- UsageSnippet language="typescript" operationID="removeCrmDeal" method="delete" path="/crm/{connection_id}/deal/{id}" -->
|
|
2106
|
-
```typescript
|
|
2107
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2108
|
-
|
|
2109
|
-
const unifiedTo = new UnifiedTo({
|
|
2110
|
-
security: {
|
|
2111
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2112
|
-
},
|
|
2113
|
-
});
|
|
2114
|
-
|
|
2115
|
-
async function run() {
|
|
2116
|
-
const result = await unifiedTo.crm.removeCrmDeal({
|
|
2117
|
-
connectionId: "<id>",
|
|
2118
|
-
id: "<id>",
|
|
2119
|
-
});
|
|
2120
|
-
|
|
2121
|
-
console.log(result);
|
|
2122
|
-
}
|
|
2123
|
-
|
|
2124
|
-
run();
|
|
2125
|
-
```
|
|
2126
|
-
|
|
2127
|
-
### Standalone function
|
|
2128
|
-
|
|
2129
|
-
The standalone function version of this method:
|
|
2130
|
-
|
|
2131
|
-
```typescript
|
|
2132
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2133
|
-
import { crmRemoveCrmDeal } from "@unified-api/typescript-sdk/funcs/crmRemoveCrmDeal.js";
|
|
2134
|
-
|
|
2135
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2136
|
-
// You can create one instance of it to use across an application.
|
|
2137
|
-
const unifiedTo = new UnifiedToCore({
|
|
2138
|
-
security: {
|
|
2139
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2140
|
-
},
|
|
2141
|
-
});
|
|
2142
|
-
|
|
2143
|
-
async function run() {
|
|
2144
|
-
const res = await crmRemoveCrmDeal(unifiedTo, {
|
|
2145
|
-
connectionId: "<id>",
|
|
2146
|
-
id: "<id>",
|
|
2147
|
-
});
|
|
2148
|
-
if (res.ok) {
|
|
2149
|
-
const { value: result } = res;
|
|
2150
|
-
console.log(result);
|
|
2151
|
-
} else {
|
|
2152
|
-
console.log("crmRemoveCrmDeal failed:", res.error);
|
|
2153
|
-
}
|
|
2154
|
-
}
|
|
2155
|
-
|
|
2156
|
-
run();
|
|
2157
|
-
```
|
|
2158
|
-
|
|
2159
|
-
### Parameters
|
|
2160
|
-
|
|
2161
|
-
| Parameter | Type | Required | Description |
|
|
2162
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2163
|
-
| `request` | [operations.RemoveCrmDealRequest](../../sdk/models/operations/removecrmdealrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2164
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2165
|
-
| `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. |
|
|
2166
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2167
|
-
|
|
2168
|
-
### Response
|
|
2169
|
-
|
|
2170
|
-
**Promise\<[operations.RemoveCrmDealResponse](../../sdk/models/operations/removecrmdealresponse.md)\>**
|
|
2171
|
-
|
|
2172
|
-
### Errors
|
|
2173
|
-
|
|
2174
|
-
| Error Type | Status Code | Content Type |
|
|
2175
|
-
| --------------- | --------------- | --------------- |
|
|
2176
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2177
|
-
|
|
2178
|
-
## removeCrmEvent
|
|
2179
|
-
|
|
2180
|
-
Remove an event
|
|
2181
|
-
|
|
2182
|
-
### Example Usage
|
|
2183
|
-
|
|
2184
|
-
<!-- UsageSnippet language="typescript" operationID="removeCrmEvent" method="delete" path="/crm/{connection_id}/event/{id}" -->
|
|
2185
|
-
```typescript
|
|
2186
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2187
|
-
|
|
2188
|
-
const unifiedTo = new UnifiedTo({
|
|
2189
|
-
security: {
|
|
2190
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2191
|
-
},
|
|
2192
|
-
});
|
|
2193
|
-
|
|
2194
|
-
async function run() {
|
|
2195
|
-
const result = await unifiedTo.crm.removeCrmEvent({
|
|
2196
|
-
connectionId: "<id>",
|
|
2197
|
-
id: "<id>",
|
|
2198
|
-
});
|
|
2199
|
-
|
|
2200
|
-
console.log(result);
|
|
2201
|
-
}
|
|
2202
|
-
|
|
2203
|
-
run();
|
|
2204
|
-
```
|
|
2205
|
-
|
|
2206
|
-
### Standalone function
|
|
2207
|
-
|
|
2208
|
-
The standalone function version of this method:
|
|
2209
|
-
|
|
2210
|
-
```typescript
|
|
2211
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2212
|
-
import { eventRemoveCrmEvent } from "@unified-api/typescript-sdk/funcs/eventRemoveCrmEvent.js";
|
|
2213
|
-
|
|
2214
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2215
|
-
// You can create one instance of it to use across an application.
|
|
2216
|
-
const unifiedTo = new UnifiedToCore({
|
|
2217
|
-
security: {
|
|
2218
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2219
|
-
},
|
|
2220
|
-
});
|
|
2221
|
-
|
|
2222
|
-
async function run() {
|
|
2223
|
-
const res = await eventRemoveCrmEvent(unifiedTo, {
|
|
2224
|
-
connectionId: "<id>",
|
|
2225
|
-
id: "<id>",
|
|
2226
|
-
});
|
|
2227
|
-
if (res.ok) {
|
|
2228
|
-
const { value: result } = res;
|
|
2229
|
-
console.log(result);
|
|
2230
|
-
} else {
|
|
2231
|
-
console.log("eventRemoveCrmEvent failed:", res.error);
|
|
2232
|
-
}
|
|
2233
|
-
}
|
|
2234
|
-
|
|
2235
|
-
run();
|
|
2236
|
-
```
|
|
2237
|
-
|
|
2238
|
-
### Parameters
|
|
2239
|
-
|
|
2240
|
-
| Parameter | Type | Required | Description |
|
|
2241
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2242
|
-
| `request` | [operations.RemoveCrmEventRequest](../../sdk/models/operations/removecrmeventrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2243
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2244
|
-
| `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. |
|
|
2245
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2246
|
-
|
|
2247
|
-
### Response
|
|
2248
|
-
|
|
2249
|
-
**Promise\<[operations.RemoveCrmEventResponse](../../sdk/models/operations/removecrmeventresponse.md)\>**
|
|
2250
|
-
|
|
2251
|
-
### Errors
|
|
2252
|
-
|
|
2253
|
-
| Error Type | Status Code | Content Type |
|
|
2254
|
-
| --------------- | --------------- | --------------- |
|
|
2255
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2256
|
-
|
|
2257
|
-
## removeCrmLead
|
|
2258
|
-
|
|
2259
|
-
Remove a lead
|
|
2260
|
-
|
|
2261
|
-
### Example Usage
|
|
2262
|
-
|
|
2263
|
-
<!-- UsageSnippet language="typescript" operationID="removeCrmLead" method="delete" path="/crm/{connection_id}/lead/{id}" -->
|
|
2264
|
-
```typescript
|
|
2265
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2266
|
-
|
|
2267
|
-
const unifiedTo = new UnifiedTo({
|
|
2268
|
-
security: {
|
|
2269
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2270
|
-
},
|
|
2271
|
-
});
|
|
2272
|
-
|
|
2273
|
-
async function run() {
|
|
2274
|
-
const result = await unifiedTo.crm.removeCrmLead({
|
|
2275
|
-
connectionId: "<id>",
|
|
2276
|
-
id: "<id>",
|
|
2277
|
-
});
|
|
2278
|
-
|
|
2279
|
-
console.log(result);
|
|
2280
|
-
}
|
|
2281
|
-
|
|
2282
|
-
run();
|
|
2283
|
-
```
|
|
2284
|
-
|
|
2285
|
-
### Standalone function
|
|
2286
|
-
|
|
2287
|
-
The standalone function version of this method:
|
|
2288
|
-
|
|
2289
|
-
```typescript
|
|
2290
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2291
|
-
import { crmRemoveCrmLead } from "@unified-api/typescript-sdk/funcs/crmRemoveCrmLead.js";
|
|
2292
|
-
|
|
2293
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2294
|
-
// You can create one instance of it to use across an application.
|
|
2295
|
-
const unifiedTo = new UnifiedToCore({
|
|
2296
|
-
security: {
|
|
2297
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2298
|
-
},
|
|
2299
|
-
});
|
|
2300
|
-
|
|
2301
|
-
async function run() {
|
|
2302
|
-
const res = await crmRemoveCrmLead(unifiedTo, {
|
|
2303
|
-
connectionId: "<id>",
|
|
2304
|
-
id: "<id>",
|
|
2305
|
-
});
|
|
2306
|
-
if (res.ok) {
|
|
2307
|
-
const { value: result } = res;
|
|
2308
|
-
console.log(result);
|
|
2309
|
-
} else {
|
|
2310
|
-
console.log("crmRemoveCrmLead failed:", res.error);
|
|
2311
|
-
}
|
|
2312
|
-
}
|
|
2313
|
-
|
|
2314
|
-
run();
|
|
2315
|
-
```
|
|
2316
|
-
|
|
2317
|
-
### Parameters
|
|
2318
|
-
|
|
2319
|
-
| Parameter | Type | Required | Description |
|
|
2320
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2321
|
-
| `request` | [operations.RemoveCrmLeadRequest](../../sdk/models/operations/removecrmleadrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2322
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2323
|
-
| `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. |
|
|
2324
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2325
|
-
|
|
2326
|
-
### Response
|
|
2327
|
-
|
|
2328
|
-
**Promise\<[operations.RemoveCrmLeadResponse](../../sdk/models/operations/removecrmleadresponse.md)\>**
|
|
2329
|
-
|
|
2330
|
-
### Errors
|
|
2331
|
-
|
|
2332
|
-
| Error Type | Status Code | Content Type |
|
|
2333
|
-
| --------------- | --------------- | --------------- |
|
|
2334
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2335
|
-
|
|
2336
|
-
## removeCrmPipeline
|
|
2337
|
-
|
|
2338
|
-
Remove a pipeline
|
|
2339
|
-
|
|
2340
|
-
### Example Usage
|
|
2341
|
-
|
|
2342
|
-
<!-- UsageSnippet language="typescript" operationID="removeCrmPipeline" method="delete" path="/crm/{connection_id}/pipeline/{id}" -->
|
|
2343
|
-
```typescript
|
|
2344
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2345
|
-
|
|
2346
|
-
const unifiedTo = new UnifiedTo({
|
|
2347
|
-
security: {
|
|
2348
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2349
|
-
},
|
|
2350
|
-
});
|
|
2351
|
-
|
|
2352
|
-
async function run() {
|
|
2353
|
-
const result = await unifiedTo.crm.removeCrmPipeline({
|
|
2354
|
-
connectionId: "<id>",
|
|
2355
|
-
id: "<id>",
|
|
2356
|
-
});
|
|
2357
|
-
|
|
2358
|
-
console.log(result);
|
|
2359
|
-
}
|
|
2360
|
-
|
|
2361
|
-
run();
|
|
2362
|
-
```
|
|
2363
|
-
|
|
2364
|
-
### Standalone function
|
|
2365
|
-
|
|
2366
|
-
The standalone function version of this method:
|
|
2367
|
-
|
|
2368
|
-
```typescript
|
|
2369
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2370
|
-
import { crmRemoveCrmPipeline } from "@unified-api/typescript-sdk/funcs/crmRemoveCrmPipeline.js";
|
|
2371
|
-
|
|
2372
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2373
|
-
// You can create one instance of it to use across an application.
|
|
2374
|
-
const unifiedTo = new UnifiedToCore({
|
|
2375
|
-
security: {
|
|
2376
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2377
|
-
},
|
|
2378
|
-
});
|
|
2379
|
-
|
|
2380
|
-
async function run() {
|
|
2381
|
-
const res = await crmRemoveCrmPipeline(unifiedTo, {
|
|
2382
|
-
connectionId: "<id>",
|
|
2383
|
-
id: "<id>",
|
|
2384
|
-
});
|
|
2385
|
-
if (res.ok) {
|
|
2386
|
-
const { value: result } = res;
|
|
2387
|
-
console.log(result);
|
|
2388
|
-
} else {
|
|
2389
|
-
console.log("crmRemoveCrmPipeline failed:", res.error);
|
|
2390
|
-
}
|
|
2391
|
-
}
|
|
2392
|
-
|
|
2393
|
-
run();
|
|
2394
|
-
```
|
|
2395
|
-
|
|
2396
|
-
### Parameters
|
|
2397
|
-
|
|
2398
|
-
| Parameter | Type | Required | Description |
|
|
2399
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2400
|
-
| `request` | [operations.RemoveCrmPipelineRequest](../../sdk/models/operations/removecrmpipelinerequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2401
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2402
|
-
| `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. |
|
|
2403
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2404
|
-
|
|
2405
|
-
### Response
|
|
2406
|
-
|
|
2407
|
-
**Promise\<[operations.RemoveCrmPipelineResponse](../../sdk/models/operations/removecrmpipelineresponse.md)\>**
|
|
2408
|
-
|
|
2409
|
-
### Errors
|
|
2410
|
-
|
|
2411
|
-
| Error Type | Status Code | Content Type |
|
|
2412
|
-
| --------------- | --------------- | --------------- |
|
|
2413
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2414
|
-
|
|
2415
|
-
## updateCrmCompany
|
|
2416
|
-
|
|
2417
|
-
Update a company
|
|
2418
|
-
|
|
2419
|
-
### Example Usage
|
|
2420
|
-
|
|
2421
|
-
<!-- UsageSnippet language="typescript" operationID="updateCrmCompany" method="put" path="/crm/{connection_id}/company/{id}" -->
|
|
2422
|
-
```typescript
|
|
2423
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2424
|
-
|
|
2425
|
-
const unifiedTo = new UnifiedTo({
|
|
2426
|
-
security: {
|
|
2427
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2428
|
-
},
|
|
2429
|
-
});
|
|
2430
|
-
|
|
2431
|
-
async function run() {
|
|
2432
|
-
const result = await unifiedTo.crm.updateCrmCompany({
|
|
2433
|
-
crmCompany: {},
|
|
2434
|
-
connectionId: "<id>",
|
|
2435
|
-
id: "<id>",
|
|
2436
|
-
});
|
|
2437
|
-
|
|
2438
|
-
console.log(result);
|
|
2439
|
-
}
|
|
2440
|
-
|
|
2441
|
-
run();
|
|
2442
|
-
```
|
|
2443
|
-
|
|
2444
|
-
### Standalone function
|
|
2445
|
-
|
|
2446
|
-
The standalone function version of this method:
|
|
2447
|
-
|
|
2448
|
-
```typescript
|
|
2449
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2450
|
-
import { companyUpdateCrmCompany } from "@unified-api/typescript-sdk/funcs/companyUpdateCrmCompany.js";
|
|
2451
|
-
|
|
2452
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2453
|
-
// You can create one instance of it to use across an application.
|
|
2454
|
-
const unifiedTo = new UnifiedToCore({
|
|
2455
|
-
security: {
|
|
2456
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2457
|
-
},
|
|
2458
|
-
});
|
|
2459
|
-
|
|
2460
|
-
async function run() {
|
|
2461
|
-
const res = await companyUpdateCrmCompany(unifiedTo, {
|
|
2462
|
-
crmCompany: {},
|
|
2463
|
-
connectionId: "<id>",
|
|
2464
|
-
id: "<id>",
|
|
2465
|
-
});
|
|
2466
|
-
if (res.ok) {
|
|
2467
|
-
const { value: result } = res;
|
|
2468
|
-
console.log(result);
|
|
2469
|
-
} else {
|
|
2470
|
-
console.log("companyUpdateCrmCompany failed:", res.error);
|
|
2471
|
-
}
|
|
2472
|
-
}
|
|
2473
|
-
|
|
2474
|
-
run();
|
|
2475
|
-
```
|
|
2476
|
-
|
|
2477
|
-
### Parameters
|
|
2478
|
-
|
|
2479
|
-
| Parameter | Type | Required | Description |
|
|
2480
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2481
|
-
| `request` | [operations.UpdateCrmCompanyRequest](../../sdk/models/operations/updatecrmcompanyrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2482
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2483
|
-
| `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. |
|
|
2484
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2485
|
-
|
|
2486
|
-
### Response
|
|
2487
|
-
|
|
2488
|
-
**Promise\<[shared.CrmCompany](../../sdk/models/shared/crmcompany.md)\>**
|
|
2489
|
-
|
|
2490
|
-
### Errors
|
|
2491
|
-
|
|
2492
|
-
| Error Type | Status Code | Content Type |
|
|
2493
|
-
| --------------- | --------------- | --------------- |
|
|
2494
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2495
|
-
|
|
2496
|
-
## updateCrmContact
|
|
2497
|
-
|
|
2498
|
-
Update a contact
|
|
2499
|
-
|
|
2500
|
-
### Example Usage
|
|
2501
|
-
|
|
2502
|
-
<!-- UsageSnippet language="typescript" operationID="updateCrmContact" method="put" path="/crm/{connection_id}/contact/{id}" -->
|
|
2503
|
-
```typescript
|
|
2504
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2505
|
-
|
|
2506
|
-
const unifiedTo = new UnifiedTo({
|
|
2507
|
-
security: {
|
|
2508
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2509
|
-
},
|
|
2510
|
-
});
|
|
2511
|
-
|
|
2512
|
-
async function run() {
|
|
2513
|
-
const result = await unifiedTo.crm.updateCrmContact({
|
|
2514
|
-
crmContact: {},
|
|
2515
|
-
connectionId: "<id>",
|
|
2516
|
-
id: "<id>",
|
|
2517
|
-
});
|
|
2518
|
-
|
|
2519
|
-
console.log(result);
|
|
2520
|
-
}
|
|
2521
|
-
|
|
2522
|
-
run();
|
|
2523
|
-
```
|
|
2524
|
-
|
|
2525
|
-
### Standalone function
|
|
2526
|
-
|
|
2527
|
-
The standalone function version of this method:
|
|
2528
|
-
|
|
2529
|
-
```typescript
|
|
2530
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2531
|
-
import { contactUpdateCrmContact } from "@unified-api/typescript-sdk/funcs/contactUpdateCrmContact.js";
|
|
2532
|
-
|
|
2533
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2534
|
-
// You can create one instance of it to use across an application.
|
|
2535
|
-
const unifiedTo = new UnifiedToCore({
|
|
2536
|
-
security: {
|
|
2537
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2538
|
-
},
|
|
2539
|
-
});
|
|
2540
|
-
|
|
2541
|
-
async function run() {
|
|
2542
|
-
const res = await contactUpdateCrmContact(unifiedTo, {
|
|
2543
|
-
crmContact: {},
|
|
2544
|
-
connectionId: "<id>",
|
|
2545
|
-
id: "<id>",
|
|
2546
|
-
});
|
|
2547
|
-
if (res.ok) {
|
|
2548
|
-
const { value: result } = res;
|
|
2549
|
-
console.log(result);
|
|
2550
|
-
} else {
|
|
2551
|
-
console.log("contactUpdateCrmContact failed:", res.error);
|
|
2552
|
-
}
|
|
2553
|
-
}
|
|
2554
|
-
|
|
2555
|
-
run();
|
|
2556
|
-
```
|
|
2557
|
-
|
|
2558
|
-
### Parameters
|
|
2559
|
-
|
|
2560
|
-
| Parameter | Type | Required | Description |
|
|
2561
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2562
|
-
| `request` | [operations.UpdateCrmContactRequest](../../sdk/models/operations/updatecrmcontactrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2563
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2564
|
-
| `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. |
|
|
2565
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2566
|
-
|
|
2567
|
-
### Response
|
|
2568
|
-
|
|
2569
|
-
**Promise\<[shared.CrmContact](../../sdk/models/shared/crmcontact.md)\>**
|
|
2570
|
-
|
|
2571
|
-
### Errors
|
|
2572
|
-
|
|
2573
|
-
| Error Type | Status Code | Content Type |
|
|
2574
|
-
| --------------- | --------------- | --------------- |
|
|
2575
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2576
|
-
|
|
2577
|
-
## updateCrmDeal
|
|
2578
|
-
|
|
2579
|
-
Update a deal
|
|
2580
|
-
|
|
2581
|
-
### Example Usage
|
|
2582
|
-
|
|
2583
|
-
<!-- UsageSnippet language="typescript" operationID="updateCrmDeal" method="put" path="/crm/{connection_id}/deal/{id}" -->
|
|
2584
|
-
```typescript
|
|
2585
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2586
|
-
|
|
2587
|
-
const unifiedTo = new UnifiedTo({
|
|
2588
|
-
security: {
|
|
2589
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2590
|
-
},
|
|
2591
|
-
});
|
|
2592
|
-
|
|
2593
|
-
async function run() {
|
|
2594
|
-
const result = await unifiedTo.crm.updateCrmDeal({
|
|
2595
|
-
crmDeal: {},
|
|
2596
|
-
connectionId: "<id>",
|
|
2597
|
-
id: "<id>",
|
|
2598
|
-
});
|
|
2599
|
-
|
|
2600
|
-
console.log(result);
|
|
2601
|
-
}
|
|
2602
|
-
|
|
2603
|
-
run();
|
|
2604
|
-
```
|
|
2605
|
-
|
|
2606
|
-
### Standalone function
|
|
2607
|
-
|
|
2608
|
-
The standalone function version of this method:
|
|
2609
|
-
|
|
2610
|
-
```typescript
|
|
2611
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2612
|
-
import { crmUpdateCrmDeal } from "@unified-api/typescript-sdk/funcs/crmUpdateCrmDeal.js";
|
|
2613
|
-
|
|
2614
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2615
|
-
// You can create one instance of it to use across an application.
|
|
2616
|
-
const unifiedTo = new UnifiedToCore({
|
|
2617
|
-
security: {
|
|
2618
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2619
|
-
},
|
|
2620
|
-
});
|
|
2621
|
-
|
|
2622
|
-
async function run() {
|
|
2623
|
-
const res = await crmUpdateCrmDeal(unifiedTo, {
|
|
2624
|
-
crmDeal: {},
|
|
2625
|
-
connectionId: "<id>",
|
|
2626
|
-
id: "<id>",
|
|
2627
|
-
});
|
|
2628
|
-
if (res.ok) {
|
|
2629
|
-
const { value: result } = res;
|
|
2630
|
-
console.log(result);
|
|
2631
|
-
} else {
|
|
2632
|
-
console.log("crmUpdateCrmDeal failed:", res.error);
|
|
2633
|
-
}
|
|
2634
|
-
}
|
|
2635
|
-
|
|
2636
|
-
run();
|
|
2637
|
-
```
|
|
2638
|
-
|
|
2639
|
-
### Parameters
|
|
2640
|
-
|
|
2641
|
-
| Parameter | Type | Required | Description |
|
|
2642
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2643
|
-
| `request` | [operations.UpdateCrmDealRequest](../../sdk/models/operations/updatecrmdealrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2644
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2645
|
-
| `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. |
|
|
2646
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2647
|
-
|
|
2648
|
-
### Response
|
|
2649
|
-
|
|
2650
|
-
**Promise\<[shared.CrmDeal](../../sdk/models/shared/crmdeal.md)\>**
|
|
2651
|
-
|
|
2652
|
-
### Errors
|
|
2653
|
-
|
|
2654
|
-
| Error Type | Status Code | Content Type |
|
|
2655
|
-
| --------------- | --------------- | --------------- |
|
|
2656
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2657
|
-
|
|
2658
|
-
## updateCrmEvent
|
|
2659
|
-
|
|
2660
|
-
Update an event
|
|
2661
|
-
|
|
2662
|
-
### Example Usage
|
|
2663
|
-
|
|
2664
|
-
<!-- UsageSnippet language="typescript" operationID="updateCrmEvent" method="put" path="/crm/{connection_id}/event/{id}" -->
|
|
2665
|
-
```typescript
|
|
2666
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2667
|
-
|
|
2668
|
-
const unifiedTo = new UnifiedTo({
|
|
2669
|
-
security: {
|
|
2670
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2671
|
-
},
|
|
2672
|
-
});
|
|
2673
|
-
|
|
2674
|
-
async function run() {
|
|
2675
|
-
const result = await unifiedTo.crm.updateCrmEvent({
|
|
2676
|
-
crmEvent: {},
|
|
2677
|
-
connectionId: "<id>",
|
|
2678
|
-
id: "<id>",
|
|
2679
|
-
});
|
|
2680
|
-
|
|
2681
|
-
console.log(result);
|
|
2682
|
-
}
|
|
2683
|
-
|
|
2684
|
-
run();
|
|
2685
|
-
```
|
|
2686
|
-
|
|
2687
|
-
### Standalone function
|
|
2688
|
-
|
|
2689
|
-
The standalone function version of this method:
|
|
2690
|
-
|
|
2691
|
-
```typescript
|
|
2692
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2693
|
-
import { eventUpdateCrmEvent } from "@unified-api/typescript-sdk/funcs/eventUpdateCrmEvent.js";
|
|
2694
|
-
|
|
2695
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2696
|
-
// You can create one instance of it to use across an application.
|
|
2697
|
-
const unifiedTo = new UnifiedToCore({
|
|
2698
|
-
security: {
|
|
2699
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2700
|
-
},
|
|
2701
|
-
});
|
|
2702
|
-
|
|
2703
|
-
async function run() {
|
|
2704
|
-
const res = await eventUpdateCrmEvent(unifiedTo, {
|
|
2705
|
-
crmEvent: {},
|
|
2706
|
-
connectionId: "<id>",
|
|
2707
|
-
id: "<id>",
|
|
2708
|
-
});
|
|
2709
|
-
if (res.ok) {
|
|
2710
|
-
const { value: result } = res;
|
|
2711
|
-
console.log(result);
|
|
2712
|
-
} else {
|
|
2713
|
-
console.log("eventUpdateCrmEvent failed:", res.error);
|
|
2714
|
-
}
|
|
2715
|
-
}
|
|
2716
|
-
|
|
2717
|
-
run();
|
|
2718
|
-
```
|
|
2719
|
-
|
|
2720
|
-
### Parameters
|
|
2721
|
-
|
|
2722
|
-
| Parameter | Type | Required | Description |
|
|
2723
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2724
|
-
| `request` | [operations.UpdateCrmEventRequest](../../sdk/models/operations/updatecrmeventrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2725
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2726
|
-
| `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. |
|
|
2727
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2728
|
-
|
|
2729
|
-
### Response
|
|
2730
|
-
|
|
2731
|
-
**Promise\<[shared.CrmEvent](../../sdk/models/shared/crmevent.md)\>**
|
|
2732
|
-
|
|
2733
|
-
### Errors
|
|
2734
|
-
|
|
2735
|
-
| Error Type | Status Code | Content Type |
|
|
2736
|
-
| --------------- | --------------- | --------------- |
|
|
2737
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2738
|
-
|
|
2739
|
-
## updateCrmLead
|
|
2740
|
-
|
|
2741
|
-
Update a lead
|
|
2742
|
-
|
|
2743
|
-
### Example Usage
|
|
2744
|
-
|
|
2745
|
-
<!-- UsageSnippet language="typescript" operationID="updateCrmLead" method="put" path="/crm/{connection_id}/lead/{id}" -->
|
|
2746
|
-
```typescript
|
|
2747
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2748
|
-
|
|
2749
|
-
const unifiedTo = new UnifiedTo({
|
|
2750
|
-
security: {
|
|
2751
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2752
|
-
},
|
|
2753
|
-
});
|
|
2754
|
-
|
|
2755
|
-
async function run() {
|
|
2756
|
-
const result = await unifiedTo.crm.updateCrmLead({
|
|
2757
|
-
crmLead: {},
|
|
2758
|
-
connectionId: "<id>",
|
|
2759
|
-
id: "<id>",
|
|
2760
|
-
});
|
|
2761
|
-
|
|
2762
|
-
console.log(result);
|
|
2763
|
-
}
|
|
2764
|
-
|
|
2765
|
-
run();
|
|
2766
|
-
```
|
|
2767
|
-
|
|
2768
|
-
### Standalone function
|
|
2769
|
-
|
|
2770
|
-
The standalone function version of this method:
|
|
2771
|
-
|
|
2772
|
-
```typescript
|
|
2773
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2774
|
-
import { crmUpdateCrmLead } from "@unified-api/typescript-sdk/funcs/crmUpdateCrmLead.js";
|
|
2775
|
-
|
|
2776
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2777
|
-
// You can create one instance of it to use across an application.
|
|
2778
|
-
const unifiedTo = new UnifiedToCore({
|
|
2779
|
-
security: {
|
|
2780
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2781
|
-
},
|
|
2782
|
-
});
|
|
2783
|
-
|
|
2784
|
-
async function run() {
|
|
2785
|
-
const res = await crmUpdateCrmLead(unifiedTo, {
|
|
2786
|
-
crmLead: {},
|
|
2787
|
-
connectionId: "<id>",
|
|
2788
|
-
id: "<id>",
|
|
2789
|
-
});
|
|
2790
|
-
if (res.ok) {
|
|
2791
|
-
const { value: result } = res;
|
|
2792
|
-
console.log(result);
|
|
2793
|
-
} else {
|
|
2794
|
-
console.log("crmUpdateCrmLead failed:", res.error);
|
|
2795
|
-
}
|
|
2796
|
-
}
|
|
2797
|
-
|
|
2798
|
-
run();
|
|
2799
|
-
```
|
|
2800
|
-
|
|
2801
|
-
### Parameters
|
|
2802
|
-
|
|
2803
|
-
| Parameter | Type | Required | Description |
|
|
2804
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2805
|
-
| `request` | [operations.UpdateCrmLeadRequest](../../sdk/models/operations/updatecrmleadrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2806
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2807
|
-
| `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. |
|
|
2808
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2809
|
-
|
|
2810
|
-
### Response
|
|
2811
|
-
|
|
2812
|
-
**Promise\<[shared.CrmLead](../../sdk/models/shared/crmlead.md)\>**
|
|
2813
|
-
|
|
2814
|
-
### Errors
|
|
2815
|
-
|
|
2816
|
-
| Error Type | Status Code | Content Type |
|
|
2817
|
-
| --------------- | --------------- | --------------- |
|
|
2818
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|
|
2819
|
-
|
|
2820
|
-
## updateCrmPipeline
|
|
2821
|
-
|
|
2822
|
-
Update a pipeline
|
|
2823
|
-
|
|
2824
|
-
### Example Usage
|
|
2825
|
-
|
|
2826
|
-
<!-- UsageSnippet language="typescript" operationID="updateCrmPipeline" method="put" path="/crm/{connection_id}/pipeline/{id}" -->
|
|
2827
|
-
```typescript
|
|
2828
|
-
import { UnifiedTo } from "@unified-api/typescript-sdk";
|
|
2829
|
-
|
|
2830
|
-
const unifiedTo = new UnifiedTo({
|
|
2831
|
-
security: {
|
|
2832
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2833
|
-
},
|
|
2834
|
-
});
|
|
2835
|
-
|
|
2836
|
-
async function run() {
|
|
2837
|
-
const result = await unifiedTo.crm.updateCrmPipeline({
|
|
2838
|
-
crmPipeline: {},
|
|
2839
|
-
connectionId: "<id>",
|
|
2840
|
-
id: "<id>",
|
|
2841
|
-
});
|
|
2842
|
-
|
|
2843
|
-
console.log(result);
|
|
2844
|
-
}
|
|
2845
|
-
|
|
2846
|
-
run();
|
|
2847
|
-
```
|
|
2848
|
-
|
|
2849
|
-
### Standalone function
|
|
2850
|
-
|
|
2851
|
-
The standalone function version of this method:
|
|
2852
|
-
|
|
2853
|
-
```typescript
|
|
2854
|
-
import { UnifiedToCore } from "@unified-api/typescript-sdk/core.js";
|
|
2855
|
-
import { crmUpdateCrmPipeline } from "@unified-api/typescript-sdk/funcs/crmUpdateCrmPipeline.js";
|
|
2856
|
-
|
|
2857
|
-
// Use `UnifiedToCore` for best tree-shaking performance.
|
|
2858
|
-
// You can create one instance of it to use across an application.
|
|
2859
|
-
const unifiedTo = new UnifiedToCore({
|
|
2860
|
-
security: {
|
|
2861
|
-
jwt: "<YOUR_API_KEY_HERE>",
|
|
2862
|
-
},
|
|
2863
|
-
});
|
|
2864
|
-
|
|
2865
|
-
async function run() {
|
|
2866
|
-
const res = await crmUpdateCrmPipeline(unifiedTo, {
|
|
2867
|
-
crmPipeline: {},
|
|
2868
|
-
connectionId: "<id>",
|
|
2869
|
-
id: "<id>",
|
|
2870
|
-
});
|
|
2871
|
-
if (res.ok) {
|
|
2872
|
-
const { value: result } = res;
|
|
2873
|
-
console.log(result);
|
|
2874
|
-
} else {
|
|
2875
|
-
console.log("crmUpdateCrmPipeline failed:", res.error);
|
|
2876
|
-
}
|
|
2877
|
-
}
|
|
2878
|
-
|
|
2879
|
-
run();
|
|
2880
|
-
```
|
|
2881
|
-
|
|
2882
|
-
### Parameters
|
|
2883
|
-
|
|
2884
|
-
| Parameter | Type | Required | Description |
|
|
2885
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
2886
|
-
| `request` | [operations.UpdateCrmPipelineRequest](../../sdk/models/operations/updatecrmpipelinerequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
2887
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
2888
|
-
| `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. |
|
|
2889
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
2890
|
-
|
|
2891
|
-
### Response
|
|
2892
|
-
|
|
2893
|
-
**Promise\<[shared.CrmPipeline](../../sdk/models/shared/crmpipeline.md)\>**
|
|
2894
|
-
|
|
2895
|
-
### Errors
|
|
2896
|
-
|
|
2897
|
-
| Error Type | Status Code | Content Type |
|
|
2898
|
-
| --------------- | --------------- | --------------- |
|
|
2899
|
-
| errors.SDKError | 4XX, 5XX | \*/\* |
|