hume 0.11.1 → 0.11.2
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 +24 -0
- package/.mock/definition/empathic-voice/configs.yml +2 -0
- package/.mock/definition/tts/__package__.yml +28 -0
- package/.mock/fern.config.json +1 -1
- package/Client.d.ts +11 -7
- package/Client.js +54 -6
- package/api/resources/empathicVoice/errors/BadRequestError.d.ts +2 -1
- package/api/resources/empathicVoice/errors/BadRequestError.js +2 -1
- package/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +4 -2
- package/api/resources/empathicVoice/resources/chatGroups/client/Client.js +74 -40
- package/api/resources/empathicVoice/resources/chats/client/Client.d.ts +2 -1
- package/api/resources/empathicVoice/resources/chats/client/Client.js +55 -30
- package/api/resources/empathicVoice/resources/configs/client/Client.d.ts +14 -7
- package/api/resources/empathicVoice/resources/configs/client/Client.js +134 -64
- package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +1 -0
- package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +1 -0
- package/api/resources/empathicVoice/resources/customVoices/client/Client.d.ts +10 -5
- package/api/resources/empathicVoice/resources/customVoices/client/Client.js +88 -41
- package/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +16 -8
- package/api/resources/empathicVoice/resources/prompts/client/Client.js +133 -62
- package/api/resources/empathicVoice/resources/tools/client/Client.d.ts +14 -7
- package/api/resources/empathicVoice/resources/tools/client/Client.js +134 -64
- package/api/resources/empathicVoice/types/PostedNudgeSpec.d.ts +12 -0
- package/api/resources/empathicVoice/types/PostedNudgeSpec.js +5 -0
- package/api/resources/empathicVoice/types/ReturnConfig.d.ts +1 -0
- package/api/resources/empathicVoice/types/ReturnNudgeSpec.d.ts +12 -0
- package/api/resources/empathicVoice/types/ReturnNudgeSpec.js +5 -0
- package/api/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +2 -1
- package/api/resources/empathicVoice/types/WebhookEventChatStatus.js +1 -0
- package/api/resources/empathicVoice/types/index.d.ts +2 -0
- package/api/resources/empathicVoice/types/index.js +2 -0
- package/api/resources/expressionMeasurement/resources/batch/client/Client.d.ts +12 -6
- package/api/resources/expressionMeasurement/resources/batch/client/Client.js +89 -38
- package/api/resources/tts/client/Client.d.ts +24 -18
- package/api/resources/tts/client/Client.js +84 -46
- package/api/resources/tts/client/index.d.ts +1 -1
- package/api/resources/tts/client/index.js +15 -0
- package/api/resources/tts/client/requests/SynthesizeJsonRequest.d.ts +36 -0
- package/api/resources/tts/client/requests/SynthesizeJsonRequest.js +5 -0
- package/api/resources/tts/client/requests/index.d.ts +1 -0
- package/api/resources/tts/client/requests/index.js +2 -0
- package/api/resources/tts/errors/BadRequestError.d.ts +2 -1
- package/api/resources/tts/errors/BadRequestError.js +2 -1
- package/api/resources/tts/errors/UnprocessableEntityError.d.ts +2 -1
- package/api/resources/tts/errors/UnprocessableEntityError.js +2 -1
- package/api/resources/tts/resources/voices/client/Client.d.ts +4 -2
- package/api/resources/tts/resources/voices/client/Client.js +45 -22
- package/api/resources/tts/types/Snippet.d.ts +2 -0
- package/api/resources/tts/types/SnippetAudioChunk.d.ts +2 -0
- package/core/fetcher/APIResponse.d.ts +10 -0
- package/core/fetcher/Fetcher.js +7 -0
- package/core/fetcher/Headers.d.ts +2 -0
- package/core/fetcher/Headers.js +84 -0
- package/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/core/fetcher/HttpResponsePromise.js +103 -0
- package/core/fetcher/RawResponse.d.ts +29 -0
- package/core/fetcher/RawResponse.js +44 -0
- package/core/fetcher/index.d.ts +3 -0
- package/core/fetcher/index.js +7 -1
- package/core/form-data-utils/FormDataWrapper.d.ts +3 -0
- package/core/form-data-utils/FormDataWrapper.js +48 -9
- package/core/pagination/Page.d.ts +5 -2
- package/core/pagination/Page.js +5 -2
- package/core/pagination/Pageable.d.ts +2 -0
- package/dist/Client.d.ts +11 -7
- package/dist/Client.js +54 -6
- package/dist/api/resources/empathicVoice/errors/BadRequestError.d.ts +2 -1
- package/dist/api/resources/empathicVoice/errors/BadRequestError.js +2 -1
- package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +4 -2
- package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.js +74 -40
- package/dist/api/resources/empathicVoice/resources/chats/client/Client.d.ts +2 -1
- package/dist/api/resources/empathicVoice/resources/chats/client/Client.js +55 -30
- package/dist/api/resources/empathicVoice/resources/configs/client/Client.d.ts +14 -7
- package/dist/api/resources/empathicVoice/resources/configs/client/Client.js +134 -64
- package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +1 -0
- package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +1 -0
- package/dist/api/resources/empathicVoice/resources/customVoices/client/Client.d.ts +10 -5
- package/dist/api/resources/empathicVoice/resources/customVoices/client/Client.js +88 -41
- package/dist/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +16 -8
- package/dist/api/resources/empathicVoice/resources/prompts/client/Client.js +133 -62
- package/dist/api/resources/empathicVoice/resources/tools/client/Client.d.ts +14 -7
- package/dist/api/resources/empathicVoice/resources/tools/client/Client.js +134 -64
- package/dist/api/resources/empathicVoice/types/PostedNudgeSpec.d.ts +12 -0
- package/dist/api/resources/empathicVoice/types/PostedNudgeSpec.js +5 -0
- package/dist/api/resources/empathicVoice/types/ReturnConfig.d.ts +1 -0
- package/dist/api/resources/empathicVoice/types/ReturnNudgeSpec.d.ts +12 -0
- package/dist/api/resources/empathicVoice/types/ReturnNudgeSpec.js +5 -0
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +2 -1
- package/dist/api/resources/empathicVoice/types/WebhookEventChatStatus.js +1 -0
- package/dist/api/resources/empathicVoice/types/index.d.ts +2 -0
- package/dist/api/resources/empathicVoice/types/index.js +2 -0
- package/dist/api/resources/expressionMeasurement/resources/batch/client/Client.d.ts +12 -6
- package/dist/api/resources/expressionMeasurement/resources/batch/client/Client.js +89 -38
- package/dist/api/resources/tts/client/Client.d.ts +24 -18
- package/dist/api/resources/tts/client/Client.js +84 -46
- package/dist/api/resources/tts/client/index.d.ts +1 -1
- package/dist/api/resources/tts/client/index.js +15 -0
- package/dist/api/resources/tts/client/requests/SynthesizeJsonRequest.d.ts +36 -0
- package/dist/api/resources/tts/client/requests/SynthesizeJsonRequest.js +5 -0
- package/dist/api/resources/tts/client/requests/index.d.ts +1 -0
- package/dist/api/resources/tts/client/requests/index.js +2 -0
- package/dist/api/resources/tts/errors/BadRequestError.d.ts +2 -1
- package/dist/api/resources/tts/errors/BadRequestError.js +2 -1
- package/dist/api/resources/tts/errors/UnprocessableEntityError.d.ts +2 -1
- package/dist/api/resources/tts/errors/UnprocessableEntityError.js +2 -1
- package/dist/api/resources/tts/resources/voices/client/Client.d.ts +4 -2
- package/dist/api/resources/tts/resources/voices/client/Client.js +45 -22
- package/dist/api/resources/tts/types/Snippet.d.ts +2 -0
- package/dist/api/resources/tts/types/SnippetAudioChunk.d.ts +2 -0
- package/dist/core/fetcher/APIResponse.d.ts +10 -0
- package/dist/core/fetcher/Fetcher.js +7 -0
- package/dist/core/fetcher/Headers.d.ts +2 -0
- package/dist/core/fetcher/Headers.js +84 -0
- package/dist/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/dist/core/fetcher/HttpResponsePromise.js +103 -0
- package/dist/core/fetcher/RawResponse.d.ts +29 -0
- package/dist/core/fetcher/RawResponse.js +44 -0
- package/dist/core/fetcher/index.d.ts +3 -0
- package/dist/core/fetcher/index.js +7 -1
- package/dist/core/form-data-utils/FormDataWrapper.d.ts +3 -0
- package/dist/core/form-data-utils/FormDataWrapper.js +48 -9
- package/dist/core/pagination/Page.d.ts +5 -2
- package/dist/core/pagination/Page.js +5 -2
- package/dist/core/pagination/Pageable.d.ts +2 -0
- package/dist/errors/HumeError.d.ts +7 -2
- package/dist/errors/HumeError.js +10 -10
- 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/PostedNudgeSpec.d.ts +13 -0
- package/dist/serialization/resources/empathicVoice/types/PostedNudgeSpec.js +44 -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/ReturnNudgeSpec.d.ts +13 -0
- package/dist/serialization/resources/empathicVoice/types/ReturnNudgeSpec.js +44 -0
- package/dist/serialization/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +1 -1
- package/dist/serialization/resources/empathicVoice/types/WebhookEventChatStatus.js +1 -0
- package/dist/serialization/resources/empathicVoice/types/index.d.ts +2 -0
- package/dist/serialization/resources/empathicVoice/types/index.js +2 -0
- package/dist/serialization/resources/tts/types/Snippet.d.ts +1 -0
- package/dist/serialization/resources/tts/types/Snippet.js +1 -0
- package/dist/serialization/resources/tts/types/SnippetAudioChunk.d.ts +1 -0
- package/dist/serialization/resources/tts/types/SnippetAudioChunk.js +1 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/wrapper/expressionMeasurement/ExpressionMeasurementClient.js +2 -0
- package/dist/wrapper/expressionMeasurement/batch/BatchClient.d.ts +2 -1
- package/dist/wrapper/expressionMeasurement/batch/BatchClient.js +43 -17
- package/errors/HumeError.d.ts +7 -2
- package/errors/HumeError.js +10 -10
- package/package.json +3 -2
- package/reference.md +17 -15
- 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/PostedNudgeSpec.d.ts +13 -0
- package/serialization/resources/empathicVoice/types/PostedNudgeSpec.js +44 -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/ReturnNudgeSpec.d.ts +13 -0
- package/serialization/resources/empathicVoice/types/ReturnNudgeSpec.js +44 -0
- package/serialization/resources/empathicVoice/types/WebhookEventChatStatus.d.ts +1 -1
- package/serialization/resources/empathicVoice/types/WebhookEventChatStatus.js +1 -0
- package/serialization/resources/empathicVoice/types/index.d.ts +2 -0
- package/serialization/resources/empathicVoice/types/index.js +2 -0
- package/serialization/resources/tts/types/Snippet.d.ts +1 -0
- package/serialization/resources/tts/types/Snippet.js +1 -0
- package/serialization/resources/tts/types/SnippetAudioChunk.d.ts +1 -0
- package/serialization/resources/tts/types/SnippetAudioChunk.js +1 -0
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/wrapper/expressionMeasurement/ExpressionMeasurementClient.js +2 -0
- package/wrapper/expressionMeasurement/batch/BatchClient.d.ts +2 -1
- package/wrapper/expressionMeasurement/batch/BatchClient.js +43 -17
|
@@ -57,7 +57,8 @@ export declare class CustomVoices {
|
|
|
57
57
|
* parameterModel: "20241004-11parameter"
|
|
58
58
|
* })
|
|
59
59
|
*/
|
|
60
|
-
createCustomVoice(request: Hume.empathicVoice.PostedCustomVoice, requestOptions?: CustomVoices.RequestOptions):
|
|
60
|
+
createCustomVoice(request: Hume.empathicVoice.PostedCustomVoice, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnCustomVoice>;
|
|
61
|
+
private __createCustomVoice;
|
|
61
62
|
/**
|
|
62
63
|
* Fetches a specific **Custom Voice** by ID.
|
|
63
64
|
*
|
|
@@ -71,7 +72,8 @@ export declare class CustomVoices {
|
|
|
71
72
|
* @example
|
|
72
73
|
* await client.empathicVoice.customVoices.getCustomVoice("id")
|
|
73
74
|
*/
|
|
74
|
-
getCustomVoice(id: string, requestOptions?: CustomVoices.RequestOptions):
|
|
75
|
+
getCustomVoice(id: string, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnCustomVoice>;
|
|
76
|
+
private __getCustomVoice;
|
|
75
77
|
/**
|
|
76
78
|
* Updates a **Custom Voice** by creating a new version of the **Custom Voice**.
|
|
77
79
|
*
|
|
@@ -90,7 +92,8 @@ export declare class CustomVoices {
|
|
|
90
92
|
* parameterModel: "20241004-11parameter"
|
|
91
93
|
* })
|
|
92
94
|
*/
|
|
93
|
-
createCustomVoiceVersion(id: string, request: Hume.empathicVoice.PostedCustomVoice, requestOptions?: CustomVoices.RequestOptions):
|
|
95
|
+
createCustomVoiceVersion(id: string, request: Hume.empathicVoice.PostedCustomVoice, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnCustomVoice>;
|
|
96
|
+
private __createCustomVoiceVersion;
|
|
94
97
|
/**
|
|
95
98
|
* Deletes a **Custom Voice** and its versions.
|
|
96
99
|
*
|
|
@@ -104,7 +107,8 @@ export declare class CustomVoices {
|
|
|
104
107
|
* @example
|
|
105
108
|
* await client.empathicVoice.customVoices.deleteCustomVoice("id")
|
|
106
109
|
*/
|
|
107
|
-
deleteCustomVoice(id: string, requestOptions?: CustomVoices.RequestOptions):
|
|
110
|
+
deleteCustomVoice(id: string, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<void>;
|
|
111
|
+
private __deleteCustomVoice;
|
|
108
112
|
/**
|
|
109
113
|
* Updates the name of a **Custom Voice**.
|
|
110
114
|
*
|
|
@@ -121,7 +125,8 @@ export declare class CustomVoices {
|
|
|
121
125
|
* name: "name"
|
|
122
126
|
* })
|
|
123
127
|
*/
|
|
124
|
-
updateCustomVoiceName(id: string, request: Hume.empathicVoice.PostedCustomVoiceName, requestOptions?: CustomVoices.RequestOptions):
|
|
128
|
+
updateCustomVoiceName(id: string, request: Hume.empathicVoice.PostedCustomVoiceName, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<string>;
|
|
129
|
+
private __updateCustomVoiceName;
|
|
125
130
|
protected _getCustomAuthorizationHeaders(): Promise<{
|
|
126
131
|
"X-Hume-Api-Key": string | undefined;
|
|
127
132
|
}>;
|
|
@@ -74,7 +74,7 @@ class CustomVoices {
|
|
|
74
74
|
*/
|
|
75
75
|
listCustomVoices() {
|
|
76
76
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
77
|
-
const list = (request) => __awaiter(this, void 0, void 0, function* () {
|
|
77
|
+
const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
|
|
78
78
|
var _a, _b, _c;
|
|
79
79
|
const { pageNumber, pageSize, name } = request;
|
|
80
80
|
const _queryParams = {};
|
|
@@ -90,7 +90,7 @@ class CustomVoices {
|
|
|
90
90
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
91
91
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Production, "v0/evi/custom_voices"),
|
|
92
92
|
method: "GET",
|
|
93
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.
|
|
93
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.2", "User-Agent": "hume/0.11.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
94
94
|
contentType: "application/json",
|
|
95
95
|
queryParameters: _queryParams,
|
|
96
96
|
requestType: "json",
|
|
@@ -99,12 +99,15 @@ class CustomVoices {
|
|
|
99
99
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
100
100
|
});
|
|
101
101
|
if (_response.ok) {
|
|
102
|
-
return
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
102
|
+
return {
|
|
103
|
+
data: serializers.empathicVoice.ReturnPagedCustomVoices.parseOrThrow(_response.body, {
|
|
104
|
+
unrecognizedObjectKeys: "passthrough",
|
|
105
|
+
allowUnrecognizedUnionMembers: true,
|
|
106
|
+
allowUnrecognizedEnumValues: true,
|
|
107
|
+
breadcrumbsPrefix: ["response"],
|
|
108
|
+
}),
|
|
109
|
+
rawResponse: _response.rawResponse,
|
|
110
|
+
};
|
|
108
111
|
}
|
|
109
112
|
if (_response.error.reason === "status-code") {
|
|
110
113
|
switch (_response.error.statusCode) {
|
|
@@ -114,11 +117,12 @@ class CustomVoices {
|
|
|
114
117
|
allowUnrecognizedUnionMembers: true,
|
|
115
118
|
allowUnrecognizedEnumValues: true,
|
|
116
119
|
breadcrumbsPrefix: ["response"],
|
|
117
|
-
}));
|
|
120
|
+
}), _response.rawResponse);
|
|
118
121
|
default:
|
|
119
122
|
throw new errors.HumeError({
|
|
120
123
|
statusCode: _response.error.statusCode,
|
|
121
124
|
body: _response.error.body,
|
|
125
|
+
rawResponse: _response.rawResponse,
|
|
122
126
|
});
|
|
123
127
|
}
|
|
124
128
|
}
|
|
@@ -127,18 +131,22 @@ class CustomVoices {
|
|
|
127
131
|
throw new errors.HumeError({
|
|
128
132
|
statusCode: _response.error.statusCode,
|
|
129
133
|
body: _response.error.rawBody,
|
|
134
|
+
rawResponse: _response.rawResponse,
|
|
130
135
|
});
|
|
131
136
|
case "timeout":
|
|
132
137
|
throw new errors.HumeTimeoutError("Timeout exceeded when calling GET /v0/evi/custom_voices.");
|
|
133
138
|
case "unknown":
|
|
134
139
|
throw new errors.HumeError({
|
|
135
140
|
message: _response.error.errorMessage,
|
|
141
|
+
rawResponse: _response.rawResponse,
|
|
136
142
|
});
|
|
137
143
|
}
|
|
138
|
-
});
|
|
144
|
+
}));
|
|
139
145
|
let _offset = (request === null || request === void 0 ? void 0 : request.pageNumber) != null ? request === null || request === void 0 ? void 0 : request.pageNumber : 0;
|
|
146
|
+
const dataWithRawResponse = yield list(request).withRawResponse();
|
|
140
147
|
return new core.Pageable({
|
|
141
|
-
response:
|
|
148
|
+
response: dataWithRawResponse.data,
|
|
149
|
+
rawResponse: dataWithRawResponse.rawResponse,
|
|
142
150
|
hasNextPage: (response) => { var _a; return ((_a = response === null || response === void 0 ? void 0 : response.customVoicesPage) !== null && _a !== void 0 ? _a : []).length > 0; },
|
|
143
151
|
getItems: (response) => { var _a; return (_a = response === null || response === void 0 ? void 0 : response.customVoicesPage) !== null && _a !== void 0 ? _a : []; },
|
|
144
152
|
loadPage: (_response) => {
|
|
@@ -166,12 +174,15 @@ class CustomVoices {
|
|
|
166
174
|
* })
|
|
167
175
|
*/
|
|
168
176
|
createCustomVoice(request, requestOptions) {
|
|
177
|
+
return core.HttpResponsePromise.fromPromise(this.__createCustomVoice(request, requestOptions));
|
|
178
|
+
}
|
|
179
|
+
__createCustomVoice(request, requestOptions) {
|
|
169
180
|
return __awaiter(this, void 0, void 0, function* () {
|
|
170
181
|
var _a, _b, _c;
|
|
171
182
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
172
183
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Production, "v0/evi/custom_voices"),
|
|
173
184
|
method: "POST",
|
|
174
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.
|
|
185
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.2", "User-Agent": "hume/0.11.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
175
186
|
contentType: "application/json",
|
|
176
187
|
requestType: "json",
|
|
177
188
|
body: serializers.empathicVoice.PostedCustomVoice.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -180,12 +191,15 @@ class CustomVoices {
|
|
|
180
191
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
181
192
|
});
|
|
182
193
|
if (_response.ok) {
|
|
183
|
-
return
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
194
|
+
return {
|
|
195
|
+
data: serializers.empathicVoice.ReturnCustomVoice.parseOrThrow(_response.body, {
|
|
196
|
+
unrecognizedObjectKeys: "passthrough",
|
|
197
|
+
allowUnrecognizedUnionMembers: true,
|
|
198
|
+
allowUnrecognizedEnumValues: true,
|
|
199
|
+
breadcrumbsPrefix: ["response"],
|
|
200
|
+
}),
|
|
201
|
+
rawResponse: _response.rawResponse,
|
|
202
|
+
};
|
|
189
203
|
}
|
|
190
204
|
if (_response.error.reason === "status-code") {
|
|
191
205
|
switch (_response.error.statusCode) {
|
|
@@ -195,11 +209,12 @@ class CustomVoices {
|
|
|
195
209
|
allowUnrecognizedUnionMembers: true,
|
|
196
210
|
allowUnrecognizedEnumValues: true,
|
|
197
211
|
breadcrumbsPrefix: ["response"],
|
|
198
|
-
}));
|
|
212
|
+
}), _response.rawResponse);
|
|
199
213
|
default:
|
|
200
214
|
throw new errors.HumeError({
|
|
201
215
|
statusCode: _response.error.statusCode,
|
|
202
216
|
body: _response.error.body,
|
|
217
|
+
rawResponse: _response.rawResponse,
|
|
203
218
|
});
|
|
204
219
|
}
|
|
205
220
|
}
|
|
@@ -208,12 +223,14 @@ class CustomVoices {
|
|
|
208
223
|
throw new errors.HumeError({
|
|
209
224
|
statusCode: _response.error.statusCode,
|
|
210
225
|
body: _response.error.rawBody,
|
|
226
|
+
rawResponse: _response.rawResponse,
|
|
211
227
|
});
|
|
212
228
|
case "timeout":
|
|
213
229
|
throw new errors.HumeTimeoutError("Timeout exceeded when calling POST /v0/evi/custom_voices.");
|
|
214
230
|
case "unknown":
|
|
215
231
|
throw new errors.HumeError({
|
|
216
232
|
message: _response.error.errorMessage,
|
|
233
|
+
rawResponse: _response.rawResponse,
|
|
217
234
|
});
|
|
218
235
|
}
|
|
219
236
|
});
|
|
@@ -232,12 +249,15 @@ class CustomVoices {
|
|
|
232
249
|
* await client.empathicVoice.customVoices.getCustomVoice("id")
|
|
233
250
|
*/
|
|
234
251
|
getCustomVoice(id, requestOptions) {
|
|
252
|
+
return core.HttpResponsePromise.fromPromise(this.__getCustomVoice(id, requestOptions));
|
|
253
|
+
}
|
|
254
|
+
__getCustomVoice(id, requestOptions) {
|
|
235
255
|
return __awaiter(this, void 0, void 0, function* () {
|
|
236
256
|
var _a, _b, _c;
|
|
237
257
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
238
258
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Production, `v0/evi/custom_voices/${encodeURIComponent(id)}`),
|
|
239
259
|
method: "GET",
|
|
240
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.
|
|
260
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.2", "User-Agent": "hume/0.11.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
241
261
|
contentType: "application/json",
|
|
242
262
|
requestType: "json",
|
|
243
263
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -245,12 +265,15 @@ class CustomVoices {
|
|
|
245
265
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
246
266
|
});
|
|
247
267
|
if (_response.ok) {
|
|
248
|
-
return
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
268
|
+
return {
|
|
269
|
+
data: serializers.empathicVoice.ReturnCustomVoice.parseOrThrow(_response.body, {
|
|
270
|
+
unrecognizedObjectKeys: "passthrough",
|
|
271
|
+
allowUnrecognizedUnionMembers: true,
|
|
272
|
+
allowUnrecognizedEnumValues: true,
|
|
273
|
+
breadcrumbsPrefix: ["response"],
|
|
274
|
+
}),
|
|
275
|
+
rawResponse: _response.rawResponse,
|
|
276
|
+
};
|
|
254
277
|
}
|
|
255
278
|
if (_response.error.reason === "status-code") {
|
|
256
279
|
switch (_response.error.statusCode) {
|
|
@@ -260,11 +283,12 @@ class CustomVoices {
|
|
|
260
283
|
allowUnrecognizedUnionMembers: true,
|
|
261
284
|
allowUnrecognizedEnumValues: true,
|
|
262
285
|
breadcrumbsPrefix: ["response"],
|
|
263
|
-
}));
|
|
286
|
+
}), _response.rawResponse);
|
|
264
287
|
default:
|
|
265
288
|
throw new errors.HumeError({
|
|
266
289
|
statusCode: _response.error.statusCode,
|
|
267
290
|
body: _response.error.body,
|
|
291
|
+
rawResponse: _response.rawResponse,
|
|
268
292
|
});
|
|
269
293
|
}
|
|
270
294
|
}
|
|
@@ -273,12 +297,14 @@ class CustomVoices {
|
|
|
273
297
|
throw new errors.HumeError({
|
|
274
298
|
statusCode: _response.error.statusCode,
|
|
275
299
|
body: _response.error.rawBody,
|
|
300
|
+
rawResponse: _response.rawResponse,
|
|
276
301
|
});
|
|
277
302
|
case "timeout":
|
|
278
303
|
throw new errors.HumeTimeoutError("Timeout exceeded when calling GET /v0/evi/custom_voices/{id}.");
|
|
279
304
|
case "unknown":
|
|
280
305
|
throw new errors.HumeError({
|
|
281
306
|
message: _response.error.errorMessage,
|
|
307
|
+
rawResponse: _response.rawResponse,
|
|
282
308
|
});
|
|
283
309
|
}
|
|
284
310
|
});
|
|
@@ -302,12 +328,15 @@ class CustomVoices {
|
|
|
302
328
|
* })
|
|
303
329
|
*/
|
|
304
330
|
createCustomVoiceVersion(id, request, requestOptions) {
|
|
331
|
+
return core.HttpResponsePromise.fromPromise(this.__createCustomVoiceVersion(id, request, requestOptions));
|
|
332
|
+
}
|
|
333
|
+
__createCustomVoiceVersion(id, request, requestOptions) {
|
|
305
334
|
return __awaiter(this, void 0, void 0, function* () {
|
|
306
335
|
var _a, _b, _c;
|
|
307
336
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
308
337
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Production, `v0/evi/custom_voices/${encodeURIComponent(id)}`),
|
|
309
338
|
method: "POST",
|
|
310
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.
|
|
339
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.2", "User-Agent": "hume/0.11.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
311
340
|
contentType: "application/json",
|
|
312
341
|
requestType: "json",
|
|
313
342
|
body: serializers.empathicVoice.PostedCustomVoice.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -316,12 +345,15 @@ class CustomVoices {
|
|
|
316
345
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
317
346
|
});
|
|
318
347
|
if (_response.ok) {
|
|
319
|
-
return
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
348
|
+
return {
|
|
349
|
+
data: serializers.empathicVoice.ReturnCustomVoice.parseOrThrow(_response.body, {
|
|
350
|
+
unrecognizedObjectKeys: "passthrough",
|
|
351
|
+
allowUnrecognizedUnionMembers: true,
|
|
352
|
+
allowUnrecognizedEnumValues: true,
|
|
353
|
+
breadcrumbsPrefix: ["response"],
|
|
354
|
+
}),
|
|
355
|
+
rawResponse: _response.rawResponse,
|
|
356
|
+
};
|
|
325
357
|
}
|
|
326
358
|
if (_response.error.reason === "status-code") {
|
|
327
359
|
switch (_response.error.statusCode) {
|
|
@@ -331,11 +363,12 @@ class CustomVoices {
|
|
|
331
363
|
allowUnrecognizedUnionMembers: true,
|
|
332
364
|
allowUnrecognizedEnumValues: true,
|
|
333
365
|
breadcrumbsPrefix: ["response"],
|
|
334
|
-
}));
|
|
366
|
+
}), _response.rawResponse);
|
|
335
367
|
default:
|
|
336
368
|
throw new errors.HumeError({
|
|
337
369
|
statusCode: _response.error.statusCode,
|
|
338
370
|
body: _response.error.body,
|
|
371
|
+
rawResponse: _response.rawResponse,
|
|
339
372
|
});
|
|
340
373
|
}
|
|
341
374
|
}
|
|
@@ -344,12 +377,14 @@ class CustomVoices {
|
|
|
344
377
|
throw new errors.HumeError({
|
|
345
378
|
statusCode: _response.error.statusCode,
|
|
346
379
|
body: _response.error.rawBody,
|
|
380
|
+
rawResponse: _response.rawResponse,
|
|
347
381
|
});
|
|
348
382
|
case "timeout":
|
|
349
383
|
throw new errors.HumeTimeoutError("Timeout exceeded when calling POST /v0/evi/custom_voices/{id}.");
|
|
350
384
|
case "unknown":
|
|
351
385
|
throw new errors.HumeError({
|
|
352
386
|
message: _response.error.errorMessage,
|
|
387
|
+
rawResponse: _response.rawResponse,
|
|
353
388
|
});
|
|
354
389
|
}
|
|
355
390
|
});
|
|
@@ -368,12 +403,15 @@ class CustomVoices {
|
|
|
368
403
|
* await client.empathicVoice.customVoices.deleteCustomVoice("id")
|
|
369
404
|
*/
|
|
370
405
|
deleteCustomVoice(id, requestOptions) {
|
|
406
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteCustomVoice(id, requestOptions));
|
|
407
|
+
}
|
|
408
|
+
__deleteCustomVoice(id, requestOptions) {
|
|
371
409
|
return __awaiter(this, void 0, void 0, function* () {
|
|
372
410
|
var _a, _b, _c;
|
|
373
411
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
374
412
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Production, `v0/evi/custom_voices/${encodeURIComponent(id)}`),
|
|
375
413
|
method: "DELETE",
|
|
376
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.
|
|
414
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.2", "User-Agent": "hume/0.11.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
377
415
|
contentType: "application/json",
|
|
378
416
|
requestType: "json",
|
|
379
417
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -381,7 +419,7 @@ class CustomVoices {
|
|
|
381
419
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
382
420
|
});
|
|
383
421
|
if (_response.ok) {
|
|
384
|
-
return;
|
|
422
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
385
423
|
}
|
|
386
424
|
if (_response.error.reason === "status-code") {
|
|
387
425
|
switch (_response.error.statusCode) {
|
|
@@ -391,11 +429,12 @@ class CustomVoices {
|
|
|
391
429
|
allowUnrecognizedUnionMembers: true,
|
|
392
430
|
allowUnrecognizedEnumValues: true,
|
|
393
431
|
breadcrumbsPrefix: ["response"],
|
|
394
|
-
}));
|
|
432
|
+
}), _response.rawResponse);
|
|
395
433
|
default:
|
|
396
434
|
throw new errors.HumeError({
|
|
397
435
|
statusCode: _response.error.statusCode,
|
|
398
436
|
body: _response.error.body,
|
|
437
|
+
rawResponse: _response.rawResponse,
|
|
399
438
|
});
|
|
400
439
|
}
|
|
401
440
|
}
|
|
@@ -404,12 +443,14 @@ class CustomVoices {
|
|
|
404
443
|
throw new errors.HumeError({
|
|
405
444
|
statusCode: _response.error.statusCode,
|
|
406
445
|
body: _response.error.rawBody,
|
|
446
|
+
rawResponse: _response.rawResponse,
|
|
407
447
|
});
|
|
408
448
|
case "timeout":
|
|
409
449
|
throw new errors.HumeTimeoutError("Timeout exceeded when calling DELETE /v0/evi/custom_voices/{id}.");
|
|
410
450
|
case "unknown":
|
|
411
451
|
throw new errors.HumeError({
|
|
412
452
|
message: _response.error.errorMessage,
|
|
453
|
+
rawResponse: _response.rawResponse,
|
|
413
454
|
});
|
|
414
455
|
}
|
|
415
456
|
});
|
|
@@ -431,12 +472,15 @@ class CustomVoices {
|
|
|
431
472
|
* })
|
|
432
473
|
*/
|
|
433
474
|
updateCustomVoiceName(id, request, requestOptions) {
|
|
475
|
+
return core.HttpResponsePromise.fromPromise(this.__updateCustomVoiceName(id, request, requestOptions));
|
|
476
|
+
}
|
|
477
|
+
__updateCustomVoiceName(id, request, requestOptions) {
|
|
434
478
|
return __awaiter(this, void 0, void 0, function* () {
|
|
435
479
|
var _a, _b, _c;
|
|
436
480
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
437
481
|
url: (0, url_join_1.default)((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Production, `v0/evi/custom_voices/${encodeURIComponent(id)}`),
|
|
438
482
|
method: "PATCH",
|
|
439
|
-
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.
|
|
483
|
+
headers: Object.assign(Object.assign({ "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "hume", "X-Fern-SDK-Version": "0.11.2", "User-Agent": "hume/0.11.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version }, (yield this._getCustomAuthorizationHeaders())), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
440
484
|
contentType: "application/json",
|
|
441
485
|
requestType: "json",
|
|
442
486
|
body: serializers.empathicVoice.PostedCustomVoiceName.jsonOrThrow(request, {
|
|
@@ -448,7 +492,7 @@ class CustomVoices {
|
|
|
448
492
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
449
493
|
});
|
|
450
494
|
if (_response.ok) {
|
|
451
|
-
return _response.body;
|
|
495
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
452
496
|
}
|
|
453
497
|
if (_response.error.reason === "status-code") {
|
|
454
498
|
switch (_response.error.statusCode) {
|
|
@@ -458,11 +502,12 @@ class CustomVoices {
|
|
|
458
502
|
allowUnrecognizedUnionMembers: true,
|
|
459
503
|
allowUnrecognizedEnumValues: true,
|
|
460
504
|
breadcrumbsPrefix: ["response"],
|
|
461
|
-
}));
|
|
505
|
+
}), _response.rawResponse);
|
|
462
506
|
default:
|
|
463
507
|
throw new errors.HumeError({
|
|
464
508
|
statusCode: _response.error.statusCode,
|
|
465
509
|
body: _response.error.body,
|
|
510
|
+
rawResponse: _response.rawResponse,
|
|
466
511
|
});
|
|
467
512
|
}
|
|
468
513
|
}
|
|
@@ -471,12 +516,14 @@ class CustomVoices {
|
|
|
471
516
|
throw new errors.HumeError({
|
|
472
517
|
statusCode: _response.error.statusCode,
|
|
473
518
|
body: _response.error.rawBody,
|
|
519
|
+
rawResponse: _response.rawResponse,
|
|
474
520
|
});
|
|
475
521
|
case "timeout":
|
|
476
522
|
throw new errors.HumeTimeoutError("Timeout exceeded when calling PATCH /v0/evi/custom_voices/{id}.");
|
|
477
523
|
case "unknown":
|
|
478
524
|
throw new errors.HumeError({
|
|
479
525
|
message: _response.error.errorMessage,
|
|
526
|
+
rawResponse: _response.rawResponse,
|
|
480
527
|
});
|
|
481
528
|
}
|
|
482
529
|
});
|
|
@@ -59,7 +59,8 @@ export declare class Prompts {
|
|
|
59
59
|
* text: "<role>You are an AI weather assistant providing users with accurate and up-to-date weather information. Respond to user queries concisely and clearly. Use simple language and avoid technical jargon. Provide temperature, precipitation, wind conditions, and any weather alerts. Include helpful tips if severe weather is expected.</role>"
|
|
60
60
|
* })
|
|
61
61
|
*/
|
|
62
|
-
createPrompt(request: Hume.empathicVoice.PostedPrompt, requestOptions?: Prompts.RequestOptions):
|
|
62
|
+
createPrompt(request: Hume.empathicVoice.PostedPrompt, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnPrompt | undefined>;
|
|
63
|
+
private __createPrompt;
|
|
63
64
|
/**
|
|
64
65
|
* Fetches a list of a **Prompt's** versions.
|
|
65
66
|
*
|
|
@@ -74,7 +75,8 @@ export declare class Prompts {
|
|
|
74
75
|
* @example
|
|
75
76
|
* await client.empathicVoice.prompts.listPromptVersions("af699d45-2985-42cc-91b9-af9e5da3bac5")
|
|
76
77
|
*/
|
|
77
|
-
listPromptVersions(id: string, request?: Hume.empathicVoice.PromptsListPromptVersionsRequest, requestOptions?: Prompts.RequestOptions):
|
|
78
|
+
listPromptVersions(id: string, request?: Hume.empathicVoice.PromptsListPromptVersionsRequest, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnPagedPrompts>;
|
|
79
|
+
private __listPromptVersions;
|
|
78
80
|
/**
|
|
79
81
|
* Updates a **Prompt** by creating a new version of the **Prompt**.
|
|
80
82
|
*
|
|
@@ -92,7 +94,8 @@ export declare class Prompts {
|
|
|
92
94
|
* versionDescription: "This is an updated version of the Weather Assistant Prompt."
|
|
93
95
|
* })
|
|
94
96
|
*/
|
|
95
|
-
createPromptVersion(id: string, request: Hume.empathicVoice.PostedPromptVersion, requestOptions?: Prompts.RequestOptions):
|
|
97
|
+
createPromptVersion(id: string, request: Hume.empathicVoice.PostedPromptVersion, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnPrompt | undefined>;
|
|
98
|
+
private __createPromptVersion;
|
|
96
99
|
/**
|
|
97
100
|
* Deletes a **Prompt** and its versions.
|
|
98
101
|
*
|
|
@@ -106,7 +109,8 @@ export declare class Prompts {
|
|
|
106
109
|
* @example
|
|
107
110
|
* await client.empathicVoice.prompts.deletePrompt("af699d45-2985-42cc-91b9-af9e5da3bac5")
|
|
108
111
|
*/
|
|
109
|
-
deletePrompt(id: string, requestOptions?: Prompts.RequestOptions):
|
|
112
|
+
deletePrompt(id: string, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<void>;
|
|
113
|
+
private __deletePrompt;
|
|
110
114
|
/**
|
|
111
115
|
* Updates the name of a **Prompt**.
|
|
112
116
|
*
|
|
@@ -123,7 +127,8 @@ export declare class Prompts {
|
|
|
123
127
|
* name: "Updated Weather Assistant Prompt Name"
|
|
124
128
|
* })
|
|
125
129
|
*/
|
|
126
|
-
updatePromptName(id: string, request: Hume.empathicVoice.PostedPromptName, requestOptions?: Prompts.RequestOptions):
|
|
130
|
+
updatePromptName(id: string, request: Hume.empathicVoice.PostedPromptName, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<string>;
|
|
131
|
+
private __updatePromptName;
|
|
127
132
|
/**
|
|
128
133
|
* Fetches a specified version of a **Prompt**.
|
|
129
134
|
*
|
|
@@ -142,7 +147,8 @@ export declare class Prompts {
|
|
|
142
147
|
* @example
|
|
143
148
|
* await client.empathicVoice.prompts.getPromptVersion("af699d45-2985-42cc-91b9-af9e5da3bac5", 0)
|
|
144
149
|
*/
|
|
145
|
-
getPromptVersion(id: string, version: number, requestOptions?: Prompts.RequestOptions):
|
|
150
|
+
getPromptVersion(id: string, version: number, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnPrompt | undefined>;
|
|
151
|
+
private __getPromptVersion;
|
|
146
152
|
/**
|
|
147
153
|
* Deletes a specified version of a **Prompt**.
|
|
148
154
|
*
|
|
@@ -161,7 +167,8 @@ export declare class Prompts {
|
|
|
161
167
|
* @example
|
|
162
168
|
* await client.empathicVoice.prompts.deletePromptVersion("af699d45-2985-42cc-91b9-af9e5da3bac5", 1)
|
|
163
169
|
*/
|
|
164
|
-
deletePromptVersion(id: string, version: number, requestOptions?: Prompts.RequestOptions):
|
|
170
|
+
deletePromptVersion(id: string, version: number, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<void>;
|
|
171
|
+
private __deletePromptVersion;
|
|
165
172
|
/**
|
|
166
173
|
* Updates the description of a **Prompt**.
|
|
167
174
|
*
|
|
@@ -183,7 +190,8 @@ export declare class Prompts {
|
|
|
183
190
|
* versionDescription: "This is an updated version_description."
|
|
184
191
|
* })
|
|
185
192
|
*/
|
|
186
|
-
updatePromptDescription(id: string, version: number, request?: Hume.empathicVoice.PostedPromptVersionDescription, requestOptions?: Prompts.RequestOptions):
|
|
193
|
+
updatePromptDescription(id: string, version: number, request?: Hume.empathicVoice.PostedPromptVersionDescription, requestOptions?: Prompts.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnPrompt | undefined>;
|
|
194
|
+
private __updatePromptDescription;
|
|
187
195
|
protected _getCustomAuthorizationHeaders(): Promise<{
|
|
188
196
|
"X-Hume-Api-Key": string | undefined;
|
|
189
197
|
}>;
|