@cartesia/cartesia-js 1.0.3 → 1.2.1-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/README.md +32 -3
  3. package/dist/{chunk-BHY7MNGT.js → chunk-5SBAQNWQ.js} +1 -1
  4. package/dist/{chunk-LZO6K34D.js → chunk-CSOXALSC.js} +7 -7
  5. package/dist/{chunk-PISCPZK4.js → chunk-FLWYXP5Z.js} +1 -1
  6. package/dist/chunk-GLZYI5DM.js +43 -0
  7. package/dist/{chunk-6YQ6KDIQ.js → chunk-I5YVYTNK.js} +47 -16
  8. package/dist/{chunk-NQVZNVOU.js → chunk-LKKWJLUG.js} +1 -1
  9. package/dist/{chunk-GHY2WEOK.js → chunk-NJDRWDQ3.js} +8 -35
  10. package/dist/{chunk-ZF6HASZT.js → chunk-QWNB544W.js} +7 -3
  11. package/dist/{chunk-YFN6TFR4.js → chunk-RJICGVPL.js} +12 -4
  12. package/dist/chunk-WLEVU3HN.js +42 -0
  13. package/dist/{chunk-EUW2435M.js → chunk-WSIVWXEI.js} +49 -25
  14. package/dist/index.cjs +162 -76
  15. package/dist/index.d.cts +2 -1
  16. package/dist/index.d.ts +2 -1
  17. package/dist/index.js +10 -9
  18. package/dist/lib/client.js +2 -2
  19. package/dist/lib/constants.js +1 -1
  20. package/dist/lib/index.cjs +157 -71
  21. package/dist/lib/index.d.cts +2 -0
  22. package/dist/lib/index.d.ts +2 -0
  23. package/dist/lib/index.js +9 -8
  24. package/dist/react/index.cjs +165 -76
  25. package/dist/react/index.js +14 -10
  26. package/dist/react/utils.js +2 -2
  27. package/dist/tts/index.cjs +114 -69
  28. package/dist/tts/index.d.cts +8 -1
  29. package/dist/tts/index.d.ts +8 -1
  30. package/dist/tts/index.js +6 -6
  31. package/dist/tts/player.cjs +13 -27
  32. package/dist/tts/player.js +4 -4
  33. package/dist/tts/source.cjs +54 -37
  34. package/dist/tts/source.d.cts +9 -0
  35. package/dist/tts/source.d.ts +9 -0
  36. package/dist/tts/source.js +2 -2
  37. package/dist/tts/utils.js +3 -3
  38. package/dist/tts/websocket.cjs +99 -69
  39. package/dist/tts/websocket.d.cts +15 -9
  40. package/dist/tts/websocket.d.ts +15 -9
  41. package/dist/tts/websocket.js +5 -5
  42. package/dist/types/index.d.cts +42 -3
  43. package/dist/types/index.d.ts +42 -3
  44. package/dist/voice-changer/index.cjs +143 -0
  45. package/dist/voice-changer/index.d.cts +9 -0
  46. package/dist/voice-changer/index.d.ts +9 -0
  47. package/dist/voice-changer/index.js +9 -0
  48. package/dist/voices/index.cjs +10 -2
  49. package/dist/voices/index.d.cts +2 -1
  50. package/dist/voices/index.d.ts +2 -1
  51. package/dist/voices/index.js +3 -3
  52. package/package.json +8 -16
  53. package/src/lib/index.ts +3 -0
  54. package/src/react/index.ts +4 -0
  55. package/src/tts/index.ts +16 -1
  56. package/src/tts/source.ts +35 -0
  57. package/src/tts/websocket.ts +33 -2
  58. package/src/types/index.ts +60 -2
  59. package/src/voice-changer/index.ts +37 -0
  60. package/src/voices/index.ts +12 -3
  61. package/.turbo/turbo-build.log +0 -75
  62. package/dist/chunk-NWCW6C7H.js +0 -25
  63. package/tsconfig.json +0 -3
@@ -1,75 +0,0 @@
1
- $ tsup src/ --format cjs,esm --dts
2
- CLI Building entry: src/index.ts, src/lib/client.ts, src/lib/constants.ts, src/lib/index.ts, src/react/index.ts, src/react/utils.ts, src/tts/index.ts, src/tts/player.ts, src/tts/source.ts, src/tts/utils.ts, src/tts/websocket.ts, src/types/index.ts, src/voices/index.ts
3
- CLI Using tsconfig: tsconfig.json
4
- CLI tsup v8.0.2
5
- CLI Target: es6
6
- CJS Build start
7
- ESM Build start
8
- ESM dist/chunk-FXPGR372.js 0 B
9
- ESM dist/index.js 499.00 B
10
- ESM dist/lib/client.js 132.00 B
11
- ESM dist/react/index.js 7.62 KB
12
- ESM dist/tts/index.js 261.00 B
13
- ESM dist/lib/constants.js 183.00 B
14
- ESM dist/lib/index.js 322.00 B
15
- ESM dist/chunk-ZF6HASZT.js 353.00 B
16
- ESM dist/chunk-YFN6TFR4.js 1.74 KB
17
- ESM dist/react/utils.js 109.00 B
18
- ESM dist/chunk-NQVZNVOU.js 337.00 B
19
- ESM dist/chunk-NWCW6C7H.js 439.00 B
20
- ESM dist/chunk-EUW2435M.js 7.17 KB
21
- ESM dist/chunk-PISCPZK4.js 1.02 KB
22
- ESM dist/chunk-2BFEKY3F.js 366.00 B
23
- ESM dist/tts/player.js 174.00 B
24
- ESM dist/chunk-LZO6K34D.js 3.76 KB
25
- ESM dist/chunk-BHY7MNGT.js 2.11 KB
26
- ESM dist/chunk-6YQ6KDIQ.js 5.32 KB
27
- ESM dist/chunk-GHY2WEOK.js 2.70 KB
28
- ESM dist/voices/index.js 174.00 B
29
- ESM dist/types/index.js 31.00 B
30
- ESM dist/tts/source.js 144.00 B
31
- ESM dist/tts/utils.js 426.00 B
32
- ESM dist/tts/websocket.js 242.00 B
33
- ESM ⚡️ Build success in 72ms
34
- CJS dist/index.cjs 24.98 KB
35
- CJS dist/lib/client.cjs 4.07 KB
36
- CJS dist/lib/constants.cjs 1.43 KB
37
- CJS dist/lib/index.cjs 20.87 KB
38
- CJS dist/react/index.cjs 32.54 KB
39
- CJS dist/react/utils.cjs 1.80 KB
40
- CJS dist/tts/index.cjs 18.96 KB
41
- CJS dist/tts/player.cjs 6.96 KB
42
- CJS dist/tts/utils.cjs 4.33 KB
43
- CJS dist/tts/source.cjs 8.15 KB
44
- CJS dist/types/index.cjs 764.00 B
45
- CJS dist/tts/websocket.cjs 18.65 KB
46
- CJS dist/voices/index.cjs 5.62 KB
47
- CJS ⚡️ Build success in 73ms
48
- DTS Build start
49
- DTS ⚡️ Build success in 8468ms
50
- DTS dist/index.d.cts 866.00 B
51
- DTS dist/lib/constants.d.cts 564.00 B
52
- DTS dist/lib/index.d.cts 410.00 B
53
- DTS dist/react/index.d.cts 1.09 KB
54
- DTS dist/react/utils.d.cts 240.00 B
55
- DTS dist/tts/index.d.cts 471.00 B
56
- DTS dist/tts/player.d.cts 1.20 KB
57
- DTS dist/tts/utils.d.cts 2.68 KB
58
- DTS dist/tts/websocket.d.cts 2.94 KB
59
- DTS dist/tts/source.d.cts 2.55 KB
60
- DTS dist/voices/index.d.cts 573.00 B
61
- DTS dist/lib/client.d.cts 293.00 B
62
- DTS dist/types/index.d.cts 3.50 KB
63
- DTS dist/index.d.ts 858.00 B
64
- DTS dist/lib/constants.d.ts 564.00 B
65
- DTS dist/lib/index.d.ts 404.00 B
66
- DTS dist/react/index.d.ts 1.09 KB
67
- DTS dist/react/utils.d.ts 240.00 B
68
- DTS dist/tts/index.d.ts 467.00 B
69
- DTS dist/tts/player.d.ts 1.20 KB
70
- DTS dist/tts/utils.d.ts 2.68 KB
71
- DTS dist/tts/websocket.d.ts 2.94 KB
72
- DTS dist/tts/source.d.ts 2.55 KB
73
- DTS dist/voices/index.d.ts 571.00 B
74
- DTS dist/lib/client.d.ts 292.00 B
75
- DTS dist/types/index.d.ts 3.50 KB
@@ -1,25 +0,0 @@
1
- import {
2
- WebSocket
3
- } from "./chunk-EUW2435M.js";
4
- import {
5
- Client
6
- } from "./chunk-PISCPZK4.js";
7
-
8
- // src/tts/index.ts
9
- var TTS = class extends Client {
10
- /**
11
- * Get a WebSocket client for streaming audio from the TTS API.
12
- *
13
- * @returns {WebSocket} A Cartesia WebSocket client.
14
- */
15
- websocket(options) {
16
- return new WebSocket(options, {
17
- apiKey: this.apiKey,
18
- baseUrl: this.baseUrl
19
- });
20
- }
21
- };
22
-
23
- export {
24
- TTS
25
- };
package/tsconfig.json DELETED
@@ -1,3 +0,0 @@
1
- {
2
- "extends": "@repo/config-typescript/react-library.json"
3
- }