telnyx 5.25.0 → 5.26.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 (182) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/client.js.map +1 -1
  3. package/client.mjs.map +1 -1
  4. package/package.json +1 -1
  5. package/resources/ai/ai.d.mts +8 -0
  6. package/resources/ai/ai.d.mts.map +1 -1
  7. package/resources/ai/ai.d.ts +8 -0
  8. package/resources/ai/ai.d.ts.map +1 -1
  9. package/resources/ai/ai.js +8 -0
  10. package/resources/ai/ai.js.map +1 -1
  11. package/resources/ai/ai.mjs +8 -0
  12. package/resources/ai/ai.mjs.map +1 -1
  13. package/resources/ai/assistants/scheduled-events.d.mts +21 -0
  14. package/resources/ai/assistants/scheduled-events.d.mts.map +1 -1
  15. package/resources/ai/assistants/scheduled-events.d.ts +21 -0
  16. package/resources/ai/assistants/scheduled-events.d.ts.map +1 -1
  17. package/resources/ai/index.d.mts +2 -0
  18. package/resources/ai/index.d.mts.map +1 -1
  19. package/resources/ai/index.d.ts +2 -0
  20. package/resources/ai/index.d.ts.map +1 -1
  21. package/resources/ai/index.js +5 -1
  22. package/resources/ai/index.js.map +1 -1
  23. package/resources/ai/index.mjs +2 -0
  24. package/resources/ai/index.mjs.map +1 -1
  25. package/resources/ai/missions/index.d.mts +6 -0
  26. package/resources/ai/missions/index.d.mts.map +1 -0
  27. package/resources/ai/missions/index.d.ts +6 -0
  28. package/resources/ai/missions/index.d.ts.map +1 -0
  29. package/resources/ai/missions/index.js +15 -0
  30. package/resources/ai/missions/index.js.map +1 -0
  31. package/resources/ai/missions/index.mjs +7 -0
  32. package/resources/ai/missions/index.mjs.map +1 -0
  33. package/resources/ai/missions/knowledge-bases.d.mts +84 -0
  34. package/resources/ai/missions/knowledge-bases.d.mts.map +1 -0
  35. package/resources/ai/missions/knowledge-bases.d.ts +84 -0
  36. package/resources/ai/missions/knowledge-bases.d.ts.map +1 -0
  37. package/resources/ai/missions/knowledge-bases.js +89 -0
  38. package/resources/ai/missions/knowledge-bases.js.map +1 -0
  39. package/resources/ai/missions/knowledge-bases.mjs +85 -0
  40. package/resources/ai/missions/knowledge-bases.mjs.map +1 -0
  41. package/resources/ai/missions/mcp-servers.d.mts +84 -0
  42. package/resources/ai/missions/mcp-servers.d.mts.map +1 -0
  43. package/resources/ai/missions/mcp-servers.d.ts +84 -0
  44. package/resources/ai/missions/mcp-servers.d.ts.map +1 -0
  45. package/resources/ai/missions/mcp-servers.js +89 -0
  46. package/resources/ai/missions/mcp-servers.js.map +1 -0
  47. package/resources/ai/missions/mcp-servers.mjs +85 -0
  48. package/resources/ai/missions/mcp-servers.mjs.map +1 -0
  49. package/resources/ai/missions/missions.d.mts +168 -0
  50. package/resources/ai/missions/missions.d.mts.map +1 -0
  51. package/resources/ai/missions/missions.d.ts +168 -0
  52. package/resources/ai/missions/missions.d.ts.map +1 -0
  53. package/resources/ai/missions/missions.js +131 -0
  54. package/resources/ai/missions/missions.js.map +1 -0
  55. package/resources/ai/missions/missions.mjs +126 -0
  56. package/resources/ai/missions/missions.mjs.map +1 -0
  57. package/resources/ai/missions/runs/events.d.mts +161 -0
  58. package/resources/ai/missions/runs/events.d.mts.map +1 -0
  59. package/resources/ai/missions/runs/events.d.ts +161 -0
  60. package/resources/ai/missions/runs/events.d.ts.map +1 -0
  61. package/resources/ai/missions/runs/events.js +67 -0
  62. package/resources/ai/missions/runs/events.js.map +1 -0
  63. package/resources/ai/missions/runs/events.mjs +63 -0
  64. package/resources/ai/missions/runs/events.mjs.map +1 -0
  65. package/resources/ai/missions/runs/index.d.mts +5 -0
  66. package/resources/ai/missions/runs/index.d.mts.map +1 -0
  67. package/resources/ai/missions/runs/index.d.ts +5 -0
  68. package/resources/ai/missions/runs/index.d.ts.map +1 -0
  69. package/resources/ai/missions/runs/index.js +13 -0
  70. package/resources/ai/missions/runs/index.js.map +1 -0
  71. package/resources/ai/missions/runs/index.mjs +6 -0
  72. package/resources/ai/missions/runs/index.mjs.map +1 -0
  73. package/resources/ai/missions/runs/plan.d.mts +190 -0
  74. package/resources/ai/missions/runs/plan.d.mts.map +1 -0
  75. package/resources/ai/missions/runs/plan.d.ts +190 -0
  76. package/resources/ai/missions/runs/plan.d.ts.map +1 -0
  77. package/resources/ai/missions/runs/plan.js +112 -0
  78. package/resources/ai/missions/runs/plan.js.map +1 -0
  79. package/resources/ai/missions/runs/plan.mjs +108 -0
  80. package/resources/ai/missions/runs/plan.mjs.map +1 -0
  81. package/resources/ai/missions/runs/runs.d.mts +213 -0
  82. package/resources/ai/missions/runs/runs.d.mts.map +1 -0
  83. package/resources/ai/missions/runs/runs.d.ts +213 -0
  84. package/resources/ai/missions/runs/runs.d.ts.map +1 -0
  85. package/resources/ai/missions/runs/runs.js +148 -0
  86. package/resources/ai/missions/runs/runs.js.map +1 -0
  87. package/resources/ai/missions/runs/runs.mjs +143 -0
  88. package/resources/ai/missions/runs/runs.mjs.map +1 -0
  89. package/resources/ai/missions/runs/telnyx-agents.d.mts +90 -0
  90. package/resources/ai/missions/runs/telnyx-agents.d.mts.map +1 -0
  91. package/resources/ai/missions/runs/telnyx-agents.d.ts +90 -0
  92. package/resources/ai/missions/runs/telnyx-agents.d.ts.map +1 -0
  93. package/resources/ai/missions/runs/telnyx-agents.js +67 -0
  94. package/resources/ai/missions/runs/telnyx-agents.js.map +1 -0
  95. package/resources/ai/missions/runs/telnyx-agents.mjs +63 -0
  96. package/resources/ai/missions/runs/telnyx-agents.mjs.map +1 -0
  97. package/resources/ai/missions/runs.d.mts +2 -0
  98. package/resources/ai/missions/runs.d.mts.map +1 -0
  99. package/resources/ai/missions/runs.d.ts +2 -0
  100. package/resources/ai/missions/runs.d.ts.map +1 -0
  101. package/resources/ai/missions/runs.js +6 -0
  102. package/resources/ai/missions/runs.js.map +1 -0
  103. package/resources/ai/missions/runs.mjs +3 -0
  104. package/resources/ai/missions/runs.mjs.map +1 -0
  105. package/resources/ai/missions/tools.d.mts +79 -0
  106. package/resources/ai/missions/tools.d.mts.map +1 -0
  107. package/resources/ai/missions/tools.d.ts +79 -0
  108. package/resources/ai/missions/tools.d.ts.map +1 -0
  109. package/resources/ai/missions/tools.js +84 -0
  110. package/resources/ai/missions/tools.js.map +1 -0
  111. package/resources/ai/missions/tools.mjs +80 -0
  112. package/resources/ai/missions/tools.mjs.map +1 -0
  113. package/resources/ai/missions.d.mts +2 -0
  114. package/resources/ai/missions.d.mts.map +1 -0
  115. package/resources/ai/missions.d.ts +2 -0
  116. package/resources/ai/missions.d.ts.map +1 -0
  117. package/resources/ai/missions.js +6 -0
  118. package/resources/ai/missions.js.map +1 -0
  119. package/resources/ai/missions.mjs +3 -0
  120. package/resources/ai/missions.mjs.map +1 -0
  121. package/resources/ai/openai/embeddings.d.mts +133 -0
  122. package/resources/ai/openai/embeddings.d.mts.map +1 -0
  123. package/resources/ai/openai/embeddings.d.ts +133 -0
  124. package/resources/ai/openai/embeddings.d.ts.map +1 -0
  125. package/resources/ai/openai/embeddings.js +41 -0
  126. package/resources/ai/openai/embeddings.js.map +1 -0
  127. package/resources/ai/openai/embeddings.mjs +37 -0
  128. package/resources/ai/openai/embeddings.mjs.map +1 -0
  129. package/resources/ai/openai/index.d.mts +3 -0
  130. package/resources/ai/openai/index.d.mts.map +1 -0
  131. package/resources/ai/openai/index.d.ts +3 -0
  132. package/resources/ai/openai/index.d.ts.map +1 -0
  133. package/resources/ai/openai/index.js +9 -0
  134. package/resources/ai/openai/index.js.map +1 -0
  135. package/resources/ai/openai/index.mjs +4 -0
  136. package/resources/ai/openai/index.mjs.map +1 -0
  137. package/resources/ai/openai/openai.d.mts +10 -0
  138. package/resources/ai/openai/openai.d.mts.map +1 -0
  139. package/resources/ai/openai/openai.d.ts +10 -0
  140. package/resources/ai/openai/openai.d.ts.map +1 -0
  141. package/resources/ai/openai/openai.js +17 -0
  142. package/resources/ai/openai/openai.js.map +1 -0
  143. package/resources/ai/openai/openai.mjs +12 -0
  144. package/resources/ai/openai/openai.mjs.map +1 -0
  145. package/resources/ai/openai.d.mts +2 -0
  146. package/resources/ai/openai.d.mts.map +1 -0
  147. package/resources/ai/openai.d.ts +2 -0
  148. package/resources/ai/openai.d.ts.map +1 -0
  149. package/resources/ai/openai.js +6 -0
  150. package/resources/ai/openai.js.map +1 -0
  151. package/resources/ai/openai.mjs +3 -0
  152. package/resources/ai/openai.mjs.map +1 -0
  153. package/resources/shared.d.mts +4 -3
  154. package/resources/shared.d.mts.map +1 -1
  155. package/resources/shared.d.ts +4 -3
  156. package/resources/shared.d.ts.map +1 -1
  157. package/src/client.ts +1 -1
  158. package/src/resources/ai/ai.ts +40 -0
  159. package/src/resources/ai/assistants/scheduled-events.ts +18 -0
  160. package/src/resources/ai/index.ts +16 -0
  161. package/src/resources/ai/missions/index.ts +66 -0
  162. package/src/resources/ai/missions/knowledge-bases.ts +136 -0
  163. package/src/resources/ai/missions/mcp-servers.ts +136 -0
  164. package/src/resources/ai/missions/missions.ts +365 -0
  165. package/src/resources/ai/missions/runs/events.ts +271 -0
  166. package/src/resources/ai/missions/runs/index.ts +53 -0
  167. package/src/resources/ai/missions/runs/plan.ts +271 -0
  168. package/src/resources/ai/missions/runs/runs.ts +384 -0
  169. package/src/resources/ai/missions/runs/telnyx-agents.ts +139 -0
  170. package/src/resources/ai/missions/runs.ts +3 -0
  171. package/src/resources/ai/missions/tools.ts +119 -0
  172. package/src/resources/ai/missions.ts +3 -0
  173. package/src/resources/ai/openai/embeddings.ts +168 -0
  174. package/src/resources/ai/openai/index.ts +9 -0
  175. package/src/resources/ai/openai/openai.ts +25 -0
  176. package/src/resources/ai/openai.ts +3 -0
  177. package/src/resources/shared.ts +5 -3
  178. package/src/version.ts +1 -1
  179. package/version.d.mts +1 -1
  180. package/version.d.ts +1 -1
  181. package/version.js +1 -1
  182. package/version.mjs +1 -1
@@ -0,0 +1,139 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../../../core/resource';
4
+ import { APIPromise } from '../../../../core/api-promise';
5
+ import { buildHeaders } from '../../../../internal/headers';
6
+ import { RequestOptions } from '../../../../internal/request-options';
7
+ import { path } from '../../../../internal/utils/path';
8
+
9
+ export class TelnyxAgents extends APIResource {
10
+ /**
11
+ * List all Telnyx agents linked to a run
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * const telnyxAgents =
16
+ * await client.ai.missions.runs.telnyxAgents.list(
17
+ * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
18
+ * { mission_id: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e' },
19
+ * );
20
+ * ```
21
+ */
22
+ list(
23
+ runID: string,
24
+ params: TelnyxAgentListParams,
25
+ options?: RequestOptions,
26
+ ): APIPromise<TelnyxAgentListResponse> {
27
+ const { mission_id } = params;
28
+ return this._client.get(path`/ai/missions/${mission_id}/runs/${runID}/telnyx-agents`, options);
29
+ }
30
+
31
+ /**
32
+ * Link a Telnyx AI agent (voice/messaging) to a run
33
+ *
34
+ * @example
35
+ * ```ts
36
+ * const response =
37
+ * await client.ai.missions.runs.telnyxAgents.link(
38
+ * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
39
+ * {
40
+ * mission_id: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
41
+ * telnyx_agent_id: 'telnyx_agent_id',
42
+ * },
43
+ * );
44
+ * ```
45
+ */
46
+ link(
47
+ runID: string,
48
+ params: TelnyxAgentLinkParams,
49
+ options?: RequestOptions,
50
+ ): APIPromise<TelnyxAgentLinkResponse> {
51
+ const { mission_id, ...body } = params;
52
+ return this._client.post(path`/ai/missions/${mission_id}/runs/${runID}/telnyx-agents`, {
53
+ body,
54
+ ...options,
55
+ });
56
+ }
57
+
58
+ /**
59
+ * Unlink a Telnyx agent from a run
60
+ *
61
+ * @example
62
+ * ```ts
63
+ * await client.ai.missions.runs.telnyxAgents.unlink(
64
+ * 'telnyx_agent_id',
65
+ * {
66
+ * mission_id: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
67
+ * run_id: '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
68
+ * },
69
+ * );
70
+ * ```
71
+ */
72
+ unlink(telnyxAgentID: string, params: TelnyxAgentUnlinkParams, options?: RequestOptions): APIPromise<void> {
73
+ const { mission_id, run_id } = params;
74
+ return this._client.delete(
75
+ path`/ai/missions/${mission_id}/runs/${run_id}/telnyx-agents/${telnyxAgentID}`,
76
+ { ...options, headers: buildHeaders([{ Accept: '*/*' }, options?.headers]) },
77
+ );
78
+ }
79
+ }
80
+
81
+ export interface TelnyxAgentListResponse {
82
+ data: Array<TelnyxAgentListResponse.Data>;
83
+ }
84
+
85
+ export namespace TelnyxAgentListResponse {
86
+ export interface Data {
87
+ created_at: string;
88
+
89
+ run_id: string;
90
+
91
+ telnyx_agent_id: string;
92
+ }
93
+ }
94
+
95
+ export interface TelnyxAgentLinkResponse {
96
+ data: TelnyxAgentLinkResponse.Data;
97
+ }
98
+
99
+ export namespace TelnyxAgentLinkResponse {
100
+ export interface Data {
101
+ created_at: string;
102
+
103
+ run_id: string;
104
+
105
+ telnyx_agent_id: string;
106
+ }
107
+ }
108
+
109
+ export interface TelnyxAgentListParams {
110
+ mission_id: string;
111
+ }
112
+
113
+ export interface TelnyxAgentLinkParams {
114
+ /**
115
+ * Path param
116
+ */
117
+ mission_id: string;
118
+
119
+ /**
120
+ * Body param: The Telnyx AI agent ID to link
121
+ */
122
+ telnyx_agent_id: string;
123
+ }
124
+
125
+ export interface TelnyxAgentUnlinkParams {
126
+ mission_id: string;
127
+
128
+ run_id: string;
129
+ }
130
+
131
+ export declare namespace TelnyxAgents {
132
+ export {
133
+ type TelnyxAgentListResponse as TelnyxAgentListResponse,
134
+ type TelnyxAgentLinkResponse as TelnyxAgentLinkResponse,
135
+ type TelnyxAgentListParams as TelnyxAgentListParams,
136
+ type TelnyxAgentLinkParams as TelnyxAgentLinkParams,
137
+ type TelnyxAgentUnlinkParams as TelnyxAgentUnlinkParams,
138
+ };
139
+ }
@@ -0,0 +1,3 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export * from './runs/index';
@@ -0,0 +1,119 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../../core/resource';
4
+ import { APIPromise } from '../../../core/api-promise';
5
+ import { buildHeaders } from '../../../internal/headers';
6
+ import { RequestOptions } from '../../../internal/request-options';
7
+ import { path } from '../../../internal/utils/path';
8
+
9
+ export class Tools extends APIResource {
10
+ /**
11
+ * Create a new tool for a mission
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * const response = await client.ai.missions.tools.createTool(
16
+ * 'mission_id',
17
+ * );
18
+ * ```
19
+ */
20
+ createTool(missionID: string, options?: RequestOptions): APIPromise<unknown> {
21
+ return this._client.post(path`/ai/missions/${missionID}/tools`, options);
22
+ }
23
+
24
+ /**
25
+ * Delete a tool from a mission
26
+ *
27
+ * @example
28
+ * ```ts
29
+ * await client.ai.missions.tools.deleteTool('tool_id', {
30
+ * mission_id: 'mission_id',
31
+ * });
32
+ * ```
33
+ */
34
+ deleteTool(toolID: string, params: ToolDeleteToolParams, options?: RequestOptions): APIPromise<void> {
35
+ const { mission_id } = params;
36
+ return this._client.delete(path`/ai/missions/${mission_id}/tools/${toolID}`, {
37
+ ...options,
38
+ headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
39
+ });
40
+ }
41
+
42
+ /**
43
+ * Get a specific tool by ID
44
+ *
45
+ * @example
46
+ * ```ts
47
+ * const response = await client.ai.missions.tools.getTool(
48
+ * 'tool_id',
49
+ * { mission_id: 'mission_id' },
50
+ * );
51
+ * ```
52
+ */
53
+ getTool(toolID: string, params: ToolGetToolParams, options?: RequestOptions): APIPromise<unknown> {
54
+ const { mission_id } = params;
55
+ return this._client.get(path`/ai/missions/${mission_id}/tools/${toolID}`, options);
56
+ }
57
+
58
+ /**
59
+ * List all tools for a mission
60
+ *
61
+ * @example
62
+ * ```ts
63
+ * const response = await client.ai.missions.tools.listTools(
64
+ * 'mission_id',
65
+ * );
66
+ * ```
67
+ */
68
+ listTools(missionID: string, options?: RequestOptions): APIPromise<unknown> {
69
+ return this._client.get(path`/ai/missions/${missionID}/tools`, options);
70
+ }
71
+
72
+ /**
73
+ * Update a tool definition
74
+ *
75
+ * @example
76
+ * ```ts
77
+ * const response = await client.ai.missions.tools.updateTool(
78
+ * 'tool_id',
79
+ * { mission_id: 'mission_id' },
80
+ * );
81
+ * ```
82
+ */
83
+ updateTool(toolID: string, params: ToolUpdateToolParams, options?: RequestOptions): APIPromise<unknown> {
84
+ const { mission_id } = params;
85
+ return this._client.put(path`/ai/missions/${mission_id}/tools/${toolID}`, options);
86
+ }
87
+ }
88
+
89
+ export type ToolCreateToolResponse = unknown;
90
+
91
+ export type ToolGetToolResponse = unknown;
92
+
93
+ export type ToolListToolsResponse = unknown;
94
+
95
+ export type ToolUpdateToolResponse = unknown;
96
+
97
+ export interface ToolDeleteToolParams {
98
+ mission_id: string;
99
+ }
100
+
101
+ export interface ToolGetToolParams {
102
+ mission_id: string;
103
+ }
104
+
105
+ export interface ToolUpdateToolParams {
106
+ mission_id: string;
107
+ }
108
+
109
+ export declare namespace Tools {
110
+ export {
111
+ type ToolCreateToolResponse as ToolCreateToolResponse,
112
+ type ToolGetToolResponse as ToolGetToolResponse,
113
+ type ToolListToolsResponse as ToolListToolsResponse,
114
+ type ToolUpdateToolResponse as ToolUpdateToolResponse,
115
+ type ToolDeleteToolParams as ToolDeleteToolParams,
116
+ type ToolGetToolParams as ToolGetToolParams,
117
+ type ToolUpdateToolParams as ToolUpdateToolParams,
118
+ };
119
+ }
@@ -0,0 +1,3 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export * from './missions/index';
@@ -0,0 +1,168 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../../core/resource';
4
+ import { APIPromise } from '../../../core/api-promise';
5
+ import { RequestOptions } from '../../../internal/request-options';
6
+
7
+ export class Embeddings extends APIResource {
8
+ /**
9
+ * Creates an embedding vector representing the input text. This endpoint is
10
+ * compatible with the
11
+ * [OpenAI Embeddings API](https://platform.openai.com/docs/api-reference/embeddings)
12
+ * and may be used with the OpenAI JS or Python SDK by setting the base URL to
13
+ * `https://api.telnyx.com/v2/ai/openai`.
14
+ *
15
+ * @example
16
+ * ```ts
17
+ * const response =
18
+ * await client.ai.openai.embeddings.createEmbeddings({
19
+ * input: 'The quick brown fox jumps over the lazy dog',
20
+ * model: 'thenlper/gte-large',
21
+ * });
22
+ * ```
23
+ */
24
+ createEmbeddings(
25
+ body: EmbeddingCreateEmbeddingsParams,
26
+ options?: RequestOptions,
27
+ ): APIPromise<EmbeddingCreateEmbeddingsResponse> {
28
+ return this._client.post('/ai/openai/embeddings', { body, ...options });
29
+ }
30
+
31
+ /**
32
+ * Returns a list of available embedding models. This endpoint is compatible with
33
+ * the OpenAI Models API format.
34
+ *
35
+ * @example
36
+ * ```ts
37
+ * const response =
38
+ * await client.ai.openai.embeddings.listEmbeddingModels();
39
+ * ```
40
+ */
41
+ listEmbeddingModels(options?: RequestOptions): APIPromise<EmbeddingListEmbeddingModelsResponse> {
42
+ return this._client.get('/ai/openai/embeddings/models', options);
43
+ }
44
+ }
45
+
46
+ export interface EmbeddingCreateEmbeddingsResponse {
47
+ /**
48
+ * List of embedding objects
49
+ */
50
+ data: Array<EmbeddingCreateEmbeddingsResponse.Data>;
51
+
52
+ /**
53
+ * The model used for embedding
54
+ */
55
+ model: string;
56
+
57
+ /**
58
+ * The object type, always 'list'
59
+ */
60
+ object: string;
61
+
62
+ usage: EmbeddingCreateEmbeddingsResponse.Usage;
63
+ }
64
+
65
+ export namespace EmbeddingCreateEmbeddingsResponse {
66
+ export interface Data {
67
+ /**
68
+ * The embedding vector
69
+ */
70
+ embedding: Array<number>;
71
+
72
+ /**
73
+ * The index of the embedding in the list of embeddings
74
+ */
75
+ index: number;
76
+
77
+ /**
78
+ * The object type, always 'embedding'
79
+ */
80
+ object: string;
81
+ }
82
+
83
+ export interface Usage {
84
+ /**
85
+ * Number of tokens in the input
86
+ */
87
+ prompt_tokens: number;
88
+
89
+ /**
90
+ * Total number of tokens used
91
+ */
92
+ total_tokens: number;
93
+ }
94
+ }
95
+
96
+ export interface EmbeddingListEmbeddingModelsResponse {
97
+ /**
98
+ * List of available embedding models
99
+ */
100
+ data: Array<EmbeddingListEmbeddingModelsResponse.Data>;
101
+
102
+ /**
103
+ * The object type, always 'list'
104
+ */
105
+ object: string;
106
+ }
107
+
108
+ export namespace EmbeddingListEmbeddingModelsResponse {
109
+ export interface Data {
110
+ /**
111
+ * The model identifier
112
+ */
113
+ id: string;
114
+
115
+ /**
116
+ * Unix timestamp of when the model was created
117
+ */
118
+ created: number;
119
+
120
+ /**
121
+ * The object type, always 'model'
122
+ */
123
+ object: string;
124
+
125
+ /**
126
+ * The organization that owns the model
127
+ */
128
+ owned_by: string;
129
+ }
130
+ }
131
+
132
+ export interface EmbeddingCreateEmbeddingsParams {
133
+ /**
134
+ * Input text to embed. Can be a string or array of strings.
135
+ */
136
+ input: string | Array<string>;
137
+
138
+ /**
139
+ * ID of the model to use. Use the List embedding models endpoint to see available
140
+ * models.
141
+ */
142
+ model: string;
143
+
144
+ /**
145
+ * The number of dimensions the resulting output embeddings should have. Only
146
+ * supported in some models.
147
+ */
148
+ dimensions?: number;
149
+
150
+ /**
151
+ * The format to return the embeddings in.
152
+ */
153
+ encoding_format?: 'float' | 'base64';
154
+
155
+ /**
156
+ * A unique identifier representing your end-user for monitoring and abuse
157
+ * detection.
158
+ */
159
+ user?: string;
160
+ }
161
+
162
+ export declare namespace Embeddings {
163
+ export {
164
+ type EmbeddingCreateEmbeddingsResponse as EmbeddingCreateEmbeddingsResponse,
165
+ type EmbeddingListEmbeddingModelsResponse as EmbeddingListEmbeddingModelsResponse,
166
+ type EmbeddingCreateEmbeddingsParams as EmbeddingCreateEmbeddingsParams,
167
+ };
168
+ }
@@ -0,0 +1,9 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export {
4
+ Embeddings,
5
+ type EmbeddingCreateEmbeddingsResponse,
6
+ type EmbeddingListEmbeddingModelsResponse,
7
+ type EmbeddingCreateEmbeddingsParams,
8
+ } from './embeddings';
9
+ export { OpenAI } from './openai';
@@ -0,0 +1,25 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../../core/resource';
4
+ import * as EmbeddingsAPI from './embeddings';
5
+ import {
6
+ EmbeddingCreateEmbeddingsParams,
7
+ EmbeddingCreateEmbeddingsResponse,
8
+ EmbeddingListEmbeddingModelsResponse,
9
+ Embeddings,
10
+ } from './embeddings';
11
+
12
+ export class OpenAI extends APIResource {
13
+ embeddings: EmbeddingsAPI.Embeddings = new EmbeddingsAPI.Embeddings(this._client);
14
+ }
15
+
16
+ OpenAI.Embeddings = Embeddings;
17
+
18
+ export declare namespace OpenAI {
19
+ export {
20
+ Embeddings as Embeddings,
21
+ type EmbeddingCreateEmbeddingsResponse as EmbeddingCreateEmbeddingsResponse,
22
+ type EmbeddingListEmbeddingModelsResponse as EmbeddingListEmbeddingModelsResponse,
23
+ type EmbeddingCreateEmbeddingsParams as EmbeddingCreateEmbeddingsParams,
24
+ };
25
+ }
@@ -0,0 +1,3 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ export * from './openai/index';
@@ -74,7 +74,7 @@ export interface ConnectionNoiseSuppressionDetails {
74
74
  * The attenuation limit value for the selected engine. Default values vary by
75
75
  * engine: 0 for 'denoiser', 80 for 'deep_filter_net', 'deep_filter_net_large', and
76
76
  * all Krisp engines ('krisp_viva_tel', 'krisp_viva_tel_lite',
77
- * 'krisp_viva_promodel', 'krisp_viva_ss').
77
+ * 'krisp_viva_promodel', 'krisp_viva_ss'), 100 for 'quail_voice_focus'.
78
78
  */
79
79
  attenuation_limit?: number;
80
80
 
@@ -83,7 +83,8 @@ export interface ConnectionNoiseSuppressionDetails {
83
83
  * 'deep_filter_net' and 'deep_filter_net_large' are alternative engines with
84
84
  * different performance characteristics. Krisp engines ('krisp_viva_tel',
85
85
  * 'krisp_viva_tel_lite', 'krisp_viva_promodel', 'krisp_viva_ss') provide advanced
86
- * noise suppression capabilities.
86
+ * noise suppression capabilities. 'quail_voice_focus' provides Quail-based voice
87
+ * focus noise suppression.
87
88
  */
88
89
  engine?:
89
90
  | 'denoiser'
@@ -92,7 +93,8 @@ export interface ConnectionNoiseSuppressionDetails {
92
93
  | 'krisp_viva_tel'
93
94
  | 'krisp_viva_tel_lite'
94
95
  | 'krisp_viva_promodel'
95
- | 'krisp_viva_ss';
96
+ | 'krisp_viva_ss'
97
+ | 'quail_voice_focus';
96
98
  }
97
99
 
98
100
  export interface ConnectionsPaginationMeta {
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '5.25.0'; // x-release-please-version
1
+ export const VERSION = '5.26.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "5.25.0";
1
+ export declare const VERSION = "5.26.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "5.25.0";
1
+ export declare const VERSION = "5.26.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '5.25.0'; // x-release-please-version
4
+ exports.VERSION = '5.26.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '5.25.0'; // x-release-please-version
1
+ export const VERSION = '5.26.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map