intercom-client 6.0.0 → 6.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +24 -28
- package/api/resources/admins/client/Client.js +10 -10
- package/api/resources/admins/types/Admin.d.ts +11 -2
- package/api/resources/articles/client/Client.js +12 -12
- package/api/resources/articles/client/requests/CreateArticleRequest.d.ts +9 -1
- package/api/resources/articles/client/requests/CreateArticleRequest.js +4 -0
- package/api/resources/articles/client/requests/UpdateArticleRequest.d.ts +9 -1
- package/api/resources/articles/client/requests/UpdateArticleRequest.js +4 -0
- package/api/resources/companies/client/Client.d.ts +2 -2
- package/api/resources/companies/client/Client.js +24 -24
- package/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.d.ts +1 -1
- package/api/resources/companies/types/Company.d.ts +1 -1
- package/api/resources/contacts/client/Client.d.ts +1 -2
- package/api/resources/contacts/client/Client.js +31 -32
- package/api/resources/contacts/types/Contact.d.ts +3 -3
- package/api/resources/conversations/client/Client.d.ts +28 -9
- package/api/resources/conversations/client/Client.js +52 -33
- package/api/resources/conversations/client/requests/CreateConversationRequest.d.ts +2 -0
- package/api/resources/conversations/client/requests/ManageConversationPartsRequest.d.ts +10 -20
- package/api/resources/dataAttributes/client/Client.js +6 -6
- package/api/resources/dataExport/client/Client.js +8 -8
- package/api/resources/events/client/Client.js +6 -6
- package/api/resources/helpCenters/client/Client.js +4 -4
- package/api/resources/helpCenters/resources/collections/client/Client.js +10 -10
- package/api/resources/index.d.ts +0 -2
- package/api/resources/index.js +1 -3
- package/api/resources/messages/client/Client.d.ts +3 -23
- package/api/resources/messages/client/Client.js +5 -25
- package/api/resources/news/resources/feeds/client/Client.js +6 -6
- package/api/resources/news/resources/items/client/Client.js +10 -10
- package/api/resources/notes/client/Client.js +6 -6
- package/api/resources/phoneCallRedirects/client/Client.js +2 -2
- package/api/resources/segments/client/Client.js +4 -4
- package/api/resources/subscriptionTypes/client/Client.js +2 -2
- package/api/resources/subscriptionTypes/types/SubscriptionType.d.ts +1 -1
- package/api/resources/tags/client/Client.js +20 -20
- package/api/resources/tags/types/Tag.d.ts +1 -1
- package/api/resources/teams/client/Client.js +4 -4
- package/api/resources/ticketTypes/client/Client.js +8 -8
- package/api/resources/ticketTypes/resources/attributes/client/Client.js +4 -4
- package/api/resources/tickets/client/Client.js +10 -10
- package/api/resources/visitors/client/Client.js +6 -6
- package/api/types/ActionComponent.d.ts +16 -0
- package/api/types/ButtonComponent.d.ts +33 -0
- package/api/types/ButtonComponent.js +14 -0
- package/api/types/CanvasObject.d.ts +20 -0
- package/api/types/CheckboxComponent.d.ts +36 -0
- package/api/types/CheckboxComponent.js +14 -0
- package/api/types/CheckboxOption.d.ts +16 -0
- package/api/types/CheckboxOption.js +5 -0
- package/api/types/Component.d.ts +43 -0
- package/api/types/Component.js +5 -0
- package/api/types/ConfigureRequest.d.ts +22 -0
- package/api/types/ConfigureRequest.js +5 -0
- package/api/types/ConfigureResponse.d.ts +12 -0
- package/api/types/ConfigureResponse.js +5 -0
- package/api/types/ContactCompanies.d.ts +5 -0
- package/api/types/ContactCompany.d.ts +14 -0
- package/api/types/ContactCompany.js +5 -0
- package/api/types/ContentObject.d.ts +13 -0
- package/api/types/ContentObject.js +5 -0
- package/api/types/Context.d.ts +34 -0
- package/api/types/Context.js +15 -0
- package/api/types/ConversationSource.d.ts +19 -1
- package/api/types/ConversationSource.js +16 -0
- package/api/types/ConversationTeammates.d.ts +2 -2
- package/api/types/CurrentCanvas.d.ts +11 -0
- package/api/types/CurrentCanvas.js +5 -0
- package/api/types/CustomAttributes.d.ts +2 -6
- package/api/types/DataEventSummaryItem.d.ts +1 -1
- package/api/types/DataTableComponent.d.ts +11 -0
- package/api/types/DataTableComponent.js +5 -0
- package/api/types/DataTableItem.d.ts +14 -0
- package/api/types/DataTableItem.js +5 -0
- package/api/types/DividerComponent.d.ts +12 -0
- package/api/types/DividerComponent.js +5 -0
- package/api/types/DropdownComponent.d.ts +34 -0
- package/api/types/DropdownComponent.js +14 -0
- package/api/types/DropdownOption.d.ts +16 -0
- package/api/types/DropdownOption.js +5 -0
- package/api/types/Error_.d.ts +1 -1
- package/api/types/Event.d.ts +10 -0
- package/api/types/Event.js +5 -0
- package/api/types/ImageComponent.d.ts +40 -0
- package/api/types/ImageComponent.js +15 -0
- package/api/types/InitializeRequest.d.ts +23 -0
- package/api/types/InitializeRequest.js +5 -0
- package/api/types/InitializeResponse.d.ts +11 -0
- package/api/types/InitializeResponse.js +5 -0
- package/api/types/InputComponent.d.ts +37 -0
- package/api/types/InputComponent.js +14 -0
- package/api/types/ListComponent.d.ts +23 -0
- package/api/types/ListComponent.js +5 -0
- package/api/types/ListItem.d.ts +25 -0
- package/api/types/ListItem.js +5 -0
- package/api/types/ListItemWithImage.d.ts +12 -0
- package/api/types/ListItemWithImage.js +5 -0
- package/api/types/ListItemWithoutImage.d.ts +12 -0
- package/api/types/ListItemWithoutImage.js +5 -0
- package/api/types/LiveCanvasRequest.d.ts +21 -0
- package/api/types/LiveCanvasRequest.js +5 -0
- package/api/types/LiveCanvasResponse.d.ts +11 -0
- package/api/types/LiveCanvasResponse.js +5 -0
- package/api/types/MultipleFilterSearchRequest.d.ts +1 -8
- package/api/types/MultipleOrSingleFilterSearchRequest.d.ts +5 -0
- package/api/types/MultipleOrSingleFilterSearchRequest.js +5 -0
- package/api/types/ResultsResponse.d.ts +10 -0
- package/api/types/ResultsResponse.js +5 -0
- package/api/types/SheetActionComponent.d.ts +12 -0
- package/api/types/SheetActionComponent.js +5 -0
- package/api/types/SingleFilterSearchRequest.d.ts +5 -1
- package/api/types/SingleSelectComponent.d.ts +39 -0
- package/api/types/SingleSelectComponent.js +14 -0
- package/api/types/SingleSelectOption.d.ts +16 -0
- package/api/types/SingleSelectOption.js +5 -0
- package/api/types/SocialProfile.d.ts +1 -1
- package/api/types/SpacerComponent.d.ts +25 -0
- package/api/types/SpacerComponent.js +16 -0
- package/api/types/SubmitActionComponent.d.ts +8 -0
- package/api/types/SubmitActionComponent.js +5 -0
- package/api/types/SubmitRequest.d.ts +29 -0
- package/api/types/SubmitRequest.js +5 -0
- package/api/types/SubmitResponse.d.ts +23 -0
- package/api/types/SubmitResponse.js +5 -0
- package/api/types/TextAreaComponent.d.ts +22 -0
- package/api/types/TextAreaComponent.js +5 -0
- package/api/types/TextComponent.d.ts +39 -0
- package/api/types/TextComponent.js +20 -0
- package/api/types/TicketTypeAttribute.d.ts +16 -1
- package/api/types/TicketTypeAttribute.js +13 -0
- package/api/types/UrlActionComponent.d.ts +10 -0
- package/api/types/UrlActionComponent.js +5 -0
- package/api/types/Visitor.d.ts +2 -2
- package/api/types/index.d.ts +41 -1
- package/api/types/index.js +41 -1
- package/dist/api/resources/admins/client/Client.js +10 -10
- package/dist/api/resources/admins/types/Admin.d.ts +11 -2
- package/dist/api/resources/articles/client/Client.js +12 -12
- package/dist/api/resources/articles/client/requests/CreateArticleRequest.d.ts +9 -1
- package/dist/api/resources/articles/client/requests/CreateArticleRequest.js +4 -0
- package/dist/api/resources/articles/client/requests/UpdateArticleRequest.d.ts +9 -1
- package/dist/api/resources/articles/client/requests/UpdateArticleRequest.js +4 -0
- package/dist/api/resources/companies/client/Client.d.ts +2 -2
- package/dist/api/resources/companies/client/Client.js +24 -24
- package/dist/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.d.ts +1 -1
- package/dist/api/resources/companies/types/Company.d.ts +1 -1
- package/dist/api/resources/contacts/client/Client.d.ts +1 -2
- package/dist/api/resources/contacts/client/Client.js +31 -32
- package/dist/api/resources/contacts/types/Contact.d.ts +3 -3
- package/dist/api/resources/conversations/client/Client.d.ts +28 -9
- package/dist/api/resources/conversations/client/Client.js +52 -33
- package/dist/api/resources/conversations/client/requests/CreateConversationRequest.d.ts +2 -0
- package/dist/api/resources/conversations/client/requests/ManageConversationPartsRequest.d.ts +10 -20
- package/dist/api/resources/dataAttributes/client/Client.js +6 -6
- package/dist/api/resources/dataExport/client/Client.js +8 -8
- package/dist/api/resources/events/client/Client.js +6 -6
- package/dist/api/resources/helpCenters/client/Client.js +4 -4
- package/dist/api/resources/helpCenters/resources/collections/client/Client.js +10 -10
- package/dist/api/resources/index.d.ts +0 -2
- package/dist/api/resources/index.js +1 -3
- package/dist/api/resources/messages/client/Client.d.ts +3 -23
- package/dist/api/resources/messages/client/Client.js +5 -25
- package/dist/api/resources/news/resources/feeds/client/Client.js +6 -6
- package/dist/api/resources/news/resources/items/client/Client.js +10 -10
- package/dist/api/resources/notes/client/Client.js +6 -6
- package/dist/api/resources/phoneCallRedirects/client/Client.js +2 -2
- package/dist/api/resources/segments/client/Client.js +4 -4
- package/dist/api/resources/subscriptionTypes/client/Client.js +2 -2
- package/dist/api/resources/subscriptionTypes/types/SubscriptionType.d.ts +1 -1
- package/dist/api/resources/tags/client/Client.js +20 -20
- package/dist/api/resources/tags/types/Tag.d.ts +1 -1
- package/dist/api/resources/teams/client/Client.js +4 -4
- package/dist/api/resources/ticketTypes/client/Client.js +8 -8
- package/dist/api/resources/ticketTypes/resources/attributes/client/Client.js +4 -4
- package/dist/api/resources/tickets/client/Client.js +10 -10
- package/dist/api/resources/visitors/client/Client.js +6 -6
- package/dist/api/types/ActionComponent.d.ts +16 -0
- package/dist/api/types/ActionComponent.js +5 -0
- package/dist/api/types/ButtonComponent.d.ts +33 -0
- package/dist/api/types/ButtonComponent.js +14 -0
- package/dist/api/types/CanvasObject.d.ts +20 -0
- package/dist/api/types/CanvasObject.js +5 -0
- package/dist/api/types/CheckboxComponent.d.ts +36 -0
- package/dist/api/types/CheckboxComponent.js +14 -0
- package/dist/api/types/CheckboxOption.d.ts +16 -0
- package/dist/api/types/CheckboxOption.js +5 -0
- package/dist/api/types/Component.d.ts +43 -0
- package/dist/api/types/Component.js +5 -0
- package/dist/api/types/ConfigureRequest.d.ts +22 -0
- package/dist/api/types/ConfigureRequest.js +5 -0
- package/dist/api/types/ConfigureResponse.d.ts +12 -0
- package/dist/api/types/ConfigureResponse.js +5 -0
- package/dist/api/types/ContactCompanies.d.ts +5 -0
- package/dist/api/types/ContactCompany.d.ts +14 -0
- package/dist/api/types/ContactCompany.js +5 -0
- package/dist/api/types/ContentObject.d.ts +13 -0
- package/dist/api/types/ContentObject.js +5 -0
- package/dist/api/types/Context.d.ts +34 -0
- package/dist/api/types/Context.js +15 -0
- package/dist/api/types/ConversationSource.d.ts +19 -1
- package/dist/api/types/ConversationSource.js +16 -0
- package/dist/api/types/ConversationTeammates.d.ts +2 -2
- package/dist/api/types/CurrentCanvas.d.ts +11 -0
- package/dist/api/types/CurrentCanvas.js +5 -0
- package/dist/api/types/CustomAttributes.d.ts +2 -6
- package/dist/api/types/DataEventSummaryItem.d.ts +1 -1
- package/dist/api/types/DataTableComponent.d.ts +11 -0
- package/dist/api/types/DataTableComponent.js +5 -0
- package/dist/api/types/DataTableItem.d.ts +14 -0
- package/dist/api/types/DataTableItem.js +5 -0
- package/dist/api/types/DividerComponent.d.ts +12 -0
- package/dist/api/types/DividerComponent.js +5 -0
- package/dist/api/types/DropdownComponent.d.ts +34 -0
- package/dist/api/types/DropdownComponent.js +14 -0
- package/dist/api/types/DropdownOption.d.ts +16 -0
- package/dist/api/types/DropdownOption.js +5 -0
- package/dist/api/types/Error_.d.ts +1 -1
- package/dist/api/types/Event.d.ts +10 -0
- package/dist/api/types/Event.js +5 -0
- package/dist/api/types/ImageComponent.d.ts +40 -0
- package/dist/api/types/ImageComponent.js +15 -0
- package/dist/api/types/InitializeRequest.d.ts +23 -0
- package/dist/api/types/InitializeRequest.js +5 -0
- package/dist/api/types/InitializeResponse.d.ts +11 -0
- package/dist/api/types/InitializeResponse.js +5 -0
- package/dist/api/types/InputComponent.d.ts +37 -0
- package/dist/api/types/InputComponent.js +14 -0
- package/dist/api/types/ListComponent.d.ts +23 -0
- package/dist/api/types/ListComponent.js +5 -0
- package/dist/api/types/ListItem.d.ts +25 -0
- package/dist/api/types/ListItem.js +5 -0
- package/dist/api/types/ListItemWithImage.d.ts +12 -0
- package/dist/api/types/ListItemWithImage.js +5 -0
- package/dist/api/types/ListItemWithoutImage.d.ts +12 -0
- package/dist/api/types/ListItemWithoutImage.js +5 -0
- package/dist/api/types/LiveCanvasRequest.d.ts +21 -0
- package/dist/api/types/LiveCanvasRequest.js +5 -0
- package/dist/api/types/LiveCanvasResponse.d.ts +11 -0
- package/dist/api/types/LiveCanvasResponse.js +5 -0
- package/dist/api/types/MultipleFilterSearchRequest.d.ts +1 -8
- package/dist/api/types/MultipleOrSingleFilterSearchRequest.d.ts +5 -0
- package/dist/api/types/MultipleOrSingleFilterSearchRequest.js +5 -0
- package/dist/api/types/ResultsResponse.d.ts +10 -0
- package/dist/api/types/ResultsResponse.js +5 -0
- package/dist/api/types/SheetActionComponent.d.ts +12 -0
- package/dist/api/types/SheetActionComponent.js +5 -0
- package/dist/api/types/SingleFilterSearchRequest.d.ts +5 -1
- package/dist/api/types/SingleSelectComponent.d.ts +39 -0
- package/dist/api/types/SingleSelectComponent.js +14 -0
- package/dist/api/types/SingleSelectOption.d.ts +16 -0
- package/dist/api/types/SingleSelectOption.js +5 -0
- package/dist/api/types/SocialProfile.d.ts +1 -1
- package/dist/api/types/SpacerComponent.d.ts +25 -0
- package/dist/api/types/SpacerComponent.js +16 -0
- package/dist/api/types/SubmitActionComponent.d.ts +8 -0
- package/dist/api/types/SubmitActionComponent.js +5 -0
- package/dist/api/types/SubmitRequest.d.ts +29 -0
- package/dist/api/types/SubmitRequest.js +5 -0
- package/dist/api/types/SubmitResponse.d.ts +23 -0
- package/dist/api/types/SubmitResponse.js +5 -0
- package/dist/api/types/TextAreaComponent.d.ts +22 -0
- package/dist/api/types/TextAreaComponent.js +5 -0
- package/dist/api/types/TextComponent.d.ts +39 -0
- package/dist/api/types/TextComponent.js +20 -0
- package/dist/api/types/TicketTypeAttribute.d.ts +16 -1
- package/dist/api/types/TicketTypeAttribute.js +13 -0
- package/dist/api/types/UrlActionComponent.d.ts +10 -0
- package/dist/api/types/UrlActionComponent.js +5 -0
- package/dist/api/types/Visitor.d.ts +2 -2
- package/dist/api/types/index.d.ts +41 -1
- package/dist/api/types/index.js +41 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +10 -2
- package/reference.md +12 -14
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/api/resources/customObjectInstances/index.d.ts +0 -1
- package/api/resources/customObjectInstances/index.js +0 -17
- package/api/resources/customObjectInstances/types/CustomObjectInstance.d.ts +0 -16
- package/api/resources/customObjectInstances/types/index.d.ts +0 -1
- package/api/resources/customObjectInstances/types/index.js +0 -17
- package/dist/api/resources/customObjectInstances/index.d.ts +0 -1
- package/dist/api/resources/customObjectInstances/index.js +0 -17
- package/dist/api/resources/customObjectInstances/types/CustomObjectInstance.d.ts +0 -16
- package/dist/api/resources/customObjectInstances/types/index.d.ts +0 -1
- package/dist/api/resources/customObjectInstances/types/index.js +0 -17
- /package/api/{resources/customObjectInstances/types/CustomObjectInstance.js → types/ActionComponent.js} +0 -0
- /package/{dist/api/resources/customObjectInstances/types/CustomObjectInstance.js → api/types/CanvasObject.js} +0 -0
|
@@ -95,11 +95,11 @@ class Conversations {
|
|
|
95
95
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
96
96
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "conversations"),
|
|
97
97
|
method: "GET",
|
|
98
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
98
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
99
99
|
contentType: "application/json",
|
|
100
100
|
queryParameters: _queryParams,
|
|
101
101
|
requestType: "json",
|
|
102
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
102
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
103
103
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
104
104
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
105
105
|
});
|
|
@@ -187,11 +187,11 @@ class Conversations {
|
|
|
187
187
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
188
188
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "conversations"),
|
|
189
189
|
method: "POST",
|
|
190
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
190
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
191
191
|
contentType: "application/json",
|
|
192
192
|
requestType: "json",
|
|
193
193
|
body: request,
|
|
194
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
194
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
195
195
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
196
196
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
197
197
|
});
|
|
@@ -264,11 +264,11 @@ class Conversations {
|
|
|
264
264
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
265
265
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}`),
|
|
266
266
|
method: "GET",
|
|
267
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
267
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
268
268
|
contentType: "application/json",
|
|
269
269
|
queryParameters: _queryParams,
|
|
270
270
|
requestType: "json",
|
|
271
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
271
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
272
272
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
273
273
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
274
274
|
});
|
|
@@ -343,12 +343,12 @@ class Conversations {
|
|
|
343
343
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
344
344
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}`),
|
|
345
345
|
method: "PUT",
|
|
346
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
346
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
347
347
|
contentType: "application/json",
|
|
348
348
|
queryParameters: _queryParams,
|
|
349
349
|
requestType: "json",
|
|
350
350
|
body: _body,
|
|
351
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
351
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
352
352
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
353
353
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
354
354
|
});
|
|
@@ -511,11 +511,11 @@ class Conversations {
|
|
|
511
511
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
512
512
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "conversations/search"),
|
|
513
513
|
method: "POST",
|
|
514
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
514
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
515
515
|
contentType: "application/json",
|
|
516
516
|
requestType: "json",
|
|
517
517
|
body: request,
|
|
518
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
518
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
519
519
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
520
520
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
521
521
|
});
|
|
@@ -614,11 +614,11 @@ class Conversations {
|
|
|
614
614
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
615
615
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}/reply`),
|
|
616
616
|
method: "POST",
|
|
617
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
617
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
618
618
|
contentType: "application/json",
|
|
619
619
|
requestType: "json",
|
|
620
620
|
body: _body,
|
|
621
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
621
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
622
622
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
623
623
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
624
624
|
});
|
|
@@ -673,11 +673,28 @@ class Conversations {
|
|
|
673
673
|
* await client.conversations.manage({
|
|
674
674
|
* conversation_id: "123",
|
|
675
675
|
* body: {
|
|
676
|
-
* message_type: "
|
|
676
|
+
* message_type: "close",
|
|
677
677
|
* type: "admin",
|
|
678
|
-
* admin_id: "12345"
|
|
679
|
-
*
|
|
680
|
-
*
|
|
678
|
+
* admin_id: "12345"
|
|
679
|
+
* }
|
|
680
|
+
* })
|
|
681
|
+
*
|
|
682
|
+
* @example
|
|
683
|
+
* await client.conversations.manage({
|
|
684
|
+
* conversation_id: "123",
|
|
685
|
+
* body: {
|
|
686
|
+
* message_type: "snoozed",
|
|
687
|
+
* admin_id: "5017691",
|
|
688
|
+
* snoozed_until: 1673609604
|
|
689
|
+
* }
|
|
690
|
+
* })
|
|
691
|
+
*
|
|
692
|
+
* @example
|
|
693
|
+
* await client.conversations.manage({
|
|
694
|
+
* conversation_id: "123",
|
|
695
|
+
* body: {
|
|
696
|
+
* message_type: "open",
|
|
697
|
+
* admin_id: "5017690"
|
|
681
698
|
* }
|
|
682
699
|
* })
|
|
683
700
|
*
|
|
@@ -688,8 +705,7 @@ class Conversations {
|
|
|
688
705
|
* message_type: "assignment",
|
|
689
706
|
* type: "admin",
|
|
690
707
|
* admin_id: "12345",
|
|
691
|
-
* assignee_id: "4324241"
|
|
692
|
-
* body: "Let me pass you over to one of my colleagues."
|
|
708
|
+
* assignee_id: "4324241"
|
|
693
709
|
* }
|
|
694
710
|
* })
|
|
695
711
|
*/
|
|
@@ -700,11 +716,11 @@ class Conversations {
|
|
|
700
716
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
701
717
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}/parts`),
|
|
702
718
|
method: "POST",
|
|
703
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
719
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
704
720
|
contentType: "application/json",
|
|
705
721
|
requestType: "json",
|
|
706
722
|
body: _body,
|
|
707
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
723
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
708
724
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
709
725
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
710
726
|
});
|
|
@@ -742,8 +758,11 @@ class Conversations {
|
|
|
742
758
|
});
|
|
743
759
|
}
|
|
744
760
|
/**
|
|
761
|
+
* {% admonition type="danger" name="Deprecation of Run Assignment Rules" %}
|
|
762
|
+
* Run assignment rules is now deprecated in version 2.12 and future versions and will be permanently removed on December 31, 2026. After this date, any requests made to this endpoint will fail.
|
|
763
|
+
* {% /admonition %}
|
|
745
764
|
* You can let a conversation be automatically assigned following assignment rules.
|
|
746
|
-
* {% admonition type="
|
|
765
|
+
* {% admonition type="warning" name="When using workflows" %}
|
|
747
766
|
* It is not possible to use this endpoint with Workflows.
|
|
748
767
|
* {% /admonition %}
|
|
749
768
|
*
|
|
@@ -766,10 +785,10 @@ class Conversations {
|
|
|
766
785
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
767
786
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}/run_assignment_rules`),
|
|
768
787
|
method: "POST",
|
|
769
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
788
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
770
789
|
contentType: "application/json",
|
|
771
790
|
requestType: "json",
|
|
772
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
791
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
773
792
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
774
793
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
775
794
|
});
|
|
@@ -809,7 +828,7 @@ class Conversations {
|
|
|
809
828
|
/**
|
|
810
829
|
* You can add participants who are contacts to a conversation, on behalf of either another contact or an admin.
|
|
811
830
|
*
|
|
812
|
-
* {% admonition type="
|
|
831
|
+
* {% admonition type="warning" name="Contacts without an email" %}
|
|
813
832
|
* If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`.
|
|
814
833
|
* {% /admonition %}
|
|
815
834
|
*
|
|
@@ -846,11 +865,11 @@ class Conversations {
|
|
|
846
865
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
847
866
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}/customers`),
|
|
848
867
|
method: "POST",
|
|
849
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
868
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
850
869
|
contentType: "application/json",
|
|
851
870
|
requestType: "json",
|
|
852
871
|
body: _body,
|
|
853
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
872
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
854
873
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
855
874
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
856
875
|
});
|
|
@@ -890,7 +909,7 @@ class Conversations {
|
|
|
890
909
|
/**
|
|
891
910
|
* You can add participants who are contacts to a conversation, on behalf of either another contact or an admin.
|
|
892
911
|
*
|
|
893
|
-
* {% admonition type="
|
|
912
|
+
* {% admonition type="warning" name="Contacts without an email" %}
|
|
894
913
|
* If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`.
|
|
895
914
|
* {% /admonition %}
|
|
896
915
|
*
|
|
@@ -917,11 +936,11 @@ class Conversations {
|
|
|
917
936
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
918
937
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}/customers/${encodeURIComponent(contactId)}`),
|
|
919
938
|
method: "DELETE",
|
|
920
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
939
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
921
940
|
contentType: "application/json",
|
|
922
941
|
requestType: "json",
|
|
923
942
|
body: _body,
|
|
924
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
943
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
925
944
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
926
945
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
927
946
|
});
|
|
@@ -994,11 +1013,11 @@ class Conversations {
|
|
|
994
1013
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
995
1014
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "conversations/redact"),
|
|
996
1015
|
method: "POST",
|
|
997
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
1016
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
998
1017
|
contentType: "application/json",
|
|
999
1018
|
requestType: "json",
|
|
1000
1019
|
body: request,
|
|
1001
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
1020
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
1002
1021
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
1003
1022
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1004
1023
|
});
|
|
@@ -1060,11 +1079,11 @@ class Conversations {
|
|
|
1060
1079
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
1061
1080
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `conversations/${encodeURIComponent(conversationId)}/convert`),
|
|
1062
1081
|
method: "POST",
|
|
1063
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
1082
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
1064
1083
|
contentType: "application/json",
|
|
1065
1084
|
requestType: "json",
|
|
1066
1085
|
body: _body,
|
|
1067
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
1086
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
1068
1087
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
1069
1088
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
1070
1089
|
});
|
|
@@ -24,6 +24,8 @@ export interface CreateConversationRequest {
|
|
|
24
24
|
from: CreateConversationRequest.From;
|
|
25
25
|
/** The content of the message. HTML is not supported. */
|
|
26
26
|
body: string;
|
|
27
|
+
/** The time the conversation was created as a UTC Unix timestamp. If not provided, the current time will be used. This field is only recommneded for migrating past conversations from another source into Intercom. */
|
|
28
|
+
created_at?: number;
|
|
27
29
|
}
|
|
28
30
|
export declare namespace CreateConversationRequest {
|
|
29
31
|
interface From {
|
|
@@ -7,11 +7,9 @@ import * as Intercom from "../../../../index";
|
|
|
7
7
|
* {
|
|
8
8
|
* conversation_id: "123",
|
|
9
9
|
* body: {
|
|
10
|
-
* message_type: "
|
|
10
|
+
* message_type: "close",
|
|
11
11
|
* type: "admin",
|
|
12
|
-
* admin_id: "12345"
|
|
13
|
-
* assignee_id: "4324241",
|
|
14
|
-
* body: "Goodbye :)"
|
|
12
|
+
* admin_id: "12345"
|
|
15
13
|
* }
|
|
16
14
|
* }
|
|
17
15
|
*
|
|
@@ -19,11 +17,9 @@ import * as Intercom from "../../../../index";
|
|
|
19
17
|
* {
|
|
20
18
|
* conversation_id: "123",
|
|
21
19
|
* body: {
|
|
22
|
-
* message_type: "
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
* assignee_id: "4324241",
|
|
26
|
-
* body: "Let me pass you over to one of my colleagues."
|
|
20
|
+
* message_type: "snoozed",
|
|
21
|
+
* admin_id: "5017691",
|
|
22
|
+
* snoozed_until: 1673609604
|
|
27
23
|
* }
|
|
28
24
|
* }
|
|
29
25
|
*
|
|
@@ -31,11 +27,8 @@ import * as Intercom from "../../../../index";
|
|
|
31
27
|
* {
|
|
32
28
|
* conversation_id: "123",
|
|
33
29
|
* body: {
|
|
34
|
-
* message_type: "
|
|
35
|
-
*
|
|
36
|
-
* admin_id: "12345",
|
|
37
|
-
* assignee_id: "4324241",
|
|
38
|
-
* body: "Let me pass you over to one of my colleagues."
|
|
30
|
+
* message_type: "open",
|
|
31
|
+
* admin_id: "5017690"
|
|
39
32
|
* }
|
|
40
33
|
* }
|
|
41
34
|
*
|
|
@@ -46,8 +39,7 @@ import * as Intercom from "../../../../index";
|
|
|
46
39
|
* message_type: "assignment",
|
|
47
40
|
* type: "admin",
|
|
48
41
|
* admin_id: "12345",
|
|
49
|
-
* assignee_id: "4324241"
|
|
50
|
-
* body: "Let me pass you over to one of my colleagues."
|
|
42
|
+
* assignee_id: "4324241"
|
|
51
43
|
* }
|
|
52
44
|
* }
|
|
53
45
|
*
|
|
@@ -55,11 +47,9 @@ import * as Intercom from "../../../../index";
|
|
|
55
47
|
* {
|
|
56
48
|
* conversation_id: "123",
|
|
57
49
|
* body: {
|
|
58
|
-
* message_type: "
|
|
50
|
+
* message_type: "close",
|
|
59
51
|
* type: "admin",
|
|
60
|
-
* admin_id: "12345"
|
|
61
|
-
* assignee_id: "4324241",
|
|
62
|
-
* body: "Goodbye :)"
|
|
52
|
+
* admin_id: "12345"
|
|
63
53
|
* }
|
|
64
54
|
* }
|
|
65
55
|
*/
|
|
@@ -87,11 +87,11 @@ class DataAttributes {
|
|
|
87
87
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
88
88
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "data_attributes"),
|
|
89
89
|
method: "GET",
|
|
90
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
90
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
91
91
|
contentType: "application/json",
|
|
92
92
|
queryParameters: _queryParams,
|
|
93
93
|
requestType: "json",
|
|
94
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
94
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
95
95
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
96
96
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
97
97
|
});
|
|
@@ -183,11 +183,11 @@ class DataAttributes {
|
|
|
183
183
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
184
184
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "data_attributes"),
|
|
185
185
|
method: "POST",
|
|
186
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
186
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
187
187
|
contentType: "application/json",
|
|
188
188
|
requestType: "json",
|
|
189
189
|
body: request,
|
|
190
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
190
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
191
191
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
192
192
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
193
193
|
});
|
|
@@ -276,11 +276,11 @@ class DataAttributes {
|
|
|
276
276
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
277
277
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `data_attributes/${encodeURIComponent(dataAttributeId)}`),
|
|
278
278
|
method: "PUT",
|
|
279
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
279
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
280
280
|
contentType: "application/json",
|
|
281
281
|
requestType: "json",
|
|
282
282
|
body: _body,
|
|
283
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
283
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
284
284
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
285
285
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
286
286
|
});
|
|
@@ -82,11 +82,11 @@ class DataExport {
|
|
|
82
82
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
83
83
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "export/content/data"),
|
|
84
84
|
method: "POST",
|
|
85
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
85
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
86
86
|
contentType: "application/json",
|
|
87
87
|
requestType: "json",
|
|
88
88
|
body: request,
|
|
89
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
89
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
90
90
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
91
91
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
92
92
|
});
|
|
@@ -136,10 +136,10 @@ class DataExport {
|
|
|
136
136
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
137
137
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `export/content/data/${encodeURIComponent(jobIdentifier)}`),
|
|
138
138
|
method: "GET",
|
|
139
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
139
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
140
140
|
contentType: "application/json",
|
|
141
141
|
requestType: "json",
|
|
142
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
142
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
143
143
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
144
144
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
145
145
|
});
|
|
@@ -185,10 +185,10 @@ class DataExport {
|
|
|
185
185
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
186
186
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `export/cancel/${encodeURIComponent(jobIdentifier)}`),
|
|
187
187
|
method: "POST",
|
|
188
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
188
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
189
189
|
contentType: "application/json",
|
|
190
190
|
requestType: "json",
|
|
191
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
191
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
192
192
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
193
193
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
194
194
|
});
|
|
@@ -240,10 +240,10 @@ class DataExport {
|
|
|
240
240
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
241
241
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `download/content/data/${encodeURIComponent(jobIdentifier)}`),
|
|
242
242
|
method: "GET",
|
|
243
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
243
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
244
244
|
contentType: "application/json",
|
|
245
245
|
requestType: "json",
|
|
246
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
246
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
247
247
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
248
248
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
249
249
|
});
|
|
@@ -98,11 +98,11 @@ class Events {
|
|
|
98
98
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
99
99
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "events"),
|
|
100
100
|
method: "GET",
|
|
101
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
101
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
102
102
|
contentType: "application/json",
|
|
103
103
|
queryParameters: _queryParams,
|
|
104
104
|
requestType: "json",
|
|
105
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
105
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
106
106
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
107
107
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
108
108
|
});
|
|
@@ -197,11 +197,11 @@ class Events {
|
|
|
197
197
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
198
198
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "events"),
|
|
199
199
|
method: "POST",
|
|
200
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
200
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
201
201
|
contentType: "application/json",
|
|
202
202
|
requestType: "json",
|
|
203
203
|
body: request,
|
|
204
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
204
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
205
205
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
206
206
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
207
207
|
});
|
|
@@ -252,11 +252,11 @@ class Events {
|
|
|
252
252
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
253
253
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "events/summaries"),
|
|
254
254
|
method: "POST",
|
|
255
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
255
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
256
256
|
contentType: "application/json",
|
|
257
257
|
requestType: "json",
|
|
258
258
|
body: request,
|
|
259
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
259
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
260
260
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
261
261
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
262
262
|
});
|
|
@@ -74,10 +74,10 @@ class HelpCenters {
|
|
|
74
74
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
75
75
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `help_center/help_centers/${encodeURIComponent(helpCenterId)}`),
|
|
76
76
|
method: "GET",
|
|
77
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
77
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
78
78
|
contentType: "application/json",
|
|
79
79
|
requestType: "json",
|
|
80
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
80
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
81
81
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
82
82
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
83
83
|
});
|
|
@@ -138,11 +138,11 @@ class HelpCenters {
|
|
|
138
138
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
139
139
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "help_center/help_centers"),
|
|
140
140
|
method: "GET",
|
|
141
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.
|
|
141
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "6.1.0", "User-Agent": "intercom-client/6.1.0", "Intercom-Version": (_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.version) !== null && _e !== void 0 ? _e : "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
142
142
|
contentType: "application/json",
|
|
143
143
|
queryParameters: _queryParams,
|
|
144
144
|
requestType: "json",
|
|
145
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
145
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
146
146
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
147
147
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
148
148
|
});
|