hume 0.9.8 → 0.9.10
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/.mock/definition/empathic-voice/__package__.yml +121 -48
- package/.mock/definition/empathic-voice/chatGroups.yml +16 -14
- package/.mock/definition/empathic-voice/chatWebhooks.yml +21 -0
- package/.mock/definition/empathic-voice/chats.yml +5 -0
- package/.mock/definition/empathic-voice/configs.yml +6 -0
- package/Client.d.ts +1 -3
- package/Client.js +1 -3
- package/api/resources/empathicVoice/client/Client.d.ts +4 -3
- package/api/resources/empathicVoice/client/Client.js +14 -11
- package/api/resources/empathicVoice/resources/chat/client/Client.d.ts +1 -0
- package/api/resources/empathicVoice/resources/chat/client/Client.js +1 -0
- package/api/resources/empathicVoice/resources/chat/client/Socket.d.ts +1 -0
- package/api/resources/empathicVoice/resources/chat/client/Socket.js +1 -0
- package/api/resources/empathicVoice/resources/chat/client/index.d.ts +1 -0
- package/api/resources/empathicVoice/resources/chat/client/index.js +1 -0
- package/api/resources/empathicVoice/resources/chat/index.d.ts +1 -0
- package/api/resources/empathicVoice/resources/chat/index.js +1 -0
- package/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +1 -1
- package/api/resources/empathicVoice/resources/chatGroups/client/Client.js +5 -5
- package/api/resources/empathicVoice/resources/chatGroups/client/requests/ChatGroupsGetAudioRequest.d.ts +5 -5
- package/api/resources/empathicVoice/resources/chats/client/Client.js +7 -4
- package/api/resources/empathicVoice/resources/chats/client/requests/ChatsListChatsRequest.d.ts +4 -0
- package/api/resources/empathicVoice/resources/configs/client/Client.js +9 -9
- package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +2 -0
- package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +2 -0
- package/api/resources/empathicVoice/resources/customVoices/client/Client.js +6 -6
- package/api/resources/empathicVoice/resources/prompts/client/Client.js +9 -9
- package/api/resources/empathicVoice/resources/tools/client/Client.js +9 -9
- package/api/resources/empathicVoice/types/PostedWebhookEventType.d.ts +11 -0
- package/api/resources/empathicVoice/types/PostedWebhookEventType.js +10 -0
- package/api/resources/empathicVoice/types/PostedWebhookSpec.d.ts +13 -0
- package/api/resources/empathicVoice/types/ReturnChatGroup.d.ts +2 -0
- package/api/resources/empathicVoice/types/ReturnConfig.d.ts +2 -0
- package/api/resources/empathicVoice/types/ReturnWebhookEventType.d.ts +11 -0
- package/api/resources/empathicVoice/types/ReturnWebhookEventType.js +10 -0
- package/api/resources/empathicVoice/types/ReturnWebhookSpec.d.ts +13 -0
- package/api/resources/empathicVoice/types/WebhookEvent.d.ts +5 -0
- package/api/resources/empathicVoice/types/WebhookEventBase.d.ts +14 -0
- package/api/resources/empathicVoice/types/WebhookEventChatEnded.d.ts +13 -0
- package/api/resources/empathicVoice/types/WebhookEventChatEnded.js +5 -0
- package/api/resources/empathicVoice/types/WebhookEventChatStartType.d.ts +8 -0
- package/api/resources/empathicVoice/types/WebhookEventChatStartType.js +10 -0
- package/api/resources/empathicVoice/types/WebhookEventChatStarted.d.ts +16 -0
- package/api/resources/empathicVoice/types/WebhookEventChatStarted.js +5 -0
- package/api/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +12 -0
- package/api/resources/empathicVoice/types/WebhookEventChatStatus.js +14 -0
- package/api/resources/empathicVoice/types/index.d.ts +10 -3
- package/api/resources/empathicVoice/types/index.js +10 -3
- package/api/resources/expressionMeasurement/resources/batch/client/Client.js +6 -6
- package/api/resources/index.d.ts +1 -1
- package/api/resources/index.js +2 -2
- package/core/fetcher/Supplier.d.ts +1 -0
- package/core/index.d.ts +1 -0
- package/core/index.js +1 -0
- package/core/websocket/events.d.ts +1 -0
- package/core/websocket/events.js +1 -0
- package/core/websocket/index.d.ts +1 -0
- package/core/websocket/index.js +1 -0
- package/core/websocket/ws.js +1 -0
- package/dist/Client.d.ts +1 -3
- package/dist/Client.js +1 -3
- package/dist/api/resources/empathicVoice/client/Client.d.ts +4 -3
- package/dist/api/resources/empathicVoice/client/Client.js +14 -11
- package/dist/api/resources/empathicVoice/resources/chat/client/Client.d.ts +1 -0
- package/dist/api/resources/empathicVoice/resources/chat/client/Client.js +1 -0
- package/dist/api/resources/empathicVoice/resources/chat/client/Socket.d.ts +1 -0
- package/dist/api/resources/empathicVoice/resources/chat/client/Socket.js +1 -0
- package/dist/api/resources/empathicVoice/resources/chat/client/index.d.ts +1 -0
- package/dist/api/resources/empathicVoice/resources/chat/client/index.js +1 -0
- package/dist/api/resources/empathicVoice/resources/chat/index.d.ts +1 -0
- package/dist/api/resources/empathicVoice/resources/chat/index.js +1 -0
- package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +1 -1
- package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.js +5 -5
- package/dist/api/resources/empathicVoice/resources/chatGroups/client/requests/ChatGroupsGetAudioRequest.d.ts +5 -5
- package/dist/api/resources/empathicVoice/resources/chats/client/Client.js +7 -4
- package/dist/api/resources/empathicVoice/resources/chats/client/requests/ChatsListChatsRequest.d.ts +4 -0
- package/dist/api/resources/empathicVoice/resources/configs/client/Client.js +9 -9
- package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +2 -0
- package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +2 -0
- package/dist/api/resources/empathicVoice/resources/customVoices/client/Client.js +6 -6
- package/dist/api/resources/empathicVoice/resources/prompts/client/Client.js +9 -9
- package/dist/api/resources/empathicVoice/resources/tools/client/Client.js +9 -9
- package/dist/api/resources/empathicVoice/types/PostedWebhookEventType.d.ts +11 -0
- package/dist/api/resources/empathicVoice/types/PostedWebhookEventType.js +10 -0
- package/dist/api/resources/empathicVoice/types/PostedWebhookSpec.d.ts +13 -0
- package/dist/api/resources/empathicVoice/types/PostedWebhookSpec.js +5 -0
- package/dist/api/resources/empathicVoice/types/ReturnChatGroup.d.ts +2 -0
- package/dist/api/resources/empathicVoice/types/ReturnConfig.d.ts +2 -0
- package/dist/api/resources/empathicVoice/types/ReturnWebhookEventType.d.ts +11 -0
- package/dist/api/resources/empathicVoice/types/ReturnWebhookEventType.js +10 -0
- package/dist/api/resources/empathicVoice/types/ReturnWebhookSpec.d.ts +13 -0
- package/dist/api/resources/empathicVoice/types/ReturnWebhookSpec.js +5 -0
- package/dist/api/resources/empathicVoice/types/WebhookEvent.d.ts +5 -0
- package/dist/api/resources/empathicVoice/types/WebhookEvent.js +5 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventBase.d.ts +14 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventBase.js +5 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatEnded.d.ts +13 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatEnded.js +5 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStartType.d.ts +8 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStartType.js +10 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStarted.d.ts +16 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStarted.js +5 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +12 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStatus.js +14 -0
- package/dist/api/resources/empathicVoice/types/index.d.ts +10 -3
- package/dist/api/resources/empathicVoice/types/index.js +10 -3
- package/dist/api/resources/expressionMeasurement/resources/batch/client/Client.js +6 -6
- package/dist/api/resources/index.d.ts +1 -1
- package/dist/api/resources/index.js +2 -2
- package/dist/core/fetcher/Supplier.d.ts +1 -0
- package/dist/core/index.d.ts +1 -0
- package/dist/core/index.js +1 -0
- package/dist/core/websocket/events.d.ts +1 -0
- package/dist/core/websocket/events.js +1 -0
- package/dist/core/websocket/index.d.ts +1 -0
- package/dist/core/websocket/index.js +1 -0
- package/dist/core/websocket/ws.js +1 -0
- package/dist/errors/HumeError.d.ts +1 -3
- package/dist/errors/HumeError.js +1 -3
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +2 -0
- package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.js +2 -0
- package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +2 -0
- package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.js +2 -0
- package/dist/serialization/resources/empathicVoice/types/PostedWebhookEventType.d.ts +10 -0
- package/{serialization/resources/empathicVoice/types/ReturnActiveChatCountPerTag.js → dist/serialization/resources/empathicVoice/types/PostedWebhookEventType.js} +2 -5
- package/dist/serialization/resources/empathicVoice/types/PostedWebhookSpec.d.ts +14 -0
- package/dist/serialization/resources/empathicVoice/types/PostedWebhookSpec.js +35 -0
- package/dist/serialization/resources/empathicVoice/types/ReturnChatGroup.d.ts +2 -0
- package/dist/serialization/resources/empathicVoice/types/ReturnChatGroup.js +2 -0
- package/dist/serialization/resources/empathicVoice/types/ReturnConfig.d.ts +2 -0
- package/dist/serialization/resources/empathicVoice/types/ReturnConfig.js +2 -0
- package/dist/serialization/resources/empathicVoice/types/ReturnWebhookEventType.d.ts +10 -0
- package/dist/serialization/resources/empathicVoice/types/{ReturnActiveChatCountPerTag.js → ReturnWebhookEventType.js} +2 -5
- package/dist/serialization/resources/empathicVoice/types/ReturnWebhookSpec.d.ts +14 -0
- package/dist/serialization/resources/empathicVoice/types/ReturnWebhookSpec.js +35 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEvent.d.ts +12 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEvent.js +33 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEventBase.d.ts +14 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEventBase.js +35 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEventChatEnded.d.ts +19 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEventChatEnded.js +42 -0
- package/dist/serialization/resources/empathicVoice/types/{VoiceNameEnum.d.ts → WebhookEventChatStartType.d.ts} +3 -3
- package/dist/serialization/resources/empathicVoice/types/WebhookEventChatStartType.js +31 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEventChatStarted.d.ts +18 -0
- package/dist/serialization/resources/empathicVoice/types/{ReturnActiveChatCount.js → WebhookEventChatStarted.js} +12 -9
- package/dist/serialization/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +10 -0
- package/dist/serialization/resources/empathicVoice/types/{VoiceNameEnum.js → WebhookEventChatStatus.js} +8 -16
- package/dist/serialization/resources/empathicVoice/types/index.d.ts +10 -3
- package/dist/serialization/resources/empathicVoice/types/index.js +10 -3
- package/dist/serialization/resources/index.d.ts +1 -1
- package/dist/serialization/resources/index.js +2 -2
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/wrapper/convertBase64ToBlob.d.ts +1 -1
- package/errors/HumeError.d.ts +1 -3
- package/errors/HumeError.js +1 -3
- package/index.d.ts +1 -0
- package/index.js +1 -0
- package/package.json +1 -1
- package/reference.md +538 -538
- package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +2 -0
- package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.js +2 -0
- package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +2 -0
- package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.js +2 -0
- package/serialization/resources/empathicVoice/types/PostedWebhookEventType.d.ts +10 -0
- package/serialization/resources/empathicVoice/types/PostedWebhookEventType.js +31 -0
- package/serialization/resources/empathicVoice/types/PostedWebhookSpec.d.ts +14 -0
- package/serialization/resources/empathicVoice/types/PostedWebhookSpec.js +35 -0
- package/serialization/resources/empathicVoice/types/ReturnChatGroup.d.ts +2 -0
- package/serialization/resources/empathicVoice/types/ReturnChatGroup.js +2 -0
- package/serialization/resources/empathicVoice/types/ReturnConfig.d.ts +2 -0
- package/serialization/resources/empathicVoice/types/ReturnConfig.js +2 -0
- package/serialization/resources/empathicVoice/types/ReturnWebhookEventType.d.ts +10 -0
- package/serialization/resources/empathicVoice/types/ReturnWebhookEventType.js +31 -0
- package/serialization/resources/empathicVoice/types/ReturnWebhookSpec.d.ts +14 -0
- package/serialization/resources/empathicVoice/types/ReturnWebhookSpec.js +35 -0
- package/serialization/resources/empathicVoice/types/WebhookEvent.d.ts +12 -0
- package/serialization/resources/empathicVoice/types/WebhookEvent.js +33 -0
- package/serialization/resources/empathicVoice/types/WebhookEventBase.d.ts +14 -0
- package/serialization/resources/empathicVoice/types/WebhookEventBase.js +35 -0
- package/serialization/resources/empathicVoice/types/WebhookEventChatEnded.d.ts +19 -0
- package/serialization/resources/empathicVoice/types/WebhookEventChatEnded.js +42 -0
- package/serialization/resources/empathicVoice/types/{VoiceNameEnum.d.ts → WebhookEventChatStartType.d.ts} +3 -3
- package/serialization/resources/empathicVoice/types/WebhookEventChatStartType.js +31 -0
- package/serialization/resources/empathicVoice/types/WebhookEventChatStarted.d.ts +18 -0
- package/serialization/resources/empathicVoice/types/{ReturnActiveChatCount.js → WebhookEventChatStarted.js} +12 -9
- package/serialization/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +10 -0
- package/serialization/resources/empathicVoice/types/{VoiceNameEnum.js → WebhookEventChatStatus.js} +8 -16
- package/serialization/resources/empathicVoice/types/index.d.ts +10 -3
- package/serialization/resources/empathicVoice/types/index.js +10 -3
- package/serialization/resources/index.d.ts +1 -1
- package/serialization/resources/index.js +2 -2
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/wrapper/convertBase64ToBlob.d.ts +1 -1
- package/api/resources/empathicVoice/types/ReturnActiveChatCount.d.ts +0 -19
- package/api/resources/empathicVoice/types/ReturnActiveChatCountPerTag.d.ts +0 -12
- package/api/resources/empathicVoice/types/VoiceNameEnum.d.ts +0 -20
- package/api/resources/empathicVoice/types/VoiceNameEnum.js +0 -22
- package/dist/api/resources/empathicVoice/types/ReturnActiveChatCount.d.ts +0 -19
- package/dist/api/resources/empathicVoice/types/ReturnActiveChatCountPerTag.d.ts +0 -12
- package/dist/api/resources/empathicVoice/types/VoiceNameEnum.d.ts +0 -20
- package/dist/api/resources/empathicVoice/types/VoiceNameEnum.js +0 -22
- package/dist/serialization/resources/empathicVoice/types/ReturnActiveChatCount.d.ts +0 -17
- package/dist/serialization/resources/empathicVoice/types/ReturnActiveChatCountPerTag.d.ts +0 -13
- package/serialization/resources/empathicVoice/types/ReturnActiveChatCount.d.ts +0 -17
- package/serialization/resources/empathicVoice/types/ReturnActiveChatCountPerTag.d.ts +0 -13
- /package/api/resources/empathicVoice/types/{ReturnActiveChatCount.js → PostedWebhookSpec.js} +0 -0
- /package/api/resources/empathicVoice/types/{ReturnActiveChatCountPerTag.js → ReturnWebhookSpec.js} +0 -0
- /package/{dist/api/resources/empathicVoice/types/ReturnActiveChatCount.js → api/resources/empathicVoice/types/WebhookEvent.js} +0 -0
- /package/{dist/api/resources/empathicVoice/types/ReturnActiveChatCountPerTag.js → api/resources/empathicVoice/types/WebhookEventBase.js} +0 -0
|
@@ -88,7 +88,7 @@ class Batch {
|
|
|
88
88
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
89
89
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, "v0/batch/jobs"),
|
|
90
90
|
method: "GET",
|
|
91
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.
|
|
91
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.10", "User-Agent": "hume/0.9.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
92
92
|
contentType: "application/json",
|
|
93
93
|
queryParameters: _queryParams,
|
|
94
94
|
requestType: "json",
|
|
@@ -143,7 +143,7 @@ class Batch {
|
|
|
143
143
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
144
144
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, "v0/batch/jobs"),
|
|
145
145
|
method: "POST",
|
|
146
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.
|
|
146
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.10", "User-Agent": "hume/0.9.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
147
147
|
contentType: "application/json",
|
|
148
148
|
requestType: "json",
|
|
149
149
|
body: serializers.expressionMeasurement.batch.InferenceBaseRequest.jsonOrThrow(request, {
|
|
@@ -197,7 +197,7 @@ class Batch {
|
|
|
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.HumeEnvironment.Production, `v0/batch/jobs/${encodeURIComponent(id)}`),
|
|
199
199
|
method: "GET",
|
|
200
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.
|
|
200
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.10", "User-Agent": "hume/0.9.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
201
201
|
contentType: "application/json",
|
|
202
202
|
requestType: "json",
|
|
203
203
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -248,7 +248,7 @@ class Batch {
|
|
|
248
248
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
249
249
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, `v0/batch/jobs/${encodeURIComponent(id)}/predictions`),
|
|
250
250
|
method: "GET",
|
|
251
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.
|
|
251
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.10", "User-Agent": "hume/0.9.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
252
252
|
contentType: "application/json",
|
|
253
253
|
requestType: "json",
|
|
254
254
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -293,7 +293,7 @@ class Batch {
|
|
|
293
293
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
294
294
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, `v0/batch/jobs/${encodeURIComponent(id)}/artifacts`),
|
|
295
295
|
method: "GET",
|
|
296
|
-
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.
|
|
296
|
+
headers: Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.10", "User-Agent": "hume/0.9.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())),
|
|
297
297
|
contentType: "application/json",
|
|
298
298
|
requestType: "json",
|
|
299
299
|
responseType: "streaming",
|
|
@@ -349,7 +349,7 @@ class Batch {
|
|
|
349
349
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
350
350
|
url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.HumeEnvironment.Production, "v0/batch/jobs"),
|
|
351
351
|
method: "POST",
|
|
352
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.
|
|
352
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.9.10", "User-Agent": "hume/0.9.10", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), _maybeEncodedRequest.headers),
|
|
353
353
|
requestType: "file",
|
|
354
354
|
duplex: _maybeEncodedRequest.duplex,
|
|
355
355
|
body: _maybeEncodedRequest.body,
|
|
@@ -23,6 +23,6 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.
|
|
27
|
-
exports.empathicVoice = __importStar(require("./empathicVoice"));
|
|
26
|
+
exports.empathicVoice = exports.expressionMeasurement = void 0;
|
|
28
27
|
exports.expressionMeasurement = __importStar(require("./expressionMeasurement"));
|
|
28
|
+
exports.empathicVoice = __importStar(require("./empathicVoice"));
|
package/dist/core/index.d.ts
CHANGED
package/dist/core/index.js
CHANGED
|
@@ -27,6 +27,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
29
|
exports.serialization = void 0;
|
|
30
|
+
/** THIS FILE IS MANUALLY MAINAINED: see .fernignore */
|
|
30
31
|
__exportStar(require("./fetcher"), exports);
|
|
31
32
|
__exportStar(require("./runtime"), exports);
|
|
32
33
|
__exportStar(require("./form-data-utils"), exports);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CloseEvent = exports.ErrorEvent = exports.Event = void 0;
|
|
4
|
+
/** THIS FILE IS MANUALLY MAINAINED: see .fernignore */
|
|
4
5
|
class Event {
|
|
5
6
|
constructor(type, target) {
|
|
6
7
|
this.target = target;
|
|
@@ -14,4 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
/** THIS FILE IS MANUALLY MAINAINED: see .fernignore */
|
|
17
18
|
__exportStar(require("./ws"), exports);
|
|
@@ -24,6 +24,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.ReconnectingWebSocket = void 0;
|
|
27
|
+
/** THIS FILE IS MANUALLY MAINAINED: see .fernignore */
|
|
27
28
|
const runtime_1 = require("../runtime");
|
|
28
29
|
const Events = __importStar(require("./events"));
|
|
29
30
|
const ws_1 = require("ws");
|
package/dist/errors/HumeError.js
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
-
*/
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
3
|
exports.HumeError = void 0;
|
|
4
|
+
/** THIS FILE IS MANUALLY MAINAINED: see .fernignore */
|
|
7
5
|
class HumeError extends Error {
|
|
8
6
|
constructor({ message, statusCode, body }) {
|
|
9
7
|
super(buildMessage({ message, statusCode, body }));
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -27,6 +27,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
29
|
exports.HumeTimeoutError = exports.HumeError = exports.HumeEnvironment = exports.Hume = void 0;
|
|
30
|
+
/** THIS FILE IS MANUALLY MAINAINED: see .fernignore */
|
|
30
31
|
exports.Hume = __importStar(require("./api"));
|
|
31
32
|
__exportStar(require("./wrapper"), exports);
|
|
32
33
|
var environments_1 = require("./environments");
|
|
@@ -12,6 +12,7 @@ import { PostedUserDefinedToolSpec } from "../../../../types/PostedUserDefinedTo
|
|
|
12
12
|
import { PostedBuiltinTool } from "../../../../types/PostedBuiltinTool";
|
|
13
13
|
import { PostedEventMessageSpecs } from "../../../../types/PostedEventMessageSpecs";
|
|
14
14
|
import { PostedTimeoutSpecs } from "../../../../types/PostedTimeoutSpecs";
|
|
15
|
+
import { PostedWebhookSpec } from "../../../../types/PostedWebhookSpec";
|
|
15
16
|
export declare const PostedConfig: core.serialization.Schema<serializers.empathicVoice.PostedConfig.Raw, Hume.empathicVoice.PostedConfig>;
|
|
16
17
|
export declare namespace PostedConfig {
|
|
17
18
|
interface Raw {
|
|
@@ -26,5 +27,6 @@ export declare namespace PostedConfig {
|
|
|
26
27
|
builtin_tools?: (PostedBuiltinTool.Raw | null | undefined)[] | null;
|
|
27
28
|
event_messages?: PostedEventMessageSpecs.Raw | null;
|
|
28
29
|
timeouts?: PostedTimeoutSpecs.Raw | null;
|
|
30
|
+
webhooks?: (PostedWebhookSpec.Raw | null | undefined)[] | null;
|
|
29
31
|
}
|
|
30
32
|
}
|
package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.js
CHANGED
|
@@ -36,6 +36,7 @@ const PostedUserDefinedToolSpec_1 = require("../../../../types/PostedUserDefined
|
|
|
36
36
|
const PostedBuiltinTool_1 = require("../../../../types/PostedBuiltinTool");
|
|
37
37
|
const PostedEventMessageSpecs_1 = require("../../../../types/PostedEventMessageSpecs");
|
|
38
38
|
const PostedTimeoutSpecs_1 = require("../../../../types/PostedTimeoutSpecs");
|
|
39
|
+
const PostedWebhookSpec_1 = require("../../../../types/PostedWebhookSpec");
|
|
39
40
|
exports.PostedConfig = core.serialization.object({
|
|
40
41
|
eviVersion: core.serialization.property("evi_version", core.serialization.string()),
|
|
41
42
|
name: core.serialization.string(),
|
|
@@ -48,4 +49,5 @@ exports.PostedConfig = core.serialization.object({
|
|
|
48
49
|
builtinTools: core.serialization.property("builtin_tools", core.serialization.list(PostedBuiltinTool_1.PostedBuiltinTool.optional()).optional()),
|
|
49
50
|
eventMessages: core.serialization.property("event_messages", PostedEventMessageSpecs_1.PostedEventMessageSpecs.optional()),
|
|
50
51
|
timeouts: PostedTimeoutSpecs_1.PostedTimeoutSpecs.optional(),
|
|
52
|
+
webhooks: core.serialization.list(PostedWebhookSpec_1.PostedWebhookSpec.optional()).optional(),
|
|
51
53
|
});
|
|
@@ -12,6 +12,7 @@ import { PostedUserDefinedToolSpec } from "../../../../types/PostedUserDefinedTo
|
|
|
12
12
|
import { PostedBuiltinTool } from "../../../../types/PostedBuiltinTool";
|
|
13
13
|
import { PostedEventMessageSpecs } from "../../../../types/PostedEventMessageSpecs";
|
|
14
14
|
import { PostedTimeoutSpecs } from "../../../../types/PostedTimeoutSpecs";
|
|
15
|
+
import { PostedWebhookSpec } from "../../../../types/PostedWebhookSpec";
|
|
15
16
|
export declare const PostedConfigVersion: core.serialization.Schema<serializers.empathicVoice.PostedConfigVersion.Raw, Hume.empathicVoice.PostedConfigVersion>;
|
|
16
17
|
export declare namespace PostedConfigVersion {
|
|
17
18
|
interface Raw {
|
|
@@ -25,5 +26,6 @@ export declare namespace PostedConfigVersion {
|
|
|
25
26
|
builtin_tools?: (PostedBuiltinTool.Raw | null | undefined)[] | null;
|
|
26
27
|
event_messages?: PostedEventMessageSpecs.Raw | null;
|
|
27
28
|
timeouts?: PostedTimeoutSpecs.Raw | null;
|
|
29
|
+
webhooks?: (PostedWebhookSpec.Raw | null | undefined)[] | null;
|
|
28
30
|
}
|
|
29
31
|
}
|
|
@@ -36,6 +36,7 @@ const PostedUserDefinedToolSpec_1 = require("../../../../types/PostedUserDefined
|
|
|
36
36
|
const PostedBuiltinTool_1 = require("../../../../types/PostedBuiltinTool");
|
|
37
37
|
const PostedEventMessageSpecs_1 = require("../../../../types/PostedEventMessageSpecs");
|
|
38
38
|
const PostedTimeoutSpecs_1 = require("../../../../types/PostedTimeoutSpecs");
|
|
39
|
+
const PostedWebhookSpec_1 = require("../../../../types/PostedWebhookSpec");
|
|
39
40
|
exports.PostedConfigVersion = core.serialization.object({
|
|
40
41
|
eviVersion: core.serialization.property("evi_version", core.serialization.string()),
|
|
41
42
|
versionDescription: core.serialization.property("version_description", core.serialization.string().optional()),
|
|
@@ -47,4 +48,5 @@ exports.PostedConfigVersion = core.serialization.object({
|
|
|
47
48
|
builtinTools: core.serialization.property("builtin_tools", core.serialization.list(PostedBuiltinTool_1.PostedBuiltinTool.optional()).optional()),
|
|
48
49
|
eventMessages: core.serialization.property("event_messages", PostedEventMessageSpecs_1.PostedEventMessageSpecs.optional()),
|
|
49
50
|
timeouts: PostedTimeoutSpecs_1.PostedTimeoutSpecs.optional(),
|
|
51
|
+
webhooks: core.serialization.list(PostedWebhookSpec_1.PostedWebhookSpec.optional()).optional(),
|
|
50
52
|
});
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as serializers from "../../../index";
|
|
5
|
+
import * as Hume from "../../../../api/index";
|
|
6
|
+
import * as core from "../../../../core";
|
|
7
|
+
export declare const PostedWebhookEventType: core.serialization.Schema<serializers.empathicVoice.PostedWebhookEventType.Raw, Hume.empathicVoice.PostedWebhookEventType>;
|
|
8
|
+
export declare namespace PostedWebhookEventType {
|
|
9
|
+
type Raw = "chat_started" | "chat_ended";
|
|
10
|
+
}
|
|
@@ -26,9 +26,6 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
26
26
|
return result;
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.
|
|
29
|
+
exports.PostedWebhookEventType = void 0;
|
|
30
30
|
const core = __importStar(require("../../../../core"));
|
|
31
|
-
exports.
|
|
32
|
-
tag: core.serialization.string(),
|
|
33
|
-
totalTagActiveChats: core.serialization.property("total_tag_active_chats", core.serialization.number()),
|
|
34
|
-
});
|
|
31
|
+
exports.PostedWebhookEventType = core.serialization.enum_(["chat_started", "chat_ended"]);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as serializers from "../../../index";
|
|
5
|
+
import * as Hume from "../../../../api/index";
|
|
6
|
+
import * as core from "../../../../core";
|
|
7
|
+
import { PostedWebhookEventType } from "./PostedWebhookEventType";
|
|
8
|
+
export declare const PostedWebhookSpec: core.serialization.ObjectSchema<serializers.empathicVoice.PostedWebhookSpec.Raw, Hume.empathicVoice.PostedWebhookSpec>;
|
|
9
|
+
export declare namespace PostedWebhookSpec {
|
|
10
|
+
interface Raw {
|
|
11
|
+
url: string;
|
|
12
|
+
events: PostedWebhookEventType.Raw[];
|
|
13
|
+
}
|
|
14
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.PostedWebhookSpec = void 0;
|
|
30
|
+
const core = __importStar(require("../../../../core"));
|
|
31
|
+
const PostedWebhookEventType_1 = require("./PostedWebhookEventType");
|
|
32
|
+
exports.PostedWebhookSpec = core.serialization.object({
|
|
33
|
+
url: core.serialization.string(),
|
|
34
|
+
events: core.serialization.list(PostedWebhookEventType_1.PostedWebhookEventType),
|
|
35
|
+
});
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
import * as serializers from "../../../index";
|
|
5
5
|
import * as Hume from "../../../../api/index";
|
|
6
6
|
import * as core from "../../../../core";
|
|
7
|
+
import { ReturnConfigSpec } from "./ReturnConfigSpec";
|
|
7
8
|
export declare const ReturnChatGroup: core.serialization.ObjectSchema<serializers.empathicVoice.ReturnChatGroup.Raw, Hume.empathicVoice.ReturnChatGroup>;
|
|
8
9
|
export declare namespace ReturnChatGroup {
|
|
9
10
|
interface Raw {
|
|
@@ -11,6 +12,7 @@ export declare namespace ReturnChatGroup {
|
|
|
11
12
|
first_start_timestamp: number;
|
|
12
13
|
most_recent_start_timestamp: number;
|
|
13
14
|
most_recent_chat_id?: string | null;
|
|
15
|
+
most_recent_config?: ReturnConfigSpec.Raw | null;
|
|
14
16
|
num_chats: number;
|
|
15
17
|
active?: boolean | null;
|
|
16
18
|
}
|
|
@@ -28,11 +28,13 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
29
|
exports.ReturnChatGroup = void 0;
|
|
30
30
|
const core = __importStar(require("../../../../core"));
|
|
31
|
+
const ReturnConfigSpec_1 = require("./ReturnConfigSpec");
|
|
31
32
|
exports.ReturnChatGroup = core.serialization.object({
|
|
32
33
|
id: core.serialization.string(),
|
|
33
34
|
firstStartTimestamp: core.serialization.property("first_start_timestamp", core.serialization.number()),
|
|
34
35
|
mostRecentStartTimestamp: core.serialization.property("most_recent_start_timestamp", core.serialization.number()),
|
|
35
36
|
mostRecentChatId: core.serialization.property("most_recent_chat_id", core.serialization.string().optional()),
|
|
37
|
+
mostRecentConfig: core.serialization.property("most_recent_config", ReturnConfigSpec_1.ReturnConfigSpec.optional()),
|
|
36
38
|
numChats: core.serialization.property("num_chats", core.serialization.number()),
|
|
37
39
|
active: core.serialization.boolean().optional(),
|
|
38
40
|
});
|
|
@@ -12,6 +12,7 @@ import { ReturnUserDefinedTool } from "./ReturnUserDefinedTool";
|
|
|
12
12
|
import { ReturnBuiltinTool } from "./ReturnBuiltinTool";
|
|
13
13
|
import { ReturnEventMessageSpecs } from "./ReturnEventMessageSpecs";
|
|
14
14
|
import { ReturnTimeoutSpecs } from "./ReturnTimeoutSpecs";
|
|
15
|
+
import { ReturnWebhookSpec } from "./ReturnWebhookSpec";
|
|
15
16
|
export declare const ReturnConfig: core.serialization.ObjectSchema<serializers.empathicVoice.ReturnConfig.Raw, Hume.empathicVoice.ReturnConfig>;
|
|
16
17
|
export declare namespace ReturnConfig {
|
|
17
18
|
interface Raw {
|
|
@@ -30,5 +31,6 @@ export declare namespace ReturnConfig {
|
|
|
30
31
|
builtin_tools?: (ReturnBuiltinTool.Raw | null | undefined)[] | null;
|
|
31
32
|
event_messages?: ReturnEventMessageSpecs.Raw | null;
|
|
32
33
|
timeouts?: ReturnTimeoutSpecs.Raw | null;
|
|
34
|
+
webhooks?: (ReturnWebhookSpec.Raw | null | undefined)[] | null;
|
|
33
35
|
}
|
|
34
36
|
}
|
|
@@ -36,6 +36,7 @@ const ReturnUserDefinedTool_1 = require("./ReturnUserDefinedTool");
|
|
|
36
36
|
const ReturnBuiltinTool_1 = require("./ReturnBuiltinTool");
|
|
37
37
|
const ReturnEventMessageSpecs_1 = require("./ReturnEventMessageSpecs");
|
|
38
38
|
const ReturnTimeoutSpecs_1 = require("./ReturnTimeoutSpecs");
|
|
39
|
+
const ReturnWebhookSpec_1 = require("./ReturnWebhookSpec");
|
|
39
40
|
exports.ReturnConfig = core.serialization.object({
|
|
40
41
|
id: core.serialization.string().optional(),
|
|
41
42
|
version: core.serialization.number().optional(),
|
|
@@ -52,4 +53,5 @@ exports.ReturnConfig = core.serialization.object({
|
|
|
52
53
|
builtinTools: core.serialization.property("builtin_tools", core.serialization.list(ReturnBuiltinTool_1.ReturnBuiltinTool.optional()).optional()),
|
|
53
54
|
eventMessages: core.serialization.property("event_messages", ReturnEventMessageSpecs_1.ReturnEventMessageSpecs.optional()),
|
|
54
55
|
timeouts: ReturnTimeoutSpecs_1.ReturnTimeoutSpecs.optional(),
|
|
56
|
+
webhooks: core.serialization.list(ReturnWebhookSpec_1.ReturnWebhookSpec.optional()).optional(),
|
|
55
57
|
});
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as serializers from "../../../index";
|
|
5
|
+
import * as Hume from "../../../../api/index";
|
|
6
|
+
import * as core from "../../../../core";
|
|
7
|
+
export declare const ReturnWebhookEventType: core.serialization.Schema<serializers.empathicVoice.ReturnWebhookEventType.Raw, Hume.empathicVoice.ReturnWebhookEventType>;
|
|
8
|
+
export declare namespace ReturnWebhookEventType {
|
|
9
|
+
type Raw = "chat_started" | "chat_ended";
|
|
10
|
+
}
|
|
@@ -26,9 +26,6 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
26
26
|
return result;
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.
|
|
29
|
+
exports.ReturnWebhookEventType = void 0;
|
|
30
30
|
const core = __importStar(require("../../../../core"));
|
|
31
|
-
exports.
|
|
32
|
-
tag: core.serialization.string(),
|
|
33
|
-
totalTagActiveChats: core.serialization.property("total_tag_active_chats", core.serialization.number()),
|
|
34
|
-
});
|
|
31
|
+
exports.ReturnWebhookEventType = core.serialization.enum_(["chat_started", "chat_ended"]);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as serializers from "../../../index";
|
|
5
|
+
import * as Hume from "../../../../api/index";
|
|
6
|
+
import * as core from "../../../../core";
|
|
7
|
+
import { ReturnWebhookEventType } from "./ReturnWebhookEventType";
|
|
8
|
+
export declare const ReturnWebhookSpec: core.serialization.ObjectSchema<serializers.empathicVoice.ReturnWebhookSpec.Raw, Hume.empathicVoice.ReturnWebhookSpec>;
|
|
9
|
+
export declare namespace ReturnWebhookSpec {
|
|
10
|
+
interface Raw {
|
|
11
|
+
url: string;
|
|
12
|
+
events: ReturnWebhookEventType.Raw[];
|
|
13
|
+
}
|
|
14
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.ReturnWebhookSpec = void 0;
|
|
30
|
+
const core = __importStar(require("../../../../core"));
|
|
31
|
+
const ReturnWebhookEventType_1 = require("./ReturnWebhookEventType");
|
|
32
|
+
exports.ReturnWebhookSpec = core.serialization.object({
|
|
33
|
+
url: core.serialization.string(),
|
|
34
|
+
events: core.serialization.list(ReturnWebhookEventType_1.ReturnWebhookEventType),
|
|
35
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as serializers from "../../../index";
|
|
5
|
+
import * as Hume from "../../../../api/index";
|
|
6
|
+
import * as core from "../../../../core";
|
|
7
|
+
import { WebhookEventChatStarted } from "./WebhookEventChatStarted";
|
|
8
|
+
import { WebhookEventChatEnded } from "./WebhookEventChatEnded";
|
|
9
|
+
export declare const WebhookEvent: core.serialization.Schema<serializers.empathicVoice.WebhookEvent.Raw, Hume.empathicVoice.WebhookEvent>;
|
|
10
|
+
export declare namespace WebhookEvent {
|
|
11
|
+
type Raw = WebhookEventChatStarted.Raw | WebhookEventChatEnded.Raw;
|
|
12
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.WebhookEvent = void 0;
|
|
30
|
+
const core = __importStar(require("../../../../core"));
|
|
31
|
+
const WebhookEventChatStarted_1 = require("./WebhookEventChatStarted");
|
|
32
|
+
const WebhookEventChatEnded_1 = require("./WebhookEventChatEnded");
|
|
33
|
+
exports.WebhookEvent = core.serialization.undiscriminatedUnion([WebhookEventChatStarted_1.WebhookEventChatStarted, WebhookEventChatEnded_1.WebhookEventChatEnded]);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as serializers from "../../../index";
|
|
5
|
+
import * as Hume from "../../../../api/index";
|
|
6
|
+
import * as core from "../../../../core";
|
|
7
|
+
export declare const WebhookEventBase: core.serialization.ObjectSchema<serializers.empathicVoice.WebhookEventBase.Raw, Hume.empathicVoice.WebhookEventBase>;
|
|
8
|
+
export declare namespace WebhookEventBase {
|
|
9
|
+
interface Raw {
|
|
10
|
+
chat_group_id: string;
|
|
11
|
+
chat_id: string;
|
|
12
|
+
config_id?: string | null;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.WebhookEventBase = void 0;
|
|
30
|
+
const core = __importStar(require("../../../../core"));
|
|
31
|
+
exports.WebhookEventBase = core.serialization.object({
|
|
32
|
+
chatGroupId: core.serialization.property("chat_group_id", core.serialization.string()),
|
|
33
|
+
chatId: core.serialization.property("chat_id", core.serialization.string()),
|
|
34
|
+
configId: core.serialization.property("config_id", core.serialization.string().optional()),
|
|
35
|
+
});
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as serializers from "../../../index";
|
|
5
|
+
import * as Hume from "../../../../api/index";
|
|
6
|
+
import * as core from "../../../../core";
|
|
7
|
+
import { WebhookEventChatStatus } from "./WebhookEventChatStatus";
|
|
8
|
+
import { WebhookEventBase } from "./WebhookEventBase";
|
|
9
|
+
export declare const WebhookEventChatEnded: core.serialization.ObjectSchema<serializers.empathicVoice.WebhookEventChatEnded.Raw, Hume.empathicVoice.WebhookEventChatEnded>;
|
|
10
|
+
export declare namespace WebhookEventChatEnded {
|
|
11
|
+
interface Raw extends WebhookEventBase.Raw {
|
|
12
|
+
event_name?: "chat_ended" | null;
|
|
13
|
+
end_time: number;
|
|
14
|
+
duration_seconds: number;
|
|
15
|
+
end_reason: WebhookEventChatStatus.Raw;
|
|
16
|
+
caller_number?: string | null;
|
|
17
|
+
custom_session_id?: string | null;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
22
|
+
if (mod && mod.__esModule) return mod;
|
|
23
|
+
var result = {};
|
|
24
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
25
|
+
__setModuleDefault(result, mod);
|
|
26
|
+
return result;
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.WebhookEventChatEnded = void 0;
|
|
30
|
+
const core = __importStar(require("../../../../core"));
|
|
31
|
+
const WebhookEventChatStatus_1 = require("./WebhookEventChatStatus");
|
|
32
|
+
const WebhookEventBase_1 = require("./WebhookEventBase");
|
|
33
|
+
exports.WebhookEventChatEnded = core.serialization
|
|
34
|
+
.object({
|
|
35
|
+
eventName: core.serialization.property("event_name", core.serialization.stringLiteral("chat_ended").optional()),
|
|
36
|
+
endTime: core.serialization.property("end_time", core.serialization.number()),
|
|
37
|
+
durationSeconds: core.serialization.property("duration_seconds", core.serialization.number()),
|
|
38
|
+
endReason: core.serialization.property("end_reason", WebhookEventChatStatus_1.WebhookEventChatStatus),
|
|
39
|
+
callerNumber: core.serialization.property("caller_number", core.serialization.string().optional()),
|
|
40
|
+
customSessionId: core.serialization.property("custom_session_id", core.serialization.string().optional()),
|
|
41
|
+
})
|
|
42
|
+
.extend(WebhookEventBase_1.WebhookEventBase);
|