@iblai/iblai-api 4.265.1-ai → 4.265.2-ai
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/dist/index.cjs.js +1946 -36
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +1943 -37
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +1946 -36
- package/dist/index.umd.js.map +1 -1
- package/dist/types/index.d.ts +26 -1
- package/dist/types/models/Activity.d.ts +83 -0
- package/dist/types/models/ActivityTypeEnum.d.ts +18 -0
- package/dist/types/models/Deal.d.ts +83 -0
- package/dist/types/models/DealLostRequest.d.ts +10 -0
- package/dist/types/models/DealMoveStageRequest.d.ts +10 -0
- package/dist/types/models/DealStatusEnum.d.ts +10 -0
- package/dist/types/models/DealWonRequest.d.ts +6 -0
- package/dist/types/models/LeadSource.d.ts +30 -0
- package/dist/types/models/NotificationTemplateDetail.d.ts +24 -2
- package/dist/types/models/NotificationTemplateList.d.ts +5 -2
- package/dist/types/models/Organization.d.ts +1 -1
- package/dist/types/models/PaginatedActivityList.d.ts +7 -0
- package/dist/types/models/PaginatedDealList.d.ts +7 -0
- package/dist/types/models/PaginatedLeadSourceList.d.ts +7 -0
- package/dist/types/models/PaginatedPipelineList.d.ts +7 -0
- package/dist/types/models/PaginatedPipelineStageList.d.ts +7 -0
- package/dist/types/models/PatchedActivity.d.ts +83 -0
- package/dist/types/models/PatchedDeal.d.ts +83 -0
- package/dist/types/models/PatchedLeadSource.d.ts +30 -0
- package/dist/types/models/PatchedNotificationTemplateDetail.d.ts +24 -2
- package/dist/types/models/PatchedOrganization.d.ts +1 -1
- package/dist/types/models/PatchedPipeline.d.ts +34 -0
- package/dist/types/models/PatchedPipelineStage.d.ts +40 -0
- package/dist/types/models/Pipeline.d.ts +34 -0
- package/dist/types/models/PipelineStage.d.ts +40 -0
- package/dist/types/models/RecipientsRecipientModeEnum.d.ts +14 -0
- package/dist/types/models/{TypeD36Enum.d.ts → Type4b7Enum.d.ts} +7 -1
- package/dist/types/services/ActivitiesService.d.ts +126 -0
- package/dist/types/services/CrmService.d.ts +553 -1
- package/dist/types/services/DealsService.d.ts +160 -0
- package/dist/types/services/LeadSourcesService.d.ts +95 -0
- package/dist/types/services/PersonsService.d.ts +1 -1
- package/dist/types/services/PipelinesService.d.ts +183 -0
- package/package.json +1 -1
- package/sdk_schema.yml +4093 -141
- package/src/core/OpenAPI.ts +1 -1
- package/src/index.ts +26 -1
- package/src/models/Activity.ts +88 -0
- package/src/models/ActivityTypeEnum.ts +22 -0
- package/src/models/Deal.ts +88 -0
- package/src/models/DealLostRequest.ts +15 -0
- package/src/models/DealMoveStageRequest.ts +15 -0
- package/src/models/DealStatusEnum.ts +14 -0
- package/src/models/DealWonRequest.ts +11 -0
- package/src/models/LeadSource.ts +35 -0
- package/src/models/NotificationTemplateDetail.ts +24 -2
- package/src/models/NotificationTemplateList.ts +5 -2
- package/src/models/Organization.ts +1 -1
- package/src/models/PaginatedActivityList.ts +12 -0
- package/src/models/PaginatedDealList.ts +12 -0
- package/src/models/PaginatedLeadSourceList.ts +12 -0
- package/src/models/PaginatedPipelineList.ts +12 -0
- package/src/models/PaginatedPipelineStageList.ts +12 -0
- package/src/models/PatchedActivity.ts +88 -0
- package/src/models/PatchedDeal.ts +88 -0
- package/src/models/PatchedLeadSource.ts +35 -0
- package/src/models/PatchedNotificationTemplateDetail.ts +24 -2
- package/src/models/PatchedOrganization.ts +1 -1
- package/src/models/PatchedPipeline.ts +39 -0
- package/src/models/PatchedPipelineStage.ts +45 -0
- package/src/models/Pipeline.ts +39 -0
- package/src/models/PipelineStage.ts +45 -0
- package/src/models/RecipientsRecipientModeEnum.ts +18 -0
- package/src/models/{TypeD36Enum.ts → Type4b7Enum.ts} +7 -1
- package/src/services/ActivitiesService.ts +255 -0
- package/src/services/CrmService.ts +1161 -1
- package/src/services/DealsService.ts +337 -0
- package/src/services/LeadSourcesService.ts +198 -0
- package/src/services/PersonsService.ts +1 -1
- package/src/services/PipelinesService.ts +406 -0
package/dist/index.cjs.js
CHANGED
|
@@ -110,7 +110,7 @@ class CancelablePromise {
|
|
|
110
110
|
|
|
111
111
|
const OpenAPI = {
|
|
112
112
|
BASE: 'https://base.manager.iblai.app',
|
|
113
|
-
VERSION: '4.265.
|
|
113
|
+
VERSION: '4.265.2-ai-plus',
|
|
114
114
|
WITH_CREDENTIALS: false,
|
|
115
115
|
CREDENTIALS: 'include',
|
|
116
116
|
TOKEN: undefined,
|
|
@@ -150,6 +150,30 @@ exports.AccessEnum = void 0;
|
|
|
150
150
|
AccessEnum["PRIVATE"] = "private";
|
|
151
151
|
})(exports.AccessEnum || (exports.AccessEnum = {}));
|
|
152
152
|
|
|
153
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
154
|
+
/* istanbul ignore file */
|
|
155
|
+
/* tslint:disable */
|
|
156
|
+
/* eslint-disable */
|
|
157
|
+
/**
|
|
158
|
+
* * `call` - Call
|
|
159
|
+
* * `meeting` - Meeting
|
|
160
|
+
* * `email` - Email
|
|
161
|
+
* * `note` - Note
|
|
162
|
+
* * `task` - Task
|
|
163
|
+
* * `lunch` - Lunch
|
|
164
|
+
* * `deadline` - Deadline
|
|
165
|
+
*/
|
|
166
|
+
exports.ActivityTypeEnum = void 0;
|
|
167
|
+
(function (ActivityTypeEnum) {
|
|
168
|
+
ActivityTypeEnum["CALL"] = "call";
|
|
169
|
+
ActivityTypeEnum["MEETING"] = "meeting";
|
|
170
|
+
ActivityTypeEnum["EMAIL"] = "email";
|
|
171
|
+
ActivityTypeEnum["NOTE"] = "note";
|
|
172
|
+
ActivityTypeEnum["TASK"] = "task";
|
|
173
|
+
ActivityTypeEnum["LUNCH"] = "lunch";
|
|
174
|
+
ActivityTypeEnum["DEADLINE"] = "deadline";
|
|
175
|
+
})(exports.ActivityTypeEnum || (exports.ActivityTypeEnum = {}));
|
|
176
|
+
|
|
153
177
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
154
178
|
/* istanbul ignore file */
|
|
155
179
|
/* tslint:disable */
|
|
@@ -451,6 +475,22 @@ exports.DataTypeEnum = void 0;
|
|
|
451
475
|
DataTypeEnum["CATEGORICAL"] = "CATEGORICAL";
|
|
452
476
|
})(exports.DataTypeEnum || (exports.DataTypeEnum = {}));
|
|
453
477
|
|
|
478
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
479
|
+
/* istanbul ignore file */
|
|
480
|
+
/* tslint:disable */
|
|
481
|
+
/* eslint-disable */
|
|
482
|
+
/**
|
|
483
|
+
* * `open` - Open
|
|
484
|
+
* * `won` - Won
|
|
485
|
+
* * `lost` - Lost
|
|
486
|
+
*/
|
|
487
|
+
exports.DealStatusEnum = void 0;
|
|
488
|
+
(function (DealStatusEnum) {
|
|
489
|
+
DealStatusEnum["OPEN"] = "open";
|
|
490
|
+
DealStatusEnum["WON"] = "won";
|
|
491
|
+
DealStatusEnum["LOST"] = "lost";
|
|
492
|
+
})(exports.DealStatusEnum || (exports.DealStatusEnum = {}));
|
|
493
|
+
|
|
454
494
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
455
495
|
/* istanbul ignore file */
|
|
456
496
|
/* tslint:disable */
|
|
@@ -1331,6 +1371,26 @@ exports.RatingEnum = void 0;
|
|
|
1331
1371
|
RatingEnum[RatingEnum["_-1"] = -1] = "_-1";
|
|
1332
1372
|
})(exports.RatingEnum || (exports.RatingEnum = {}));
|
|
1333
1373
|
|
|
1374
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
1375
|
+
/* istanbul ignore file */
|
|
1376
|
+
/* tslint:disable */
|
|
1377
|
+
/* eslint-disable */
|
|
1378
|
+
/**
|
|
1379
|
+
* * `platform_admins_only` - platform_admins_only
|
|
1380
|
+
* * `object_owner_only` - object_owner_only
|
|
1381
|
+
* * `object_owner_only_strict` - object_owner_only_strict
|
|
1382
|
+
* * `platform_admins_and_object_owner` - platform_admins_and_object_owner
|
|
1383
|
+
* * `custom` - custom
|
|
1384
|
+
*/
|
|
1385
|
+
exports.RecipientsRecipientModeEnum = void 0;
|
|
1386
|
+
(function (RecipientsRecipientModeEnum) {
|
|
1387
|
+
RecipientsRecipientModeEnum["PLATFORM_ADMINS_ONLY"] = "platform_admins_only";
|
|
1388
|
+
RecipientsRecipientModeEnum["OBJECT_OWNER_ONLY"] = "object_owner_only";
|
|
1389
|
+
RecipientsRecipientModeEnum["OBJECT_OWNER_ONLY_STRICT"] = "object_owner_only_strict";
|
|
1390
|
+
RecipientsRecipientModeEnum["PLATFORM_ADMINS_AND_OBJECT_OWNER"] = "platform_admins_and_object_owner";
|
|
1391
|
+
RecipientsRecipientModeEnum["CUSTOM"] = "custom";
|
|
1392
|
+
})(exports.RecipientsRecipientModeEnum || (exports.RecipientsRecipientModeEnum = {}));
|
|
1393
|
+
|
|
1334
1394
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
1335
1395
|
/* istanbul ignore file */
|
|
1336
1396
|
/* tslint:disable */
|
|
@@ -1659,6 +1719,9 @@ exports.TtsProviderEnum = void 0;
|
|
|
1659
1719
|
* * `COURSE_LICENSE_GROUP_ASSIGNMENT` - Course License Group Assignment
|
|
1660
1720
|
* * `COURSE_SCHEDULE_CHANGE` - Course Schedule Change
|
|
1661
1721
|
* * `COURSES_PROGRESS_SUMMARY` - Courses Progress Summary
|
|
1722
|
+
* * `CRM_DEAL_STAGE_CHANGED` - Crm Deal Stage Changed
|
|
1723
|
+
* * `CRM_PERSON_CREATED` - Crm Person Created
|
|
1724
|
+
* * `CRM_PERSON_LINKED_TO_USER` - Crm Person Linked To User
|
|
1662
1725
|
* * `CUSTOM_NOTIFICATION` - Custom Notification
|
|
1663
1726
|
* * `DEFAULT_TEMPLATE` - Default Template
|
|
1664
1727
|
* * `HUMAN_SUPPORT_NOTIFICATION` - Human Support Notification
|
|
@@ -1683,41 +1746,44 @@ exports.TtsProviderEnum = void 0;
|
|
|
1683
1746
|
* * `USER_NOTIF_USER_INACTIVITY` - User Notif User Inactivity
|
|
1684
1747
|
* * `USER_NOTIF_USER_REGISTRATION` - User Notif User Registration
|
|
1685
1748
|
*/
|
|
1686
|
-
exports.
|
|
1687
|
-
(function (
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1749
|
+
exports.Type4b7Enum = void 0;
|
|
1750
|
+
(function (Type4b7Enum) {
|
|
1751
|
+
Type4b7Enum["ACTIVITY_COURSE_MILESTONE"] = "ACTIVITY_COURSE_MILESTONE";
|
|
1752
|
+
Type4b7Enum["ACTIVITY_NEW_CONTENT"] = "ACTIVITY_NEW_CONTENT";
|
|
1753
|
+
Type4b7Enum["ADMIN_NOTIF_COURSE_ENROLLMENT"] = "ADMIN_NOTIF_COURSE_ENROLLMENT";
|
|
1754
|
+
Type4b7Enum["APP_REGISTRATION"] = "APP_REGISTRATION";
|
|
1755
|
+
Type4b7Enum["COURSE_INVITATION"] = "COURSE_INVITATION";
|
|
1756
|
+
Type4b7Enum["COURSE_LICENSE_ASSIGNMENT"] = "COURSE_LICENSE_ASSIGNMENT";
|
|
1757
|
+
Type4b7Enum["COURSE_LICENSE_GROUP_ASSIGNMENT"] = "COURSE_LICENSE_GROUP_ASSIGNMENT";
|
|
1758
|
+
Type4b7Enum["COURSE_SCHEDULE_CHANGE"] = "COURSE_SCHEDULE_CHANGE";
|
|
1759
|
+
Type4b7Enum["COURSES_PROGRESS_SUMMARY"] = "COURSES_PROGRESS_SUMMARY";
|
|
1760
|
+
Type4b7Enum["CRM_DEAL_STAGE_CHANGED"] = "CRM_DEAL_STAGE_CHANGED";
|
|
1761
|
+
Type4b7Enum["CRM_PERSON_CREATED"] = "CRM_PERSON_CREATED";
|
|
1762
|
+
Type4b7Enum["CRM_PERSON_LINKED_TO_USER"] = "CRM_PERSON_LINKED_TO_USER";
|
|
1763
|
+
Type4b7Enum["CUSTOM_NOTIFICATION"] = "CUSTOM_NOTIFICATION";
|
|
1764
|
+
Type4b7Enum["DEFAULT_TEMPLATE"] = "DEFAULT_TEMPLATE";
|
|
1765
|
+
Type4b7Enum["HUMAN_SUPPORT_NOTIFICATION"] = "HUMAN_SUPPORT_NOTIFICATION";
|
|
1766
|
+
Type4b7Enum["PATHWAY_ENROLLMENT_CONFIRMATION"] = "PATHWAY_ENROLLMENT_CONFIRMATION";
|
|
1767
|
+
Type4b7Enum["PLATFORM_INVITATION"] = "PLATFORM_INVITATION";
|
|
1768
|
+
Type4b7Enum["POLICY_ASSIGNMENT"] = "POLICY_ASSIGNMENT";
|
|
1769
|
+
Type4b7Enum["PROACTIVE_LEARNER_NOTIFICATION"] = "PROACTIVE_LEARNER_NOTIFICATION";
|
|
1770
|
+
Type4b7Enum["PROGRAM_ENROLLMENT_CONFIRMATION"] = "PROGRAM_ENROLLMENT_CONFIRMATION";
|
|
1771
|
+
Type4b7Enum["PROGRAM_INVITATION"] = "PROGRAM_INVITATION";
|
|
1772
|
+
Type4b7Enum["PROGRAM_LICENSE_ASSIGNMENT"] = "PROGRAM_LICENSE_ASSIGNMENT";
|
|
1773
|
+
Type4b7Enum["PROGRAM_LICENSE_GROUP_ASSIGNMENT"] = "PROGRAM_LICENSE_GROUP_ASSIGNMENT";
|
|
1774
|
+
Type4b7Enum["REPORT_COMPLETED"] = "REPORT_COMPLETED";
|
|
1775
|
+
Type4b7Enum["ROLE_CHANGE"] = "ROLE_CHANGE";
|
|
1776
|
+
Type4b7Enum["SKILL_MASTERY_CHANGE"] = "SKILL_MASTERY_CHANGE";
|
|
1777
|
+
Type4b7Enum["SUBSECTION_GRADE_UPDATE"] = "SUBSECTION_GRADE_UPDATE";
|
|
1778
|
+
Type4b7Enum["USER_LICENSE_ASSIGNMENT"] = "USER_LICENSE_ASSIGNMENT";
|
|
1779
|
+
Type4b7Enum["USER_LICENSE_GROUP_ASSIGNMENT"] = "USER_LICENSE_GROUP_ASSIGNMENT";
|
|
1780
|
+
Type4b7Enum["USER_NOTIF_COURSE_COMPLETION"] = "USER_NOTIF_COURSE_COMPLETION";
|
|
1781
|
+
Type4b7Enum["USER_NOTIF_COURSE_ENROLLMENT"] = "USER_NOTIF_COURSE_ENROLLMENT";
|
|
1782
|
+
Type4b7Enum["USER_NOTIF_CREDENTIALS"] = "USER_NOTIF_CREDENTIALS";
|
|
1783
|
+
Type4b7Enum["USER_NOTIF_LEARNER_PROGRESS"] = "USER_NOTIF_LEARNER_PROGRESS";
|
|
1784
|
+
Type4b7Enum["USER_NOTIF_USER_INACTIVITY"] = "USER_NOTIF_USER_INACTIVITY";
|
|
1785
|
+
Type4b7Enum["USER_NOTIF_USER_REGISTRATION"] = "USER_NOTIF_USER_REGISTRATION";
|
|
1786
|
+
})(exports.Type4b7Enum || (exports.Type4b7Enum = {}));
|
|
1721
1787
|
|
|
1722
1788
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
1723
1789
|
/* istanbul ignore file */
|
|
@@ -2094,6 +2160,195 @@ class AccountService {
|
|
|
2094
2160
|
}
|
|
2095
2161
|
}
|
|
2096
2162
|
|
|
2163
|
+
class ActivitiesService {
|
|
2164
|
+
/**
|
|
2165
|
+
* List activities
|
|
2166
|
+
* Returns a paginated list of Activities in your Platform. Supports filtering by `type`, `is_done`, `owner`, `deal`, `person`, schedule-from ranges, and `metadata__has_key`.
|
|
2167
|
+
*
|
|
2168
|
+
* **Required permission:** `Ibl.CRM/Activities/list`.
|
|
2169
|
+
* @returns PaginatedActivityList
|
|
2170
|
+
* @throws ApiError
|
|
2171
|
+
*/
|
|
2172
|
+
static activitiesList({
|
|
2173
|
+
deal,
|
|
2174
|
+
isDone,
|
|
2175
|
+
metadataHasKey,
|
|
2176
|
+
owner,
|
|
2177
|
+
page,
|
|
2178
|
+
pageSize,
|
|
2179
|
+
person,
|
|
2180
|
+
scheduleFromGte,
|
|
2181
|
+
scheduleFromLte,
|
|
2182
|
+
type
|
|
2183
|
+
}) {
|
|
2184
|
+
return request(OpenAPI, {
|
|
2185
|
+
method: 'GET',
|
|
2186
|
+
url: '/activities/',
|
|
2187
|
+
query: {
|
|
2188
|
+
'deal': deal,
|
|
2189
|
+
'is_done': isDone,
|
|
2190
|
+
'metadata__has_key': metadataHasKey,
|
|
2191
|
+
'owner': owner,
|
|
2192
|
+
'page': page,
|
|
2193
|
+
'page_size': pageSize,
|
|
2194
|
+
'person': person,
|
|
2195
|
+
'schedule_from__gte': scheduleFromGte,
|
|
2196
|
+
'schedule_from__lte': scheduleFromLte,
|
|
2197
|
+
'type': type
|
|
2198
|
+
},
|
|
2199
|
+
errors: {
|
|
2200
|
+
401: `Authentication required.`,
|
|
2201
|
+
403: `Missing required permission \`Ibl.CRM/Activities/list\`.`
|
|
2202
|
+
}
|
|
2203
|
+
});
|
|
2204
|
+
}
|
|
2205
|
+
/**
|
|
2206
|
+
* Create an activity
|
|
2207
|
+
* Creates an Activity. Either `deal` or `person` must be supplied; both must belong to your Platform.
|
|
2208
|
+
*
|
|
2209
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
2210
|
+
* @returns Activity
|
|
2211
|
+
* @throws ApiError
|
|
2212
|
+
*/
|
|
2213
|
+
static activitiesCreate({
|
|
2214
|
+
requestBody
|
|
2215
|
+
}) {
|
|
2216
|
+
return request(OpenAPI, {
|
|
2217
|
+
method: 'POST',
|
|
2218
|
+
url: '/activities/',
|
|
2219
|
+
body: requestBody,
|
|
2220
|
+
mediaType: 'application/json',
|
|
2221
|
+
errors: {
|
|
2222
|
+
400: `Validation error.`,
|
|
2223
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`
|
|
2224
|
+
}
|
|
2225
|
+
});
|
|
2226
|
+
}
|
|
2227
|
+
/**
|
|
2228
|
+
* Retrieve an activity
|
|
2229
|
+
* Returns a single Activity by id.
|
|
2230
|
+
*
|
|
2231
|
+
* **Required permission:** `Ibl.CRM/Activities/read`.
|
|
2232
|
+
* @returns Activity
|
|
2233
|
+
* @throws ApiError
|
|
2234
|
+
*/
|
|
2235
|
+
static activitiesRetrieve({
|
|
2236
|
+
id
|
|
2237
|
+
}) {
|
|
2238
|
+
return request(OpenAPI, {
|
|
2239
|
+
method: 'GET',
|
|
2240
|
+
url: '/activities/{id}/',
|
|
2241
|
+
path: {
|
|
2242
|
+
'id': id
|
|
2243
|
+
},
|
|
2244
|
+
errors: {
|
|
2245
|
+
403: `Missing required permission \`Ibl.CRM/Activities/read\`.`,
|
|
2246
|
+
404: `Activity not found.`
|
|
2247
|
+
}
|
|
2248
|
+
});
|
|
2249
|
+
}
|
|
2250
|
+
/**
|
|
2251
|
+
* Replace an activity
|
|
2252
|
+
* Replaces all editable fields on the Activity.
|
|
2253
|
+
*
|
|
2254
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
2255
|
+
* @returns Activity
|
|
2256
|
+
* @throws ApiError
|
|
2257
|
+
*/
|
|
2258
|
+
static activitiesUpdate({
|
|
2259
|
+
id,
|
|
2260
|
+
requestBody
|
|
2261
|
+
}) {
|
|
2262
|
+
return request(OpenAPI, {
|
|
2263
|
+
method: 'PUT',
|
|
2264
|
+
url: '/activities/{id}/',
|
|
2265
|
+
path: {
|
|
2266
|
+
'id': id
|
|
2267
|
+
},
|
|
2268
|
+
body: requestBody,
|
|
2269
|
+
mediaType: 'application/json',
|
|
2270
|
+
errors: {
|
|
2271
|
+
400: `Validation error.`,
|
|
2272
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`,
|
|
2273
|
+
404: `Activity not found.`
|
|
2274
|
+
}
|
|
2275
|
+
});
|
|
2276
|
+
}
|
|
2277
|
+
/**
|
|
2278
|
+
* Update an activity
|
|
2279
|
+
* Updates only the supplied fields on the Activity.
|
|
2280
|
+
*
|
|
2281
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
2282
|
+
* @returns Activity
|
|
2283
|
+
* @throws ApiError
|
|
2284
|
+
*/
|
|
2285
|
+
static activitiesPartialUpdate({
|
|
2286
|
+
id,
|
|
2287
|
+
requestBody
|
|
2288
|
+
}) {
|
|
2289
|
+
return request(OpenAPI, {
|
|
2290
|
+
method: 'PATCH',
|
|
2291
|
+
url: '/activities/{id}/',
|
|
2292
|
+
path: {
|
|
2293
|
+
'id': id
|
|
2294
|
+
},
|
|
2295
|
+
body: requestBody,
|
|
2296
|
+
mediaType: 'application/json',
|
|
2297
|
+
errors: {
|
|
2298
|
+
400: `Validation error.`,
|
|
2299
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`,
|
|
2300
|
+
404: `Activity not found.`
|
|
2301
|
+
}
|
|
2302
|
+
});
|
|
2303
|
+
}
|
|
2304
|
+
/**
|
|
2305
|
+
* Delete an activity
|
|
2306
|
+
* Deletes the Activity.
|
|
2307
|
+
*
|
|
2308
|
+
* **Required permission:** `Ibl.CRM/Activities/delete`.
|
|
2309
|
+
* @returns void
|
|
2310
|
+
* @throws ApiError
|
|
2311
|
+
*/
|
|
2312
|
+
static activitiesDestroy({
|
|
2313
|
+
id
|
|
2314
|
+
}) {
|
|
2315
|
+
return request(OpenAPI, {
|
|
2316
|
+
method: 'DELETE',
|
|
2317
|
+
url: '/activities/{id}/',
|
|
2318
|
+
path: {
|
|
2319
|
+
'id': id
|
|
2320
|
+
},
|
|
2321
|
+
errors: {
|
|
2322
|
+
403: `Missing required permission \`Ibl.CRM/Activities/delete\`.`,
|
|
2323
|
+
404: `Activity not found.`
|
|
2324
|
+
}
|
|
2325
|
+
});
|
|
2326
|
+
}
|
|
2327
|
+
/**
|
|
2328
|
+
* Mark an activity as done
|
|
2329
|
+
* Flips `is_done=True` and stamps `done_at` if it isn't already set. Idempotent — calling on an already-done Activity preserves the original `done_at`.
|
|
2330
|
+
*
|
|
2331
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
2332
|
+
* @returns Activity
|
|
2333
|
+
* @throws ApiError
|
|
2334
|
+
*/
|
|
2335
|
+
static activitiesDoneCreate({
|
|
2336
|
+
id
|
|
2337
|
+
}) {
|
|
2338
|
+
return request(OpenAPI, {
|
|
2339
|
+
method: 'POST',
|
|
2340
|
+
url: '/activities/{id}/done/',
|
|
2341
|
+
path: {
|
|
2342
|
+
'id': id
|
|
2343
|
+
},
|
|
2344
|
+
errors: {
|
|
2345
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`,
|
|
2346
|
+
404: `Activity not found.`
|
|
2347
|
+
}
|
|
2348
|
+
});
|
|
2349
|
+
}
|
|
2350
|
+
}
|
|
2351
|
+
|
|
2097
2352
|
class AiAccountService {
|
|
2098
2353
|
/**
|
|
2099
2354
|
* @returns ConnectedService Callback for the OAuth flow
|
|
@@ -44773,6 +45028,595 @@ class CreditsService {
|
|
|
44773
45028
|
}
|
|
44774
45029
|
|
|
44775
45030
|
class CrmService {
|
|
45031
|
+
/**
|
|
45032
|
+
* List activities
|
|
45033
|
+
* Returns a paginated list of Activities in your Platform. Supports filtering by `type`, `is_done`, `owner`, `deal`, `person`, schedule-from ranges, and `metadata__has_key`.
|
|
45034
|
+
*
|
|
45035
|
+
* **Required permission:** `Ibl.CRM/Activities/list`.
|
|
45036
|
+
* @returns PaginatedActivityList
|
|
45037
|
+
* @throws ApiError
|
|
45038
|
+
*/
|
|
45039
|
+
static crmActivitiesList({
|
|
45040
|
+
deal,
|
|
45041
|
+
isDone,
|
|
45042
|
+
metadataHasKey,
|
|
45043
|
+
owner,
|
|
45044
|
+
page,
|
|
45045
|
+
pageSize,
|
|
45046
|
+
person,
|
|
45047
|
+
scheduleFromGte,
|
|
45048
|
+
scheduleFromLte,
|
|
45049
|
+
type
|
|
45050
|
+
}) {
|
|
45051
|
+
return request(OpenAPI, {
|
|
45052
|
+
method: 'GET',
|
|
45053
|
+
url: '/api/crm/activities/',
|
|
45054
|
+
query: {
|
|
45055
|
+
'deal': deal,
|
|
45056
|
+
'is_done': isDone,
|
|
45057
|
+
'metadata__has_key': metadataHasKey,
|
|
45058
|
+
'owner': owner,
|
|
45059
|
+
'page': page,
|
|
45060
|
+
'page_size': pageSize,
|
|
45061
|
+
'person': person,
|
|
45062
|
+
'schedule_from__gte': scheduleFromGte,
|
|
45063
|
+
'schedule_from__lte': scheduleFromLte,
|
|
45064
|
+
'type': type
|
|
45065
|
+
},
|
|
45066
|
+
errors: {
|
|
45067
|
+
401: `Authentication required.`,
|
|
45068
|
+
403: `Missing required permission \`Ibl.CRM/Activities/list\`.`
|
|
45069
|
+
}
|
|
45070
|
+
});
|
|
45071
|
+
}
|
|
45072
|
+
/**
|
|
45073
|
+
* Create an activity
|
|
45074
|
+
* Creates an Activity. Either `deal` or `person` must be supplied; both must belong to your Platform.
|
|
45075
|
+
*
|
|
45076
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
45077
|
+
* @returns Activity
|
|
45078
|
+
* @throws ApiError
|
|
45079
|
+
*/
|
|
45080
|
+
static crmActivitiesCreate({
|
|
45081
|
+
requestBody
|
|
45082
|
+
}) {
|
|
45083
|
+
return request(OpenAPI, {
|
|
45084
|
+
method: 'POST',
|
|
45085
|
+
url: '/api/crm/activities/',
|
|
45086
|
+
body: requestBody,
|
|
45087
|
+
mediaType: 'application/json',
|
|
45088
|
+
errors: {
|
|
45089
|
+
400: `Validation error.`,
|
|
45090
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`
|
|
45091
|
+
}
|
|
45092
|
+
});
|
|
45093
|
+
}
|
|
45094
|
+
/**
|
|
45095
|
+
* Retrieve an activity
|
|
45096
|
+
* Returns a single Activity by id.
|
|
45097
|
+
*
|
|
45098
|
+
* **Required permission:** `Ibl.CRM/Activities/read`.
|
|
45099
|
+
* @returns Activity
|
|
45100
|
+
* @throws ApiError
|
|
45101
|
+
*/
|
|
45102
|
+
static crmActivitiesRetrieve({
|
|
45103
|
+
id
|
|
45104
|
+
}) {
|
|
45105
|
+
return request(OpenAPI, {
|
|
45106
|
+
method: 'GET',
|
|
45107
|
+
url: '/api/crm/activities/{id}/',
|
|
45108
|
+
path: {
|
|
45109
|
+
'id': id
|
|
45110
|
+
},
|
|
45111
|
+
errors: {
|
|
45112
|
+
403: `Missing required permission \`Ibl.CRM/Activities/read\`.`,
|
|
45113
|
+
404: `Activity not found.`
|
|
45114
|
+
}
|
|
45115
|
+
});
|
|
45116
|
+
}
|
|
45117
|
+
/**
|
|
45118
|
+
* Replace an activity
|
|
45119
|
+
* Replaces all editable fields on the Activity.
|
|
45120
|
+
*
|
|
45121
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
45122
|
+
* @returns Activity
|
|
45123
|
+
* @throws ApiError
|
|
45124
|
+
*/
|
|
45125
|
+
static crmActivitiesUpdate({
|
|
45126
|
+
id,
|
|
45127
|
+
requestBody
|
|
45128
|
+
}) {
|
|
45129
|
+
return request(OpenAPI, {
|
|
45130
|
+
method: 'PUT',
|
|
45131
|
+
url: '/api/crm/activities/{id}/',
|
|
45132
|
+
path: {
|
|
45133
|
+
'id': id
|
|
45134
|
+
},
|
|
45135
|
+
body: requestBody,
|
|
45136
|
+
mediaType: 'application/json',
|
|
45137
|
+
errors: {
|
|
45138
|
+
400: `Validation error.`,
|
|
45139
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`,
|
|
45140
|
+
404: `Activity not found.`
|
|
45141
|
+
}
|
|
45142
|
+
});
|
|
45143
|
+
}
|
|
45144
|
+
/**
|
|
45145
|
+
* Update an activity
|
|
45146
|
+
* Updates only the supplied fields on the Activity.
|
|
45147
|
+
*
|
|
45148
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
45149
|
+
* @returns Activity
|
|
45150
|
+
* @throws ApiError
|
|
45151
|
+
*/
|
|
45152
|
+
static crmActivitiesPartialUpdate({
|
|
45153
|
+
id,
|
|
45154
|
+
requestBody
|
|
45155
|
+
}) {
|
|
45156
|
+
return request(OpenAPI, {
|
|
45157
|
+
method: 'PATCH',
|
|
45158
|
+
url: '/api/crm/activities/{id}/',
|
|
45159
|
+
path: {
|
|
45160
|
+
'id': id
|
|
45161
|
+
},
|
|
45162
|
+
body: requestBody,
|
|
45163
|
+
mediaType: 'application/json',
|
|
45164
|
+
errors: {
|
|
45165
|
+
400: `Validation error.`,
|
|
45166
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`,
|
|
45167
|
+
404: `Activity not found.`
|
|
45168
|
+
}
|
|
45169
|
+
});
|
|
45170
|
+
}
|
|
45171
|
+
/**
|
|
45172
|
+
* Delete an activity
|
|
45173
|
+
* Deletes the Activity.
|
|
45174
|
+
*
|
|
45175
|
+
* **Required permission:** `Ibl.CRM/Activities/delete`.
|
|
45176
|
+
* @returns void
|
|
45177
|
+
* @throws ApiError
|
|
45178
|
+
*/
|
|
45179
|
+
static crmActivitiesDestroy({
|
|
45180
|
+
id
|
|
45181
|
+
}) {
|
|
45182
|
+
return request(OpenAPI, {
|
|
45183
|
+
method: 'DELETE',
|
|
45184
|
+
url: '/api/crm/activities/{id}/',
|
|
45185
|
+
path: {
|
|
45186
|
+
'id': id
|
|
45187
|
+
},
|
|
45188
|
+
errors: {
|
|
45189
|
+
403: `Missing required permission \`Ibl.CRM/Activities/delete\`.`,
|
|
45190
|
+
404: `Activity not found.`
|
|
45191
|
+
}
|
|
45192
|
+
});
|
|
45193
|
+
}
|
|
45194
|
+
/**
|
|
45195
|
+
* Mark an activity as done
|
|
45196
|
+
* Flips `is_done=True` and stamps `done_at` if it isn't already set. Idempotent — calling on an already-done Activity preserves the original `done_at`.
|
|
45197
|
+
*
|
|
45198
|
+
* **Required permission:** `Ibl.CRM/Activities/write`.
|
|
45199
|
+
* @returns Activity
|
|
45200
|
+
* @throws ApiError
|
|
45201
|
+
*/
|
|
45202
|
+
static crmActivitiesDoneCreate({
|
|
45203
|
+
id
|
|
45204
|
+
}) {
|
|
45205
|
+
return request(OpenAPI, {
|
|
45206
|
+
method: 'POST',
|
|
45207
|
+
url: '/api/crm/activities/{id}/done/',
|
|
45208
|
+
path: {
|
|
45209
|
+
'id': id
|
|
45210
|
+
},
|
|
45211
|
+
errors: {
|
|
45212
|
+
403: `Missing required permission \`Ibl.CRM/Activities/write\`.`,
|
|
45213
|
+
404: `Activity not found.`
|
|
45214
|
+
}
|
|
45215
|
+
});
|
|
45216
|
+
}
|
|
45217
|
+
/**
|
|
45218
|
+
* List deals
|
|
45219
|
+
* Returns a paginated list of Deals in your Platform. Supports filtering by `status`, `pipeline`, `stage`, `owner`, `source`, `person`, `organization`, expected-close-date and created-at ranges, and `metadata__has_key`.
|
|
45220
|
+
*
|
|
45221
|
+
* **Required permission:** `Ibl.CRM/Deals/list`.
|
|
45222
|
+
* @returns PaginatedDealList
|
|
45223
|
+
* @throws ApiError
|
|
45224
|
+
*/
|
|
45225
|
+
static crmDealsList({
|
|
45226
|
+
createdAtGte,
|
|
45227
|
+
createdAtLte,
|
|
45228
|
+
expectedCloseDateGte,
|
|
45229
|
+
expectedCloseDateLte,
|
|
45230
|
+
metadataHasKey,
|
|
45231
|
+
organization,
|
|
45232
|
+
owner,
|
|
45233
|
+
page,
|
|
45234
|
+
pageSize,
|
|
45235
|
+
person,
|
|
45236
|
+
pipeline,
|
|
45237
|
+
source,
|
|
45238
|
+
stage,
|
|
45239
|
+
status
|
|
45240
|
+
}) {
|
|
45241
|
+
return request(OpenAPI, {
|
|
45242
|
+
method: 'GET',
|
|
45243
|
+
url: '/api/crm/deals/',
|
|
45244
|
+
query: {
|
|
45245
|
+
'created_at__gte': createdAtGte,
|
|
45246
|
+
'created_at__lte': createdAtLte,
|
|
45247
|
+
'expected_close_date__gte': expectedCloseDateGte,
|
|
45248
|
+
'expected_close_date__lte': expectedCloseDateLte,
|
|
45249
|
+
'metadata__has_key': metadataHasKey,
|
|
45250
|
+
'organization': organization,
|
|
45251
|
+
'owner': owner,
|
|
45252
|
+
'page': page,
|
|
45253
|
+
'page_size': pageSize,
|
|
45254
|
+
'person': person,
|
|
45255
|
+
'pipeline': pipeline,
|
|
45256
|
+
'source': source,
|
|
45257
|
+
'stage': stage,
|
|
45258
|
+
'status': status
|
|
45259
|
+
},
|
|
45260
|
+
errors: {
|
|
45261
|
+
401: `Authentication required.`,
|
|
45262
|
+
403: `Missing required permission \`Ibl.CRM/Deals/list\`.`
|
|
45263
|
+
}
|
|
45264
|
+
});
|
|
45265
|
+
}
|
|
45266
|
+
/**
|
|
45267
|
+
* Create a deal
|
|
45268
|
+
* Creates a new Deal. All FK targets (`person`, `organization`, `pipeline`, `stage`, `source`) must belong to your Platform; `stage` must belong to `pipeline`. `status` and `closed_at` are service-managed — passing them returns `400`.
|
|
45269
|
+
*
|
|
45270
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
45271
|
+
* @returns Deal
|
|
45272
|
+
* @throws ApiError
|
|
45273
|
+
*/
|
|
45274
|
+
static crmDealsCreate({
|
|
45275
|
+
requestBody
|
|
45276
|
+
}) {
|
|
45277
|
+
return request(OpenAPI, {
|
|
45278
|
+
method: 'POST',
|
|
45279
|
+
url: '/api/crm/deals/',
|
|
45280
|
+
body: requestBody,
|
|
45281
|
+
mediaType: 'application/json',
|
|
45282
|
+
errors: {
|
|
45283
|
+
400: `Validation error.`,
|
|
45284
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`
|
|
45285
|
+
}
|
|
45286
|
+
});
|
|
45287
|
+
}
|
|
45288
|
+
/**
|
|
45289
|
+
* Retrieve a deal
|
|
45290
|
+
* Returns a single Deal by id.
|
|
45291
|
+
*
|
|
45292
|
+
* **Required permission:** `Ibl.CRM/Deals/read`.
|
|
45293
|
+
* @returns Deal
|
|
45294
|
+
* @throws ApiError
|
|
45295
|
+
*/
|
|
45296
|
+
static crmDealsRetrieve({
|
|
45297
|
+
id
|
|
45298
|
+
}) {
|
|
45299
|
+
return request(OpenAPI, {
|
|
45300
|
+
method: 'GET',
|
|
45301
|
+
url: '/api/crm/deals/{id}/',
|
|
45302
|
+
path: {
|
|
45303
|
+
'id': id
|
|
45304
|
+
},
|
|
45305
|
+
errors: {
|
|
45306
|
+
403: `Missing required permission \`Ibl.CRM/Deals/read\`.`,
|
|
45307
|
+
404: `Deal not found.`
|
|
45308
|
+
}
|
|
45309
|
+
});
|
|
45310
|
+
}
|
|
45311
|
+
/**
|
|
45312
|
+
* Replace a deal
|
|
45313
|
+
* Replaces all editable fields on the Deal.
|
|
45314
|
+
*
|
|
45315
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
45316
|
+
* @returns Deal
|
|
45317
|
+
* @throws ApiError
|
|
45318
|
+
*/
|
|
45319
|
+
static crmDealsUpdate({
|
|
45320
|
+
id,
|
|
45321
|
+
requestBody
|
|
45322
|
+
}) {
|
|
45323
|
+
return request(OpenAPI, {
|
|
45324
|
+
method: 'PUT',
|
|
45325
|
+
url: '/api/crm/deals/{id}/',
|
|
45326
|
+
path: {
|
|
45327
|
+
'id': id
|
|
45328
|
+
},
|
|
45329
|
+
body: requestBody,
|
|
45330
|
+
mediaType: 'application/json',
|
|
45331
|
+
errors: {
|
|
45332
|
+
400: `Validation error.`,
|
|
45333
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
45334
|
+
404: `Deal not found.`
|
|
45335
|
+
}
|
|
45336
|
+
});
|
|
45337
|
+
}
|
|
45338
|
+
/**
|
|
45339
|
+
* Update a deal
|
|
45340
|
+
* Updates only the supplied fields on the Deal. Direct writes to `status` or `closed_at` are rejected with `400` — use `POST /deals/{id}/move-stage/`, `won/`, or `lost/`.
|
|
45341
|
+
*
|
|
45342
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
45343
|
+
* @returns Deal
|
|
45344
|
+
* @throws ApiError
|
|
45345
|
+
*/
|
|
45346
|
+
static crmDealsPartialUpdate({
|
|
45347
|
+
id,
|
|
45348
|
+
requestBody
|
|
45349
|
+
}) {
|
|
45350
|
+
return request(OpenAPI, {
|
|
45351
|
+
method: 'PATCH',
|
|
45352
|
+
url: '/api/crm/deals/{id}/',
|
|
45353
|
+
path: {
|
|
45354
|
+
'id': id
|
|
45355
|
+
},
|
|
45356
|
+
body: requestBody,
|
|
45357
|
+
mediaType: 'application/json',
|
|
45358
|
+
errors: {
|
|
45359
|
+
400: `Validation error.`,
|
|
45360
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
45361
|
+
404: `Deal not found.`
|
|
45362
|
+
}
|
|
45363
|
+
});
|
|
45364
|
+
}
|
|
45365
|
+
/**
|
|
45366
|
+
* Delete a deal
|
|
45367
|
+
* Deletes the Deal.
|
|
45368
|
+
*
|
|
45369
|
+
* **Required permission:** `Ibl.CRM/Deals/delete`.
|
|
45370
|
+
* @returns void
|
|
45371
|
+
* @throws ApiError
|
|
45372
|
+
*/
|
|
45373
|
+
static crmDealsDestroy({
|
|
45374
|
+
id
|
|
45375
|
+
}) {
|
|
45376
|
+
return request(OpenAPI, {
|
|
45377
|
+
method: 'DELETE',
|
|
45378
|
+
url: '/api/crm/deals/{id}/',
|
|
45379
|
+
path: {
|
|
45380
|
+
'id': id
|
|
45381
|
+
},
|
|
45382
|
+
errors: {
|
|
45383
|
+
403: `Missing required permission \`Ibl.CRM/Deals/delete\`.`,
|
|
45384
|
+
404: `Deal not found.`
|
|
45385
|
+
}
|
|
45386
|
+
});
|
|
45387
|
+
}
|
|
45388
|
+
/**
|
|
45389
|
+
* Mark a deal as lost
|
|
45390
|
+
* Moves the Deal into a closed-lost stage and persists `lost_reason`. If `stage_code` is omitted, the first `is_lost=True` stage in the Deal's pipeline (by sort order) is used.
|
|
45391
|
+
*
|
|
45392
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
45393
|
+
* @returns Deal
|
|
45394
|
+
* @throws ApiError
|
|
45395
|
+
*/
|
|
45396
|
+
static crmDealsLostCreate({
|
|
45397
|
+
id,
|
|
45398
|
+
requestBody
|
|
45399
|
+
}) {
|
|
45400
|
+
return request(OpenAPI, {
|
|
45401
|
+
method: 'POST',
|
|
45402
|
+
url: '/api/crm/deals/{id}/lost/',
|
|
45403
|
+
path: {
|
|
45404
|
+
'id': id
|
|
45405
|
+
},
|
|
45406
|
+
body: requestBody,
|
|
45407
|
+
mediaType: 'application/json',
|
|
45408
|
+
errors: {
|
|
45409
|
+
400: `Missing \`lost_reason\`, no \`is_lost\` stage configured, or the supplied stage_code is not flagged is_lost=True.`,
|
|
45410
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
45411
|
+
404: `Deal not found.`
|
|
45412
|
+
}
|
|
45413
|
+
});
|
|
45414
|
+
}
|
|
45415
|
+
/**
|
|
45416
|
+
* Move a deal to a different stage
|
|
45417
|
+
* Moves the Deal to the stage identified by `stage_id` or `stage_code`. The target stage must belong to this Deal's pipeline. Records an audit Activity and emits `deal_stage_changed`. `Deal.status` is recomputed from the new stage's `is_won` / `is_lost` flags.
|
|
45418
|
+
*
|
|
45419
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
45420
|
+
* @returns Deal
|
|
45421
|
+
* @throws ApiError
|
|
45422
|
+
*/
|
|
45423
|
+
static crmDealsMoveStageCreate({
|
|
45424
|
+
id,
|
|
45425
|
+
requestBody
|
|
45426
|
+
}) {
|
|
45427
|
+
return request(OpenAPI, {
|
|
45428
|
+
method: 'POST',
|
|
45429
|
+
url: '/api/crm/deals/{id}/move-stage/',
|
|
45430
|
+
path: {
|
|
45431
|
+
'id': id
|
|
45432
|
+
},
|
|
45433
|
+
body: requestBody,
|
|
45434
|
+
mediaType: 'application/json',
|
|
45435
|
+
errors: {
|
|
45436
|
+
400: `Validation error (e.g. stage not in pipeline).`,
|
|
45437
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
45438
|
+
404: `Deal or stage not found.`
|
|
45439
|
+
}
|
|
45440
|
+
});
|
|
45441
|
+
}
|
|
45442
|
+
/**
|
|
45443
|
+
* Mark a deal as won
|
|
45444
|
+
* Moves the Deal into a closed-won stage and sets `status='won'`. If `stage_code` is omitted, the first `is_won=True` stage in the Deal's pipeline (by sort order) is used.
|
|
45445
|
+
*
|
|
45446
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
45447
|
+
* @returns Deal
|
|
45448
|
+
* @throws ApiError
|
|
45449
|
+
*/
|
|
45450
|
+
static crmDealsWonCreate({
|
|
45451
|
+
id,
|
|
45452
|
+
requestBody
|
|
45453
|
+
}) {
|
|
45454
|
+
return request(OpenAPI, {
|
|
45455
|
+
method: 'POST',
|
|
45456
|
+
url: '/api/crm/deals/{id}/won/',
|
|
45457
|
+
path: {
|
|
45458
|
+
'id': id
|
|
45459
|
+
},
|
|
45460
|
+
body: requestBody,
|
|
45461
|
+
mediaType: 'application/json',
|
|
45462
|
+
errors: {
|
|
45463
|
+
400: `No \`is_won\` stage configured, or the supplied stage_code is not flagged is_won=True.`,
|
|
45464
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
45465
|
+
404: `Deal not found.`
|
|
45466
|
+
}
|
|
45467
|
+
});
|
|
45468
|
+
}
|
|
45469
|
+
/**
|
|
45470
|
+
* List lead sources
|
|
45471
|
+
* Returns a paginated list of LeadSources in your Platform.
|
|
45472
|
+
*
|
|
45473
|
+
* **Required permission:** `Ibl.CRM/Pipelines/list`.
|
|
45474
|
+
* @returns PaginatedLeadSourceList
|
|
45475
|
+
* @throws ApiError
|
|
45476
|
+
*/
|
|
45477
|
+
static crmLeadSourcesList({
|
|
45478
|
+
code,
|
|
45479
|
+
name,
|
|
45480
|
+
page,
|
|
45481
|
+
pageSize
|
|
45482
|
+
}) {
|
|
45483
|
+
return request(OpenAPI, {
|
|
45484
|
+
method: 'GET',
|
|
45485
|
+
url: '/api/crm/lead-sources/',
|
|
45486
|
+
query: {
|
|
45487
|
+
'code': code,
|
|
45488
|
+
'name': name,
|
|
45489
|
+
'page': page,
|
|
45490
|
+
'page_size': pageSize
|
|
45491
|
+
},
|
|
45492
|
+
errors: {
|
|
45493
|
+
401: `Authentication required.`,
|
|
45494
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/list\`.`
|
|
45495
|
+
}
|
|
45496
|
+
});
|
|
45497
|
+
}
|
|
45498
|
+
/**
|
|
45499
|
+
* Create a lead source
|
|
45500
|
+
* Creates a new LeadSource in your Platform. `code` must be unique.
|
|
45501
|
+
*
|
|
45502
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
45503
|
+
* @returns LeadSource
|
|
45504
|
+
* @throws ApiError
|
|
45505
|
+
*/
|
|
45506
|
+
static crmLeadSourcesCreate({
|
|
45507
|
+
requestBody
|
|
45508
|
+
}) {
|
|
45509
|
+
return request(OpenAPI, {
|
|
45510
|
+
method: 'POST',
|
|
45511
|
+
url: '/api/crm/lead-sources/',
|
|
45512
|
+
body: requestBody,
|
|
45513
|
+
mediaType: 'application/json',
|
|
45514
|
+
errors: {
|
|
45515
|
+
400: `Validation error.`,
|
|
45516
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
|
|
45517
|
+
}
|
|
45518
|
+
});
|
|
45519
|
+
}
|
|
45520
|
+
/**
|
|
45521
|
+
* Retrieve a lead source
|
|
45522
|
+
* Returns a single LeadSource by id.
|
|
45523
|
+
*
|
|
45524
|
+
* **Required permission:** `Ibl.CRM/Pipelines/read`.
|
|
45525
|
+
* @returns LeadSource
|
|
45526
|
+
* @throws ApiError
|
|
45527
|
+
*/
|
|
45528
|
+
static crmLeadSourcesRetrieve({
|
|
45529
|
+
id
|
|
45530
|
+
}) {
|
|
45531
|
+
return request(OpenAPI, {
|
|
45532
|
+
method: 'GET',
|
|
45533
|
+
url: '/api/crm/lead-sources/{id}/',
|
|
45534
|
+
path: {
|
|
45535
|
+
'id': id
|
|
45536
|
+
},
|
|
45537
|
+
errors: {
|
|
45538
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/read\`.`,
|
|
45539
|
+
404: `LeadSource not found.`
|
|
45540
|
+
}
|
|
45541
|
+
});
|
|
45542
|
+
}
|
|
45543
|
+
/**
|
|
45544
|
+
* Replace a lead source
|
|
45545
|
+
* Replaces all editable fields on the LeadSource.
|
|
45546
|
+
*
|
|
45547
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
45548
|
+
* @returns LeadSource
|
|
45549
|
+
* @throws ApiError
|
|
45550
|
+
*/
|
|
45551
|
+
static crmLeadSourcesUpdate({
|
|
45552
|
+
id,
|
|
45553
|
+
requestBody
|
|
45554
|
+
}) {
|
|
45555
|
+
return request(OpenAPI, {
|
|
45556
|
+
method: 'PUT',
|
|
45557
|
+
url: '/api/crm/lead-sources/{id}/',
|
|
45558
|
+
path: {
|
|
45559
|
+
'id': id
|
|
45560
|
+
},
|
|
45561
|
+
body: requestBody,
|
|
45562
|
+
mediaType: 'application/json',
|
|
45563
|
+
errors: {
|
|
45564
|
+
400: `Validation error.`,
|
|
45565
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
45566
|
+
404: `LeadSource not found.`
|
|
45567
|
+
}
|
|
45568
|
+
});
|
|
45569
|
+
}
|
|
45570
|
+
/**
|
|
45571
|
+
* Update a lead source
|
|
45572
|
+
* Updates only the supplied fields on the LeadSource.
|
|
45573
|
+
*
|
|
45574
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
45575
|
+
* @returns LeadSource
|
|
45576
|
+
* @throws ApiError
|
|
45577
|
+
*/
|
|
45578
|
+
static crmLeadSourcesPartialUpdate({
|
|
45579
|
+
id,
|
|
45580
|
+
requestBody
|
|
45581
|
+
}) {
|
|
45582
|
+
return request(OpenAPI, {
|
|
45583
|
+
method: 'PATCH',
|
|
45584
|
+
url: '/api/crm/lead-sources/{id}/',
|
|
45585
|
+
path: {
|
|
45586
|
+
'id': id
|
|
45587
|
+
},
|
|
45588
|
+
body: requestBody,
|
|
45589
|
+
mediaType: 'application/json',
|
|
45590
|
+
errors: {
|
|
45591
|
+
400: `Validation error.`,
|
|
45592
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
45593
|
+
404: `LeadSource not found.`
|
|
45594
|
+
}
|
|
45595
|
+
});
|
|
45596
|
+
}
|
|
45597
|
+
/**
|
|
45598
|
+
* Delete a lead source
|
|
45599
|
+
* Deletes the LeadSource. Any Deals referencing it have their `source` cleared.
|
|
45600
|
+
*
|
|
45601
|
+
* **Required permission:** `Ibl.CRM/Pipelines/delete`.
|
|
45602
|
+
* @returns void
|
|
45603
|
+
* @throws ApiError
|
|
45604
|
+
*/
|
|
45605
|
+
static crmLeadSourcesDestroy({
|
|
45606
|
+
id
|
|
45607
|
+
}) {
|
|
45608
|
+
return request(OpenAPI, {
|
|
45609
|
+
method: 'DELETE',
|
|
45610
|
+
url: '/api/crm/lead-sources/{id}/',
|
|
45611
|
+
path: {
|
|
45612
|
+
'id': id
|
|
45613
|
+
},
|
|
45614
|
+
errors: {
|
|
45615
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/delete\`.`,
|
|
45616
|
+
404: `LeadSource not found.`
|
|
45617
|
+
}
|
|
45618
|
+
});
|
|
45619
|
+
}
|
|
44776
45620
|
/**
|
|
44777
45621
|
* List organizations
|
|
44778
45622
|
* Returns a paginated list of organizations in your Platform. Supports filtering by `owner` and by `name` (case-insensitive substring match).
|
|
@@ -45167,6 +46011,331 @@ class CrmService {
|
|
|
45167
46011
|
}
|
|
45168
46012
|
});
|
|
45169
46013
|
}
|
|
46014
|
+
/**
|
|
46015
|
+
* List pipelines
|
|
46016
|
+
* Returns a paginated list of Pipelines in your Platform. Each Pipeline includes its ordered `stages` inline.
|
|
46017
|
+
*
|
|
46018
|
+
* **Required permission:** `Ibl.CRM/Pipelines/list`.
|
|
46019
|
+
* @returns PaginatedPipelineList
|
|
46020
|
+
* @throws ApiError
|
|
46021
|
+
*/
|
|
46022
|
+
static crmPipelinesList({
|
|
46023
|
+
code,
|
|
46024
|
+
isDefault,
|
|
46025
|
+
name,
|
|
46026
|
+
page,
|
|
46027
|
+
pageSize
|
|
46028
|
+
}) {
|
|
46029
|
+
return request(OpenAPI, {
|
|
46030
|
+
method: 'GET',
|
|
46031
|
+
url: '/api/crm/pipelines/',
|
|
46032
|
+
query: {
|
|
46033
|
+
'code': code,
|
|
46034
|
+
'is_default': isDefault,
|
|
46035
|
+
'name': name,
|
|
46036
|
+
'page': page,
|
|
46037
|
+
'page_size': pageSize
|
|
46038
|
+
},
|
|
46039
|
+
errors: {
|
|
46040
|
+
401: `Authentication required.`,
|
|
46041
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/list\`.`
|
|
46042
|
+
}
|
|
46043
|
+
});
|
|
46044
|
+
}
|
|
46045
|
+
/**
|
|
46046
|
+
* Create a pipeline
|
|
46047
|
+
* Creates a new Pipeline. `code` must be unique within your Platform. Promoting another Pipeline to `is_default=true` while one already exists will fail — unset the existing default first.
|
|
46048
|
+
*
|
|
46049
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46050
|
+
* @returns Pipeline
|
|
46051
|
+
* @throws ApiError
|
|
46052
|
+
*/
|
|
46053
|
+
static crmPipelinesCreate({
|
|
46054
|
+
requestBody
|
|
46055
|
+
}) {
|
|
46056
|
+
return request(OpenAPI, {
|
|
46057
|
+
method: 'POST',
|
|
46058
|
+
url: '/api/crm/pipelines/',
|
|
46059
|
+
body: requestBody,
|
|
46060
|
+
mediaType: 'application/json',
|
|
46061
|
+
errors: {
|
|
46062
|
+
400: `Validation error.`,
|
|
46063
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
|
|
46064
|
+
}
|
|
46065
|
+
});
|
|
46066
|
+
}
|
|
46067
|
+
/**
|
|
46068
|
+
* List stages for a pipeline
|
|
46069
|
+
* Returns the ordered list of PipelineStages for the given Pipeline.
|
|
46070
|
+
*
|
|
46071
|
+
* **Required permission:** `Ibl.CRM/Pipelines/list`.
|
|
46072
|
+
* @returns PaginatedPipelineStageList
|
|
46073
|
+
* @throws ApiError
|
|
46074
|
+
*/
|
|
46075
|
+
static crmPipelinesStagesList({
|
|
46076
|
+
pipelinePk,
|
|
46077
|
+
code,
|
|
46078
|
+
isLost,
|
|
46079
|
+
isWon,
|
|
46080
|
+
page,
|
|
46081
|
+
pageSize
|
|
46082
|
+
}) {
|
|
46083
|
+
return request(OpenAPI, {
|
|
46084
|
+
method: 'GET',
|
|
46085
|
+
url: '/api/crm/pipelines/{pipeline_pk}/stages/',
|
|
46086
|
+
path: {
|
|
46087
|
+
'pipeline_pk': pipelinePk
|
|
46088
|
+
},
|
|
46089
|
+
query: {
|
|
46090
|
+
'code': code,
|
|
46091
|
+
'is_lost': isLost,
|
|
46092
|
+
'is_won': isWon,
|
|
46093
|
+
'page': page,
|
|
46094
|
+
'page_size': pageSize
|
|
46095
|
+
},
|
|
46096
|
+
errors: {
|
|
46097
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/list\`.`,
|
|
46098
|
+
404: `Pipeline not found.`
|
|
46099
|
+
}
|
|
46100
|
+
});
|
|
46101
|
+
}
|
|
46102
|
+
/**
|
|
46103
|
+
* Create a stage
|
|
46104
|
+
* Creates a new PipelineStage in the URL Pipeline. `code` must be unique within that Pipeline. At most one of `is_won` / `is_lost` may be true.
|
|
46105
|
+
*
|
|
46106
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46107
|
+
* @returns PipelineStage
|
|
46108
|
+
* @throws ApiError
|
|
46109
|
+
*/
|
|
46110
|
+
static crmPipelinesStagesCreate({
|
|
46111
|
+
pipelinePk,
|
|
46112
|
+
requestBody
|
|
46113
|
+
}) {
|
|
46114
|
+
return request(OpenAPI, {
|
|
46115
|
+
method: 'POST',
|
|
46116
|
+
url: '/api/crm/pipelines/{pipeline_pk}/stages/',
|
|
46117
|
+
path: {
|
|
46118
|
+
'pipeline_pk': pipelinePk
|
|
46119
|
+
},
|
|
46120
|
+
body: requestBody,
|
|
46121
|
+
mediaType: 'application/json',
|
|
46122
|
+
errors: {
|
|
46123
|
+
400: `Validation error.`,
|
|
46124
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
46125
|
+
404: `Pipeline not found.`
|
|
46126
|
+
}
|
|
46127
|
+
});
|
|
46128
|
+
}
|
|
46129
|
+
/**
|
|
46130
|
+
* Retrieve a stage
|
|
46131
|
+
* Returns a single PipelineStage by id (must belong to the URL Pipeline).
|
|
46132
|
+
*
|
|
46133
|
+
* **Required permission:** `Ibl.CRM/Pipelines/read`.
|
|
46134
|
+
* @returns PipelineStage
|
|
46135
|
+
* @throws ApiError
|
|
46136
|
+
*/
|
|
46137
|
+
static crmPipelinesStagesRetrieve({
|
|
46138
|
+
id,
|
|
46139
|
+
pipelinePk
|
|
46140
|
+
}) {
|
|
46141
|
+
return request(OpenAPI, {
|
|
46142
|
+
method: 'GET',
|
|
46143
|
+
url: '/api/crm/pipelines/{pipeline_pk}/stages/{id}/',
|
|
46144
|
+
path: {
|
|
46145
|
+
'id': id,
|
|
46146
|
+
'pipeline_pk': pipelinePk
|
|
46147
|
+
},
|
|
46148
|
+
errors: {
|
|
46149
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/read\`.`,
|
|
46150
|
+
404: `Stage not found in this Pipeline.`
|
|
46151
|
+
}
|
|
46152
|
+
});
|
|
46153
|
+
}
|
|
46154
|
+
/**
|
|
46155
|
+
* Replace a stage
|
|
46156
|
+
* Replaces all editable fields on the PipelineStage.
|
|
46157
|
+
*
|
|
46158
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46159
|
+
* @returns PipelineStage
|
|
46160
|
+
* @throws ApiError
|
|
46161
|
+
*/
|
|
46162
|
+
static crmPipelinesStagesUpdate({
|
|
46163
|
+
id,
|
|
46164
|
+
pipelinePk,
|
|
46165
|
+
requestBody
|
|
46166
|
+
}) {
|
|
46167
|
+
return request(OpenAPI, {
|
|
46168
|
+
method: 'PUT',
|
|
46169
|
+
url: '/api/crm/pipelines/{pipeline_pk}/stages/{id}/',
|
|
46170
|
+
path: {
|
|
46171
|
+
'id': id,
|
|
46172
|
+
'pipeline_pk': pipelinePk
|
|
46173
|
+
},
|
|
46174
|
+
body: requestBody,
|
|
46175
|
+
mediaType: 'application/json',
|
|
46176
|
+
errors: {
|
|
46177
|
+
400: `Validation error.`,
|
|
46178
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
46179
|
+
404: `Stage not found in this Pipeline.`
|
|
46180
|
+
}
|
|
46181
|
+
});
|
|
46182
|
+
}
|
|
46183
|
+
/**
|
|
46184
|
+
* Update a stage
|
|
46185
|
+
* Updates only the supplied fields on the PipelineStage.
|
|
46186
|
+
*
|
|
46187
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46188
|
+
* @returns PipelineStage
|
|
46189
|
+
* @throws ApiError
|
|
46190
|
+
*/
|
|
46191
|
+
static crmPipelinesStagesPartialUpdate({
|
|
46192
|
+
id,
|
|
46193
|
+
pipelinePk,
|
|
46194
|
+
requestBody
|
|
46195
|
+
}) {
|
|
46196
|
+
return request(OpenAPI, {
|
|
46197
|
+
method: 'PATCH',
|
|
46198
|
+
url: '/api/crm/pipelines/{pipeline_pk}/stages/{id}/',
|
|
46199
|
+
path: {
|
|
46200
|
+
'id': id,
|
|
46201
|
+
'pipeline_pk': pipelinePk
|
|
46202
|
+
},
|
|
46203
|
+
body: requestBody,
|
|
46204
|
+
mediaType: 'application/json',
|
|
46205
|
+
errors: {
|
|
46206
|
+
400: `Validation error.`,
|
|
46207
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
46208
|
+
404: `Stage not found in this Pipeline.`
|
|
46209
|
+
}
|
|
46210
|
+
});
|
|
46211
|
+
}
|
|
46212
|
+
/**
|
|
46213
|
+
* Delete a stage
|
|
46214
|
+
* Deletes the PipelineStage. Fails with `409 Conflict` if any Deal still references it (FK is PROTECTed).
|
|
46215
|
+
*
|
|
46216
|
+
* **Required permission:** `Ibl.CRM/Pipelines/delete`.
|
|
46217
|
+
* @returns void
|
|
46218
|
+
* @throws ApiError
|
|
46219
|
+
*/
|
|
46220
|
+
static crmPipelinesStagesDestroy({
|
|
46221
|
+
id,
|
|
46222
|
+
pipelinePk
|
|
46223
|
+
}) {
|
|
46224
|
+
return request(OpenAPI, {
|
|
46225
|
+
method: 'DELETE',
|
|
46226
|
+
url: '/api/crm/pipelines/{pipeline_pk}/stages/{id}/',
|
|
46227
|
+
path: {
|
|
46228
|
+
'id': id,
|
|
46229
|
+
'pipeline_pk': pipelinePk
|
|
46230
|
+
},
|
|
46231
|
+
errors: {
|
|
46232
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/delete\`.`,
|
|
46233
|
+
404: `Stage not found in this Pipeline.`,
|
|
46234
|
+
409: `Stage still has Deals attached.`
|
|
46235
|
+
}
|
|
46236
|
+
});
|
|
46237
|
+
}
|
|
46238
|
+
/**
|
|
46239
|
+
* Retrieve a pipeline
|
|
46240
|
+
* Returns a single Pipeline by id, including its ordered `stages`.
|
|
46241
|
+
*
|
|
46242
|
+
* **Required permission:** `Ibl.CRM/Pipelines/read`.
|
|
46243
|
+
* @returns Pipeline
|
|
46244
|
+
* @throws ApiError
|
|
46245
|
+
*/
|
|
46246
|
+
static crmPipelinesRetrieve({
|
|
46247
|
+
id
|
|
46248
|
+
}) {
|
|
46249
|
+
return request(OpenAPI, {
|
|
46250
|
+
method: 'GET',
|
|
46251
|
+
url: '/api/crm/pipelines/{id}/',
|
|
46252
|
+
path: {
|
|
46253
|
+
'id': id
|
|
46254
|
+
},
|
|
46255
|
+
errors: {
|
|
46256
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/read\`.`,
|
|
46257
|
+
404: `Pipeline not found.`
|
|
46258
|
+
}
|
|
46259
|
+
});
|
|
46260
|
+
}
|
|
46261
|
+
/**
|
|
46262
|
+
* Replace a pipeline
|
|
46263
|
+
* Replaces all editable fields on the Pipeline.
|
|
46264
|
+
*
|
|
46265
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46266
|
+
* @returns Pipeline
|
|
46267
|
+
* @throws ApiError
|
|
46268
|
+
*/
|
|
46269
|
+
static crmPipelinesUpdate({
|
|
46270
|
+
id,
|
|
46271
|
+
requestBody
|
|
46272
|
+
}) {
|
|
46273
|
+
return request(OpenAPI, {
|
|
46274
|
+
method: 'PUT',
|
|
46275
|
+
url: '/api/crm/pipelines/{id}/',
|
|
46276
|
+
path: {
|
|
46277
|
+
'id': id
|
|
46278
|
+
},
|
|
46279
|
+
body: requestBody,
|
|
46280
|
+
mediaType: 'application/json',
|
|
46281
|
+
errors: {
|
|
46282
|
+
400: `Validation error.`,
|
|
46283
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
46284
|
+
404: `Pipeline not found.`
|
|
46285
|
+
}
|
|
46286
|
+
});
|
|
46287
|
+
}
|
|
46288
|
+
/**
|
|
46289
|
+
* Update a pipeline
|
|
46290
|
+
* Updates only the supplied fields on the Pipeline.
|
|
46291
|
+
*
|
|
46292
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46293
|
+
* @returns Pipeline
|
|
46294
|
+
* @throws ApiError
|
|
46295
|
+
*/
|
|
46296
|
+
static crmPipelinesPartialUpdate({
|
|
46297
|
+
id,
|
|
46298
|
+
requestBody
|
|
46299
|
+
}) {
|
|
46300
|
+
return request(OpenAPI, {
|
|
46301
|
+
method: 'PATCH',
|
|
46302
|
+
url: '/api/crm/pipelines/{id}/',
|
|
46303
|
+
path: {
|
|
46304
|
+
'id': id
|
|
46305
|
+
},
|
|
46306
|
+
body: requestBody,
|
|
46307
|
+
mediaType: 'application/json',
|
|
46308
|
+
errors: {
|
|
46309
|
+
400: `Validation error.`,
|
|
46310
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
46311
|
+
404: `Pipeline not found.`
|
|
46312
|
+
}
|
|
46313
|
+
});
|
|
46314
|
+
}
|
|
46315
|
+
/**
|
|
46316
|
+
* Delete a pipeline
|
|
46317
|
+
* Deletes the Pipeline. Fails with `409 Conflict` if any Deal still references it (FK is PROTECTed).
|
|
46318
|
+
*
|
|
46319
|
+
* **Required permission:** `Ibl.CRM/Pipelines/delete`.
|
|
46320
|
+
* @returns void
|
|
46321
|
+
* @throws ApiError
|
|
46322
|
+
*/
|
|
46323
|
+
static crmPipelinesDestroy({
|
|
46324
|
+
id
|
|
46325
|
+
}) {
|
|
46326
|
+
return request(OpenAPI, {
|
|
46327
|
+
method: 'DELETE',
|
|
46328
|
+
url: '/api/crm/pipelines/{id}/',
|
|
46329
|
+
path: {
|
|
46330
|
+
'id': id
|
|
46331
|
+
},
|
|
46332
|
+
errors: {
|
|
46333
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/delete\`.`,
|
|
46334
|
+
404: `Pipeline not found.`,
|
|
46335
|
+
409: `Pipeline still has Deals attached.`
|
|
46336
|
+
}
|
|
46337
|
+
});
|
|
46338
|
+
}
|
|
45170
46339
|
}
|
|
45171
46340
|
|
|
45172
46341
|
class CustomDomainsService {
|
|
@@ -45258,6 +46427,261 @@ class CustomDomainsService {
|
|
|
45258
46427
|
}
|
|
45259
46428
|
}
|
|
45260
46429
|
|
|
46430
|
+
class DealsService {
|
|
46431
|
+
/**
|
|
46432
|
+
* List deals
|
|
46433
|
+
* Returns a paginated list of Deals in your Platform. Supports filtering by `status`, `pipeline`, `stage`, `owner`, `source`, `person`, `organization`, expected-close-date and created-at ranges, and `metadata__has_key`.
|
|
46434
|
+
*
|
|
46435
|
+
* **Required permission:** `Ibl.CRM/Deals/list`.
|
|
46436
|
+
* @returns PaginatedDealList
|
|
46437
|
+
* @throws ApiError
|
|
46438
|
+
*/
|
|
46439
|
+
static dealsList({
|
|
46440
|
+
createdAtGte,
|
|
46441
|
+
createdAtLte,
|
|
46442
|
+
expectedCloseDateGte,
|
|
46443
|
+
expectedCloseDateLte,
|
|
46444
|
+
metadataHasKey,
|
|
46445
|
+
organization,
|
|
46446
|
+
owner,
|
|
46447
|
+
page,
|
|
46448
|
+
pageSize,
|
|
46449
|
+
person,
|
|
46450
|
+
pipeline,
|
|
46451
|
+
source,
|
|
46452
|
+
stage,
|
|
46453
|
+
status
|
|
46454
|
+
}) {
|
|
46455
|
+
return request(OpenAPI, {
|
|
46456
|
+
method: 'GET',
|
|
46457
|
+
url: '/deals/',
|
|
46458
|
+
query: {
|
|
46459
|
+
'created_at__gte': createdAtGte,
|
|
46460
|
+
'created_at__lte': createdAtLte,
|
|
46461
|
+
'expected_close_date__gte': expectedCloseDateGte,
|
|
46462
|
+
'expected_close_date__lte': expectedCloseDateLte,
|
|
46463
|
+
'metadata__has_key': metadataHasKey,
|
|
46464
|
+
'organization': organization,
|
|
46465
|
+
'owner': owner,
|
|
46466
|
+
'page': page,
|
|
46467
|
+
'page_size': pageSize,
|
|
46468
|
+
'person': person,
|
|
46469
|
+
'pipeline': pipeline,
|
|
46470
|
+
'source': source,
|
|
46471
|
+
'stage': stage,
|
|
46472
|
+
'status': status
|
|
46473
|
+
},
|
|
46474
|
+
errors: {
|
|
46475
|
+
401: `Authentication required.`,
|
|
46476
|
+
403: `Missing required permission \`Ibl.CRM/Deals/list\`.`
|
|
46477
|
+
}
|
|
46478
|
+
});
|
|
46479
|
+
}
|
|
46480
|
+
/**
|
|
46481
|
+
* Create a deal
|
|
46482
|
+
* Creates a new Deal. All FK targets (`person`, `organization`, `pipeline`, `stage`, `source`) must belong to your Platform; `stage` must belong to `pipeline`. `status` and `closed_at` are service-managed — passing them returns `400`.
|
|
46483
|
+
*
|
|
46484
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
46485
|
+
* @returns Deal
|
|
46486
|
+
* @throws ApiError
|
|
46487
|
+
*/
|
|
46488
|
+
static dealsCreate({
|
|
46489
|
+
requestBody
|
|
46490
|
+
}) {
|
|
46491
|
+
return request(OpenAPI, {
|
|
46492
|
+
method: 'POST',
|
|
46493
|
+
url: '/deals/',
|
|
46494
|
+
body: requestBody,
|
|
46495
|
+
mediaType: 'application/json',
|
|
46496
|
+
errors: {
|
|
46497
|
+
400: `Validation error.`,
|
|
46498
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`
|
|
46499
|
+
}
|
|
46500
|
+
});
|
|
46501
|
+
}
|
|
46502
|
+
/**
|
|
46503
|
+
* Retrieve a deal
|
|
46504
|
+
* Returns a single Deal by id.
|
|
46505
|
+
*
|
|
46506
|
+
* **Required permission:** `Ibl.CRM/Deals/read`.
|
|
46507
|
+
* @returns Deal
|
|
46508
|
+
* @throws ApiError
|
|
46509
|
+
*/
|
|
46510
|
+
static dealsRetrieve({
|
|
46511
|
+
id
|
|
46512
|
+
}) {
|
|
46513
|
+
return request(OpenAPI, {
|
|
46514
|
+
method: 'GET',
|
|
46515
|
+
url: '/deals/{id}/',
|
|
46516
|
+
path: {
|
|
46517
|
+
'id': id
|
|
46518
|
+
},
|
|
46519
|
+
errors: {
|
|
46520
|
+
403: `Missing required permission \`Ibl.CRM/Deals/read\`.`,
|
|
46521
|
+
404: `Deal not found.`
|
|
46522
|
+
}
|
|
46523
|
+
});
|
|
46524
|
+
}
|
|
46525
|
+
/**
|
|
46526
|
+
* Replace a deal
|
|
46527
|
+
* Replaces all editable fields on the Deal.
|
|
46528
|
+
*
|
|
46529
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
46530
|
+
* @returns Deal
|
|
46531
|
+
* @throws ApiError
|
|
46532
|
+
*/
|
|
46533
|
+
static dealsUpdate({
|
|
46534
|
+
id,
|
|
46535
|
+
requestBody
|
|
46536
|
+
}) {
|
|
46537
|
+
return request(OpenAPI, {
|
|
46538
|
+
method: 'PUT',
|
|
46539
|
+
url: '/deals/{id}/',
|
|
46540
|
+
path: {
|
|
46541
|
+
'id': id
|
|
46542
|
+
},
|
|
46543
|
+
body: requestBody,
|
|
46544
|
+
mediaType: 'application/json',
|
|
46545
|
+
errors: {
|
|
46546
|
+
400: `Validation error.`,
|
|
46547
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
46548
|
+
404: `Deal not found.`
|
|
46549
|
+
}
|
|
46550
|
+
});
|
|
46551
|
+
}
|
|
46552
|
+
/**
|
|
46553
|
+
* Update a deal
|
|
46554
|
+
* Updates only the supplied fields on the Deal. Direct writes to `status` or `closed_at` are rejected with `400` — use `POST /deals/{id}/move-stage/`, `won/`, or `lost/`.
|
|
46555
|
+
*
|
|
46556
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
46557
|
+
* @returns Deal
|
|
46558
|
+
* @throws ApiError
|
|
46559
|
+
*/
|
|
46560
|
+
static dealsPartialUpdate({
|
|
46561
|
+
id,
|
|
46562
|
+
requestBody
|
|
46563
|
+
}) {
|
|
46564
|
+
return request(OpenAPI, {
|
|
46565
|
+
method: 'PATCH',
|
|
46566
|
+
url: '/deals/{id}/',
|
|
46567
|
+
path: {
|
|
46568
|
+
'id': id
|
|
46569
|
+
},
|
|
46570
|
+
body: requestBody,
|
|
46571
|
+
mediaType: 'application/json',
|
|
46572
|
+
errors: {
|
|
46573
|
+
400: `Validation error.`,
|
|
46574
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
46575
|
+
404: `Deal not found.`
|
|
46576
|
+
}
|
|
46577
|
+
});
|
|
46578
|
+
}
|
|
46579
|
+
/**
|
|
46580
|
+
* Delete a deal
|
|
46581
|
+
* Deletes the Deal.
|
|
46582
|
+
*
|
|
46583
|
+
* **Required permission:** `Ibl.CRM/Deals/delete`.
|
|
46584
|
+
* @returns void
|
|
46585
|
+
* @throws ApiError
|
|
46586
|
+
*/
|
|
46587
|
+
static dealsDestroy({
|
|
46588
|
+
id
|
|
46589
|
+
}) {
|
|
46590
|
+
return request(OpenAPI, {
|
|
46591
|
+
method: 'DELETE',
|
|
46592
|
+
url: '/deals/{id}/',
|
|
46593
|
+
path: {
|
|
46594
|
+
'id': id
|
|
46595
|
+
},
|
|
46596
|
+
errors: {
|
|
46597
|
+
403: `Missing required permission \`Ibl.CRM/Deals/delete\`.`,
|
|
46598
|
+
404: `Deal not found.`
|
|
46599
|
+
}
|
|
46600
|
+
});
|
|
46601
|
+
}
|
|
46602
|
+
/**
|
|
46603
|
+
* Mark a deal as lost
|
|
46604
|
+
* Moves the Deal into a closed-lost stage and persists `lost_reason`. If `stage_code` is omitted, the first `is_lost=True` stage in the Deal's pipeline (by sort order) is used.
|
|
46605
|
+
*
|
|
46606
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
46607
|
+
* @returns Deal
|
|
46608
|
+
* @throws ApiError
|
|
46609
|
+
*/
|
|
46610
|
+
static dealsLostCreate({
|
|
46611
|
+
id,
|
|
46612
|
+
requestBody
|
|
46613
|
+
}) {
|
|
46614
|
+
return request(OpenAPI, {
|
|
46615
|
+
method: 'POST',
|
|
46616
|
+
url: '/deals/{id}/lost/',
|
|
46617
|
+
path: {
|
|
46618
|
+
'id': id
|
|
46619
|
+
},
|
|
46620
|
+
body: requestBody,
|
|
46621
|
+
mediaType: 'application/json',
|
|
46622
|
+
errors: {
|
|
46623
|
+
400: `Missing \`lost_reason\`, no \`is_lost\` stage configured, or the supplied stage_code is not flagged is_lost=True.`,
|
|
46624
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
46625
|
+
404: `Deal not found.`
|
|
46626
|
+
}
|
|
46627
|
+
});
|
|
46628
|
+
}
|
|
46629
|
+
/**
|
|
46630
|
+
* Move a deal to a different stage
|
|
46631
|
+
* Moves the Deal to the stage identified by `stage_id` or `stage_code`. The target stage must belong to this Deal's pipeline. Records an audit Activity and emits `deal_stage_changed`. `Deal.status` is recomputed from the new stage's `is_won` / `is_lost` flags.
|
|
46632
|
+
*
|
|
46633
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
46634
|
+
* @returns Deal
|
|
46635
|
+
* @throws ApiError
|
|
46636
|
+
*/
|
|
46637
|
+
static dealsMoveStageCreate({
|
|
46638
|
+
id,
|
|
46639
|
+
requestBody
|
|
46640
|
+
}) {
|
|
46641
|
+
return request(OpenAPI, {
|
|
46642
|
+
method: 'POST',
|
|
46643
|
+
url: '/deals/{id}/move-stage/',
|
|
46644
|
+
path: {
|
|
46645
|
+
'id': id
|
|
46646
|
+
},
|
|
46647
|
+
body: requestBody,
|
|
46648
|
+
mediaType: 'application/json',
|
|
46649
|
+
errors: {
|
|
46650
|
+
400: `Validation error (e.g. stage not in pipeline).`,
|
|
46651
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
46652
|
+
404: `Deal or stage not found.`
|
|
46653
|
+
}
|
|
46654
|
+
});
|
|
46655
|
+
}
|
|
46656
|
+
/**
|
|
46657
|
+
* Mark a deal as won
|
|
46658
|
+
* Moves the Deal into a closed-won stage and sets `status='won'`. If `stage_code` is omitted, the first `is_won=True` stage in the Deal's pipeline (by sort order) is used.
|
|
46659
|
+
*
|
|
46660
|
+
* **Required permission:** `Ibl.CRM/Deals/write`.
|
|
46661
|
+
* @returns Deal
|
|
46662
|
+
* @throws ApiError
|
|
46663
|
+
*/
|
|
46664
|
+
static dealsWonCreate({
|
|
46665
|
+
id,
|
|
46666
|
+
requestBody
|
|
46667
|
+
}) {
|
|
46668
|
+
return request(OpenAPI, {
|
|
46669
|
+
method: 'POST',
|
|
46670
|
+
url: '/deals/{id}/won/',
|
|
46671
|
+
path: {
|
|
46672
|
+
'id': id
|
|
46673
|
+
},
|
|
46674
|
+
body: requestBody,
|
|
46675
|
+
mediaType: 'application/json',
|
|
46676
|
+
errors: {
|
|
46677
|
+
400: `No \`is_won\` stage configured, or the supplied stage_code is not flagged is_won=True.`,
|
|
46678
|
+
403: `Missing required permission \`Ibl.CRM/Deals/write\`.`,
|
|
46679
|
+
404: `Deal not found.`
|
|
46680
|
+
}
|
|
46681
|
+
});
|
|
46682
|
+
}
|
|
46683
|
+
}
|
|
46684
|
+
|
|
45261
46685
|
class FeaturesService {
|
|
45262
46686
|
/**
|
|
45263
46687
|
* Returns a list of the apps that the user has access to.
|
|
@@ -45424,6 +46848,160 @@ class ItemsService {
|
|
|
45424
46848
|
}
|
|
45425
46849
|
}
|
|
45426
46850
|
|
|
46851
|
+
class LeadSourcesService {
|
|
46852
|
+
/**
|
|
46853
|
+
* List lead sources
|
|
46854
|
+
* Returns a paginated list of LeadSources in your Platform.
|
|
46855
|
+
*
|
|
46856
|
+
* **Required permission:** `Ibl.CRM/Pipelines/list`.
|
|
46857
|
+
* @returns PaginatedLeadSourceList
|
|
46858
|
+
* @throws ApiError
|
|
46859
|
+
*/
|
|
46860
|
+
static leadSourcesList({
|
|
46861
|
+
code,
|
|
46862
|
+
name,
|
|
46863
|
+
page,
|
|
46864
|
+
pageSize
|
|
46865
|
+
}) {
|
|
46866
|
+
return request(OpenAPI, {
|
|
46867
|
+
method: 'GET',
|
|
46868
|
+
url: '/lead-sources/',
|
|
46869
|
+
query: {
|
|
46870
|
+
'code': code,
|
|
46871
|
+
'name': name,
|
|
46872
|
+
'page': page,
|
|
46873
|
+
'page_size': pageSize
|
|
46874
|
+
},
|
|
46875
|
+
errors: {
|
|
46876
|
+
401: `Authentication required.`,
|
|
46877
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/list\`.`
|
|
46878
|
+
}
|
|
46879
|
+
});
|
|
46880
|
+
}
|
|
46881
|
+
/**
|
|
46882
|
+
* Create a lead source
|
|
46883
|
+
* Creates a new LeadSource in your Platform. `code` must be unique.
|
|
46884
|
+
*
|
|
46885
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46886
|
+
* @returns LeadSource
|
|
46887
|
+
* @throws ApiError
|
|
46888
|
+
*/
|
|
46889
|
+
static leadSourcesCreate({
|
|
46890
|
+
requestBody
|
|
46891
|
+
}) {
|
|
46892
|
+
return request(OpenAPI, {
|
|
46893
|
+
method: 'POST',
|
|
46894
|
+
url: '/lead-sources/',
|
|
46895
|
+
body: requestBody,
|
|
46896
|
+
mediaType: 'application/json',
|
|
46897
|
+
errors: {
|
|
46898
|
+
400: `Validation error.`,
|
|
46899
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
|
|
46900
|
+
}
|
|
46901
|
+
});
|
|
46902
|
+
}
|
|
46903
|
+
/**
|
|
46904
|
+
* Retrieve a lead source
|
|
46905
|
+
* Returns a single LeadSource by id.
|
|
46906
|
+
*
|
|
46907
|
+
* **Required permission:** `Ibl.CRM/Pipelines/read`.
|
|
46908
|
+
* @returns LeadSource
|
|
46909
|
+
* @throws ApiError
|
|
46910
|
+
*/
|
|
46911
|
+
static leadSourcesRetrieve({
|
|
46912
|
+
id
|
|
46913
|
+
}) {
|
|
46914
|
+
return request(OpenAPI, {
|
|
46915
|
+
method: 'GET',
|
|
46916
|
+
url: '/lead-sources/{id}/',
|
|
46917
|
+
path: {
|
|
46918
|
+
'id': id
|
|
46919
|
+
},
|
|
46920
|
+
errors: {
|
|
46921
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/read\`.`,
|
|
46922
|
+
404: `LeadSource not found.`
|
|
46923
|
+
}
|
|
46924
|
+
});
|
|
46925
|
+
}
|
|
46926
|
+
/**
|
|
46927
|
+
* Replace a lead source
|
|
46928
|
+
* Replaces all editable fields on the LeadSource.
|
|
46929
|
+
*
|
|
46930
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46931
|
+
* @returns LeadSource
|
|
46932
|
+
* @throws ApiError
|
|
46933
|
+
*/
|
|
46934
|
+
static leadSourcesUpdate({
|
|
46935
|
+
id,
|
|
46936
|
+
requestBody
|
|
46937
|
+
}) {
|
|
46938
|
+
return request(OpenAPI, {
|
|
46939
|
+
method: 'PUT',
|
|
46940
|
+
url: '/lead-sources/{id}/',
|
|
46941
|
+
path: {
|
|
46942
|
+
'id': id
|
|
46943
|
+
},
|
|
46944
|
+
body: requestBody,
|
|
46945
|
+
mediaType: 'application/json',
|
|
46946
|
+
errors: {
|
|
46947
|
+
400: `Validation error.`,
|
|
46948
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
46949
|
+
404: `LeadSource not found.`
|
|
46950
|
+
}
|
|
46951
|
+
});
|
|
46952
|
+
}
|
|
46953
|
+
/**
|
|
46954
|
+
* Update a lead source
|
|
46955
|
+
* Updates only the supplied fields on the LeadSource.
|
|
46956
|
+
*
|
|
46957
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
46958
|
+
* @returns LeadSource
|
|
46959
|
+
* @throws ApiError
|
|
46960
|
+
*/
|
|
46961
|
+
static leadSourcesPartialUpdate({
|
|
46962
|
+
id,
|
|
46963
|
+
requestBody
|
|
46964
|
+
}) {
|
|
46965
|
+
return request(OpenAPI, {
|
|
46966
|
+
method: 'PATCH',
|
|
46967
|
+
url: '/lead-sources/{id}/',
|
|
46968
|
+
path: {
|
|
46969
|
+
'id': id
|
|
46970
|
+
},
|
|
46971
|
+
body: requestBody,
|
|
46972
|
+
mediaType: 'application/json',
|
|
46973
|
+
errors: {
|
|
46974
|
+
400: `Validation error.`,
|
|
46975
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
46976
|
+
404: `LeadSource not found.`
|
|
46977
|
+
}
|
|
46978
|
+
});
|
|
46979
|
+
}
|
|
46980
|
+
/**
|
|
46981
|
+
* Delete a lead source
|
|
46982
|
+
* Deletes the LeadSource. Any Deals referencing it have their `source` cleared.
|
|
46983
|
+
*
|
|
46984
|
+
* **Required permission:** `Ibl.CRM/Pipelines/delete`.
|
|
46985
|
+
* @returns void
|
|
46986
|
+
* @throws ApiError
|
|
46987
|
+
*/
|
|
46988
|
+
static leadSourcesDestroy({
|
|
46989
|
+
id
|
|
46990
|
+
}) {
|
|
46991
|
+
return request(OpenAPI, {
|
|
46992
|
+
method: 'DELETE',
|
|
46993
|
+
url: '/lead-sources/{id}/',
|
|
46994
|
+
path: {
|
|
46995
|
+
'id': id
|
|
46996
|
+
},
|
|
46997
|
+
errors: {
|
|
46998
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/delete\`.`,
|
|
46999
|
+
404: `LeadSource not found.`
|
|
47000
|
+
}
|
|
47001
|
+
});
|
|
47002
|
+
}
|
|
47003
|
+
}
|
|
47004
|
+
|
|
45427
47005
|
class MediaService {
|
|
45428
47006
|
/**
|
|
45429
47007
|
* List and filter media resources. Supports filtering by course_id, unit_id, item_id and searching across multiple fields.
|
|
@@ -46708,6 +48286,334 @@ class PersonsService {
|
|
|
46708
48286
|
}
|
|
46709
48287
|
}
|
|
46710
48288
|
|
|
48289
|
+
class PipelinesService {
|
|
48290
|
+
/**
|
|
48291
|
+
* List pipelines
|
|
48292
|
+
* Returns a paginated list of Pipelines in your Platform. Each Pipeline includes its ordered `stages` inline.
|
|
48293
|
+
*
|
|
48294
|
+
* **Required permission:** `Ibl.CRM/Pipelines/list`.
|
|
48295
|
+
* @returns PaginatedPipelineList
|
|
48296
|
+
* @throws ApiError
|
|
48297
|
+
*/
|
|
48298
|
+
static pipelinesList({
|
|
48299
|
+
code,
|
|
48300
|
+
isDefault,
|
|
48301
|
+
name,
|
|
48302
|
+
page,
|
|
48303
|
+
pageSize
|
|
48304
|
+
}) {
|
|
48305
|
+
return request(OpenAPI, {
|
|
48306
|
+
method: 'GET',
|
|
48307
|
+
url: '/pipelines/',
|
|
48308
|
+
query: {
|
|
48309
|
+
'code': code,
|
|
48310
|
+
'is_default': isDefault,
|
|
48311
|
+
'name': name,
|
|
48312
|
+
'page': page,
|
|
48313
|
+
'page_size': pageSize
|
|
48314
|
+
},
|
|
48315
|
+
errors: {
|
|
48316
|
+
401: `Authentication required.`,
|
|
48317
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/list\`.`
|
|
48318
|
+
}
|
|
48319
|
+
});
|
|
48320
|
+
}
|
|
48321
|
+
/**
|
|
48322
|
+
* Create a pipeline
|
|
48323
|
+
* Creates a new Pipeline. `code` must be unique within your Platform. Promoting another Pipeline to `is_default=true` while one already exists will fail — unset the existing default first.
|
|
48324
|
+
*
|
|
48325
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
48326
|
+
* @returns Pipeline
|
|
48327
|
+
* @throws ApiError
|
|
48328
|
+
*/
|
|
48329
|
+
static pipelinesCreate({
|
|
48330
|
+
requestBody
|
|
48331
|
+
}) {
|
|
48332
|
+
return request(OpenAPI, {
|
|
48333
|
+
method: 'POST',
|
|
48334
|
+
url: '/pipelines/',
|
|
48335
|
+
body: requestBody,
|
|
48336
|
+
mediaType: 'application/json',
|
|
48337
|
+
errors: {
|
|
48338
|
+
400: `Validation error.`,
|
|
48339
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`
|
|
48340
|
+
}
|
|
48341
|
+
});
|
|
48342
|
+
}
|
|
48343
|
+
/**
|
|
48344
|
+
* List stages for a pipeline
|
|
48345
|
+
* Returns the ordered list of PipelineStages for the given Pipeline.
|
|
48346
|
+
*
|
|
48347
|
+
* **Required permission:** `Ibl.CRM/Pipelines/list`.
|
|
48348
|
+
* @returns PaginatedPipelineStageList
|
|
48349
|
+
* @throws ApiError
|
|
48350
|
+
*/
|
|
48351
|
+
static pipelinesStagesList({
|
|
48352
|
+
pipelinePk,
|
|
48353
|
+
code,
|
|
48354
|
+
isLost,
|
|
48355
|
+
isWon,
|
|
48356
|
+
page,
|
|
48357
|
+
pageSize
|
|
48358
|
+
}) {
|
|
48359
|
+
return request(OpenAPI, {
|
|
48360
|
+
method: 'GET',
|
|
48361
|
+
url: '/pipelines/{pipeline_pk}/stages/',
|
|
48362
|
+
path: {
|
|
48363
|
+
'pipeline_pk': pipelinePk
|
|
48364
|
+
},
|
|
48365
|
+
query: {
|
|
48366
|
+
'code': code,
|
|
48367
|
+
'is_lost': isLost,
|
|
48368
|
+
'is_won': isWon,
|
|
48369
|
+
'page': page,
|
|
48370
|
+
'page_size': pageSize
|
|
48371
|
+
},
|
|
48372
|
+
errors: {
|
|
48373
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/list\`.`,
|
|
48374
|
+
404: `Pipeline not found.`
|
|
48375
|
+
}
|
|
48376
|
+
});
|
|
48377
|
+
}
|
|
48378
|
+
/**
|
|
48379
|
+
* Create a stage
|
|
48380
|
+
* Creates a new PipelineStage in the URL Pipeline. `code` must be unique within that Pipeline. At most one of `is_won` / `is_lost` may be true.
|
|
48381
|
+
*
|
|
48382
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
48383
|
+
* @returns PipelineStage
|
|
48384
|
+
* @throws ApiError
|
|
48385
|
+
*/
|
|
48386
|
+
static pipelinesStagesCreate({
|
|
48387
|
+
pipelinePk,
|
|
48388
|
+
requestBody
|
|
48389
|
+
}) {
|
|
48390
|
+
return request(OpenAPI, {
|
|
48391
|
+
method: 'POST',
|
|
48392
|
+
url: '/pipelines/{pipeline_pk}/stages/',
|
|
48393
|
+
path: {
|
|
48394
|
+
'pipeline_pk': pipelinePk
|
|
48395
|
+
},
|
|
48396
|
+
body: requestBody,
|
|
48397
|
+
mediaType: 'application/json',
|
|
48398
|
+
errors: {
|
|
48399
|
+
400: `Validation error.`,
|
|
48400
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
48401
|
+
404: `Pipeline not found.`
|
|
48402
|
+
}
|
|
48403
|
+
});
|
|
48404
|
+
}
|
|
48405
|
+
/**
|
|
48406
|
+
* Retrieve a stage
|
|
48407
|
+
* Returns a single PipelineStage by id (must belong to the URL Pipeline).
|
|
48408
|
+
*
|
|
48409
|
+
* **Required permission:** `Ibl.CRM/Pipelines/read`.
|
|
48410
|
+
* @returns PipelineStage
|
|
48411
|
+
* @throws ApiError
|
|
48412
|
+
*/
|
|
48413
|
+
static pipelinesStagesRetrieve({
|
|
48414
|
+
id,
|
|
48415
|
+
pipelinePk
|
|
48416
|
+
}) {
|
|
48417
|
+
return request(OpenAPI, {
|
|
48418
|
+
method: 'GET',
|
|
48419
|
+
url: '/pipelines/{pipeline_pk}/stages/{id}/',
|
|
48420
|
+
path: {
|
|
48421
|
+
'id': id,
|
|
48422
|
+
'pipeline_pk': pipelinePk
|
|
48423
|
+
},
|
|
48424
|
+
errors: {
|
|
48425
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/read\`.`,
|
|
48426
|
+
404: `Stage not found in this Pipeline.`
|
|
48427
|
+
}
|
|
48428
|
+
});
|
|
48429
|
+
}
|
|
48430
|
+
/**
|
|
48431
|
+
* Replace a stage
|
|
48432
|
+
* Replaces all editable fields on the PipelineStage.
|
|
48433
|
+
*
|
|
48434
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
48435
|
+
* @returns PipelineStage
|
|
48436
|
+
* @throws ApiError
|
|
48437
|
+
*/
|
|
48438
|
+
static pipelinesStagesUpdate({
|
|
48439
|
+
id,
|
|
48440
|
+
pipelinePk,
|
|
48441
|
+
requestBody
|
|
48442
|
+
}) {
|
|
48443
|
+
return request(OpenAPI, {
|
|
48444
|
+
method: 'PUT',
|
|
48445
|
+
url: '/pipelines/{pipeline_pk}/stages/{id}/',
|
|
48446
|
+
path: {
|
|
48447
|
+
'id': id,
|
|
48448
|
+
'pipeline_pk': pipelinePk
|
|
48449
|
+
},
|
|
48450
|
+
body: requestBody,
|
|
48451
|
+
mediaType: 'application/json',
|
|
48452
|
+
errors: {
|
|
48453
|
+
400: `Validation error.`,
|
|
48454
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
48455
|
+
404: `Stage not found in this Pipeline.`
|
|
48456
|
+
}
|
|
48457
|
+
});
|
|
48458
|
+
}
|
|
48459
|
+
/**
|
|
48460
|
+
* Update a stage
|
|
48461
|
+
* Updates only the supplied fields on the PipelineStage.
|
|
48462
|
+
*
|
|
48463
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
48464
|
+
* @returns PipelineStage
|
|
48465
|
+
* @throws ApiError
|
|
48466
|
+
*/
|
|
48467
|
+
static pipelinesStagesPartialUpdate({
|
|
48468
|
+
id,
|
|
48469
|
+
pipelinePk,
|
|
48470
|
+
requestBody
|
|
48471
|
+
}) {
|
|
48472
|
+
return request(OpenAPI, {
|
|
48473
|
+
method: 'PATCH',
|
|
48474
|
+
url: '/pipelines/{pipeline_pk}/stages/{id}/',
|
|
48475
|
+
path: {
|
|
48476
|
+
'id': id,
|
|
48477
|
+
'pipeline_pk': pipelinePk
|
|
48478
|
+
},
|
|
48479
|
+
body: requestBody,
|
|
48480
|
+
mediaType: 'application/json',
|
|
48481
|
+
errors: {
|
|
48482
|
+
400: `Validation error.`,
|
|
48483
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
48484
|
+
404: `Stage not found in this Pipeline.`
|
|
48485
|
+
}
|
|
48486
|
+
});
|
|
48487
|
+
}
|
|
48488
|
+
/**
|
|
48489
|
+
* Delete a stage
|
|
48490
|
+
* Deletes the PipelineStage. Fails with `409 Conflict` if any Deal still references it (FK is PROTECTed).
|
|
48491
|
+
*
|
|
48492
|
+
* **Required permission:** `Ibl.CRM/Pipelines/delete`.
|
|
48493
|
+
* @returns void
|
|
48494
|
+
* @throws ApiError
|
|
48495
|
+
*/
|
|
48496
|
+
static pipelinesStagesDestroy({
|
|
48497
|
+
id,
|
|
48498
|
+
pipelinePk
|
|
48499
|
+
}) {
|
|
48500
|
+
return request(OpenAPI, {
|
|
48501
|
+
method: 'DELETE',
|
|
48502
|
+
url: '/pipelines/{pipeline_pk}/stages/{id}/',
|
|
48503
|
+
path: {
|
|
48504
|
+
'id': id,
|
|
48505
|
+
'pipeline_pk': pipelinePk
|
|
48506
|
+
},
|
|
48507
|
+
errors: {
|
|
48508
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/delete\`.`,
|
|
48509
|
+
404: `Stage not found in this Pipeline.`,
|
|
48510
|
+
409: `Stage still has Deals attached.`
|
|
48511
|
+
}
|
|
48512
|
+
});
|
|
48513
|
+
}
|
|
48514
|
+
/**
|
|
48515
|
+
* Retrieve a pipeline
|
|
48516
|
+
* Returns a single Pipeline by id, including its ordered `stages`.
|
|
48517
|
+
*
|
|
48518
|
+
* **Required permission:** `Ibl.CRM/Pipelines/read`.
|
|
48519
|
+
* @returns Pipeline
|
|
48520
|
+
* @throws ApiError
|
|
48521
|
+
*/
|
|
48522
|
+
static pipelinesRetrieve({
|
|
48523
|
+
id
|
|
48524
|
+
}) {
|
|
48525
|
+
return request(OpenAPI, {
|
|
48526
|
+
method: 'GET',
|
|
48527
|
+
url: '/pipelines/{id}/',
|
|
48528
|
+
path: {
|
|
48529
|
+
'id': id
|
|
48530
|
+
},
|
|
48531
|
+
errors: {
|
|
48532
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/read\`.`,
|
|
48533
|
+
404: `Pipeline not found.`
|
|
48534
|
+
}
|
|
48535
|
+
});
|
|
48536
|
+
}
|
|
48537
|
+
/**
|
|
48538
|
+
* Replace a pipeline
|
|
48539
|
+
* Replaces all editable fields on the Pipeline.
|
|
48540
|
+
*
|
|
48541
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
48542
|
+
* @returns Pipeline
|
|
48543
|
+
* @throws ApiError
|
|
48544
|
+
*/
|
|
48545
|
+
static pipelinesUpdate({
|
|
48546
|
+
id,
|
|
48547
|
+
requestBody
|
|
48548
|
+
}) {
|
|
48549
|
+
return request(OpenAPI, {
|
|
48550
|
+
method: 'PUT',
|
|
48551
|
+
url: '/pipelines/{id}/',
|
|
48552
|
+
path: {
|
|
48553
|
+
'id': id
|
|
48554
|
+
},
|
|
48555
|
+
body: requestBody,
|
|
48556
|
+
mediaType: 'application/json',
|
|
48557
|
+
errors: {
|
|
48558
|
+
400: `Validation error.`,
|
|
48559
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
48560
|
+
404: `Pipeline not found.`
|
|
48561
|
+
}
|
|
48562
|
+
});
|
|
48563
|
+
}
|
|
48564
|
+
/**
|
|
48565
|
+
* Update a pipeline
|
|
48566
|
+
* Updates only the supplied fields on the Pipeline.
|
|
48567
|
+
*
|
|
48568
|
+
* **Required permission:** `Ibl.CRM/Pipelines/write`.
|
|
48569
|
+
* @returns Pipeline
|
|
48570
|
+
* @throws ApiError
|
|
48571
|
+
*/
|
|
48572
|
+
static pipelinesPartialUpdate({
|
|
48573
|
+
id,
|
|
48574
|
+
requestBody
|
|
48575
|
+
}) {
|
|
48576
|
+
return request(OpenAPI, {
|
|
48577
|
+
method: 'PATCH',
|
|
48578
|
+
url: '/pipelines/{id}/',
|
|
48579
|
+
path: {
|
|
48580
|
+
'id': id
|
|
48581
|
+
},
|
|
48582
|
+
body: requestBody,
|
|
48583
|
+
mediaType: 'application/json',
|
|
48584
|
+
errors: {
|
|
48585
|
+
400: `Validation error.`,
|
|
48586
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/write\`.`,
|
|
48587
|
+
404: `Pipeline not found.`
|
|
48588
|
+
}
|
|
48589
|
+
});
|
|
48590
|
+
}
|
|
48591
|
+
/**
|
|
48592
|
+
* Delete a pipeline
|
|
48593
|
+
* Deletes the Pipeline. Fails with `409 Conflict` if any Deal still references it (FK is PROTECTed).
|
|
48594
|
+
*
|
|
48595
|
+
* **Required permission:** `Ibl.CRM/Pipelines/delete`.
|
|
48596
|
+
* @returns void
|
|
48597
|
+
* @throws ApiError
|
|
48598
|
+
*/
|
|
48599
|
+
static pipelinesDestroy({
|
|
48600
|
+
id
|
|
48601
|
+
}) {
|
|
48602
|
+
return request(OpenAPI, {
|
|
48603
|
+
method: 'DELETE',
|
|
48604
|
+
url: '/pipelines/{id}/',
|
|
48605
|
+
path: {
|
|
48606
|
+
'id': id
|
|
48607
|
+
},
|
|
48608
|
+
errors: {
|
|
48609
|
+
403: `Missing required permission \`Ibl.CRM/Pipelines/delete\`.`,
|
|
48610
|
+
404: `Pipeline not found.`,
|
|
48611
|
+
409: `Pipeline still has Deals attached.`
|
|
48612
|
+
}
|
|
48613
|
+
});
|
|
48614
|
+
}
|
|
48615
|
+
}
|
|
48616
|
+
|
|
46711
48617
|
class PlatformsService {
|
|
46712
48618
|
/**
|
|
46713
48619
|
* Check whether the authenticated user has payment access to an item on a scoped platform.
|
|
@@ -49555,6 +51461,7 @@ class TransactionsService {
|
|
|
49555
51461
|
|
|
49556
51462
|
exports.AccessCheckService = AccessCheckService;
|
|
49557
51463
|
exports.AccountService = AccountService;
|
|
51464
|
+
exports.ActivitiesService = ActivitiesService;
|
|
49558
51465
|
exports.AiAccountService = AiAccountService;
|
|
49559
51466
|
exports.AiAnalyticsService = AiAnalyticsService;
|
|
49560
51467
|
exports.AiBotService = AiBotService;
|
|
@@ -49579,14 +51486,17 @@ exports.CredentialsService = CredentialsService;
|
|
|
49579
51486
|
exports.CreditsService = CreditsService;
|
|
49580
51487
|
exports.CrmService = CrmService;
|
|
49581
51488
|
exports.CustomDomainsService = CustomDomainsService;
|
|
51489
|
+
exports.DealsService = DealsService;
|
|
49582
51490
|
exports.FeaturesService = FeaturesService;
|
|
49583
51491
|
exports.IntegrationCredentialsService = IntegrationCredentialsService;
|
|
49584
51492
|
exports.ItemsService = ItemsService;
|
|
51493
|
+
exports.LeadSourcesService = LeadSourcesService;
|
|
49585
51494
|
exports.MediaService = MediaService;
|
|
49586
51495
|
exports.NotificationsService = NotificationsService;
|
|
49587
51496
|
exports.OpenAPI = OpenAPI;
|
|
49588
51497
|
exports.OrganizationsService = OrganizationsService;
|
|
49589
51498
|
exports.PersonsService = PersonsService;
|
|
51499
|
+
exports.PipelinesService = PipelinesService;
|
|
49590
51500
|
exports.PlatformsService = PlatformsService;
|
|
49591
51501
|
exports.PricesService = PricesService;
|
|
49592
51502
|
exports.RecommendationsService = RecommendationsService;
|