hume 0.14.2-beta.5 → 0.14.2-beta.7

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.
Files changed (125) hide show
  1. package/.claude/settings.local.json +4 -1
  2. package/Client.d.ts +1 -0
  3. package/api/resources/empathicVoice/client/Client.d.ts +1 -0
  4. package/api/resources/empathicVoice/resources/chat/client/Client.d.ts +1 -1
  5. package/api/resources/empathicVoice/resources/chat/client/Client.js +3 -28
  6. package/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +1 -0
  7. package/api/resources/empathicVoice/resources/chatGroups/client/Client.js +12 -20
  8. package/api/resources/empathicVoice/resources/chats/client/Client.d.ts +1 -0
  9. package/api/resources/empathicVoice/resources/chats/client/Client.js +9 -15
  10. package/api/resources/empathicVoice/resources/configs/client/Client.d.ts +1 -0
  11. package/api/resources/empathicVoice/resources/configs/client/Client.js +29 -52
  12. package/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +1 -0
  13. package/api/resources/empathicVoice/resources/prompts/client/Client.js +29 -52
  14. package/api/resources/empathicVoice/resources/tools/client/Client.d.ts +1 -0
  15. package/api/resources/empathicVoice/resources/tools/client/Client.js +27 -46
  16. package/api/resources/expressionMeasurement/client/Client.d.ts +1 -0
  17. package/api/resources/expressionMeasurement/resources/batch/client/Client.d.ts +1 -0
  18. package/api/resources/expressionMeasurement/resources/batch/client/Client.js +18 -30
  19. package/api/resources/expressionMeasurement/resources/stream/resources/stream/client/Client.d.ts +1 -0
  20. package/api/resources/expressionMeasurement/resources/stream/resources/stream/client/Socket.js +0 -4
  21. package/api/resources/tts/client/Client.d.ts +1 -0
  22. package/api/resources/tts/client/Client.js +16 -34
  23. package/api/resources/tts/index.d.ts +1 -1
  24. package/api/resources/tts/index.js +1 -1
  25. package/api/resources/tts/resources/index.d.ts +0 -1
  26. package/api/resources/tts/resources/index.js +0 -1
  27. package/api/resources/tts/resources/streamInput/client/Client.d.ts +4 -3
  28. package/api/resources/tts/resources/streamInput/client/Client.js +14 -15
  29. package/api/resources/tts/resources/streamInput/client/Socket.d.ts +1 -1
  30. package/api/resources/tts/resources/streamInput/client/Socket.js +0 -4
  31. package/api/resources/tts/resources/streamInput/index.d.ts +0 -1
  32. package/api/resources/tts/resources/streamInput/index.js +0 -1
  33. package/api/resources/tts/resources/streamInput/types/index.js +26 -14
  34. package/api/resources/tts/resources/voices/client/Client.d.ts +1 -0
  35. package/api/resources/tts/resources/voices/client/Client.js +10 -19
  36. package/api/resources/tts/types/index.d.ts +2 -2
  37. package/api/resources/tts/types/index.js +2 -2
  38. package/changes.md +843 -0
  39. package/comment_changes.txt +0 -0
  40. package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +37 -0
  41. package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +21 -0
  42. package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +37 -0
  43. package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +18 -0
  44. package/core/file.d.ts +11 -0
  45. package/diff.txt +18143 -0
  46. package/dist/Client.d.ts +1 -0
  47. package/dist/api/resources/empathicVoice/client/Client.d.ts +1 -0
  48. package/dist/api/resources/empathicVoice/resources/chat/client/Client.d.ts +1 -1
  49. package/dist/api/resources/empathicVoice/resources/chat/client/Client.js +3 -28
  50. package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +1 -0
  51. package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.js +12 -20
  52. package/dist/api/resources/empathicVoice/resources/chats/client/Client.d.ts +1 -0
  53. package/dist/api/resources/empathicVoice/resources/chats/client/Client.js +9 -15
  54. package/dist/api/resources/empathicVoice/resources/configs/client/Client.d.ts +1 -0
  55. package/dist/api/resources/empathicVoice/resources/configs/client/Client.js +29 -52
  56. package/dist/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +1 -0
  57. package/dist/api/resources/empathicVoice/resources/prompts/client/Client.js +29 -52
  58. package/dist/api/resources/empathicVoice/resources/tools/client/Client.d.ts +1 -0
  59. package/dist/api/resources/empathicVoice/resources/tools/client/Client.js +27 -46
  60. package/dist/api/resources/expressionMeasurement/client/Client.d.ts +1 -0
  61. package/dist/api/resources/expressionMeasurement/resources/batch/client/Client.d.ts +1 -0
  62. package/dist/api/resources/expressionMeasurement/resources/batch/client/Client.js +18 -30
  63. package/dist/api/resources/expressionMeasurement/resources/stream/resources/stream/client/Client.d.ts +1 -0
  64. package/dist/api/resources/expressionMeasurement/resources/stream/resources/stream/client/Socket.js +0 -4
  65. package/dist/api/resources/tts/client/Client.d.ts +1 -0
  66. package/dist/api/resources/tts/client/Client.js +16 -34
  67. package/dist/api/resources/tts/index.d.ts +1 -1
  68. package/dist/api/resources/tts/index.js +1 -1
  69. package/dist/api/resources/tts/resources/index.d.ts +0 -1
  70. package/dist/api/resources/tts/resources/index.js +0 -1
  71. package/dist/api/resources/tts/resources/streamInput/client/Client.d.ts +4 -3
  72. package/dist/api/resources/tts/resources/streamInput/client/Client.js +14 -15
  73. package/dist/api/resources/tts/resources/streamInput/client/Socket.d.ts +1 -1
  74. package/dist/api/resources/tts/resources/streamInput/client/Socket.js +0 -4
  75. package/dist/api/resources/tts/resources/streamInput/index.d.ts +0 -1
  76. package/dist/api/resources/tts/resources/streamInput/index.js +0 -1
  77. package/dist/api/resources/tts/resources/streamInput/types/index.js +26 -14
  78. package/dist/api/resources/tts/resources/voices/client/Client.d.ts +1 -0
  79. package/dist/api/resources/tts/resources/voices/client/Client.js +10 -19
  80. package/dist/api/resources/tts/types/index.d.ts +2 -2
  81. package/dist/api/resources/tts/types/index.js +2 -2
  82. package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +37 -0
  83. package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +21 -0
  84. package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +37 -0
  85. package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +18 -0
  86. package/dist/core/file.d.ts +11 -0
  87. package/dist/main.js +40944 -0
  88. package/dist/serialization/resources/tts/resources/index.d.ts +0 -1
  89. package/dist/serialization/resources/tts/resources/index.js +0 -1
  90. package/dist/serialization/resources/tts/resources/streamInput/client/socket/StreamInputSocketResponse.d.ts +3 -3
  91. package/dist/serialization/resources/tts/resources/streamInput/client/socket/StreamInputSocketResponse.js +2 -2
  92. package/dist/serialization/resources/tts/resources/streamInput/index.d.ts +0 -1
  93. package/dist/serialization/resources/tts/resources/streamInput/index.js +0 -1
  94. package/dist/serialization/resources/tts/resources/streamInput/types/SubscribeEvent.d.ts +4 -1
  95. package/dist/serialization/resources/tts/resources/streamInput/types/SubscribeEvent.js +55 -33
  96. package/dist/serialization/resources/tts/resources/streamInput/types/index.js +26 -14
  97. package/dist/serialization/resources/tts/types/index.d.ts +2 -2
  98. package/dist/serialization/resources/tts/types/index.js +2 -2
  99. package/dist/wrapper/HumeClient.d.ts +2 -2
  100. package/dist/wrapper/HumeClient.js +27 -25
  101. package/hume-v0.14.2-beta.6.tgz +0 -0
  102. package/hume-v0.14.2-beta.7.tgz +0 -0
  103. package/js_changes.txt +2610 -0
  104. package/main.js +40944 -0
  105. package/package.json +1 -1
  106. package/serialization/resources/tts/resources/index.d.ts +0 -1
  107. package/serialization/resources/tts/resources/index.js +0 -1
  108. package/serialization/resources/tts/resources/streamInput/client/socket/StreamInputSocketResponse.d.ts +3 -3
  109. package/serialization/resources/tts/resources/streamInput/client/socket/StreamInputSocketResponse.js +2 -2
  110. package/serialization/resources/tts/resources/streamInput/index.d.ts +0 -1
  111. package/serialization/resources/tts/resources/streamInput/index.js +0 -1
  112. package/serialization/resources/tts/resources/streamInput/types/SubscribeEvent.d.ts +4 -1
  113. package/serialization/resources/tts/resources/streamInput/types/SubscribeEvent.js +55 -33
  114. package/serialization/resources/tts/resources/streamInput/types/index.js +26 -14
  115. package/serialization/resources/tts/types/index.d.ts +2 -2
  116. package/serialization/resources/tts/types/index.js +2 -2
  117. package/tts-audio/tts-74f0e855-cd7e-46e7-9657-c9bdf4b60693.wav +0 -0
  118. package/tts-audio/tts-8d0d6c9c-f54d-4ffa-880a-556f3a77eb99.wav +0 -0
  119. package/tts-audio/tts-f2a1d9fa-8f28-4011-9c02-08364592d0a9.wav +0 -0
  120. package/wrapper/HumeClient.d.ts +2 -2
  121. package/wrapper/HumeClient.js +27 -25
  122. package/hume-v0.14.2-beta.2.tgz +0 -0
  123. package/hume-v0.14.2-beta.4.tgz +0 -0
  124. package/hume-v0.14.2-beta.5.tgz +0 -0
  125. package/hume-v0.14.2-beta1.tgz +0 -0
@@ -75,7 +75,7 @@ class Configs {
75
75
  listConfigs() {
76
76
  return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
77
77
  const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
78
- var _a, _b, _c;
78
+ var _a, _b, _c, _d;
79
79
  const { pageNumber, pageSize, restrictToMostRecent, name } = request;
80
80
  const _queryParams = {};
81
81
  if (pageNumber != null) {
@@ -91,8 +91,8 @@ class Configs {
91
91
  _queryParams["name"] = name;
92
92
  }
93
93
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
94
- const _response = yield core.fetcher({
95
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod)
94
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
95
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod)
96
96
  .base, "v0/evi/configs"),
97
97
  method: "GET",
98
98
  headers: _headers,
@@ -107,7 +107,6 @@ class Configs {
107
107
  unrecognizedObjectKeys: "passthrough",
108
108
  allowUnrecognizedUnionMembers: true,
109
109
  allowUnrecognizedEnumValues: true,
110
- skipValidation: true,
111
110
  breadcrumbsPrefix: ["response"],
112
111
  }),
113
112
  rawResponse: _response.rawResponse,
@@ -120,7 +119,6 @@ class Configs {
120
119
  unrecognizedObjectKeys: "passthrough",
121
120
  allowUnrecognizedUnionMembers: true,
122
121
  allowUnrecognizedEnumValues: true,
123
- skipValidation: true,
124
122
  breadcrumbsPrefix: ["response"],
125
123
  }), _response.rawResponse);
126
124
  default:
@@ -209,19 +207,16 @@ class Configs {
209
207
  }
210
208
  __createConfig(request, requestOptions) {
211
209
  return __awaiter(this, void 0, void 0, function* () {
212
- var _a, _b, _c;
210
+ var _a, _b, _c, _d;
213
211
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
214
- const _response = yield core.fetcher({
215
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, "v0/evi/configs"),
212
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
213
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, "v0/evi/configs"),
216
214
  method: "POST",
217
215
  headers: _headers,
218
216
  contentType: "application/json",
219
217
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
220
218
  requestType: "json",
221
- body: serializers.empathicVoice.PostedConfig.jsonOrThrow(request, {
222
- unrecognizedObjectKeys: "strip",
223
- omitUndefined: true,
224
- }),
219
+ body: serializers.empathicVoice.PostedConfig.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
225
220
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
226
221
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
227
222
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -232,7 +227,6 @@ class Configs {
232
227
  unrecognizedObjectKeys: "passthrough",
233
228
  allowUnrecognizedUnionMembers: true,
234
229
  allowUnrecognizedEnumValues: true,
235
- skipValidation: true,
236
230
  breadcrumbsPrefix: ["response"],
237
231
  }),
238
232
  rawResponse: _response.rawResponse,
@@ -245,7 +239,6 @@ class Configs {
245
239
  unrecognizedObjectKeys: "passthrough",
246
240
  allowUnrecognizedUnionMembers: true,
247
241
  allowUnrecognizedEnumValues: true,
248
- skipValidation: true,
249
242
  breadcrumbsPrefix: ["response"],
250
243
  }), _response.rawResponse);
251
244
  default:
@@ -290,7 +283,7 @@ class Configs {
290
283
  listConfigVersions(id_1) {
291
284
  return __awaiter(this, arguments, void 0, function* (id, request = {}, requestOptions) {
292
285
  const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
293
- var _a, _b, _c;
286
+ var _a, _b, _c, _d;
294
287
  const { pageNumber, pageSize, restrictToMostRecent } = request;
295
288
  const _queryParams = {};
296
289
  if (pageNumber != null) {
@@ -303,8 +296,8 @@ class Configs {
303
296
  _queryParams["restrict_to_most_recent"] = restrictToMostRecent.toString();
304
297
  }
305
298
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
306
- const _response = yield core.fetcher({
307
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod)
299
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
300
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod)
308
301
  .base, `v0/evi/configs/${encodeURIComponent(id)}`),
309
302
  method: "GET",
310
303
  headers: _headers,
@@ -319,7 +312,6 @@ class Configs {
319
312
  unrecognizedObjectKeys: "passthrough",
320
313
  allowUnrecognizedUnionMembers: true,
321
314
  allowUnrecognizedEnumValues: true,
322
- skipValidation: true,
323
315
  breadcrumbsPrefix: ["response"],
324
316
  }),
325
317
  rawResponse: _response.rawResponse,
@@ -332,7 +324,6 @@ class Configs {
332
324
  unrecognizedObjectKeys: "passthrough",
333
325
  allowUnrecognizedUnionMembers: true,
334
326
  allowUnrecognizedEnumValues: true,
335
- skipValidation: true,
336
327
  breadcrumbsPrefix: ["response"],
337
328
  }), _response.rawResponse);
338
329
  default:
@@ -425,10 +416,10 @@ class Configs {
425
416
  }
426
417
  __createConfigVersion(id, request, requestOptions) {
427
418
  return __awaiter(this, void 0, void 0, function* () {
428
- var _a, _b, _c;
419
+ var _a, _b, _c, _d;
429
420
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
430
- const _response = yield core.fetcher({
431
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}`),
421
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
422
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}`),
432
423
  method: "POST",
433
424
  headers: _headers,
434
425
  contentType: "application/json",
@@ -436,7 +427,6 @@ class Configs {
436
427
  requestType: "json",
437
428
  body: serializers.empathicVoice.PostedConfigVersion.jsonOrThrow(request, {
438
429
  unrecognizedObjectKeys: "strip",
439
- omitUndefined: true,
440
430
  }),
441
431
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
442
432
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -448,7 +438,6 @@ class Configs {
448
438
  unrecognizedObjectKeys: "passthrough",
449
439
  allowUnrecognizedUnionMembers: true,
450
440
  allowUnrecognizedEnumValues: true,
451
- skipValidation: true,
452
441
  breadcrumbsPrefix: ["response"],
453
442
  }),
454
443
  rawResponse: _response.rawResponse,
@@ -461,7 +450,6 @@ class Configs {
461
450
  unrecognizedObjectKeys: "passthrough",
462
451
  allowUnrecognizedUnionMembers: true,
463
452
  allowUnrecognizedEnumValues: true,
464
- skipValidation: true,
465
453
  breadcrumbsPrefix: ["response"],
466
454
  }), _response.rawResponse);
467
455
  default:
@@ -507,10 +495,10 @@ class Configs {
507
495
  }
508
496
  __deleteConfig(id, requestOptions) {
509
497
  return __awaiter(this, void 0, void 0, function* () {
510
- var _a, _b, _c;
498
+ var _a, _b, _c, _d;
511
499
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
512
- const _response = yield core.fetcher({
513
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}`),
500
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
501
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}`),
514
502
  method: "DELETE",
515
503
  headers: _headers,
516
504
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
@@ -528,7 +516,6 @@ class Configs {
528
516
  unrecognizedObjectKeys: "passthrough",
529
517
  allowUnrecognizedUnionMembers: true,
530
518
  allowUnrecognizedEnumValues: true,
531
- skipValidation: true,
532
519
  breadcrumbsPrefix: ["response"],
533
520
  }), _response.rawResponse);
534
521
  default:
@@ -577,19 +564,16 @@ class Configs {
577
564
  }
578
565
  __updateConfigName(id, request, requestOptions) {
579
566
  return __awaiter(this, void 0, void 0, function* () {
580
- var _a, _b, _c;
567
+ var _a, _b, _c, _d;
581
568
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
582
- const _response = yield core.fetcher({
583
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}`),
569
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
570
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}`),
584
571
  method: "PATCH",
585
572
  headers: _headers,
586
573
  contentType: "application/json",
587
574
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
588
575
  requestType: "json",
589
- body: serializers.empathicVoice.PostedConfigName.jsonOrThrow(request, {
590
- unrecognizedObjectKeys: "strip",
591
- omitUndefined: true,
592
- }),
576
+ body: serializers.empathicVoice.PostedConfigName.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
593
577
  responseType: "text",
594
578
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
595
579
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -605,7 +589,6 @@ class Configs {
605
589
  unrecognizedObjectKeys: "passthrough",
606
590
  allowUnrecognizedUnionMembers: true,
607
591
  allowUnrecognizedEnumValues: true,
608
- skipValidation: true,
609
592
  breadcrumbsPrefix: ["response"],
610
593
  }), _response.rawResponse);
611
594
  default:
@@ -656,10 +639,10 @@ class Configs {
656
639
  }
657
640
  __getConfigVersion(id, version, requestOptions) {
658
641
  return __awaiter(this, void 0, void 0, function* () {
659
- var _a, _b, _c;
642
+ var _a, _b, _c, _d;
660
643
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
661
- const _response = yield core.fetcher({
662
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
644
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
645
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
663
646
  method: "GET",
664
647
  headers: _headers,
665
648
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
@@ -673,7 +656,6 @@ class Configs {
673
656
  unrecognizedObjectKeys: "passthrough",
674
657
  allowUnrecognizedUnionMembers: true,
675
658
  allowUnrecognizedEnumValues: true,
676
- skipValidation: true,
677
659
  breadcrumbsPrefix: ["response"],
678
660
  }),
679
661
  rawResponse: _response.rawResponse,
@@ -686,7 +668,6 @@ class Configs {
686
668
  unrecognizedObjectKeys: "passthrough",
687
669
  allowUnrecognizedUnionMembers: true,
688
670
  allowUnrecognizedEnumValues: true,
689
- skipValidation: true,
690
671
  breadcrumbsPrefix: ["response"],
691
672
  }), _response.rawResponse);
692
673
  default:
@@ -737,10 +718,10 @@ class Configs {
737
718
  }
738
719
  __deleteConfigVersion(id, version, requestOptions) {
739
720
  return __awaiter(this, void 0, void 0, function* () {
740
- var _a, _b, _c;
721
+ var _a, _b, _c, _d;
741
722
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
742
- const _response = yield core.fetcher({
743
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
723
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
724
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
744
725
  method: "DELETE",
745
726
  headers: _headers,
746
727
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
@@ -758,7 +739,6 @@ class Configs {
758
739
  unrecognizedObjectKeys: "passthrough",
759
740
  allowUnrecognizedUnionMembers: true,
760
741
  allowUnrecognizedEnumValues: true,
761
- skipValidation: true,
762
742
  breadcrumbsPrefix: ["response"],
763
743
  }), _response.rawResponse);
764
744
  default:
@@ -812,10 +792,10 @@ class Configs {
812
792
  }
813
793
  __updateConfigDescription(id_1, version_1) {
814
794
  return __awaiter(this, arguments, void 0, function* (id, version, request = {}, requestOptions) {
815
- var _a, _b, _c;
795
+ var _a, _b, _c, _d;
816
796
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
817
- const _response = yield core.fetcher({
818
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
797
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
798
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/configs/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
819
799
  method: "PATCH",
820
800
  headers: _headers,
821
801
  contentType: "application/json",
@@ -823,7 +803,6 @@ class Configs {
823
803
  requestType: "json",
824
804
  body: serializers.empathicVoice.PostedConfigVersionDescription.jsonOrThrow(request, {
825
805
  unrecognizedObjectKeys: "strip",
826
- omitUndefined: true,
827
806
  }),
828
807
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
829
808
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -835,7 +814,6 @@ class Configs {
835
814
  unrecognizedObjectKeys: "passthrough",
836
815
  allowUnrecognizedUnionMembers: true,
837
816
  allowUnrecognizedEnumValues: true,
838
- skipValidation: true,
839
817
  breadcrumbsPrefix: ["response"],
840
818
  }),
841
819
  rawResponse: _response.rawResponse,
@@ -848,7 +826,6 @@ class Configs {
848
826
  unrecognizedObjectKeys: "passthrough",
849
827
  allowUnrecognizedUnionMembers: true,
850
828
  allowUnrecognizedEnumValues: true,
851
- skipValidation: true,
852
829
  breadcrumbsPrefix: ["response"],
853
830
  }), _response.rawResponse);
854
831
  default:
@@ -12,6 +12,7 @@ export declare namespace Prompts {
12
12
  apiKey?: core.Supplier<string | undefined>;
13
13
  /** Additional headers to include in requests. */
14
14
  headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
15
+ fetcher?: core.FetchFunction;
15
16
  }
16
17
  interface RequestOptions {
17
18
  /** The maximum time to wait for a response in seconds. */
@@ -75,7 +75,7 @@ class Prompts {
75
75
  listPrompts() {
76
76
  return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
77
77
  const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
78
- var _a, _b, _c;
78
+ var _a, _b, _c, _d;
79
79
  const { pageNumber, pageSize, restrictToMostRecent, name } = request;
80
80
  const _queryParams = {};
81
81
  if (pageNumber != null) {
@@ -91,8 +91,8 @@ class Prompts {
91
91
  _queryParams["name"] = name;
92
92
  }
93
93
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
94
- const _response = yield core.fetcher({
95
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod)
94
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
95
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod)
96
96
  .base, "v0/evi/prompts"),
97
97
  method: "GET",
98
98
  headers: _headers,
@@ -107,7 +107,6 @@ class Prompts {
107
107
  unrecognizedObjectKeys: "passthrough",
108
108
  allowUnrecognizedUnionMembers: true,
109
109
  allowUnrecognizedEnumValues: true,
110
- skipValidation: true,
111
110
  breadcrumbsPrefix: ["response"],
112
111
  }),
113
112
  rawResponse: _response.rawResponse,
@@ -120,7 +119,6 @@ class Prompts {
120
119
  unrecognizedObjectKeys: "passthrough",
121
120
  allowUnrecognizedUnionMembers: true,
122
121
  allowUnrecognizedEnumValues: true,
123
- skipValidation: true,
124
122
  breadcrumbsPrefix: ["response"],
125
123
  }), _response.rawResponse);
126
124
  default:
@@ -182,19 +180,16 @@ class Prompts {
182
180
  }
183
181
  __createPrompt(request, requestOptions) {
184
182
  return __awaiter(this, void 0, void 0, function* () {
185
- var _a, _b, _c;
183
+ var _a, _b, _c, _d;
186
184
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
187
- const _response = yield core.fetcher({
188
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, "v0/evi/prompts"),
185
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
186
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, "v0/evi/prompts"),
189
187
  method: "POST",
190
188
  headers: _headers,
191
189
  contentType: "application/json",
192
190
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
193
191
  requestType: "json",
194
- body: serializers.empathicVoice.PostedPrompt.jsonOrThrow(request, {
195
- unrecognizedObjectKeys: "strip",
196
- omitUndefined: true,
197
- }),
192
+ body: serializers.empathicVoice.PostedPrompt.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
198
193
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
199
194
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
200
195
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -205,7 +200,6 @@ class Prompts {
205
200
  unrecognizedObjectKeys: "passthrough",
206
201
  allowUnrecognizedUnionMembers: true,
207
202
  allowUnrecognizedEnumValues: true,
208
- skipValidation: true,
209
203
  breadcrumbsPrefix: ["response"],
210
204
  }),
211
205
  rawResponse: _response.rawResponse,
@@ -218,7 +212,6 @@ class Prompts {
218
212
  unrecognizedObjectKeys: "passthrough",
219
213
  allowUnrecognizedUnionMembers: true,
220
214
  allowUnrecognizedEnumValues: true,
221
- skipValidation: true,
222
215
  breadcrumbsPrefix: ["response"],
223
216
  }), _response.rawResponse);
224
217
  default:
@@ -265,7 +258,7 @@ class Prompts {
265
258
  }
266
259
  __listPromptVersions(id_1) {
267
260
  return __awaiter(this, arguments, void 0, function* (id, request = {}, requestOptions) {
268
- var _a, _b, _c;
261
+ var _a, _b, _c, _d;
269
262
  const { pageNumber, pageSize, restrictToMostRecent } = request;
270
263
  const _queryParams = {};
271
264
  if (pageNumber != null) {
@@ -278,8 +271,8 @@ class Prompts {
278
271
  _queryParams["restrict_to_most_recent"] = restrictToMostRecent.toString();
279
272
  }
280
273
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
281
- const _response = yield core.fetcher({
282
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
274
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
275
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
283
276
  method: "GET",
284
277
  headers: _headers,
285
278
  queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
@@ -293,7 +286,6 @@ class Prompts {
293
286
  unrecognizedObjectKeys: "passthrough",
294
287
  allowUnrecognizedUnionMembers: true,
295
288
  allowUnrecognizedEnumValues: true,
296
- skipValidation: true,
297
289
  breadcrumbsPrefix: ["response"],
298
290
  }),
299
291
  rawResponse: _response.rawResponse,
@@ -306,7 +298,6 @@ class Prompts {
306
298
  unrecognizedObjectKeys: "passthrough",
307
299
  allowUnrecognizedUnionMembers: true,
308
300
  allowUnrecognizedEnumValues: true,
309
- skipValidation: true,
310
301
  breadcrumbsPrefix: ["response"],
311
302
  }), _response.rawResponse);
312
303
  default:
@@ -356,10 +347,10 @@ class Prompts {
356
347
  }
357
348
  __createPromptVersion(id, request, requestOptions) {
358
349
  return __awaiter(this, void 0, void 0, function* () {
359
- var _a, _b, _c;
350
+ var _a, _b, _c, _d;
360
351
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
361
- const _response = yield core.fetcher({
362
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
352
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
353
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
363
354
  method: "POST",
364
355
  headers: _headers,
365
356
  contentType: "application/json",
@@ -367,7 +358,6 @@ class Prompts {
367
358
  requestType: "json",
368
359
  body: serializers.empathicVoice.PostedPromptVersion.jsonOrThrow(request, {
369
360
  unrecognizedObjectKeys: "strip",
370
- omitUndefined: true,
371
361
  }),
372
362
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
373
363
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -379,7 +369,6 @@ class Prompts {
379
369
  unrecognizedObjectKeys: "passthrough",
380
370
  allowUnrecognizedUnionMembers: true,
381
371
  allowUnrecognizedEnumValues: true,
382
- skipValidation: true,
383
372
  breadcrumbsPrefix: ["response"],
384
373
  }),
385
374
  rawResponse: _response.rawResponse,
@@ -392,7 +381,6 @@ class Prompts {
392
381
  unrecognizedObjectKeys: "passthrough",
393
382
  allowUnrecognizedUnionMembers: true,
394
383
  allowUnrecognizedEnumValues: true,
395
- skipValidation: true,
396
384
  breadcrumbsPrefix: ["response"],
397
385
  }), _response.rawResponse);
398
386
  default:
@@ -438,10 +426,10 @@ class Prompts {
438
426
  }
439
427
  __deletePrompt(id, requestOptions) {
440
428
  return __awaiter(this, void 0, void 0, function* () {
441
- var _a, _b, _c;
429
+ var _a, _b, _c, _d;
442
430
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
443
- const _response = yield core.fetcher({
444
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
431
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
432
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
445
433
  method: "DELETE",
446
434
  headers: _headers,
447
435
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
@@ -459,7 +447,6 @@ class Prompts {
459
447
  unrecognizedObjectKeys: "passthrough",
460
448
  allowUnrecognizedUnionMembers: true,
461
449
  allowUnrecognizedEnumValues: true,
462
- skipValidation: true,
463
450
  breadcrumbsPrefix: ["response"],
464
451
  }), _response.rawResponse);
465
452
  default:
@@ -508,19 +495,16 @@ class Prompts {
508
495
  }
509
496
  __updatePromptName(id, request, requestOptions) {
510
497
  return __awaiter(this, void 0, void 0, function* () {
511
- var _a, _b, _c;
498
+ var _a, _b, _c, _d;
512
499
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
513
- const _response = yield core.fetcher({
514
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
500
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
501
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}`),
515
502
  method: "PATCH",
516
503
  headers: _headers,
517
504
  contentType: "application/json",
518
505
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
519
506
  requestType: "json",
520
- body: serializers.empathicVoice.PostedPromptName.jsonOrThrow(request, {
521
- unrecognizedObjectKeys: "strip",
522
- omitUndefined: true,
523
- }),
507
+ body: serializers.empathicVoice.PostedPromptName.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
524
508
  responseType: "text",
525
509
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
526
510
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -536,7 +520,6 @@ class Prompts {
536
520
  unrecognizedObjectKeys: "passthrough",
537
521
  allowUnrecognizedUnionMembers: true,
538
522
  allowUnrecognizedEnumValues: true,
539
- skipValidation: true,
540
523
  breadcrumbsPrefix: ["response"],
541
524
  }), _response.rawResponse);
542
525
  default:
@@ -587,10 +570,10 @@ class Prompts {
587
570
  }
588
571
  __getPromptVersion(id, version, requestOptions) {
589
572
  return __awaiter(this, void 0, void 0, function* () {
590
- var _a, _b, _c;
573
+ var _a, _b, _c, _d;
591
574
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
592
- const _response = yield core.fetcher({
593
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
575
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
576
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
594
577
  method: "GET",
595
578
  headers: _headers,
596
579
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
@@ -604,7 +587,6 @@ class Prompts {
604
587
  unrecognizedObjectKeys: "passthrough",
605
588
  allowUnrecognizedUnionMembers: true,
606
589
  allowUnrecognizedEnumValues: true,
607
- skipValidation: true,
608
590
  breadcrumbsPrefix: ["response"],
609
591
  }),
610
592
  rawResponse: _response.rawResponse,
@@ -617,7 +599,6 @@ class Prompts {
617
599
  unrecognizedObjectKeys: "passthrough",
618
600
  allowUnrecognizedUnionMembers: true,
619
601
  allowUnrecognizedEnumValues: true,
620
- skipValidation: true,
621
602
  breadcrumbsPrefix: ["response"],
622
603
  }), _response.rawResponse);
623
604
  default:
@@ -668,10 +649,10 @@ class Prompts {
668
649
  }
669
650
  __deletePromptVersion(id, version, requestOptions) {
670
651
  return __awaiter(this, void 0, void 0, function* () {
671
- var _a, _b, _c;
652
+ var _a, _b, _c, _d;
672
653
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
673
- const _response = yield core.fetcher({
674
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
654
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
655
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
675
656
  method: "DELETE",
676
657
  headers: _headers,
677
658
  queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
@@ -689,7 +670,6 @@ class Prompts {
689
670
  unrecognizedObjectKeys: "passthrough",
690
671
  allowUnrecognizedUnionMembers: true,
691
672
  allowUnrecognizedEnumValues: true,
692
- skipValidation: true,
693
673
  breadcrumbsPrefix: ["response"],
694
674
  }), _response.rawResponse);
695
675
  default:
@@ -743,10 +723,10 @@ class Prompts {
743
723
  }
744
724
  __updatePromptDescription(id_1, version_1) {
745
725
  return __awaiter(this, arguments, void 0, function* (id, version, request = {}, requestOptions) {
746
- var _a, _b, _c;
726
+ var _a, _b, _c, _d;
747
727
  let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
748
- const _response = yield core.fetcher({
749
- url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
728
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
729
+ url: core.url.join((_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : ((_d = (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.HumeEnvironment.Prod).base, `v0/evi/prompts/${encodeURIComponent(id)}/version/${encodeURIComponent(version)}`),
750
730
  method: "PATCH",
751
731
  headers: _headers,
752
732
  contentType: "application/json",
@@ -754,7 +734,6 @@ class Prompts {
754
734
  requestType: "json",
755
735
  body: serializers.empathicVoice.PostedPromptVersionDescription.jsonOrThrow(request, {
756
736
  unrecognizedObjectKeys: "strip",
757
- omitUndefined: true,
758
737
  }),
759
738
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
760
739
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
@@ -766,7 +745,6 @@ class Prompts {
766
745
  unrecognizedObjectKeys: "passthrough",
767
746
  allowUnrecognizedUnionMembers: true,
768
747
  allowUnrecognizedEnumValues: true,
769
- skipValidation: true,
770
748
  breadcrumbsPrefix: ["response"],
771
749
  }),
772
750
  rawResponse: _response.rawResponse,
@@ -779,7 +757,6 @@ class Prompts {
779
757
  unrecognizedObjectKeys: "passthrough",
780
758
  allowUnrecognizedUnionMembers: true,
781
759
  allowUnrecognizedEnumValues: true,
782
- skipValidation: true,
783
760
  breadcrumbsPrefix: ["response"],
784
761
  }), _response.rawResponse);
785
762
  default:
@@ -12,6 +12,7 @@ export declare namespace Tools {
12
12
  apiKey?: core.Supplier<string | undefined>;
13
13
  /** Additional headers to include in requests. */
14
14
  headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
15
+ fetcher?: core.FetchFunction;
15
16
  }
16
17
  interface RequestOptions {
17
18
  /** The maximum time to wait for a response in seconds. */