hume 0.11.5-beta.1 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (296) hide show
  1. package/.mock/definition/empathic-voice/__package__.yml +27 -517
  2. package/.mock/definition/empathic-voice/chatGroups.yml +1 -1
  3. package/.mock/definition/empathic-voice/chats.yml +1 -1
  4. package/.mock/definition/empathic-voice/configs.yml +34 -151
  5. package/.mock/definition/empathic-voice/prompts.yml +21 -21
  6. package/.mock/definition/empathic-voice/tools.yml +10 -10
  7. package/.mock/definition/tts/__package__.yml +6 -22
  8. package/api/resources/empathicVoice/client/Client.d.ts +0 -3
  9. package/api/resources/empathicVoice/client/Client.js +8 -13
  10. package/api/resources/empathicVoice/resources/chat/client/Socket.js +1 -4
  11. package/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +1 -1
  12. package/api/resources/empathicVoice/resources/chatGroups/client/Client.js +1 -1
  13. package/api/resources/empathicVoice/resources/chats/client/Client.d.ts +1 -1
  14. package/api/resources/empathicVoice/resources/chats/client/Client.js +1 -1
  15. package/api/resources/empathicVoice/resources/configs/client/Client.d.ts +13 -13
  16. package/api/resources/empathicVoice/resources/configs/client/Client.js +13 -13
  17. package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +4 -4
  18. package/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +3 -3
  19. package/api/resources/empathicVoice/resources/index.d.ts +0 -2
  20. package/api/resources/empathicVoice/resources/index.js +1 -3
  21. package/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +10 -10
  22. package/api/resources/empathicVoice/resources/prompts/client/Client.js +10 -10
  23. package/api/resources/empathicVoice/resources/prompts/client/requests/PostedPrompt.d.ts +1 -1
  24. package/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptVersion.d.ts +1 -1
  25. package/api/resources/empathicVoice/resources/tools/client/Client.d.ts +10 -10
  26. package/api/resources/empathicVoice/resources/tools/client/Client.js +10 -10
  27. package/api/resources/empathicVoice/types/JsonMessage.d.ts +1 -1
  28. package/api/resources/empathicVoice/types/PostedBuiltinTool.d.ts +1 -1
  29. package/api/resources/empathicVoice/types/PostedBuiltinToolName.d.ts +1 -1
  30. package/api/resources/empathicVoice/types/PostedWebhookSpec.d.ts +1 -1
  31. package/api/resources/empathicVoice/types/ReturnConfig.d.ts +2 -3
  32. package/api/resources/empathicVoice/types/ReturnPrompt.d.ts +1 -1
  33. package/api/resources/empathicVoice/types/ReturnWebhookSpec.d.ts +1 -1
  34. package/api/resources/empathicVoice/types/VoiceId.d.ts +10 -0
  35. package/api/resources/empathicVoice/types/VoiceName.d.ts +10 -0
  36. package/api/resources/empathicVoice/types/VoiceProvider.d.ts +8 -0
  37. package/api/resources/empathicVoice/types/{PostedVoiceProvider.js → VoiceProvider.js} +2 -2
  38. package/api/resources/empathicVoice/types/VoiceRef.d.ts +5 -0
  39. package/api/resources/empathicVoice/types/index.d.ts +4 -18
  40. package/api/resources/empathicVoice/types/index.js +4 -18
  41. package/dist/api/resources/empathicVoice/client/Client.d.ts +0 -3
  42. package/dist/api/resources/empathicVoice/client/Client.js +8 -13
  43. package/dist/api/resources/empathicVoice/resources/chat/client/Socket.js +1 -4
  44. package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.d.ts +1 -1
  45. package/dist/api/resources/empathicVoice/resources/chatGroups/client/Client.js +1 -1
  46. package/dist/api/resources/empathicVoice/resources/chats/client/Client.d.ts +1 -1
  47. package/dist/api/resources/empathicVoice/resources/chats/client/Client.js +1 -1
  48. package/dist/api/resources/empathicVoice/resources/configs/client/Client.d.ts +13 -13
  49. package/dist/api/resources/empathicVoice/resources/configs/client/Client.js +13 -13
  50. package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +4 -4
  51. package/dist/api/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +3 -3
  52. package/dist/api/resources/empathicVoice/resources/index.d.ts +0 -2
  53. package/dist/api/resources/empathicVoice/resources/index.js +1 -3
  54. package/dist/api/resources/empathicVoice/resources/prompts/client/Client.d.ts +10 -10
  55. package/dist/api/resources/empathicVoice/resources/prompts/client/Client.js +10 -10
  56. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PostedPrompt.d.ts +1 -1
  57. package/dist/api/resources/empathicVoice/resources/prompts/client/requests/PostedPromptVersion.d.ts +1 -1
  58. package/dist/api/resources/empathicVoice/resources/tools/client/Client.d.ts +10 -10
  59. package/dist/api/resources/empathicVoice/resources/tools/client/Client.js +10 -10
  60. package/dist/api/resources/empathicVoice/types/JsonMessage.d.ts +1 -1
  61. package/dist/api/resources/empathicVoice/types/PostedBuiltinTool.d.ts +1 -1
  62. package/dist/api/resources/empathicVoice/types/PostedBuiltinToolName.d.ts +1 -1
  63. package/dist/api/resources/empathicVoice/types/PostedWebhookSpec.d.ts +1 -1
  64. package/dist/api/resources/empathicVoice/types/ReturnConfig.d.ts +2 -3
  65. package/dist/api/resources/empathicVoice/types/ReturnPrompt.d.ts +1 -1
  66. package/dist/api/resources/empathicVoice/types/ReturnWebhookSpec.d.ts +1 -1
  67. package/dist/api/resources/empathicVoice/types/VoiceId.d.ts +10 -0
  68. package/dist/api/resources/empathicVoice/types/VoiceName.d.ts +10 -0
  69. package/dist/api/resources/empathicVoice/types/VoiceProvider.d.ts +8 -0
  70. package/{api/resources/empathicVoice/types/ReturnVoiceProvider.js → dist/api/resources/empathicVoice/types/VoiceProvider.js} +2 -2
  71. package/dist/api/resources/empathicVoice/types/VoiceRef.d.ts +5 -0
  72. package/dist/api/resources/empathicVoice/types/index.d.ts +4 -18
  73. package/dist/api/resources/empathicVoice/types/index.js +4 -18
  74. package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +2 -2
  75. package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.js +2 -2
  76. package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +2 -2
  77. package/dist/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.js +2 -2
  78. package/dist/serialization/resources/empathicVoice/resources/index.d.ts +0 -2
  79. package/dist/serialization/resources/empathicVoice/resources/index.js +1 -3
  80. package/dist/serialization/resources/empathicVoice/types/JsonMessage.d.ts +1 -2
  81. package/dist/serialization/resources/empathicVoice/types/JsonMessage.js +0 -2
  82. package/dist/serialization/resources/empathicVoice/types/ReturnConfig.d.ts +1 -2
  83. package/dist/serialization/resources/empathicVoice/types/ReturnConfig.js +1 -2
  84. package/dist/serialization/resources/empathicVoice/types/VoiceId.d.ts +14 -0
  85. package/dist/serialization/resources/empathicVoice/types/VoiceId.js +45 -0
  86. package/dist/serialization/resources/empathicVoice/types/VoiceName.d.ts +14 -0
  87. package/dist/serialization/resources/empathicVoice/types/VoiceName.js +45 -0
  88. package/{serialization/resources/empathicVoice/types/PostedVoiceProvider.d.ts → dist/serialization/resources/empathicVoice/types/VoiceProvider.d.ts} +2 -2
  89. package/dist/serialization/resources/empathicVoice/types/{ReturnVoiceProvider.js → VoiceProvider.js} +2 -2
  90. package/dist/serialization/resources/empathicVoice/types/VoiceRef.d.ts +12 -0
  91. package/dist/serialization/resources/empathicVoice/types/{PostedCustomVoiceBaseVoice.js → VoiceRef.js} +4 -2
  92. package/dist/serialization/resources/empathicVoice/types/index.d.ts +4 -18
  93. package/dist/serialization/resources/empathicVoice/types/index.js +4 -18
  94. package/dist/version.d.ts +1 -1
  95. package/dist/version.js +1 -1
  96. package/package.json +1 -1
  97. package/reference.md +43 -485
  98. package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.d.ts +2 -2
  99. package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfig.js +2 -2
  100. package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.d.ts +2 -2
  101. package/serialization/resources/empathicVoice/resources/configs/client/requests/PostedConfigVersion.js +2 -2
  102. package/serialization/resources/empathicVoice/resources/index.d.ts +0 -2
  103. package/serialization/resources/empathicVoice/resources/index.js +1 -3
  104. package/serialization/resources/empathicVoice/types/JsonMessage.d.ts +1 -2
  105. package/serialization/resources/empathicVoice/types/JsonMessage.js +0 -2
  106. package/serialization/resources/empathicVoice/types/ReturnConfig.d.ts +1 -2
  107. package/serialization/resources/empathicVoice/types/ReturnConfig.js +1 -2
  108. package/serialization/resources/empathicVoice/types/VoiceId.d.ts +14 -0
  109. package/serialization/resources/empathicVoice/types/VoiceId.js +45 -0
  110. package/serialization/resources/empathicVoice/types/VoiceName.d.ts +14 -0
  111. package/serialization/resources/empathicVoice/types/VoiceName.js +45 -0
  112. package/serialization/resources/empathicVoice/types/{ReturnVoiceProvider.d.ts → VoiceProvider.d.ts} +2 -2
  113. package/{dist/serialization/resources/empathicVoice/types/PostedVoiceProvider.js → serialization/resources/empathicVoice/types/VoiceProvider.js} +2 -2
  114. package/serialization/resources/empathicVoice/types/VoiceRef.d.ts +12 -0
  115. package/{dist/serialization/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.js → serialization/resources/empathicVoice/types/VoiceRef.js} +4 -2
  116. package/serialization/resources/empathicVoice/types/index.d.ts +4 -18
  117. package/serialization/resources/empathicVoice/types/index.js +4 -18
  118. package/version.d.ts +1 -1
  119. package/version.js +1 -1
  120. package/.mock/definition/empathic-voice/customVoices.yml +0 -283
  121. package/api/resources/empathicVoice/resources/customVoices/client/Client.d.ts +0 -135
  122. package/api/resources/empathicVoice/resources/customVoices/client/Client.js +0 -533
  123. package/api/resources/empathicVoice/resources/customVoices/client/index.d.ts +0 -1
  124. package/api/resources/empathicVoice/resources/customVoices/client/index.js +0 -17
  125. package/api/resources/empathicVoice/resources/customVoices/client/requests/CustomVoicesListCustomVoicesRequest.d.ts +0 -25
  126. package/api/resources/empathicVoice/resources/customVoices/client/requests/PostedCustomVoiceName.d.ts +0 -13
  127. package/api/resources/empathicVoice/resources/customVoices/client/requests/index.d.ts +0 -2
  128. package/api/resources/empathicVoice/resources/customVoices/client/requests/index.js +0 -2
  129. package/api/resources/empathicVoice/resources/customVoices/index.d.ts +0 -1
  130. package/api/resources/empathicVoice/resources/customVoices/index.js +0 -17
  131. package/api/resources/empathicVoice/types/PostedCustomVoice.d.ts +0 -25
  132. package/api/resources/empathicVoice/types/PostedCustomVoiceBaseVoice.d.ts +0 -17
  133. package/api/resources/empathicVoice/types/PostedCustomVoiceBaseVoice.js +0 -16
  134. package/api/resources/empathicVoice/types/PostedCustomVoiceParameters.d.ts +0 -70
  135. package/api/resources/empathicVoice/types/PostedVoice.d.ts +0 -20
  136. package/api/resources/empathicVoice/types/PostedVoiceProvider.d.ts +0 -11
  137. package/api/resources/empathicVoice/types/ReturnCustomVoice.d.ts +0 -31
  138. package/api/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.d.ts +0 -17
  139. package/api/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.js +0 -16
  140. package/api/resources/empathicVoice/types/ReturnCustomVoiceParameters.d.ts +0 -68
  141. package/api/resources/empathicVoice/types/ReturnCustomVoiceParameters.js +0 -5
  142. package/api/resources/empathicVoice/types/ReturnPagedCustomVoices.d.ts +0 -25
  143. package/api/resources/empathicVoice/types/ReturnPagedCustomVoices.js +0 -5
  144. package/api/resources/empathicVoice/types/ReturnSignedUri.d.ts +0 -12
  145. package/api/resources/empathicVoice/types/ReturnSignedUri.js +0 -5
  146. package/api/resources/empathicVoice/types/ReturnVoice.d.ts +0 -18
  147. package/api/resources/empathicVoice/types/ReturnVoice.js +0 -5
  148. package/api/resources/empathicVoice/types/ReturnVoiceOctaveCustom.d.ts +0 -31
  149. package/api/resources/empathicVoice/types/ReturnVoiceOctaveCustom.js +0 -5
  150. package/api/resources/empathicVoice/types/ReturnVoiceOctaveShared.d.ts +0 -15
  151. package/api/resources/empathicVoice/types/ReturnVoiceOctaveShared.js +0 -5
  152. package/api/resources/empathicVoice/types/ReturnVoiceProvider.d.ts +0 -11
  153. package/api/resources/empathicVoice/types/ReturnVoiceSpec.d.ts +0 -8
  154. package/api/resources/empathicVoice/types/ReturnVoiceSpec.js +0 -5
  155. package/api/resources/empathicVoice/types/ReturnVoiceSpecEvi2.d.ts +0 -14
  156. package/api/resources/empathicVoice/types/ReturnVoiceSpecEvi2.js +0 -5
  157. package/api/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.d.ts +0 -14
  158. package/api/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.js +0 -5
  159. package/api/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.d.ts +0 -14
  160. package/api/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.js +0 -5
  161. package/dist/api/resources/empathicVoice/resources/customVoices/client/Client.d.ts +0 -135
  162. package/dist/api/resources/empathicVoice/resources/customVoices/client/Client.js +0 -533
  163. package/dist/api/resources/empathicVoice/resources/customVoices/client/index.d.ts +0 -1
  164. package/dist/api/resources/empathicVoice/resources/customVoices/client/index.js +0 -17
  165. package/dist/api/resources/empathicVoice/resources/customVoices/client/requests/CustomVoicesListCustomVoicesRequest.d.ts +0 -25
  166. package/dist/api/resources/empathicVoice/resources/customVoices/client/requests/CustomVoicesListCustomVoicesRequest.js +0 -5
  167. package/dist/api/resources/empathicVoice/resources/customVoices/client/requests/PostedCustomVoiceName.d.ts +0 -13
  168. package/dist/api/resources/empathicVoice/resources/customVoices/client/requests/PostedCustomVoiceName.js +0 -5
  169. package/dist/api/resources/empathicVoice/resources/customVoices/client/requests/index.d.ts +0 -2
  170. package/dist/api/resources/empathicVoice/resources/customVoices/client/requests/index.js +0 -2
  171. package/dist/api/resources/empathicVoice/resources/customVoices/index.d.ts +0 -1
  172. package/dist/api/resources/empathicVoice/resources/customVoices/index.js +0 -17
  173. package/dist/api/resources/empathicVoice/types/PostedCustomVoice.d.ts +0 -25
  174. package/dist/api/resources/empathicVoice/types/PostedCustomVoice.js +0 -5
  175. package/dist/api/resources/empathicVoice/types/PostedCustomVoiceBaseVoice.d.ts +0 -17
  176. package/dist/api/resources/empathicVoice/types/PostedCustomVoiceBaseVoice.js +0 -16
  177. package/dist/api/resources/empathicVoice/types/PostedCustomVoiceParameters.d.ts +0 -70
  178. package/dist/api/resources/empathicVoice/types/PostedCustomVoiceParameters.js +0 -5
  179. package/dist/api/resources/empathicVoice/types/PostedVoice.d.ts +0 -20
  180. package/dist/api/resources/empathicVoice/types/PostedVoice.js +0 -5
  181. package/dist/api/resources/empathicVoice/types/PostedVoiceProvider.d.ts +0 -11
  182. package/dist/api/resources/empathicVoice/types/PostedVoiceProvider.js +0 -10
  183. package/dist/api/resources/empathicVoice/types/ReturnCustomVoice.d.ts +0 -31
  184. package/dist/api/resources/empathicVoice/types/ReturnCustomVoice.js +0 -5
  185. package/dist/api/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.d.ts +0 -17
  186. package/dist/api/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.js +0 -16
  187. package/dist/api/resources/empathicVoice/types/ReturnCustomVoiceParameters.d.ts +0 -68
  188. package/dist/api/resources/empathicVoice/types/ReturnCustomVoiceParameters.js +0 -5
  189. package/dist/api/resources/empathicVoice/types/ReturnPagedCustomVoices.d.ts +0 -25
  190. package/dist/api/resources/empathicVoice/types/ReturnPagedCustomVoices.js +0 -5
  191. package/dist/api/resources/empathicVoice/types/ReturnSignedUri.d.ts +0 -12
  192. package/dist/api/resources/empathicVoice/types/ReturnSignedUri.js +0 -5
  193. package/dist/api/resources/empathicVoice/types/ReturnVoice.d.ts +0 -18
  194. package/dist/api/resources/empathicVoice/types/ReturnVoice.js +0 -5
  195. package/dist/api/resources/empathicVoice/types/ReturnVoiceOctaveCustom.d.ts +0 -31
  196. package/dist/api/resources/empathicVoice/types/ReturnVoiceOctaveCustom.js +0 -5
  197. package/dist/api/resources/empathicVoice/types/ReturnVoiceOctaveShared.d.ts +0 -15
  198. package/dist/api/resources/empathicVoice/types/ReturnVoiceOctaveShared.js +0 -5
  199. package/dist/api/resources/empathicVoice/types/ReturnVoiceProvider.d.ts +0 -11
  200. package/dist/api/resources/empathicVoice/types/ReturnVoiceProvider.js +0 -10
  201. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpec.d.ts +0 -8
  202. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpec.js +0 -5
  203. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpecEvi2.d.ts +0 -14
  204. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpecEvi2.js +0 -5
  205. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.d.ts +0 -14
  206. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.js +0 -5
  207. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.d.ts +0 -14
  208. package/dist/api/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.js +0 -5
  209. package/dist/serialization/resources/empathicVoice/resources/customVoices/client/index.d.ts +0 -1
  210. package/dist/serialization/resources/empathicVoice/resources/customVoices/client/index.js +0 -17
  211. package/dist/serialization/resources/empathicVoice/resources/customVoices/client/requests/PostedCustomVoiceName.d.ts +0 -12
  212. package/dist/serialization/resources/empathicVoice/resources/customVoices/client/requests/PostedCustomVoiceName.js +0 -43
  213. package/dist/serialization/resources/empathicVoice/resources/customVoices/client/requests/index.d.ts +0 -1
  214. package/dist/serialization/resources/empathicVoice/resources/customVoices/client/requests/index.js +0 -5
  215. package/dist/serialization/resources/empathicVoice/resources/customVoices/index.d.ts +0 -1
  216. package/dist/serialization/resources/empathicVoice/resources/customVoices/index.js +0 -17
  217. package/dist/serialization/resources/empathicVoice/types/PostedCustomVoice.d.ts +0 -17
  218. package/dist/serialization/resources/empathicVoice/types/PostedCustomVoice.js +0 -48
  219. package/dist/serialization/resources/empathicVoice/types/PostedCustomVoiceBaseVoice.d.ts +0 -10
  220. package/dist/serialization/resources/empathicVoice/types/PostedCustomVoiceParameters.d.ts +0 -21
  221. package/dist/serialization/resources/empathicVoice/types/PostedCustomVoiceParameters.js +0 -52
  222. package/dist/serialization/resources/empathicVoice/types/PostedVoice.d.ts +0 -16
  223. package/dist/serialization/resources/empathicVoice/types/PostedVoice.js +0 -47
  224. package/dist/serialization/resources/empathicVoice/types/PostedVoiceProvider.d.ts +0 -10
  225. package/dist/serialization/resources/empathicVoice/types/ReturnCustomVoice.d.ts +0 -21
  226. package/dist/serialization/resources/empathicVoice/types/ReturnCustomVoice.js +0 -52
  227. package/dist/serialization/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.d.ts +0 -10
  228. package/dist/serialization/resources/empathicVoice/types/ReturnCustomVoiceParameters.d.ts +0 -21
  229. package/dist/serialization/resources/empathicVoice/types/ReturnCustomVoiceParameters.js +0 -52
  230. package/dist/serialization/resources/empathicVoice/types/ReturnPagedCustomVoices.d.ts +0 -16
  231. package/dist/serialization/resources/empathicVoice/types/ReturnPagedCustomVoices.js +0 -47
  232. package/dist/serialization/resources/empathicVoice/types/ReturnSignedUri.d.ts +0 -15
  233. package/dist/serialization/resources/empathicVoice/types/ReturnSignedUri.js +0 -46
  234. package/dist/serialization/resources/empathicVoice/types/ReturnVoice.d.ts +0 -16
  235. package/dist/serialization/resources/empathicVoice/types/ReturnVoice.js +0 -47
  236. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceOctaveCustom.d.ts +0 -34
  237. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceOctaveCustom.js +0 -65
  238. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceOctaveShared.d.ts +0 -18
  239. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceOctaveShared.js +0 -49
  240. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceProvider.d.ts +0 -10
  241. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpec.d.ts +0 -13
  242. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpec.js +0 -48
  243. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpecEvi2.d.ts +0 -15
  244. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpecEvi2.js +0 -46
  245. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.d.ts +0 -15
  246. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.js +0 -46
  247. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.d.ts +0 -15
  248. package/dist/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.js +0 -46
  249. package/serialization/resources/empathicVoice/resources/customVoices/client/index.d.ts +0 -1
  250. package/serialization/resources/empathicVoice/resources/customVoices/client/index.js +0 -17
  251. package/serialization/resources/empathicVoice/resources/customVoices/client/requests/PostedCustomVoiceName.d.ts +0 -12
  252. package/serialization/resources/empathicVoice/resources/customVoices/client/requests/PostedCustomVoiceName.js +0 -43
  253. package/serialization/resources/empathicVoice/resources/customVoices/client/requests/index.d.ts +0 -1
  254. package/serialization/resources/empathicVoice/resources/customVoices/client/requests/index.js +0 -5
  255. package/serialization/resources/empathicVoice/resources/customVoices/index.d.ts +0 -1
  256. package/serialization/resources/empathicVoice/resources/customVoices/index.js +0 -17
  257. package/serialization/resources/empathicVoice/types/PostedCustomVoice.d.ts +0 -17
  258. package/serialization/resources/empathicVoice/types/PostedCustomVoice.js +0 -48
  259. package/serialization/resources/empathicVoice/types/PostedCustomVoiceBaseVoice.d.ts +0 -10
  260. package/serialization/resources/empathicVoice/types/PostedCustomVoiceBaseVoice.js +0 -41
  261. package/serialization/resources/empathicVoice/types/PostedCustomVoiceParameters.d.ts +0 -21
  262. package/serialization/resources/empathicVoice/types/PostedCustomVoiceParameters.js +0 -52
  263. package/serialization/resources/empathicVoice/types/PostedVoice.d.ts +0 -16
  264. package/serialization/resources/empathicVoice/types/PostedVoice.js +0 -47
  265. package/serialization/resources/empathicVoice/types/PostedVoiceProvider.js +0 -41
  266. package/serialization/resources/empathicVoice/types/ReturnCustomVoice.d.ts +0 -21
  267. package/serialization/resources/empathicVoice/types/ReturnCustomVoice.js +0 -52
  268. package/serialization/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.d.ts +0 -10
  269. package/serialization/resources/empathicVoice/types/ReturnCustomVoiceBaseVoice.js +0 -41
  270. package/serialization/resources/empathicVoice/types/ReturnCustomVoiceParameters.d.ts +0 -21
  271. package/serialization/resources/empathicVoice/types/ReturnCustomVoiceParameters.js +0 -52
  272. package/serialization/resources/empathicVoice/types/ReturnPagedCustomVoices.d.ts +0 -16
  273. package/serialization/resources/empathicVoice/types/ReturnPagedCustomVoices.js +0 -47
  274. package/serialization/resources/empathicVoice/types/ReturnSignedUri.d.ts +0 -15
  275. package/serialization/resources/empathicVoice/types/ReturnSignedUri.js +0 -46
  276. package/serialization/resources/empathicVoice/types/ReturnVoice.d.ts +0 -16
  277. package/serialization/resources/empathicVoice/types/ReturnVoice.js +0 -47
  278. package/serialization/resources/empathicVoice/types/ReturnVoiceOctaveCustom.d.ts +0 -34
  279. package/serialization/resources/empathicVoice/types/ReturnVoiceOctaveCustom.js +0 -65
  280. package/serialization/resources/empathicVoice/types/ReturnVoiceOctaveShared.d.ts +0 -18
  281. package/serialization/resources/empathicVoice/types/ReturnVoiceOctaveShared.js +0 -49
  282. package/serialization/resources/empathicVoice/types/ReturnVoiceProvider.js +0 -41
  283. package/serialization/resources/empathicVoice/types/ReturnVoiceSpec.d.ts +0 -13
  284. package/serialization/resources/empathicVoice/types/ReturnVoiceSpec.js +0 -48
  285. package/serialization/resources/empathicVoice/types/ReturnVoiceSpecEvi2.d.ts +0 -15
  286. package/serialization/resources/empathicVoice/types/ReturnVoiceSpecEvi2.js +0 -46
  287. package/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.d.ts +0 -15
  288. package/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctavecustom.js +0 -46
  289. package/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.d.ts +0 -15
  290. package/serialization/resources/empathicVoice/types/ReturnVoiceSpecOctaveshared.js +0 -46
  291. /package/api/resources/empathicVoice/{resources/customVoices/client/requests/CustomVoicesListCustomVoicesRequest.js → types/VoiceId.js} +0 -0
  292. /package/api/resources/empathicVoice/{resources/customVoices/client/requests/PostedCustomVoiceName.js → types/VoiceName.js} +0 -0
  293. /package/api/resources/empathicVoice/types/{PostedCustomVoice.js → VoiceRef.js} +0 -0
  294. /package/{api/resources/empathicVoice/types/PostedCustomVoiceParameters.js → dist/api/resources/empathicVoice/types/VoiceId.js} +0 -0
  295. /package/{api/resources/empathicVoice/types/PostedVoice.js → dist/api/resources/empathicVoice/types/VoiceName.js} +0 -0
  296. /package/{api/resources/empathicVoice/types/ReturnCustomVoice.js → dist/api/resources/empathicVoice/types/VoiceRef.js} +0 -0
@@ -1,135 +0,0 @@
1
- /**
2
- * This file was auto-generated by Fern from our API Definition.
3
- */
4
- import * as environments from "../../../../../../environments";
5
- import * as core from "../../../../../../core";
6
- import * as Hume from "../../../../../index";
7
- export declare namespace CustomVoices {
8
- interface Options {
9
- environment?: core.Supplier<environments.HumeEnvironment | string>;
10
- /** Specify a custom URL to connect the client to. */
11
- baseUrl?: core.Supplier<string>;
12
- apiKey?: core.Supplier<string | undefined>;
13
- /** Additional headers to include in requests. */
14
- headers?: Record<string, string | core.Supplier<string | undefined> | undefined>;
15
- fetcher?: core.FetchFunction;
16
- }
17
- interface RequestOptions {
18
- /** The maximum time to wait for a response in seconds. */
19
- timeoutInSeconds?: number;
20
- /** The number of times to retry the request. Defaults to 2. */
21
- maxRetries?: number;
22
- /** A hook to abort the request. */
23
- abortSignal?: AbortSignal;
24
- /** Additional headers to include in the request. */
25
- headers?: Record<string, string | core.Supplier<string | undefined> | undefined>;
26
- }
27
- }
28
- export declare class CustomVoices {
29
- protected readonly _options: CustomVoices.Options;
30
- constructor(_options?: CustomVoices.Options);
31
- /**
32
- * Fetches a paginated list of **Custom Voices**.
33
- *
34
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
35
- *
36
- * @param {Hume.empathicVoice.CustomVoicesListCustomVoicesRequest} request
37
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
38
- *
39
- * @throws {@link Hume.empathicVoice.BadRequestError}
40
- *
41
- * @example
42
- * await client.empathicVoice.customVoices.listCustomVoices()
43
- */
44
- listCustomVoices(request?: Hume.empathicVoice.CustomVoicesListCustomVoicesRequest, requestOptions?: CustomVoices.RequestOptions): Promise<core.Page<Hume.empathicVoice.ReturnCustomVoice>>;
45
- /**
46
- * Creates a **Custom Voice** that can be added to an [EVI configuration](/reference/empathic-voice-interface-evi/configs/create-config).
47
- *
48
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
49
- *
50
- * @param {Hume.empathicVoice.PostedCustomVoice} request
51
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
52
- *
53
- * @throws {@link Hume.empathicVoice.BadRequestError}
54
- *
55
- * @example
56
- * await client.empathicVoice.customVoices.createCustomVoice({
57
- * name: "name",
58
- * baseVoice: "ITO",
59
- * parameterModel: "20241004-11parameter"
60
- * })
61
- */
62
- createCustomVoice(request: Hume.empathicVoice.PostedCustomVoice, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnCustomVoice>;
63
- private __createCustomVoice;
64
- /**
65
- * Fetches a specific **Custom Voice** by ID.
66
- *
67
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
68
- *
69
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
70
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
71
- *
72
- * @throws {@link Hume.empathicVoice.BadRequestError}
73
- *
74
- * @example
75
- * await client.empathicVoice.customVoices.getCustomVoice("id")
76
- */
77
- getCustomVoice(id: string, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnCustomVoice>;
78
- private __getCustomVoice;
79
- /**
80
- * Updates a **Custom Voice** by creating a new version of the **Custom Voice**.
81
- *
82
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
83
- *
84
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
85
- * @param {Hume.empathicVoice.PostedCustomVoice} request
86
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
87
- *
88
- * @throws {@link Hume.empathicVoice.BadRequestError}
89
- *
90
- * @example
91
- * await client.empathicVoice.customVoices.createCustomVoiceVersion("id", {
92
- * name: "name",
93
- * baseVoice: "ITO",
94
- * parameterModel: "20241004-11parameter"
95
- * })
96
- */
97
- createCustomVoiceVersion(id: string, request: Hume.empathicVoice.PostedCustomVoice, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<Hume.empathicVoice.ReturnCustomVoice>;
98
- private __createCustomVoiceVersion;
99
- /**
100
- * Deletes a **Custom Voice** and its versions.
101
- *
102
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
103
- *
104
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
105
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
106
- *
107
- * @throws {@link Hume.empathicVoice.BadRequestError}
108
- *
109
- * @example
110
- * await client.empathicVoice.customVoices.deleteCustomVoice("id")
111
- */
112
- deleteCustomVoice(id: string, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<void>;
113
- private __deleteCustomVoice;
114
- /**
115
- * Updates the name of a **Custom Voice**.
116
- *
117
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
118
- *
119
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
120
- * @param {Hume.empathicVoice.PostedCustomVoiceName} request
121
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
122
- *
123
- * @throws {@link Hume.empathicVoice.BadRequestError}
124
- *
125
- * @example
126
- * await client.empathicVoice.customVoices.updateCustomVoiceName("id", {
127
- * name: "name"
128
- * })
129
- */
130
- updateCustomVoiceName(id: string, request: Hume.empathicVoice.PostedCustomVoiceName, requestOptions?: CustomVoices.RequestOptions): core.HttpResponsePromise<string>;
131
- private __updateCustomVoiceName;
132
- protected _getCustomAuthorizationHeaders(): Promise<{
133
- "X-Hume-Api-Key": string | undefined;
134
- }>;
135
- }
@@ -1,533 +0,0 @@
1
- "use strict";
2
- /**
3
- * This file was auto-generated by Fern from our API Definition.
4
- */
5
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- var desc = Object.getOwnPropertyDescriptor(m, k);
8
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
- desc = { enumerable: true, get: function() { return m[k]; } };
10
- }
11
- Object.defineProperty(o, k2, desc);
12
- }) : (function(o, m, k, k2) {
13
- if (k2 === undefined) k2 = k;
14
- o[k2] = m[k];
15
- }));
16
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
- Object.defineProperty(o, "default", { enumerable: true, value: v });
18
- }) : function(o, v) {
19
- o["default"] = v;
20
- });
21
- var __importStar = (this && this.__importStar) || (function () {
22
- var ownKeys = function(o) {
23
- ownKeys = Object.getOwnPropertyNames || function (o) {
24
- var ar = [];
25
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
26
- return ar;
27
- };
28
- return ownKeys(o);
29
- };
30
- return function (mod) {
31
- if (mod && mod.__esModule) return mod;
32
- var result = {};
33
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
34
- __setModuleDefault(result, mod);
35
- return result;
36
- };
37
- })();
38
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
39
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
40
- return new (P || (P = Promise))(function (resolve, reject) {
41
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
42
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
43
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
44
- step((generator = generator.apply(thisArg, _arguments || [])).next());
45
- });
46
- };
47
- var __importDefault = (this && this.__importDefault) || function (mod) {
48
- return (mod && mod.__esModule) ? mod : { "default": mod };
49
- };
50
- Object.defineProperty(exports, "__esModule", { value: true });
51
- exports.CustomVoices = void 0;
52
- const environments = __importStar(require("../../../../../../environments"));
53
- const core = __importStar(require("../../../../../../core"));
54
- const Hume = __importStar(require("../../../../../index"));
55
- const headers_js_1 = require("../../../../../../core/headers.js");
56
- const url_join_1 = __importDefault(require("url-join"));
57
- const serializers = __importStar(require("../../../../../../serialization/index"));
58
- const errors = __importStar(require("../../../../../../errors/index"));
59
- class CustomVoices {
60
- constructor(_options = {}) {
61
- this._options = _options;
62
- }
63
- /**
64
- * Fetches a paginated list of **Custom Voices**.
65
- *
66
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
67
- *
68
- * @param {Hume.empathicVoice.CustomVoicesListCustomVoicesRequest} request
69
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
70
- *
71
- * @throws {@link Hume.empathicVoice.BadRequestError}
72
- *
73
- * @example
74
- * await client.empathicVoice.customVoices.listCustomVoices()
75
- */
76
- listCustomVoices() {
77
- return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
78
- const list = core.HttpResponsePromise.interceptFunction((request) => __awaiter(this, void 0, void 0, function* () {
79
- var _a, _b, _c, _d;
80
- const { pageNumber, pageSize, name } = request;
81
- const _queryParams = {};
82
- if (pageNumber != null) {
83
- _queryParams["page_number"] = pageNumber.toString();
84
- }
85
- if (pageSize != null) {
86
- _queryParams["page_size"] = pageSize.toString();
87
- }
88
- if (name != null) {
89
- _queryParams["name"] = name;
90
- }
91
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
92
- 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"),
93
- method: "GET",
94
- headers: (0, headers_js_1.mergeHeaders)((_d = this._options) === null || _d === void 0 ? void 0 : _d.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
95
- queryParameters: _queryParams,
96
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
97
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
98
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
99
- });
100
- if (_response.ok) {
101
- return {
102
- data: serializers.empathicVoice.ReturnPagedCustomVoices.parseOrThrow(_response.body, {
103
- unrecognizedObjectKeys: "passthrough",
104
- allowUnrecognizedUnionMembers: true,
105
- allowUnrecognizedEnumValues: true,
106
- breadcrumbsPrefix: ["response"],
107
- }),
108
- rawResponse: _response.rawResponse,
109
- };
110
- }
111
- if (_response.error.reason === "status-code") {
112
- switch (_response.error.statusCode) {
113
- case 400:
114
- throw new Hume.empathicVoice.BadRequestError(serializers.empathicVoice.ErrorResponse.parseOrThrow(_response.error.body, {
115
- unrecognizedObjectKeys: "passthrough",
116
- allowUnrecognizedUnionMembers: true,
117
- allowUnrecognizedEnumValues: true,
118
- breadcrumbsPrefix: ["response"],
119
- }), _response.rawResponse);
120
- default:
121
- throw new errors.HumeError({
122
- statusCode: _response.error.statusCode,
123
- body: _response.error.body,
124
- rawResponse: _response.rawResponse,
125
- });
126
- }
127
- }
128
- switch (_response.error.reason) {
129
- case "non-json":
130
- throw new errors.HumeError({
131
- statusCode: _response.error.statusCode,
132
- body: _response.error.rawBody,
133
- rawResponse: _response.rawResponse,
134
- });
135
- case "timeout":
136
- throw new errors.HumeTimeoutError("Timeout exceeded when calling GET /v0/evi/custom_voices.");
137
- case "unknown":
138
- throw new errors.HumeError({
139
- message: _response.error.errorMessage,
140
- rawResponse: _response.rawResponse,
141
- });
142
- }
143
- }));
144
- let _offset = (request === null || request === void 0 ? void 0 : request.pageNumber) != null ? request === null || request === void 0 ? void 0 : request.pageNumber : 0;
145
- const dataWithRawResponse = yield list(request).withRawResponse();
146
- return new core.Pageable({
147
- response: dataWithRawResponse.data,
148
- rawResponse: dataWithRawResponse.rawResponse,
149
- hasNextPage: (response) => { var _a; return ((_a = response === null || response === void 0 ? void 0 : response.customVoicesPage) !== null && _a !== void 0 ? _a : []).length > 0; },
150
- getItems: (response) => { var _a; return (_a = response === null || response === void 0 ? void 0 : response.customVoicesPage) !== null && _a !== void 0 ? _a : []; },
151
- loadPage: (_response) => {
152
- _offset += 1;
153
- return list(core.setObjectProperty(request, "pageNumber", _offset));
154
- },
155
- });
156
- });
157
- }
158
- /**
159
- * Creates a **Custom Voice** that can be added to an [EVI configuration](/reference/empathic-voice-interface-evi/configs/create-config).
160
- *
161
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
162
- *
163
- * @param {Hume.empathicVoice.PostedCustomVoice} request
164
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
165
- *
166
- * @throws {@link Hume.empathicVoice.BadRequestError}
167
- *
168
- * @example
169
- * await client.empathicVoice.customVoices.createCustomVoice({
170
- * name: "name",
171
- * baseVoice: "ITO",
172
- * parameterModel: "20241004-11parameter"
173
- * })
174
- */
175
- createCustomVoice(request, requestOptions) {
176
- return core.HttpResponsePromise.fromPromise(this.__createCustomVoice(request, requestOptions));
177
- }
178
- __createCustomVoice(request, requestOptions) {
179
- return __awaiter(this, void 0, void 0, function* () {
180
- var _a, _b, _c, _d;
181
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
182
- 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"),
183
- method: "POST",
184
- headers: (0, headers_js_1.mergeHeaders)((_d = this._options) === null || _d === void 0 ? void 0 : _d.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
185
- contentType: "application/json",
186
- requestType: "json",
187
- body: serializers.empathicVoice.PostedCustomVoice.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
188
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
189
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
190
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
191
- });
192
- if (_response.ok) {
193
- return {
194
- data: serializers.empathicVoice.ReturnCustomVoice.parseOrThrow(_response.body, {
195
- unrecognizedObjectKeys: "passthrough",
196
- allowUnrecognizedUnionMembers: true,
197
- allowUnrecognizedEnumValues: true,
198
- breadcrumbsPrefix: ["response"],
199
- }),
200
- rawResponse: _response.rawResponse,
201
- };
202
- }
203
- if (_response.error.reason === "status-code") {
204
- switch (_response.error.statusCode) {
205
- case 400:
206
- throw new Hume.empathicVoice.BadRequestError(serializers.empathicVoice.ErrorResponse.parseOrThrow(_response.error.body, {
207
- unrecognizedObjectKeys: "passthrough",
208
- allowUnrecognizedUnionMembers: true,
209
- allowUnrecognizedEnumValues: true,
210
- breadcrumbsPrefix: ["response"],
211
- }), _response.rawResponse);
212
- default:
213
- throw new errors.HumeError({
214
- statusCode: _response.error.statusCode,
215
- body: _response.error.body,
216
- rawResponse: _response.rawResponse,
217
- });
218
- }
219
- }
220
- switch (_response.error.reason) {
221
- case "non-json":
222
- throw new errors.HumeError({
223
- statusCode: _response.error.statusCode,
224
- body: _response.error.rawBody,
225
- rawResponse: _response.rawResponse,
226
- });
227
- case "timeout":
228
- throw new errors.HumeTimeoutError("Timeout exceeded when calling POST /v0/evi/custom_voices.");
229
- case "unknown":
230
- throw new errors.HumeError({
231
- message: _response.error.errorMessage,
232
- rawResponse: _response.rawResponse,
233
- });
234
- }
235
- });
236
- }
237
- /**
238
- * Fetches a specific **Custom Voice** by ID.
239
- *
240
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
241
- *
242
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
243
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
244
- *
245
- * @throws {@link Hume.empathicVoice.BadRequestError}
246
- *
247
- * @example
248
- * await client.empathicVoice.customVoices.getCustomVoice("id")
249
- */
250
- getCustomVoice(id, requestOptions) {
251
- return core.HttpResponsePromise.fromPromise(this.__getCustomVoice(id, requestOptions));
252
- }
253
- __getCustomVoice(id, requestOptions) {
254
- return __awaiter(this, void 0, void 0, function* () {
255
- var _a, _b, _c, _d;
256
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
257
- 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)}`),
258
- method: "GET",
259
- headers: (0, headers_js_1.mergeHeaders)((_d = this._options) === null || _d === void 0 ? void 0 : _d.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
260
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
261
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
262
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
263
- });
264
- if (_response.ok) {
265
- return {
266
- data: serializers.empathicVoice.ReturnCustomVoice.parseOrThrow(_response.body, {
267
- unrecognizedObjectKeys: "passthrough",
268
- allowUnrecognizedUnionMembers: true,
269
- allowUnrecognizedEnumValues: true,
270
- breadcrumbsPrefix: ["response"],
271
- }),
272
- rawResponse: _response.rawResponse,
273
- };
274
- }
275
- if (_response.error.reason === "status-code") {
276
- switch (_response.error.statusCode) {
277
- case 400:
278
- throw new Hume.empathicVoice.BadRequestError(serializers.empathicVoice.ErrorResponse.parseOrThrow(_response.error.body, {
279
- unrecognizedObjectKeys: "passthrough",
280
- allowUnrecognizedUnionMembers: true,
281
- allowUnrecognizedEnumValues: true,
282
- breadcrumbsPrefix: ["response"],
283
- }), _response.rawResponse);
284
- default:
285
- throw new errors.HumeError({
286
- statusCode: _response.error.statusCode,
287
- body: _response.error.body,
288
- rawResponse: _response.rawResponse,
289
- });
290
- }
291
- }
292
- switch (_response.error.reason) {
293
- case "non-json":
294
- throw new errors.HumeError({
295
- statusCode: _response.error.statusCode,
296
- body: _response.error.rawBody,
297
- rawResponse: _response.rawResponse,
298
- });
299
- case "timeout":
300
- throw new errors.HumeTimeoutError("Timeout exceeded when calling GET /v0/evi/custom_voices/{id}.");
301
- case "unknown":
302
- throw new errors.HumeError({
303
- message: _response.error.errorMessage,
304
- rawResponse: _response.rawResponse,
305
- });
306
- }
307
- });
308
- }
309
- /**
310
- * Updates a **Custom Voice** by creating a new version of the **Custom Voice**.
311
- *
312
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
313
- *
314
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
315
- * @param {Hume.empathicVoice.PostedCustomVoice} request
316
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
317
- *
318
- * @throws {@link Hume.empathicVoice.BadRequestError}
319
- *
320
- * @example
321
- * await client.empathicVoice.customVoices.createCustomVoiceVersion("id", {
322
- * name: "name",
323
- * baseVoice: "ITO",
324
- * parameterModel: "20241004-11parameter"
325
- * })
326
- */
327
- createCustomVoiceVersion(id, request, requestOptions) {
328
- return core.HttpResponsePromise.fromPromise(this.__createCustomVoiceVersion(id, request, requestOptions));
329
- }
330
- __createCustomVoiceVersion(id, request, requestOptions) {
331
- return __awaiter(this, void 0, void 0, function* () {
332
- var _a, _b, _c, _d;
333
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
334
- 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)}`),
335
- method: "POST",
336
- headers: (0, headers_js_1.mergeHeaders)((_d = this._options) === null || _d === void 0 ? void 0 : _d.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
337
- contentType: "application/json",
338
- requestType: "json",
339
- body: serializers.empathicVoice.PostedCustomVoice.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
340
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
341
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
342
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
343
- });
344
- if (_response.ok) {
345
- return {
346
- data: serializers.empathicVoice.ReturnCustomVoice.parseOrThrow(_response.body, {
347
- unrecognizedObjectKeys: "passthrough",
348
- allowUnrecognizedUnionMembers: true,
349
- allowUnrecognizedEnumValues: true,
350
- breadcrumbsPrefix: ["response"],
351
- }),
352
- rawResponse: _response.rawResponse,
353
- };
354
- }
355
- if (_response.error.reason === "status-code") {
356
- switch (_response.error.statusCode) {
357
- case 400:
358
- throw new Hume.empathicVoice.BadRequestError(serializers.empathicVoice.ErrorResponse.parseOrThrow(_response.error.body, {
359
- unrecognizedObjectKeys: "passthrough",
360
- allowUnrecognizedUnionMembers: true,
361
- allowUnrecognizedEnumValues: true,
362
- breadcrumbsPrefix: ["response"],
363
- }), _response.rawResponse);
364
- default:
365
- throw new errors.HumeError({
366
- statusCode: _response.error.statusCode,
367
- body: _response.error.body,
368
- rawResponse: _response.rawResponse,
369
- });
370
- }
371
- }
372
- switch (_response.error.reason) {
373
- case "non-json":
374
- throw new errors.HumeError({
375
- statusCode: _response.error.statusCode,
376
- body: _response.error.rawBody,
377
- rawResponse: _response.rawResponse,
378
- });
379
- case "timeout":
380
- throw new errors.HumeTimeoutError("Timeout exceeded when calling POST /v0/evi/custom_voices/{id}.");
381
- case "unknown":
382
- throw new errors.HumeError({
383
- message: _response.error.errorMessage,
384
- rawResponse: _response.rawResponse,
385
- });
386
- }
387
- });
388
- }
389
- /**
390
- * Deletes a **Custom Voice** and its versions.
391
- *
392
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
393
- *
394
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
395
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
396
- *
397
- * @throws {@link Hume.empathicVoice.BadRequestError}
398
- *
399
- * @example
400
- * await client.empathicVoice.customVoices.deleteCustomVoice("id")
401
- */
402
- deleteCustomVoice(id, requestOptions) {
403
- return core.HttpResponsePromise.fromPromise(this.__deleteCustomVoice(id, requestOptions));
404
- }
405
- __deleteCustomVoice(id, requestOptions) {
406
- return __awaiter(this, void 0, void 0, function* () {
407
- var _a, _b, _c, _d;
408
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
409
- 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)}`),
410
- method: "DELETE",
411
- headers: (0, headers_js_1.mergeHeaders)((_d = this._options) === null || _d === void 0 ? void 0 : _d.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
412
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
413
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
414
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
415
- });
416
- if (_response.ok) {
417
- return { data: undefined, rawResponse: _response.rawResponse };
418
- }
419
- if (_response.error.reason === "status-code") {
420
- switch (_response.error.statusCode) {
421
- case 400:
422
- throw new Hume.empathicVoice.BadRequestError(serializers.empathicVoice.ErrorResponse.parseOrThrow(_response.error.body, {
423
- unrecognizedObjectKeys: "passthrough",
424
- allowUnrecognizedUnionMembers: true,
425
- allowUnrecognizedEnumValues: true,
426
- breadcrumbsPrefix: ["response"],
427
- }), _response.rawResponse);
428
- default:
429
- throw new errors.HumeError({
430
- statusCode: _response.error.statusCode,
431
- body: _response.error.body,
432
- rawResponse: _response.rawResponse,
433
- });
434
- }
435
- }
436
- switch (_response.error.reason) {
437
- case "non-json":
438
- throw new errors.HumeError({
439
- statusCode: _response.error.statusCode,
440
- body: _response.error.rawBody,
441
- rawResponse: _response.rawResponse,
442
- });
443
- case "timeout":
444
- throw new errors.HumeTimeoutError("Timeout exceeded when calling DELETE /v0/evi/custom_voices/{id}.");
445
- case "unknown":
446
- throw new errors.HumeError({
447
- message: _response.error.errorMessage,
448
- rawResponse: _response.rawResponse,
449
- });
450
- }
451
- });
452
- }
453
- /**
454
- * Updates the name of a **Custom Voice**.
455
- *
456
- * Refer to our [voices guide](/docs/empathic-voice-interface-evi/configuration/voices) for details on creating a custom voice.
457
- *
458
- * @param {string} id - Identifier for a Custom Voice. Formatted as a UUID.
459
- * @param {Hume.empathicVoice.PostedCustomVoiceName} request
460
- * @param {CustomVoices.RequestOptions} requestOptions - Request-specific configuration.
461
- *
462
- * @throws {@link Hume.empathicVoice.BadRequestError}
463
- *
464
- * @example
465
- * await client.empathicVoice.customVoices.updateCustomVoiceName("id", {
466
- * name: "name"
467
- * })
468
- */
469
- updateCustomVoiceName(id, request, requestOptions) {
470
- return core.HttpResponsePromise.fromPromise(this.__updateCustomVoiceName(id, request, requestOptions));
471
- }
472
- __updateCustomVoiceName(id, request, requestOptions) {
473
- return __awaiter(this, void 0, void 0, function* () {
474
- var _a, _b, _c, _d;
475
- const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
476
- 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)}`),
477
- method: "PATCH",
478
- headers: (0, headers_js_1.mergeHeaders)((_d = this._options) === null || _d === void 0 ? void 0 : _d.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)(Object.assign({}, (yield this._getCustomAuthorizationHeaders()))), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
479
- contentType: "application/json",
480
- requestType: "json",
481
- body: serializers.empathicVoice.PostedCustomVoiceName.jsonOrThrow(request, {
482
- unrecognizedObjectKeys: "strip",
483
- }),
484
- responseType: "text",
485
- timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
486
- maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
487
- abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
488
- });
489
- if (_response.ok) {
490
- return { data: _response.body, rawResponse: _response.rawResponse };
491
- }
492
- if (_response.error.reason === "status-code") {
493
- switch (_response.error.statusCode) {
494
- case 400:
495
- throw new Hume.empathicVoice.BadRequestError(serializers.empathicVoice.ErrorResponse.parseOrThrow(_response.error.body, {
496
- unrecognizedObjectKeys: "passthrough",
497
- allowUnrecognizedUnionMembers: true,
498
- allowUnrecognizedEnumValues: true,
499
- breadcrumbsPrefix: ["response"],
500
- }), _response.rawResponse);
501
- default:
502
- throw new errors.HumeError({
503
- statusCode: _response.error.statusCode,
504
- body: _response.error.body,
505
- rawResponse: _response.rawResponse,
506
- });
507
- }
508
- }
509
- switch (_response.error.reason) {
510
- case "non-json":
511
- throw new errors.HumeError({
512
- statusCode: _response.error.statusCode,
513
- body: _response.error.rawBody,
514
- rawResponse: _response.rawResponse,
515
- });
516
- case "timeout":
517
- throw new errors.HumeTimeoutError("Timeout exceeded when calling PATCH /v0/evi/custom_voices/{id}.");
518
- case "unknown":
519
- throw new errors.HumeError({
520
- message: _response.error.errorMessage,
521
- rawResponse: _response.rawResponse,
522
- });
523
- }
524
- });
525
- }
526
- _getCustomAuthorizationHeaders() {
527
- return __awaiter(this, void 0, void 0, function* () {
528
- const apiKeyValue = yield core.Supplier.get(this._options.apiKey);
529
- return { "X-Hume-Api-Key": apiKeyValue };
530
- });
531
- }
532
- }
533
- exports.CustomVoices = CustomVoices;
@@ -1 +0,0 @@
1
- export * from "./requests";