@deepgram/sdk 3.3.4 → 3.4.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 (300) hide show
  1. package/README.md +129 -9
  2. package/dist/main/DeepgramClient.d.ts +65 -12
  3. package/dist/main/DeepgramClient.d.ts.map +1 -1
  4. package/dist/main/DeepgramClient.js +73 -18
  5. package/dist/main/DeepgramClient.js.map +1 -1
  6. package/dist/main/index.d.ts +13 -4
  7. package/dist/main/index.d.ts.map +1 -1
  8. package/dist/main/index.js +18 -8
  9. package/dist/main/index.js.map +1 -1
  10. package/dist/main/lib/constants.d.ts +16 -7
  11. package/dist/main/lib/constants.d.ts.map +1 -1
  12. package/dist/main/lib/constants.js +26 -9
  13. package/dist/main/lib/constants.js.map +1 -1
  14. package/dist/main/lib/enums/LiveConnectionState.d.ts +5 -0
  15. package/dist/main/lib/enums/LiveConnectionState.d.ts.map +1 -1
  16. package/dist/main/lib/enums/LiveConnectionState.js +5 -0
  17. package/dist/main/lib/enums/LiveConnectionState.js.map +1 -1
  18. package/dist/main/lib/enums/LiveTranscriptionEvents.d.ts +24 -3
  19. package/dist/main/lib/enums/LiveTranscriptionEvents.d.ts.map +1 -1
  20. package/dist/main/lib/enums/LiveTranscriptionEvents.js +23 -2
  21. package/dist/main/lib/enums/LiveTranscriptionEvents.js.map +1 -1
  22. package/dist/main/lib/enums/index.d.ts +2 -2
  23. package/dist/main/lib/enums/index.d.ts.map +1 -1
  24. package/dist/main/lib/enums/index.js +16 -5
  25. package/dist/main/lib/enums/index.js.map +1 -1
  26. package/dist/main/lib/fetch.d.ts +19 -1
  27. package/dist/main/lib/fetch.d.ts.map +1 -1
  28. package/dist/main/lib/fetch.js +19 -1
  29. package/dist/main/lib/fetch.js.map +1 -1
  30. package/dist/main/lib/helpers.d.ts +9 -5
  31. package/dist/main/lib/helpers.d.ts.map +1 -1
  32. package/dist/main/lib/helpers.js +82 -7
  33. package/dist/main/lib/helpers.js.map +1 -1
  34. package/dist/main/lib/types/CreateProjectKeySchema.d.ts +0 -1
  35. package/dist/main/lib/types/CreateProjectKeySchema.d.ts.map +1 -1
  36. package/dist/main/lib/types/DeepgramClientOptions.d.ts +75 -8
  37. package/dist/main/lib/types/DeepgramClientOptions.d.ts.map +1 -1
  38. package/dist/main/lib/types/Fetch.d.ts +3 -13
  39. package/dist/main/lib/types/Fetch.d.ts.map +1 -1
  40. package/dist/main/lib/types/LiveConfigOptions.d.ts +6 -3
  41. package/dist/main/lib/types/LiveConfigOptions.d.ts.map +1 -1
  42. package/dist/main/lib/types/SyncPrerecordedResponse.d.ts +1 -0
  43. package/dist/main/lib/types/SyncPrerecordedResponse.d.ts.map +1 -1
  44. package/dist/main/lib/types/TranscriptionSchema.d.ts +0 -1
  45. package/dist/main/lib/types/TranscriptionSchema.d.ts.map +1 -1
  46. package/dist/main/lib/types/UpdateProjectMemberScopeSchema.d.ts +1 -1
  47. package/dist/main/lib/types/UpdateProjectMemberScopeSchema.d.ts.map +1 -1
  48. package/dist/main/lib/types/UpdateProjectSchema.d.ts +0 -1
  49. package/dist/main/lib/types/UpdateProjectSchema.d.ts.map +1 -1
  50. package/dist/main/lib/types/index.d.ts +39 -39
  51. package/dist/main/lib/types/index.d.ts.map +1 -1
  52. package/dist/main/lib/types/index.js +53 -0
  53. package/dist/main/lib/types/index.js.map +1 -1
  54. package/dist/main/lib/version.d.ts +1 -1
  55. package/dist/main/lib/version.js +1 -1
  56. package/dist/main/packages/AbstractClient.d.ts +63 -10
  57. package/dist/main/packages/AbstractClient.d.ts.map +1 -1
  58. package/dist/main/packages/AbstractClient.js +103 -50
  59. package/dist/main/packages/AbstractClient.js.map +1 -1
  60. package/dist/main/packages/AbstractLiveClient.d.ts +114 -0
  61. package/dist/main/packages/AbstractLiveClient.d.ts.map +1 -0
  62. package/dist/main/packages/AbstractLiveClient.js +238 -0
  63. package/dist/main/packages/AbstractLiveClient.js.map +1 -0
  64. package/dist/main/packages/AbstractRestClient.d.ts +105 -0
  65. package/dist/main/packages/AbstractRestClient.d.ts.map +1 -0
  66. package/dist/main/packages/AbstractRestClient.js +185 -0
  67. package/dist/main/packages/AbstractRestClient.js.map +1 -0
  68. package/dist/main/packages/ListenClient.d.ts +21 -4
  69. package/dist/main/packages/ListenClient.d.ts.map +1 -1
  70. package/dist/main/packages/ListenClient.js +25 -5
  71. package/dist/main/packages/ListenClient.js.map +1 -1
  72. package/dist/main/packages/ListenLiveClient.d.ts +58 -0
  73. package/dist/main/packages/ListenLiveClient.d.ts.map +1 -0
  74. package/dist/main/packages/ListenLiveClient.js +119 -0
  75. package/dist/main/packages/ListenLiveClient.js.map +1 -0
  76. package/dist/main/packages/ListenRestClient.d.ts +57 -0
  77. package/dist/main/packages/ListenRestClient.d.ts.map +1 -0
  78. package/dist/main/packages/ListenRestClient.js +167 -0
  79. package/dist/main/packages/ListenRestClient.js.map +1 -0
  80. package/dist/main/packages/ManageRestClient.d.ts +286 -0
  81. package/dist/main/packages/ManageRestClient.d.ts.map +1 -0
  82. package/dist/main/packages/ManageRestClient.js +628 -0
  83. package/dist/main/packages/ManageRestClient.js.map +1 -0
  84. package/dist/main/packages/ReadRestClient.d.ts +57 -0
  85. package/dist/main/packages/ReadRestClient.d.ts.map +1 -0
  86. package/dist/main/packages/ReadRestClient.js +165 -0
  87. package/dist/main/packages/ReadRestClient.js.map +1 -0
  88. package/dist/main/packages/SelfHostedRestClient.d.ts +47 -0
  89. package/dist/main/packages/SelfHostedRestClient.d.ts.map +1 -0
  90. package/dist/main/packages/SelfHostedRestClient.js +120 -0
  91. package/dist/main/packages/SelfHostedRestClient.js.map +1 -0
  92. package/dist/main/packages/SpeakRestClient.d.ts +36 -0
  93. package/dist/main/packages/SpeakRestClient.d.ts.map +1 -0
  94. package/dist/main/packages/SpeakRestClient.js +84 -0
  95. package/dist/main/packages/SpeakRestClient.js.map +1 -0
  96. package/dist/main/packages/index.d.ts +10 -8
  97. package/dist/main/packages/index.d.ts.map +1 -1
  98. package/dist/main/packages/index.js +24 -17
  99. package/dist/main/packages/index.js.map +1 -1
  100. package/dist/module/DeepgramClient.d.ts +65 -12
  101. package/dist/module/DeepgramClient.d.ts.map +1 -1
  102. package/dist/module/DeepgramClient.js +72 -17
  103. package/dist/module/DeepgramClient.js.map +1 -1
  104. package/dist/module/index.d.ts +13 -4
  105. package/dist/module/index.d.ts.map +1 -1
  106. package/dist/module/index.js +18 -8
  107. package/dist/module/index.js.map +1 -1
  108. package/dist/module/lib/constants.d.ts +16 -7
  109. package/dist/module/lib/constants.d.ts.map +1 -1
  110. package/dist/module/lib/constants.js +26 -9
  111. package/dist/module/lib/constants.js.map +1 -1
  112. package/dist/module/lib/enums/LiveConnectionState.d.ts +5 -0
  113. package/dist/module/lib/enums/LiveConnectionState.d.ts.map +1 -1
  114. package/dist/module/lib/enums/LiveConnectionState.js +5 -0
  115. package/dist/module/lib/enums/LiveConnectionState.js.map +1 -1
  116. package/dist/module/lib/enums/LiveTranscriptionEvents.d.ts +24 -3
  117. package/dist/module/lib/enums/LiveTranscriptionEvents.d.ts.map +1 -1
  118. package/dist/module/lib/enums/LiveTranscriptionEvents.js +23 -2
  119. package/dist/module/lib/enums/LiveTranscriptionEvents.js.map +1 -1
  120. package/dist/module/lib/enums/index.d.ts +2 -2
  121. package/dist/module/lib/enums/index.d.ts.map +1 -1
  122. package/dist/module/lib/enums/index.js +2 -2
  123. package/dist/module/lib/enums/index.js.map +1 -1
  124. package/dist/module/lib/fetch.d.ts +19 -1
  125. package/dist/module/lib/fetch.d.ts.map +1 -1
  126. package/dist/module/lib/fetch.js +19 -1
  127. package/dist/module/lib/fetch.js.map +1 -1
  128. package/dist/module/lib/helpers.d.ts +9 -5
  129. package/dist/module/lib/helpers.d.ts.map +1 -1
  130. package/dist/module/lib/helpers.js +75 -4
  131. package/dist/module/lib/helpers.js.map +1 -1
  132. package/dist/module/lib/types/CreateProjectKeySchema.d.ts +0 -1
  133. package/dist/module/lib/types/CreateProjectKeySchema.d.ts.map +1 -1
  134. package/dist/module/lib/types/DeepgramClientOptions.d.ts +75 -8
  135. package/dist/module/lib/types/DeepgramClientOptions.d.ts.map +1 -1
  136. package/dist/module/lib/types/Fetch.d.ts +3 -13
  137. package/dist/module/lib/types/Fetch.d.ts.map +1 -1
  138. package/dist/module/lib/types/LiveConfigOptions.d.ts +6 -3
  139. package/dist/module/lib/types/LiveConfigOptions.d.ts.map +1 -1
  140. package/dist/module/lib/types/SyncPrerecordedResponse.d.ts +1 -0
  141. package/dist/module/lib/types/SyncPrerecordedResponse.d.ts.map +1 -1
  142. package/dist/module/lib/types/TranscriptionSchema.d.ts +0 -1
  143. package/dist/module/lib/types/TranscriptionSchema.d.ts.map +1 -1
  144. package/dist/module/lib/types/UpdateProjectMemberScopeSchema.d.ts +1 -1
  145. package/dist/module/lib/types/UpdateProjectMemberScopeSchema.d.ts.map +1 -1
  146. package/dist/module/lib/types/UpdateProjectSchema.d.ts +0 -1
  147. package/dist/module/lib/types/UpdateProjectSchema.d.ts.map +1 -1
  148. package/dist/module/lib/types/index.d.ts +39 -39
  149. package/dist/module/lib/types/index.d.ts.map +1 -1
  150. package/dist/module/lib/types/index.js +39 -1
  151. package/dist/module/lib/types/index.js.map +1 -1
  152. package/dist/module/lib/version.d.ts +1 -1
  153. package/dist/module/lib/version.js +1 -1
  154. package/dist/module/packages/AbstractClient.d.ts +63 -10
  155. package/dist/module/packages/AbstractClient.d.ts.map +1 -1
  156. package/dist/module/packages/AbstractClient.js +99 -50
  157. package/dist/module/packages/AbstractClient.js.map +1 -1
  158. package/dist/module/packages/AbstractLiveClient.d.ts +114 -0
  159. package/dist/module/packages/AbstractLiveClient.d.ts.map +1 -0
  160. package/dist/module/packages/AbstractLiveClient.js +211 -0
  161. package/dist/module/packages/AbstractLiveClient.js.map +1 -0
  162. package/dist/module/packages/AbstractRestClient.d.ts +105 -0
  163. package/dist/module/packages/AbstractRestClient.d.ts.map +1 -0
  164. package/dist/module/packages/AbstractRestClient.js +178 -0
  165. package/dist/module/packages/AbstractRestClient.js.map +1 -0
  166. package/dist/module/packages/ListenClient.d.ts +21 -4
  167. package/dist/module/packages/ListenClient.d.ts.map +1 -1
  168. package/dist/module/packages/ListenClient.js +25 -5
  169. package/dist/module/packages/ListenClient.js.map +1 -1
  170. package/dist/module/packages/ListenLiveClient.d.ts +58 -0
  171. package/dist/module/packages/ListenLiveClient.d.ts.map +1 -0
  172. package/dist/module/packages/ListenLiveClient.js +115 -0
  173. package/dist/module/packages/ListenLiveClient.js.map +1 -0
  174. package/dist/module/packages/ListenRestClient.d.ts +57 -0
  175. package/dist/module/packages/ListenRestClient.d.ts.map +1 -0
  176. package/dist/module/packages/ListenRestClient.js +163 -0
  177. package/dist/module/packages/ListenRestClient.js.map +1 -0
  178. package/dist/module/packages/ManageRestClient.d.ts +286 -0
  179. package/dist/module/packages/ManageRestClient.d.ts.map +1 -0
  180. package/dist/module/packages/ManageRestClient.js +624 -0
  181. package/dist/module/packages/ManageRestClient.js.map +1 -0
  182. package/dist/module/packages/ReadRestClient.d.ts +57 -0
  183. package/dist/module/packages/ReadRestClient.d.ts.map +1 -0
  184. package/dist/module/packages/ReadRestClient.js +161 -0
  185. package/dist/module/packages/ReadRestClient.js.map +1 -0
  186. package/dist/module/packages/SelfHostedRestClient.d.ts +47 -0
  187. package/dist/module/packages/SelfHostedRestClient.d.ts.map +1 -0
  188. package/dist/module/packages/SelfHostedRestClient.js +116 -0
  189. package/dist/module/packages/SelfHostedRestClient.js.map +1 -0
  190. package/dist/module/packages/SpeakRestClient.d.ts +36 -0
  191. package/dist/module/packages/SpeakRestClient.d.ts.map +1 -0
  192. package/dist/module/packages/SpeakRestClient.js +80 -0
  193. package/dist/module/packages/SpeakRestClient.js.map +1 -0
  194. package/dist/module/packages/index.d.ts +10 -8
  195. package/dist/module/packages/index.d.ts.map +1 -1
  196. package/dist/module/packages/index.js +10 -8
  197. package/dist/module/packages/index.js.map +1 -1
  198. package/dist/umd/deepgram.js +1 -1
  199. package/package.json +8 -6
  200. package/src/DeepgramClient.ts +81 -17
  201. package/src/index.ts +32 -7
  202. package/src/lib/constants.ts +33 -13
  203. package/src/lib/enums/LiveConnectionState.ts +11 -4
  204. package/src/lib/enums/LiveTranscriptionEvents.ts +27 -4
  205. package/src/lib/enums/index.ts +2 -2
  206. package/src/lib/fetch.ts +22 -2
  207. package/src/lib/helpers.ts +98 -9
  208. package/src/lib/types/CreateProjectKeySchema.ts +0 -1
  209. package/src/lib/types/DeepgramClientOptions.ts +75 -11
  210. package/src/lib/types/Fetch.ts +2 -24
  211. package/src/lib/types/LiveConfigOptions.ts +7 -3
  212. package/src/lib/types/SyncPrerecordedResponse.ts +1 -0
  213. package/src/lib/types/TranscriptionSchema.ts +0 -2
  214. package/src/lib/types/UpdateProjectMemberScopeSchema.ts +1 -1
  215. package/src/lib/types/UpdateProjectSchema.ts +0 -1
  216. package/src/lib/types/index.ts +39 -54
  217. package/src/lib/version.ts +1 -1
  218. package/src/packages/AbstractClient.ts +129 -61
  219. package/src/packages/AbstractLiveClient.ts +280 -0
  220. package/src/packages/AbstractRestClient.ts +221 -0
  221. package/src/packages/ListenClient.ts +26 -5
  222. package/src/packages/ListenLiveClient.ts +133 -0
  223. package/src/packages/ListenRestClient.ts +201 -0
  224. package/src/packages/ManageRestClient.ts +760 -0
  225. package/src/packages/ReadRestClient.ts +200 -0
  226. package/src/packages/SelfHostedRestClient.ts +134 -0
  227. package/src/packages/SpeakRestClient.ts +79 -0
  228. package/src/packages/index.ts +10 -8
  229. package/dist/main/packages/AbstractRestfulClient.d.ts +0 -26
  230. package/dist/main/packages/AbstractRestfulClient.d.ts.map +0 -1
  231. package/dist/main/packages/AbstractRestfulClient.js +0 -118
  232. package/dist/main/packages/AbstractRestfulClient.js.map +0 -1
  233. package/dist/main/packages/AbstractWsClient.d.ts +0 -10
  234. package/dist/main/packages/AbstractWsClient.d.ts.map +0 -1
  235. package/dist/main/packages/AbstractWsClient.js +0 -33
  236. package/dist/main/packages/AbstractWsClient.js.map +0 -1
  237. package/dist/main/packages/LiveClient.d.ts +0 -28
  238. package/dist/main/packages/LiveClient.d.ts.map +0 -1
  239. package/dist/main/packages/LiveClient.js +0 -110
  240. package/dist/main/packages/LiveClient.js.map +0 -1
  241. package/dist/main/packages/ManageClient.d.ts +0 -97
  242. package/dist/main/packages/ManageClient.d.ts.map +0 -1
  243. package/dist/main/packages/ManageClient.js +0 -463
  244. package/dist/main/packages/ManageClient.js.map +0 -1
  245. package/dist/main/packages/OnPremClient.d.ts +0 -21
  246. package/dist/main/packages/OnPremClient.d.ts.map +0 -1
  247. package/dist/main/packages/OnPremClient.js +0 -99
  248. package/dist/main/packages/OnPremClient.js.map +0 -1
  249. package/dist/main/packages/PrerecordedClient.d.ts +0 -10
  250. package/dist/main/packages/PrerecordedClient.d.ts.map +0 -1
  251. package/dist/main/packages/PrerecordedClient.js +0 -125
  252. package/dist/main/packages/PrerecordedClient.js.map +0 -1
  253. package/dist/main/packages/ReadClient.d.ts +0 -10
  254. package/dist/main/packages/ReadClient.d.ts.map +0 -1
  255. package/dist/main/packages/ReadClient.js +0 -123
  256. package/dist/main/packages/ReadClient.js.map +0 -1
  257. package/dist/main/packages/SpeakClient.d.ts +0 -12
  258. package/dist/main/packages/SpeakClient.d.ts.map +0 -1
  259. package/dist/main/packages/SpeakClient.js +0 -57
  260. package/dist/main/packages/SpeakClient.js.map +0 -1
  261. package/dist/module/packages/AbstractRestfulClient.d.ts +0 -26
  262. package/dist/module/packages/AbstractRestfulClient.d.ts.map +0 -1
  263. package/dist/module/packages/AbstractRestfulClient.js +0 -114
  264. package/dist/module/packages/AbstractRestfulClient.js.map +0 -1
  265. package/dist/module/packages/AbstractWsClient.d.ts +0 -10
  266. package/dist/module/packages/AbstractWsClient.d.ts.map +0 -1
  267. package/dist/module/packages/AbstractWsClient.js +0 -29
  268. package/dist/module/packages/AbstractWsClient.js.map +0 -1
  269. package/dist/module/packages/LiveClient.d.ts +0 -28
  270. package/dist/module/packages/LiveClient.d.ts.map +0 -1
  271. package/dist/module/packages/LiveClient.js +0 -106
  272. package/dist/module/packages/LiveClient.js.map +0 -1
  273. package/dist/module/packages/ManageClient.d.ts +0 -97
  274. package/dist/module/packages/ManageClient.d.ts.map +0 -1
  275. package/dist/module/packages/ManageClient.js +0 -459
  276. package/dist/module/packages/ManageClient.js.map +0 -1
  277. package/dist/module/packages/OnPremClient.d.ts +0 -21
  278. package/dist/module/packages/OnPremClient.d.ts.map +0 -1
  279. package/dist/module/packages/OnPremClient.js +0 -95
  280. package/dist/module/packages/OnPremClient.js.map +0 -1
  281. package/dist/module/packages/PrerecordedClient.d.ts +0 -10
  282. package/dist/module/packages/PrerecordedClient.d.ts.map +0 -1
  283. package/dist/module/packages/PrerecordedClient.js +0 -121
  284. package/dist/module/packages/PrerecordedClient.js.map +0 -1
  285. package/dist/module/packages/ReadClient.d.ts +0 -10
  286. package/dist/module/packages/ReadClient.d.ts.map +0 -1
  287. package/dist/module/packages/ReadClient.js +0 -119
  288. package/dist/module/packages/ReadClient.js.map +0 -1
  289. package/dist/module/packages/SpeakClient.d.ts +0 -12
  290. package/dist/module/packages/SpeakClient.d.ts.map +0 -1
  291. package/dist/module/packages/SpeakClient.js +0 -53
  292. package/dist/module/packages/SpeakClient.js.map +0 -1
  293. package/src/packages/AbstractRestfulClient.ts +0 -160
  294. package/src/packages/AbstractWsClient.ts +0 -42
  295. package/src/packages/LiveClient.ts +0 -140
  296. package/src/packages/ManageClient.ts +0 -584
  297. package/src/packages/OnPremClient.ts +0 -113
  298. package/src/packages/PrerecordedClient.ts +0 -162
  299. package/src/packages/ReadClient.ts +0 -161
  300. package/src/packages/SpeakClient.ts +0 -50
@@ -0,0 +1,57 @@
1
+ import { CallbackUrl } from "../lib/helpers";
2
+ import type { AnalyzeSchema, AsyncAnalyzeResponse, DeepgramResponse, SyncAnalyzeResponse, TextSource, UrlSource } from "../lib/types";
3
+ import { AbstractRestClient } from "./AbstractRestClient";
4
+ /**
5
+ * The `ReadRestClient` class extends the `AbstractRestClient` class and provides methods for analyzing audio sources synchronously and asynchronously.
6
+ *
7
+ * The `analyzeUrl` method analyzes a URL-based audio source synchronously, returning a promise that resolves to the analysis response or an error.
8
+ *
9
+ * The `analyzeText` method analyzes a text-based audio source synchronously, returning a promise that resolves to the analysis response or an error.
10
+ *
11
+ * The `analyzeUrlCallback` method analyzes a URL-based audio source asynchronously, returning a promise that resolves to the analysis response or an error.
12
+ *
13
+ * The `analyzeTextCallback` method analyzes a text-based audio source asynchronously, returning a promise that resolves to the analysis response or an error.
14
+ */
15
+ export declare class ReadRestClient extends AbstractRestClient {
16
+ namespace: string;
17
+ /**
18
+ * Analyzes a URL-based audio source synchronously.
19
+ *
20
+ * @param source - The URL-based audio source to analyze.
21
+ * @param options - Optional analysis options.
22
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
23
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
24
+ */
25
+ analyzeUrl(source: UrlSource, options?: AnalyzeSchema, endpoint?: string): Promise<DeepgramResponse<SyncAnalyzeResponse>>;
26
+ /**
27
+ * Analyzes a text-based audio source synchronously.
28
+ *
29
+ * @param source - The text-based audio source to analyze.
30
+ * @param options - Optional analysis options.
31
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
32
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
33
+ */
34
+ analyzeText(source: TextSource, options?: AnalyzeSchema, endpoint?: string): Promise<DeepgramResponse<SyncAnalyzeResponse>>;
35
+ /**
36
+ * Analyzes a URL-based audio source asynchronously.
37
+ *
38
+ * @param source - The URL-based audio source to analyze.
39
+ * @param callback - The URL to call back with the analysis results.
40
+ * @param options - Optional analysis options.
41
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
42
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
43
+ */
44
+ analyzeUrlCallback(source: UrlSource, callback: CallbackUrl, options?: AnalyzeSchema, endpoint?: string): Promise<DeepgramResponse<AsyncAnalyzeResponse>>;
45
+ /**
46
+ * Analyzes a text-based audio source asynchronously.
47
+ *
48
+ * @param source - The text-based audio source to analyze.
49
+ * @param callback - The URL to call back with the analysis results.
50
+ * @param options - Optional analysis options.
51
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
52
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
53
+ */
54
+ analyzeTextCallback(source: TextSource, callback: CallbackUrl, options?: AnalyzeSchema, endpoint?: string): Promise<DeepgramResponse<AsyncAnalyzeResponse>>;
55
+ }
56
+ export { ReadRestClient as ReadClient };
57
+ //# sourceMappingURL=ReadRestClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReadRestClient.d.ts","sourceRoot":"","sources":["../../../src/packages/ReadRestClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAiD,MAAM,gBAAgB,CAAC;AAE5F,OAAO,KAAK,EACV,aAAa,EACb,oBAAoB,EACpB,gBAAgB,EAChB,mBAAmB,EACnB,UAAU,EACV,SAAS,EACV,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D;;;;;;;;;;GAUG;AACH,qBAAa,cAAe,SAAQ,kBAAkB;IAC7C,SAAS,EAAE,MAAM,CAAU;IAElC;;;;;;;OAOG;IACG,UAAU,CACd,MAAM,EAAE,SAAS,EACjB,OAAO,CAAC,EAAE,aAAa,EACvB,QAAQ,SAAkB,GACzB,OAAO,CAAC,gBAAgB,CAAC,mBAAmB,CAAC,CAAC;IA+BjD;;;;;;;OAOG;IACG,WAAW,CACf,MAAM,EAAE,UAAU,EAClB,OAAO,CAAC,EAAE,aAAa,EACvB,QAAQ,SAAkB,GACzB,OAAO,CAAC,gBAAgB,CAAC,mBAAmB,CAAC,CAAC;IA+BjD;;;;;;;;OAQG;IACG,kBAAkB,CACtB,MAAM,EAAE,SAAS,EACjB,QAAQ,EAAE,WAAW,EACrB,OAAO,CAAC,EAAE,aAAa,EACvB,QAAQ,SAAkB,GACzB,OAAO,CAAC,gBAAgB,CAAC,oBAAoB,CAAC,CAAC;IA6BlD;;;;;;;;OAQG;IACG,mBAAmB,CACvB,MAAM,EAAE,UAAU,EAClB,QAAQ,EAAE,WAAW,EACrB,OAAO,CAAC,EAAE,aAAa,EACvB,QAAQ,SAAkB,GACzB,OAAO,CAAC,gBAAgB,CAAC,oBAAoB,CAAC,CAAC;CA4BnD;AAED,OAAO,EAAE,cAAc,IAAI,UAAU,EAAE,CAAC"}
@@ -0,0 +1,161 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import { isTextSource, isUrlSource } from "../lib/helpers";
11
+ import { DeepgramError, isDeepgramError } from "../lib/errors";
12
+ import { AbstractRestClient } from "./AbstractRestClient";
13
+ /**
14
+ * The `ReadRestClient` class extends the `AbstractRestClient` class and provides methods for analyzing audio sources synchronously and asynchronously.
15
+ *
16
+ * The `analyzeUrl` method analyzes a URL-based audio source synchronously, returning a promise that resolves to the analysis response or an error.
17
+ *
18
+ * The `analyzeText` method analyzes a text-based audio source synchronously, returning a promise that resolves to the analysis response or an error.
19
+ *
20
+ * The `analyzeUrlCallback` method analyzes a URL-based audio source asynchronously, returning a promise that resolves to the analysis response or an error.
21
+ *
22
+ * The `analyzeTextCallback` method analyzes a text-based audio source asynchronously, returning a promise that resolves to the analysis response or an error.
23
+ */
24
+ export class ReadRestClient extends AbstractRestClient {
25
+ constructor() {
26
+ super(...arguments);
27
+ this.namespace = "read";
28
+ }
29
+ /**
30
+ * Analyzes a URL-based audio source synchronously.
31
+ *
32
+ * @param source - The URL-based audio source to analyze.
33
+ * @param options - Optional analysis options.
34
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
35
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
36
+ */
37
+ analyzeUrl(source, options, endpoint = ":version/read") {
38
+ return __awaiter(this, void 0, void 0, function* () {
39
+ try {
40
+ let body;
41
+ if (isUrlSource(source)) {
42
+ body = JSON.stringify(source);
43
+ }
44
+ else {
45
+ throw new DeepgramError("Unknown source type");
46
+ }
47
+ if (options !== undefined && "callback" in options) {
48
+ throw new DeepgramError("Callback cannot be provided as an option to a synchronous transcription. Use `analyzeUrlCallback` or `analyzeTextCallback` instead.");
49
+ }
50
+ const requestUrl = this.getRequestUrl(endpoint, {}, Object.assign({}, options));
51
+ const result = yield this.post(requestUrl, body).then((result) => result.json());
52
+ return { result, error: null };
53
+ }
54
+ catch (error) {
55
+ if (isDeepgramError(error)) {
56
+ return { result: null, error };
57
+ }
58
+ throw error;
59
+ }
60
+ });
61
+ }
62
+ /**
63
+ * Analyzes a text-based audio source synchronously.
64
+ *
65
+ * @param source - The text-based audio source to analyze.
66
+ * @param options - Optional analysis options.
67
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
68
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
69
+ */
70
+ analyzeText(source, options, endpoint = ":version/read") {
71
+ return __awaiter(this, void 0, void 0, function* () {
72
+ try {
73
+ let body;
74
+ if (isTextSource(source)) {
75
+ body = JSON.stringify(source);
76
+ }
77
+ else {
78
+ throw new DeepgramError("Unknown source type");
79
+ }
80
+ if (options !== undefined && "callback" in options) {
81
+ throw new DeepgramError("Callback cannot be provided as an option to a synchronous requests. Use `analyzeUrlCallback` or `analyzeTextCallback` instead.");
82
+ }
83
+ const requestUrl = this.getRequestUrl(endpoint, {}, Object.assign({}, options));
84
+ const result = yield this.post(requestUrl, body).then((result) => result.json());
85
+ return { result, error: null };
86
+ }
87
+ catch (error) {
88
+ if (isDeepgramError(error)) {
89
+ return { result: null, error };
90
+ }
91
+ throw error;
92
+ }
93
+ });
94
+ }
95
+ /**
96
+ * Analyzes a URL-based audio source asynchronously.
97
+ *
98
+ * @param source - The URL-based audio source to analyze.
99
+ * @param callback - The URL to call back with the analysis results.
100
+ * @param options - Optional analysis options.
101
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
102
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
103
+ */
104
+ analyzeUrlCallback(source, callback, options, endpoint = ":version/read") {
105
+ return __awaiter(this, void 0, void 0, function* () {
106
+ try {
107
+ let body;
108
+ if (isUrlSource(source)) {
109
+ body = JSON.stringify(source);
110
+ }
111
+ else {
112
+ throw new DeepgramError("Unknown source type");
113
+ }
114
+ const requestUrl = this.getRequestUrl(endpoint, {}, Object.assign(Object.assign({}, options), { callback: callback.toString() }));
115
+ const result = yield this.post(requestUrl, body).then((result) => result.json());
116
+ return { result, error: null };
117
+ }
118
+ catch (error) {
119
+ if (isDeepgramError(error)) {
120
+ return { result: null, error };
121
+ }
122
+ throw error;
123
+ }
124
+ });
125
+ }
126
+ /**
127
+ * Analyzes a text-based audio source asynchronously.
128
+ *
129
+ * @param source - The text-based audio source to analyze.
130
+ * @param callback - The URL to call back with the analysis results.
131
+ * @param options - Optional analysis options.
132
+ * @param endpoint - The API endpoint to use for the analysis. Defaults to ":version/read".
133
+ * @returns A promise that resolves to the analysis response, or an error if the analysis fails.
134
+ */
135
+ analyzeTextCallback(source, callback, options, endpoint = ":version/read") {
136
+ return __awaiter(this, void 0, void 0, function* () {
137
+ try {
138
+ let body;
139
+ if (isTextSource(source)) {
140
+ body = JSON.stringify(source);
141
+ }
142
+ else {
143
+ throw new DeepgramError("Unknown source type");
144
+ }
145
+ const requestUrl = this.getRequestUrl(endpoint, {}, Object.assign(Object.assign({}, options), { callback: callback.toString() }));
146
+ const result = yield this.post(requestUrl, body, {
147
+ headers: { "Content-Type": "deepgram/audio+video" },
148
+ }).then((result) => result.json());
149
+ return { result, error: null };
150
+ }
151
+ catch (error) {
152
+ if (isDeepgramError(error)) {
153
+ return { result: null, error };
154
+ }
155
+ throw error;
156
+ }
157
+ });
158
+ }
159
+ }
160
+ export { ReadRestClient as ReadClient };
161
+ //# sourceMappingURL=ReadRestClient.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReadRestClient.js","sourceRoot":"","sources":["../../../src/packages/ReadRestClient.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAmC,YAAY,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC5F,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAS/D,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D;;;;;;;;;;GAUG;AACH,MAAM,OAAO,cAAe,SAAQ,kBAAkB;IAAtD;;QACS,cAAS,GAAW,MAAM,CAAC;IA6KpC,CAAC;IA3KC;;;;;;;OAOG;IACG,UAAU,CACd,MAAiB,EACjB,OAAuB,EACvB,QAAQ,GAAG,eAAe;;YAE1B,IAAI;gBACF,IAAI,IAAI,CAAC;gBAET,IAAI,WAAW,CAAC,MAAM,CAAC,EAAE;oBACvB,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;iBAC/B;qBAAM;oBACL,MAAM,IAAI,aAAa,CAAC,qBAAqB,CAAC,CAAC;iBAChD;gBAED,IAAI,OAAO,KAAK,SAAS,IAAI,UAAU,IAAI,OAAO,EAAE;oBAClD,MAAM,IAAI,aAAa,CACrB,qIAAqI,CACtI,CAAC;iBACH;gBAED,MAAM,UAAU,GAAG,IAAI,CAAC,aAAa,CAAC,QAAQ,EAAE,EAAE,gBAAO,EAAE,EAAK,OAAO,EAAG,CAAC;gBAC3E,MAAM,MAAM,GAAwB,MAAM,IAAI,CAAC,IAAI,CAAC,UAAU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AAM,UAAU,GAAG,IAAI,CAAC,aAAa,CACnC,QAAQ,EACR,EAAE,kCACG,OAAO,KAAE,QAAQ,EAAE,QAAQ,CAAC,QAAQ,EAAE,IAC5C,CAAC;gBACF,MAAM,MAAM,GAAyB,MAAM,IAAI,CAAC,IAAI,CAAC,UAAU,EAAE,IAAI,EAAE;oBACrE,OAAO,EAAE,EAAE,cAAc,EAAE,sBAAsB,EAAE;iBACpD,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC;gBAEnC,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;aAChC;YAAC,OAAO,KAAK,EAAE;gBACd,IAAI,eAAe,CAAC,KAAK,CAAC,EAAE;oBAC1B,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;iBAChC;gBAED,MAAM,KAAK,CAAC;aACb;QACH,CAAC;KAAA;CACF;AAED,OAAO,EAAE,cAAc,IAAI,UAAU,EAAE,CAAC"}
@@ -0,0 +1,47 @@
1
+ import type { CreateOnPremCredentialsSchema, DeepgramResponse, ListOnPremCredentialsResponse, MessageResponse, OnPremCredentialResponse } from "../lib/types";
2
+ import { AbstractRestClient } from "./AbstractRestClient";
3
+ /**
4
+ * The `SelfHostedRestClient` class extends the `AbstractRestClient` class and provides methods for interacting with the Deepgram self-hosted API.
5
+ *
6
+ * This class is used to list, retrieve, create, and delete self-hosted credentials for a Deepgram project.
7
+ */
8
+ export declare class SelfHostedRestClient extends AbstractRestClient {
9
+ namespace: string;
10
+ /**
11
+ * Lists the self-hosted credentials for a Deepgram project.
12
+ *
13
+ * @param projectId - The ID of the Deepgram project.
14
+ * @returns A promise that resolves to an object containing the list of self-hosted credentials and any error that occurred.
15
+ * @see https://developers.deepgram.com/reference/list-credentials
16
+ */
17
+ listCredentials(projectId: string, endpoint?: string): Promise<DeepgramResponse<ListOnPremCredentialsResponse>>;
18
+ /**
19
+ * Retrieves the self-hosted credentials for a specific Deepgram project and credentials ID.
20
+ *
21
+ * @param projectId - The ID of the Deepgram project.
22
+ * @param credentialsId - The ID of the self-hosted credentials to retrieve.
23
+ * @returns A promise that resolves to an object containing the self-hosted credentials and any error that occurred.
24
+ * @see https://developers.deepgram.com/reference/get-credentials
25
+ */
26
+ getCredentials(projectId: string, credentialsId: string, endpoint?: string): Promise<DeepgramResponse<OnPremCredentialResponse>>;
27
+ /**
28
+ * Creates self-hosted credentials for a specific Deepgram project.
29
+ *
30
+ * @param projectId - The ID of the Deepgram project.
31
+ * @param options - The options for creating the self-hosted credentials.
32
+ * @returns A promise that resolves to an object containing the created self-hosted credentials and any error that occurred.
33
+ * @see https://developers.deepgram.com/reference/create-credentials
34
+ */
35
+ createCredentials(projectId: string, options: CreateOnPremCredentialsSchema, endpoint?: string): Promise<DeepgramResponse<OnPremCredentialResponse>>;
36
+ /**
37
+ * Deletes self-hosted credentials for a specific Deepgram project.
38
+ *
39
+ * @param projectId - The ID of the Deepgram project.
40
+ * @param credentialsId - The ID of the self-hosted credentials to delete.
41
+ * @returns A promise that resolves to an object containing a message response and any error that occurred.
42
+ * @see https://developers.deepgram.com/reference/delete-credentials
43
+ */
44
+ deleteCredentials(projectId: string, credentialsId: string, endpoint?: string): Promise<DeepgramResponse<MessageResponse>>;
45
+ }
46
+ export { SelfHostedRestClient as OnPremClient };
47
+ //# sourceMappingURL=SelfHostedRestClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SelfHostedRestClient.d.ts","sourceRoot":"","sources":["../../../src/packages/SelfHostedRestClient.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,6BAA6B,EAC7B,gBAAgB,EAChB,6BAA6B,EAC7B,eAAe,EACf,wBAAwB,EACzB,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D;;;;GAIG;AACH,qBAAa,oBAAqB,SAAQ,kBAAkB;IACnD,SAAS,EAAE,MAAM,CAAgB;IAExC;;;;;;OAMG;IACG,eAAe,CACnB,SAAS,EAAE,MAAM,EACjB,QAAQ,SAAiE,GACxE,OAAO,CAAC,gBAAgB,CAAC,6BAA6B,CAAC,CAAC;IAiB3D;;;;;;;OAOG;IACG,cAAc,CAClB,SAAS,EAAE,MAAM,EACjB,aAAa,EAAE,MAAM,EACrB,QAAQ,SAAgF,GACvF,OAAO,CAAC,gBAAgB,CAAC,wBAAwB,CAAC,CAAC;IAiBtD;;;;;;;OAOG;IACG,iBAAiB,CACrB,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,6BAA6B,EACtC,QAAQ,SAAiE,GACxE,OAAO,CAAC,gBAAgB,CAAC,wBAAwB,CAAC,CAAC;IAmBtD;;;;;;;OAOG;IACG,iBAAiB,CACrB,SAAS,EAAE,MAAM,EACjB,aAAa,EAAE,MAAM,EACrB,QAAQ,SAAgF,GACvF,OAAO,CAAC,gBAAgB,CAAC,eAAe,CAAC,CAAC;CAc9C;AAED,OAAO,EAAE,oBAAoB,IAAI,YAAY,EAAE,CAAC"}
@@ -0,0 +1,116 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import { isDeepgramError } from "../lib/errors";
11
+ import { AbstractRestClient } from "./AbstractRestClient";
12
+ /**
13
+ * The `SelfHostedRestClient` class extends the `AbstractRestClient` class and provides methods for interacting with the Deepgram self-hosted API.
14
+ *
15
+ * This class is used to list, retrieve, create, and delete self-hosted credentials for a Deepgram project.
16
+ */
17
+ export class SelfHostedRestClient extends AbstractRestClient {
18
+ constructor() {
19
+ super(...arguments);
20
+ this.namespace = "selfhosted";
21
+ }
22
+ /**
23
+ * Lists the self-hosted credentials for a Deepgram project.
24
+ *
25
+ * @param projectId - The ID of the Deepgram project.
26
+ * @returns A promise that resolves to an object containing the list of self-hosted credentials and any error that occurred.
27
+ * @see https://developers.deepgram.com/reference/list-credentials
28
+ */
29
+ listCredentials(projectId, endpoint = ":version/projects/:projectId/onprem/distribution/credentials") {
30
+ return __awaiter(this, void 0, void 0, function* () {
31
+ try {
32
+ const requestUrl = this.getRequestUrl(endpoint, { projectId });
33
+ const result = yield this.get(requestUrl).then((result) => result.json());
34
+ return { result, error: null };
35
+ }
36
+ catch (error) {
37
+ if (isDeepgramError(error)) {
38
+ return { result: null, error };
39
+ }
40
+ throw error;
41
+ }
42
+ });
43
+ }
44
+ /**
45
+ * Retrieves the self-hosted credentials for a specific Deepgram project and credentials ID.
46
+ *
47
+ * @param projectId - The ID of the Deepgram project.
48
+ * @param credentialsId - The ID of the self-hosted credentials to retrieve.
49
+ * @returns A promise that resolves to an object containing the self-hosted credentials and any error that occurred.
50
+ * @see https://developers.deepgram.com/reference/get-credentials
51
+ */
52
+ getCredentials(projectId, credentialsId, endpoint = ":version/projects/:projectId/onprem/distribution/credentials/:credentialsId") {
53
+ return __awaiter(this, void 0, void 0, function* () {
54
+ try {
55
+ const requestUrl = this.getRequestUrl(endpoint, { projectId, credentialsId });
56
+ const result = yield this.get(requestUrl).then((result) => result.json());
57
+ return { result, error: null };
58
+ }
59
+ catch (error) {
60
+ if (isDeepgramError(error)) {
61
+ return { result: null, error };
62
+ }
63
+ throw error;
64
+ }
65
+ });
66
+ }
67
+ /**
68
+ * Creates self-hosted credentials for a specific Deepgram project.
69
+ *
70
+ * @param projectId - The ID of the Deepgram project.
71
+ * @param options - The options for creating the self-hosted credentials.
72
+ * @returns A promise that resolves to an object containing the created self-hosted credentials and any error that occurred.
73
+ * @see https://developers.deepgram.com/reference/create-credentials
74
+ */
75
+ createCredentials(projectId, options, endpoint = ":version/projects/:projectId/onprem/distribution/credentials") {
76
+ return __awaiter(this, void 0, void 0, function* () {
77
+ try {
78
+ const requestUrl = this.getRequestUrl(endpoint, { projectId });
79
+ const body = JSON.stringify(options);
80
+ const result = yield this.post(requestUrl, body).then((result) => result.json());
81
+ return { result, error: null };
82
+ }
83
+ catch (error) {
84
+ if (isDeepgramError(error)) {
85
+ return { result: null, error };
86
+ }
87
+ throw error;
88
+ }
89
+ });
90
+ }
91
+ /**
92
+ * Deletes self-hosted credentials for a specific Deepgram project.
93
+ *
94
+ * @param projectId - The ID of the Deepgram project.
95
+ * @param credentialsId - The ID of the self-hosted credentials to delete.
96
+ * @returns A promise that resolves to an object containing a message response and any error that occurred.
97
+ * @see https://developers.deepgram.com/reference/delete-credentials
98
+ */
99
+ deleteCredentials(projectId, credentialsId, endpoint = ":version/projects/:projectId/onprem/distribution/credentials/:credentialsId") {
100
+ return __awaiter(this, void 0, void 0, function* () {
101
+ try {
102
+ const requestUrl = this.getRequestUrl(endpoint, { projectId, credentialsId });
103
+ const result = yield this.delete(requestUrl).then((result) => result.json());
104
+ return { result, error: null };
105
+ }
106
+ catch (error) {
107
+ if (isDeepgramError(error)) {
108
+ return { result: null, error };
109
+ }
110
+ throw error;
111
+ }
112
+ });
113
+ }
114
+ }
115
+ export { SelfHostedRestClient as OnPremClient };
116
+ //# sourceMappingURL=SelfHostedRestClient.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SelfHostedRestClient.js","sourceRoot":"","sources":["../../../src/packages/SelfHostedRestClient.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAQhD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D;;;;GAIG;AACH,MAAM,OAAO,oBAAqB,SAAQ,kBAAkB;IAA5D;;QACS,cAAS,GAAW,YAAY,CAA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CAAC;KAAA;CACF;AAED,OAAO,EAAE,oBAAoB,IAAI,YAAY,EAAE,CAAC"}
@@ -0,0 +1,36 @@
1
+ import { SpeakSchema, TextSource } from "../lib/types";
2
+ import { AbstractRestClient } from "./AbstractRestClient";
3
+ /**
4
+ * Provides a client for interacting with the Deepgram Text-to-Speech API.
5
+ */
6
+ export declare class SpeakRestClient extends AbstractRestClient {
7
+ namespace: string;
8
+ result: undefined | Response;
9
+ /**
10
+ * Sends a request to the Deepgram Text-to-Speech API to generate audio from the provided text source.
11
+ *
12
+ * @param source - The text source to be converted to audio.
13
+ * @param options - Optional configuration options for the text-to-speech request.
14
+ * @param endpoint - The API endpoint to use for the request. Defaults to ":version/speak".
15
+ * @returns A promise that resolves to the SpeakRestClient instance, which can be used to retrieve the response headers and body.
16
+ * @throws {DeepgramError} If the text source type is unknown.
17
+ * @throws {DeepgramUnknownError} If the request was made before a previous request completed.
18
+ * @see https://developers.deepgram.com/reference/text-to-speech-api
19
+ */
20
+ request(source: TextSource, options?: SpeakSchema, endpoint?: string): Promise<SpeakRestClient>;
21
+ /**
22
+ * Retrieves the response body as a readable stream.
23
+ *
24
+ * @returns A promise that resolves to the response body as a readable stream, or `null` if no request has been made yet.
25
+ * @throws {DeepgramUnknownError} If a request has not been made yet.
26
+ */
27
+ getStream(): Promise<ReadableStream<Uint8Array> | null>;
28
+ /**
29
+ * Retrieves the response headers from the previous request.
30
+ *
31
+ * @returns A promise that resolves to the response headers, or throws a `DeepgramUnknownError` if no request has been made yet.
32
+ */
33
+ getHeaders(): Promise<Headers>;
34
+ }
35
+ export { SpeakRestClient as SpeakClient };
36
+ //# sourceMappingURL=SpeakRestClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SpeakRestClient.d.ts","sourceRoot":"","sources":["../../../src/packages/SpeakRestClient.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D;;GAEG;AACH,qBAAa,eAAgB,SAAQ,kBAAkB;IAC9C,SAAS,EAAE,MAAM,CAAW;IAC5B,MAAM,EAAE,SAAS,GAAG,QAAQ,CAAC;IAEpC;;;;;;;;;;OAUG;IACG,OAAO,CACX,MAAM,EAAE,UAAU,EAClB,OAAO,CAAC,EAAE,WAAW,EACrB,QAAQ,SAAmB,GAC1B,OAAO,CAAC,eAAe,CAAC;IAyB3B;;;;;OAKG;IACG,SAAS,IAAI,OAAO,CAAC,cAAc,CAAC,UAAU,CAAC,GAAG,IAAI,CAAC;IAO7D;;;;OAIG;IACG,UAAU,IAAI,OAAO,CAAC,OAAO,CAAC;CAMrC;AAED,OAAO,EAAE,eAAe,IAAI,WAAW,EAAE,CAAC"}
@@ -0,0 +1,80 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import { DeepgramError, DeepgramUnknownError } from "../lib/errors";
11
+ import { isTextSource } from "../lib/helpers";
12
+ import { AbstractRestClient } from "./AbstractRestClient";
13
+ /**
14
+ * Provides a client for interacting with the Deepgram Text-to-Speech API.
15
+ */
16
+ export class SpeakRestClient extends AbstractRestClient {
17
+ constructor() {
18
+ super(...arguments);
19
+ this.namespace = "speak";
20
+ }
21
+ /**
22
+ * Sends a request to the Deepgram Text-to-Speech API to generate audio from the provided text source.
23
+ *
24
+ * @param source - The text source to be converted to audio.
25
+ * @param options - Optional configuration options for the text-to-speech request.
26
+ * @param endpoint - The API endpoint to use for the request. Defaults to ":version/speak".
27
+ * @returns A promise that resolves to the SpeakRestClient instance, which can be used to retrieve the response headers and body.
28
+ * @throws {DeepgramError} If the text source type is unknown.
29
+ * @throws {DeepgramUnknownError} If the request was made before a previous request completed.
30
+ * @see https://developers.deepgram.com/reference/text-to-speech-api
31
+ */
32
+ request(source, options, endpoint = ":version/speak") {
33
+ return __awaiter(this, void 0, void 0, function* () {
34
+ try {
35
+ let body;
36
+ if (isTextSource(source)) {
37
+ body = JSON.stringify(source);
38
+ }
39
+ else {
40
+ throw new DeepgramError("Unknown transcription source type");
41
+ }
42
+ const requestUrl = this.getRequestUrl(endpoint, {}, Object.assign({ model: "aura-asteria-en" }, options));
43
+ this.result = yield this.post(requestUrl, body, {
44
+ headers: { Accept: "audio/*", "Content-Type": "application/json" },
45
+ });
46
+ return this;
47
+ }
48
+ catch (error) {
49
+ throw error;
50
+ }
51
+ });
52
+ }
53
+ /**
54
+ * Retrieves the response body as a readable stream.
55
+ *
56
+ * @returns A promise that resolves to the response body as a readable stream, or `null` if no request has been made yet.
57
+ * @throws {DeepgramUnknownError} If a request has not been made yet.
58
+ */
59
+ getStream() {
60
+ return __awaiter(this, void 0, void 0, function* () {
61
+ if (!this.result)
62
+ throw new DeepgramUnknownError("Tried to get stream before making request", "");
63
+ return this.result.body;
64
+ });
65
+ }
66
+ /**
67
+ * Retrieves the response headers from the previous request.
68
+ *
69
+ * @returns A promise that resolves to the response headers, or throws a `DeepgramUnknownError` if no request has been made yet.
70
+ */
71
+ getHeaders() {
72
+ return __awaiter(this, void 0, void 0, function* () {
73
+ if (!this.result)
74
+ throw new DeepgramUnknownError("Tried to get headers before making request", "");
75
+ return this.result.headers;
76
+ });
77
+ }
78
+ }
79
+ export { SpeakRestClient as SpeakClient };
80
+ //# sourceMappingURL=SpeakRestClient.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SpeakRestClient.js","sourceRoot":"","sources":["../../../src/packages/SpeakRestClient.ts"],"names":[],"mapp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CAAC,IAAI,CAAC,MAAM;gBACd,MAAM,IAAI,oBAAoB,CAAC,4CAA4C,EAAE,EAAE,CAAC,CAAC;YAEnF,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC;QAC7B,CAAC;KAAA;CACF;AAED,OAAO,EAAE,eAAe,IAAI,WAAW,EAAE,CAAC"}
@@ -1,9 +1,11 @@
1
- export { AbstractClient } from "./AbstractClient";
2
- export { AbstractRestfulClient } from "./AbstractRestfulClient";
3
- export { AbstractWsClient } from "./AbstractWsClient";
4
- export { ListenClient } from "./ListenClient";
5
- export { LiveClient } from "./LiveClient";
6
- export { ManageClient } from "./ManageClient";
7
- export { OnPremClient } from "./OnPremClient";
8
- export { PrerecordedClient } from "./PrerecordedClient";
1
+ export * from "./AbstractClient";
2
+ export * from "./AbstractLiveClient";
3
+ export * from "./AbstractRestClient";
4
+ export * from "./ListenClient";
5
+ export * from "./ListenLiveClient";
6
+ export * from "./ListenRestClient";
7
+ export * from "./ManageRestClient";
8
+ export * from "./ReadRestClient";
9
+ export * from "./SelfHostedRestClient";
10
+ export * from "./SpeakRestClient";
9
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/packages/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/packages/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC"}
@@ -1,9 +1,11 @@
1
- export { AbstractClient } from "./AbstractClient";
2
- export { AbstractRestfulClient } from "./AbstractRestfulClient";
3
- export { AbstractWsClient } from "./AbstractWsClient";
4
- export { ListenClient } from "./ListenClient";
5
- export { LiveClient } from "./LiveClient";
6
- export { ManageClient } from "./ManageClient";
7
- export { OnPremClient } from "./OnPremClient";
8
- export { PrerecordedClient } from "./PrerecordedClient";
1
+ export * from "./AbstractClient";
2
+ export * from "./AbstractLiveClient";
3
+ export * from "./AbstractRestClient";
4
+ export * from "./ListenClient";
5
+ export * from "./ListenLiveClient";
6
+ export * from "./ListenRestClient";
7
+ export * from "./ManageRestClient";
8
+ export * from "./ReadRestClient";
9
+ export * from "./SelfHostedRestClient";
10
+ export * from "./SpeakRestClient";
9
11
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/packages/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/packages/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC"}