intercom-client 6.0.0 → 6.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -30
- 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 +4 -11
- package/api/resources/conversations/client/Client.d.ts +28 -14
- package/api/resources/conversations/client/Client.js +52 -38
- 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.d.ts +0 -2
- package/api/resources/events/client/Client.js +6 -8
- 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.d.ts +0 -1
- package/api/resources/tags/client/Client.js +20 -21
- 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/ArticleList.d.ts +1 -1
- 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/CollectionList.d.ts +1 -1
- package/api/types/CompanyList.d.ts +1 -1
- 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/NoteList.d.ts +1 -1
- package/api/types/OffsetPages.d.ts +14 -0
- package/api/types/OffsetPages.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 +42 -1
- package/api/types/index.js +42 -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 +4 -11
- package/dist/api/resources/conversations/client/Client.d.ts +28 -14
- package/dist/api/resources/conversations/client/Client.js +52 -38
- 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.d.ts +0 -2
- package/dist/api/resources/events/client/Client.js +6 -8
- 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.d.ts +0 -1
- package/dist/api/resources/tags/client/Client.js +20 -21
- 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/ArticleList.d.ts +1 -1
- 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/CollectionList.d.ts +1 -1
- package/dist/api/types/CompanyList.d.ts +1 -1
- 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/NoteList.d.ts +1 -1
- package/dist/api/types/OffsetPages.d.ts +14 -0
- package/dist/api/types/OffsetPages.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 +42 -1
- package/dist/api/types/index.js +42 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +10 -2
- package/reference.md +12 -15
- 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
|
@@ -98,7 +98,6 @@ export declare class Events {
|
|
|
98
98
|
* - Event lists containing duplicate events will have those duplicates ignored.
|
|
99
99
|
* - Server errors will return a `500` response code and may contain an error message in the body.
|
|
100
100
|
*
|
|
101
|
-
*
|
|
102
101
|
* @param {Intercom.CreateDataEventRequest} request
|
|
103
102
|
* @param {Events.RequestOptions} requestOptions - Request-specific configuration.
|
|
104
103
|
*
|
|
@@ -115,7 +114,6 @@ export declare class Events {
|
|
|
115
114
|
/**
|
|
116
115
|
* Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred.
|
|
117
116
|
*
|
|
118
|
-
*
|
|
119
117
|
* @param {Intercom.ListEventSummariesRequest} request
|
|
120
118
|
* @param {Events.RequestOptions} requestOptions - Request-specific configuration.
|
|
121
119
|
*
|
|
@@ -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": "
|
|
101
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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
|
});
|
|
@@ -178,7 +178,6 @@ class Events {
|
|
|
178
178
|
* - Event lists containing duplicate events will have those duplicates ignored.
|
|
179
179
|
* - Server errors will return a `500` response code and may contain an error message in the body.
|
|
180
180
|
*
|
|
181
|
-
*
|
|
182
181
|
* @param {Intercom.CreateDataEventRequest} request
|
|
183
182
|
* @param {Events.RequestOptions} requestOptions - Request-specific configuration.
|
|
184
183
|
*
|
|
@@ -197,11 +196,11 @@ class Events {
|
|
|
197
196
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
198
197
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "events"),
|
|
199
198
|
method: "POST",
|
|
200
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
199
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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
200
|
contentType: "application/json",
|
|
202
201
|
requestType: "json",
|
|
203
202
|
body: request,
|
|
204
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
203
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
205
204
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
206
205
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
207
206
|
});
|
|
@@ -237,7 +236,6 @@ class Events {
|
|
|
237
236
|
/**
|
|
238
237
|
* Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred.
|
|
239
238
|
*
|
|
240
|
-
*
|
|
241
239
|
* @param {Intercom.ListEventSummariesRequest} request
|
|
242
240
|
* @param {Events.RequestOptions} requestOptions - Request-specific configuration.
|
|
243
241
|
*
|
|
@@ -252,11 +250,11 @@ class Events {
|
|
|
252
250
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
253
251
|
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
252
|
method: "POST",
|
|
255
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
253
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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
254
|
contentType: "application/json",
|
|
257
255
|
requestType: "json",
|
|
258
256
|
body: request,
|
|
259
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
257
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
260
258
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
261
259
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
262
260
|
});
|
|
@@ -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": "
|
|
77
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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": "
|
|
141
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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
|
});
|
|
@@ -87,11 +87,11 @@ class Collections {
|
|
|
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, "help_center/collections"),
|
|
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": "
|
|
90
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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
|
});
|
|
@@ -161,11 +161,11 @@ class Collections {
|
|
|
161
161
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
162
162
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "help_center/collections"),
|
|
163
163
|
method: "POST",
|
|
164
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
164
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
165
165
|
contentType: "application/json",
|
|
166
166
|
requestType: "json",
|
|
167
167
|
body: request,
|
|
168
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
168
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
169
169
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
170
170
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
171
171
|
});
|
|
@@ -221,10 +221,10 @@ class Collections {
|
|
|
221
221
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
222
222
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `help_center/collections/${encodeURIComponent(collectionId)}`),
|
|
223
223
|
method: "GET",
|
|
224
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
224
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
225
225
|
contentType: "application/json",
|
|
226
226
|
requestType: "json",
|
|
227
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
227
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
228
228
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
229
229
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
230
230
|
});
|
|
@@ -281,11 +281,11 @@ class Collections {
|
|
|
281
281
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
282
282
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `help_center/collections/${encodeURIComponent(collectionId)}`),
|
|
283
283
|
method: "PUT",
|
|
284
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
284
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
285
285
|
contentType: "application/json",
|
|
286
286
|
requestType: "json",
|
|
287
287
|
body: _body,
|
|
288
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
288
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
289
289
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
290
290
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
291
291
|
});
|
|
@@ -341,10 +341,10 @@ class Collections {
|
|
|
341
341
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
342
342
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `help_center/collections/${encodeURIComponent(collectionId)}`),
|
|
343
343
|
method: "DELETE",
|
|
344
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
344
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
345
345
|
contentType: "application/json",
|
|
346
346
|
requestType: "json",
|
|
347
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
347
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
348
348
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
349
349
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
350
350
|
});
|
|
@@ -32,8 +32,6 @@ export * as helpCenter from "./helpCenter";
|
|
|
32
32
|
export * from "./helpCenter/types";
|
|
33
33
|
export * as aiContentSource from "./aiContentSource";
|
|
34
34
|
export * from "./aiContentSource/types";
|
|
35
|
-
export * as customObjectInstances from "./customObjectInstances";
|
|
36
|
-
export * from "./customObjectInstances/types";
|
|
37
35
|
export * as dataEvents from "./dataEvents";
|
|
38
36
|
export * from "./dataEvents/types";
|
|
39
37
|
export * as news from "./news";
|
|
@@ -26,7 +26,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
26
26
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.visitors = exports.ticketTypes = exports.phoneCallRedirects = exports.events = exports.helpCenters = exports.news = exports.dataEvents = exports.
|
|
29
|
+
exports.visitors = exports.ticketTypes = exports.phoneCallRedirects = exports.events = exports.helpCenters = exports.news = exports.dataEvents = exports.aiContentSource = exports.helpCenter = exports.aiAgent = exports.tickets = exports.teams = exports.subscriptionTypes = exports.segments = exports.messages = exports.dataExport = exports.dataAttributes = exports.conversations = exports.tags = exports.notes = exports.contacts = exports.companies = exports.articles = exports.admins = void 0;
|
|
30
30
|
exports.admins = __importStar(require("./admins"));
|
|
31
31
|
__exportStar(require("./admins/types"), exports);
|
|
32
32
|
exports.articles = __importStar(require("./articles"));
|
|
@@ -61,8 +61,6 @@ exports.helpCenter = __importStar(require("./helpCenter"));
|
|
|
61
61
|
__exportStar(require("./helpCenter/types"), exports);
|
|
62
62
|
exports.aiContentSource = __importStar(require("./aiContentSource"));
|
|
63
63
|
__exportStar(require("./aiContentSource/types"), exports);
|
|
64
|
-
exports.customObjectInstances = __importStar(require("./customObjectInstances"));
|
|
65
|
-
__exportStar(require("./customObjectInstances/types"), exports);
|
|
66
64
|
exports.dataEvents = __importStar(require("./dataEvents"));
|
|
67
65
|
__exportStar(require("./dataEvents/types"), exports);
|
|
68
66
|
exports.news = __importStar(require("./news"));
|
|
@@ -54,9 +54,9 @@ export declare class Messages {
|
|
|
54
54
|
*
|
|
55
55
|
* @example
|
|
56
56
|
* await client.messages.create({
|
|
57
|
-
* message_type: "
|
|
57
|
+
* message_type: "email",
|
|
58
58
|
* subject: "Thanks for everything",
|
|
59
|
-
* body: "
|
|
59
|
+
* body: "Hello there",
|
|
60
60
|
* template: "plain",
|
|
61
61
|
* from: {
|
|
62
62
|
* type: "admin",
|
|
@@ -65,27 +65,7 @@ export declare class Messages {
|
|
|
65
65
|
* to: {
|
|
66
66
|
* type: "user",
|
|
67
67
|
* id: "536e564f316c83104c000020"
|
|
68
|
-
* }
|
|
69
|
-
* created_at: 1590000000,
|
|
70
|
-
* create_conversation_without_contact_reply: true
|
|
71
|
-
* })
|
|
72
|
-
*
|
|
73
|
-
* @example
|
|
74
|
-
* await client.messages.create({
|
|
75
|
-
* message_type: "inapp",
|
|
76
|
-
* subject: "Thanks for everything",
|
|
77
|
-
* body: "heyy",
|
|
78
|
-
* template: "plain",
|
|
79
|
-
* from: {
|
|
80
|
-
* type: "admin",
|
|
81
|
-
* id: 394051
|
|
82
|
-
* },
|
|
83
|
-
* to: {
|
|
84
|
-
* type: "user",
|
|
85
|
-
* id: "667d616c8a68186f43bafe52"
|
|
86
|
-
* },
|
|
87
|
-
* created_at: 1590000000,
|
|
88
|
-
* create_conversation_without_contact_reply: true
|
|
68
|
+
* }
|
|
89
69
|
* })
|
|
90
70
|
*
|
|
91
71
|
* @example
|
|
@@ -74,9 +74,9 @@ class Messages {
|
|
|
74
74
|
*
|
|
75
75
|
* @example
|
|
76
76
|
* await client.messages.create({
|
|
77
|
-
* message_type: "
|
|
77
|
+
* message_type: "email",
|
|
78
78
|
* subject: "Thanks for everything",
|
|
79
|
-
* body: "
|
|
79
|
+
* body: "Hello there",
|
|
80
80
|
* template: "plain",
|
|
81
81
|
* from: {
|
|
82
82
|
* type: "admin",
|
|
@@ -85,27 +85,7 @@ class Messages {
|
|
|
85
85
|
* to: {
|
|
86
86
|
* type: "user",
|
|
87
87
|
* id: "536e564f316c83104c000020"
|
|
88
|
-
* }
|
|
89
|
-
* created_at: 1590000000,
|
|
90
|
-
* create_conversation_without_contact_reply: true
|
|
91
|
-
* })
|
|
92
|
-
*
|
|
93
|
-
* @example
|
|
94
|
-
* await client.messages.create({
|
|
95
|
-
* message_type: "inapp",
|
|
96
|
-
* subject: "Thanks for everything",
|
|
97
|
-
* body: "heyy",
|
|
98
|
-
* template: "plain",
|
|
99
|
-
* from: {
|
|
100
|
-
* type: "admin",
|
|
101
|
-
* id: 394051
|
|
102
|
-
* },
|
|
103
|
-
* to: {
|
|
104
|
-
* type: "user",
|
|
105
|
-
* id: "667d616c8a68186f43bafe52"
|
|
106
|
-
* },
|
|
107
|
-
* created_at: 1590000000,
|
|
108
|
-
* create_conversation_without_contact_reply: true
|
|
88
|
+
* }
|
|
109
89
|
* })
|
|
110
90
|
*
|
|
111
91
|
* @example
|
|
@@ -168,11 +148,11 @@ class Messages {
|
|
|
168
148
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
169
149
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "messages"),
|
|
170
150
|
method: "POST",
|
|
171
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
151
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
172
152
|
contentType: "application/json",
|
|
173
153
|
requestType: "json",
|
|
174
154
|
body: request,
|
|
175
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
155
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
176
156
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
177
157
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
178
158
|
});
|
|
@@ -68,10 +68,10 @@ class Feeds {
|
|
|
68
68
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
69
69
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `news/newsfeeds/${encodeURIComponent(newsfeedId)}/items`),
|
|
70
70
|
method: "GET",
|
|
71
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
71
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
72
72
|
contentType: "application/json",
|
|
73
73
|
requestType: "json",
|
|
74
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
74
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
75
75
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
76
76
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
77
77
|
});
|
|
@@ -120,10 +120,10 @@ class Feeds {
|
|
|
120
120
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
121
121
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "news/newsfeeds"),
|
|
122
122
|
method: "GET",
|
|
123
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
123
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
124
124
|
contentType: "application/json",
|
|
125
125
|
requestType: "json",
|
|
126
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
126
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
127
127
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
128
128
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
129
129
|
});
|
|
@@ -176,10 +176,10 @@ class Feeds {
|
|
|
176
176
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
177
177
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `news/newsfeeds/${encodeURIComponent(newsfeedId)}`),
|
|
178
178
|
method: "GET",
|
|
179
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
179
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
180
180
|
contentType: "application/json",
|
|
181
181
|
requestType: "json",
|
|
182
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
182
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
183
183
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
184
184
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
185
185
|
});
|
|
@@ -64,10 +64,10 @@ class Items {
|
|
|
64
64
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
65
65
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "news/news_items"),
|
|
66
66
|
method: "GET",
|
|
67
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
67
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
68
68
|
contentType: "application/json",
|
|
69
69
|
requestType: "json",
|
|
70
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
70
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
71
71
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
72
72
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
73
73
|
});
|
|
@@ -129,11 +129,11 @@ class Items {
|
|
|
129
129
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
130
130
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "news/news_items"),
|
|
131
131
|
method: "POST",
|
|
132
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
132
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
133
133
|
contentType: "application/json",
|
|
134
134
|
requestType: "json",
|
|
135
135
|
body: request,
|
|
136
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
136
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
137
137
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
138
138
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
139
139
|
});
|
|
@@ -187,10 +187,10 @@ class Items {
|
|
|
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, `news/news_items/${encodeURIComponent(newsItemId)}`),
|
|
189
189
|
method: "GET",
|
|
190
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
190
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
193
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
194
194
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
195
195
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
196
196
|
});
|
|
@@ -261,11 +261,11 @@ class Items {
|
|
|
261
261
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
262
262
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `news/news_items/${encodeURIComponent(newsItemId)}`),
|
|
263
263
|
method: "PUT",
|
|
264
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
264
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
265
265
|
contentType: "application/json",
|
|
266
266
|
requestType: "json",
|
|
267
267
|
body: _body,
|
|
268
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
268
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
269
269
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
270
270
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
271
271
|
});
|
|
@@ -321,10 +321,10 @@ class Items {
|
|
|
321
321
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
322
322
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `news/news_items/${encodeURIComponent(newsItemId)}`),
|
|
323
323
|
method: "DELETE",
|
|
324
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
324
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
325
325
|
contentType: "application/json",
|
|
326
326
|
requestType: "json",
|
|
327
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
327
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
328
328
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
329
329
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
330
330
|
});
|
|
@@ -90,11 +90,11 @@ class Notes {
|
|
|
90
90
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
91
91
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `contacts/${encodeURIComponent(contactId)}/notes`),
|
|
92
92
|
method: "GET",
|
|
93
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
93
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
94
94
|
contentType: "application/json",
|
|
95
95
|
queryParameters: _queryParams,
|
|
96
96
|
requestType: "json",
|
|
97
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
97
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
98
98
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
99
99
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
100
100
|
});
|
|
@@ -160,11 +160,11 @@ class Notes {
|
|
|
160
160
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
161
161
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `contacts/${encodeURIComponent(contactId)}/notes`),
|
|
162
162
|
method: "POST",
|
|
163
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
163
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
164
164
|
contentType: "application/json",
|
|
165
165
|
requestType: "json",
|
|
166
166
|
body: _body,
|
|
167
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
167
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
168
168
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
169
169
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
170
170
|
});
|
|
@@ -218,10 +218,10 @@ class Notes {
|
|
|
218
218
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
219
219
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `notes/${encodeURIComponent(noteId)}`),
|
|
220
220
|
method: "GET",
|
|
221
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
221
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
222
222
|
contentType: "application/json",
|
|
223
223
|
requestType: "json",
|
|
224
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
224
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
225
225
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
226
226
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
227
227
|
});
|
|
@@ -85,11 +85,11 @@ class PhoneCallRedirects {
|
|
|
85
85
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
86
86
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "phone_call_redirects"),
|
|
87
87
|
method: "POST",
|
|
88
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
88
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
89
89
|
contentType: "application/json",
|
|
90
90
|
requestType: "json",
|
|
91
91
|
body: request,
|
|
92
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
92
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
93
93
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
94
94
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
95
95
|
});
|
|
@@ -73,11 +73,11 @@ class Segments {
|
|
|
73
73
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
74
74
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "segments"),
|
|
75
75
|
method: "GET",
|
|
76
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
76
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
77
77
|
contentType: "application/json",
|
|
78
78
|
queryParameters: _queryParams,
|
|
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
|
});
|
|
@@ -131,10 +131,10 @@ class Segments {
|
|
|
131
131
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
132
132
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, `segments/${encodeURIComponent(segmentId)}`),
|
|
133
133
|
method: "GET",
|
|
134
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
134
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
135
135
|
contentType: "application/json",
|
|
136
136
|
requestType: "json",
|
|
137
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
137
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
138
138
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
139
139
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
140
140
|
});
|
|
@@ -67,10 +67,10 @@ class SubscriptionTypes {
|
|
|
67
67
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
68
68
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.IntercomEnvironment.UsProduction, "subscription_types"),
|
|
69
69
|
method: "GET",
|
|
70
|
-
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "
|
|
70
|
+
headers: Object.assign({ Authorization: yield this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", "X-Fern-SDK-Version": "v6.1.1", "User-Agent": "intercom-client/v6.1.1", "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),
|
|
71
71
|
contentType: "application/json",
|
|
72
72
|
requestType: "json",
|
|
73
|
-
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 :
|
|
73
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 20000,
|
|
74
74
|
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
75
75
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
76
76
|
});
|