@vapi-ai/web 1.0.255 → 1.0.257
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.
- package/README.md +19 -1
- package/api.ts +768 -244
- package/dist/AtomicMediaSource.d.ts +17 -0
- package/dist/AtomicMediaSource.js +78 -0
- package/dist/api.d.ts +590 -212
- package/dist/api.js +8 -4
- package/dist/player.d.ts +10 -0
- package/dist/player.js +38 -0
- package/package.json +2 -2
package/api.ts
CHANGED
|
@@ -10,16 +10,101 @@
|
|
|
10
10
|
*/
|
|
11
11
|
|
|
12
12
|
export interface DeepgramVoice {
|
|
13
|
-
/**
|
|
14
|
-
* This is the voice provider that will be used.
|
|
15
|
-
*
|
|
16
|
-
* Pro Voices: `11labs`, `playht`, `openai`
|
|
17
|
-
*
|
|
18
|
-
* Basic Voices: `rime-ai`, `deepgram`
|
|
19
|
-
*/
|
|
13
|
+
/** This is the voice provider that will be used. */
|
|
20
14
|
provider: "deepgram";
|
|
21
15
|
/** This is the provider-specific ID that will be used. */
|
|
22
|
-
voiceId: "
|
|
16
|
+
voiceId: "asteria" | "luna" | "hera" | "athena" | "varun" | "leo" | "perseus" | "helios" | "angus" | string;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export interface OpenAIMessage {
|
|
20
|
+
content: string | null;
|
|
21
|
+
role: object;
|
|
22
|
+
function_call?: object;
|
|
23
|
+
tool_calls?: object[];
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export interface JsonSchema {
|
|
27
|
+
type: "string" | "number" | "integer" | "boolean" | "array" | "object";
|
|
28
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
29
|
+
items?: object;
|
|
30
|
+
/** This is an array of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
31
|
+
prefixItems?: object;
|
|
32
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
33
|
+
contains?: object;
|
|
34
|
+
/** This is a map of string to JsonSchema. However, Swagger doesn't support circular references. */
|
|
35
|
+
properties?: object;
|
|
36
|
+
/** This is a map of string to JsonSchema objects. However, Swagger doesn't support circular references. */
|
|
37
|
+
patternProperties?: object;
|
|
38
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
39
|
+
additionalProperties?: object;
|
|
40
|
+
/** This is a map of string to JsonSchema objects. However, Swagger doesn't support circular references. */
|
|
41
|
+
dependentSchemas?: object;
|
|
42
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
43
|
+
propertyNames?: object;
|
|
44
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
45
|
+
unevaluatedProperties?: object;
|
|
46
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
47
|
+
const?: object;
|
|
48
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
49
|
+
not?: object;
|
|
50
|
+
/** This is an array of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
51
|
+
oneOf?: object;
|
|
52
|
+
/** This is an array of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
53
|
+
anyOf?: object;
|
|
54
|
+
/** This is an array of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
55
|
+
allOf?: object;
|
|
56
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
57
|
+
if?: object;
|
|
58
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
59
|
+
then?: object;
|
|
60
|
+
/** This is of type JsonSchema. However, Swagger doesn't support circular references. */
|
|
61
|
+
else?: object;
|
|
62
|
+
title?: string;
|
|
63
|
+
description?: string;
|
|
64
|
+
multipleOf?: number;
|
|
65
|
+
maximum?: number;
|
|
66
|
+
exclusiveMaximum?: number;
|
|
67
|
+
minimum?: number;
|
|
68
|
+
exclusiveMinimum?: number;
|
|
69
|
+
maxLength?: number;
|
|
70
|
+
/** @min 0 */
|
|
71
|
+
minLength?: number;
|
|
72
|
+
pattern?: string;
|
|
73
|
+
format?: string;
|
|
74
|
+
maxItems?: number;
|
|
75
|
+
/** @min 0 */
|
|
76
|
+
minItems?: number;
|
|
77
|
+
minContains?: number;
|
|
78
|
+
maxContains?: number;
|
|
79
|
+
maxProperties?: number;
|
|
80
|
+
/** @min 0 */
|
|
81
|
+
minProperties?: number;
|
|
82
|
+
required?: object[];
|
|
83
|
+
dependentRequired?: object;
|
|
84
|
+
enum?: object[];
|
|
85
|
+
$id?: string;
|
|
86
|
+
$ref?: string;
|
|
87
|
+
$schema?: string;
|
|
88
|
+
$comment?: string;
|
|
89
|
+
default?: object;
|
|
90
|
+
examples?: object[];
|
|
91
|
+
readOnly?: boolean;
|
|
92
|
+
writeOnly?: boolean;
|
|
93
|
+
contentEncoding?: string;
|
|
94
|
+
contentMediaType?: string;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
export interface OpenAIFunctionParameters {
|
|
98
|
+
/** This must be set to 'object'. It instructs the model to return a JSON object containing the function call properties. */
|
|
99
|
+
type: "object";
|
|
100
|
+
/**
|
|
101
|
+
* This provides a description of the properties required by the function.
|
|
102
|
+
* JSON Schema can be used to specify expectations for each property.
|
|
103
|
+
* Refer to [this doc](https://ajv.js.org/json-schema.html#json-data-type) for a comprehensive guide on JSON Schema.
|
|
104
|
+
*/
|
|
105
|
+
properties: Record<string, JsonSchema>;
|
|
106
|
+
/** This specifies the properties that are required by the function. */
|
|
107
|
+
required?: string[];
|
|
23
108
|
}
|
|
24
109
|
|
|
25
110
|
export interface OpenAIFunction {
|
|
@@ -28,6 +113,7 @@ export interface OpenAIFunction {
|
|
|
28
113
|
*
|
|
29
114
|
* Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
|
|
30
115
|
* @maxLength 64
|
|
116
|
+
* @pattern /^[a-zA-Z0-9_-]{1,64}$/
|
|
31
117
|
*/
|
|
32
118
|
name: string;
|
|
33
119
|
/** Setting async: true will cause the function to be called asynchronously, meaning that the Assistant will not wait for the function to return before continuing. */
|
|
@@ -37,110 +123,168 @@ export interface OpenAIFunction {
|
|
|
37
123
|
/**
|
|
38
124
|
* These are the parameters the functions accepts, described as a JSON Schema object.
|
|
39
125
|
*
|
|
40
|
-
* See the [OpenAI guide](https://platform.openai.com/docs/guides/
|
|
126
|
+
* See the [OpenAI guide](https://platform.openai.com/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema) for documentation about the format.
|
|
41
127
|
*
|
|
42
|
-
*
|
|
128
|
+
* Omitting parameters defines a function with an empty parameter list.
|
|
43
129
|
*/
|
|
44
|
-
parameters
|
|
130
|
+
parameters?: OpenAIFunctionParameters;
|
|
45
131
|
}
|
|
46
132
|
|
|
47
133
|
export interface TogetherAIModel {
|
|
134
|
+
/** This is the starting state for the conversation. */
|
|
135
|
+
messages?: OpenAIMessage[];
|
|
48
136
|
provider: "together-ai";
|
|
49
137
|
/** The key of the model from the custom provider. Ex. cognitivecomputations/dolphin-mixtral-8x7b */
|
|
50
138
|
model: string;
|
|
51
|
-
/** This sets the objective and understanding for the assistant. */
|
|
52
|
-
systemPrompt?: string;
|
|
53
139
|
/**
|
|
54
|
-
* This is the temperature that will be used for calls. Default is
|
|
140
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
55
141
|
* @min 0
|
|
56
142
|
* @max 2
|
|
57
143
|
*/
|
|
58
144
|
temperature?: number;
|
|
59
145
|
/** These are the functions that the assistant can execute during the call. */
|
|
60
146
|
functions?: OpenAIFunction[];
|
|
147
|
+
/**
|
|
148
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
149
|
+
* @min 50
|
|
150
|
+
* @max 1000
|
|
151
|
+
*/
|
|
152
|
+
maxTokens?: number;
|
|
61
153
|
}
|
|
62
154
|
|
|
63
155
|
export interface AnyscaleModel {
|
|
156
|
+
/** This is the starting state for the conversation. */
|
|
157
|
+
messages?: OpenAIMessage[];
|
|
64
158
|
provider: "anyscale";
|
|
65
159
|
/** The key of the model from the custom provider. Ex. cognitivecomputations/dolphin-mixtral-8x7b */
|
|
66
160
|
model: string;
|
|
67
|
-
/** This sets the objective and understanding for the assistant. */
|
|
68
|
-
systemPrompt?: string;
|
|
69
161
|
/**
|
|
70
|
-
* This is the temperature that will be used for calls. Default is
|
|
162
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
71
163
|
* @min 0
|
|
72
164
|
* @max 2
|
|
73
165
|
*/
|
|
74
166
|
temperature?: number;
|
|
75
167
|
/** These are the functions that the assistant can execute during the call. */
|
|
76
168
|
functions?: OpenAIFunction[];
|
|
169
|
+
/**
|
|
170
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
171
|
+
* @min 50
|
|
172
|
+
* @max 1000
|
|
173
|
+
*/
|
|
174
|
+
maxTokens?: number;
|
|
77
175
|
}
|
|
78
176
|
|
|
79
177
|
export interface OpenRouterModel {
|
|
178
|
+
/** This is the starting state for the conversation. */
|
|
179
|
+
messages?: OpenAIMessage[];
|
|
80
180
|
provider: "openrouter";
|
|
81
181
|
/** The key of the model from the custom provider. Ex. cognitivecomputations/dolphin-mixtral-8x7b */
|
|
82
182
|
model: string;
|
|
83
|
-
/** This sets the objective and understanding for the assistant. */
|
|
84
|
-
systemPrompt?: string;
|
|
85
183
|
/**
|
|
86
|
-
* This is the temperature that will be used for calls. Default is
|
|
184
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
87
185
|
* @min 0
|
|
88
186
|
* @max 2
|
|
89
187
|
*/
|
|
90
188
|
temperature?: number;
|
|
91
189
|
/** These are the functions that the assistant can execute during the call. */
|
|
92
190
|
functions?: OpenAIFunction[];
|
|
191
|
+
/**
|
|
192
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
193
|
+
* @min 50
|
|
194
|
+
* @max 1000
|
|
195
|
+
*/
|
|
196
|
+
maxTokens?: number;
|
|
93
197
|
}
|
|
94
198
|
|
|
95
199
|
export interface PerplexityAIModel {
|
|
200
|
+
/** This is the starting state for the conversation. */
|
|
201
|
+
messages?: OpenAIMessage[];
|
|
96
202
|
provider: "perplexity-ai";
|
|
97
203
|
/** The key of the model from the custom provider. Ex. cognitivecomputations/dolphin-mixtral-8x7b */
|
|
98
204
|
model: string;
|
|
99
|
-
/** This sets the objective and understanding for the assistant. */
|
|
100
|
-
systemPrompt?: string;
|
|
101
205
|
/**
|
|
102
|
-
* This is the temperature that will be used for calls. Default is
|
|
206
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
103
207
|
* @min 0
|
|
104
208
|
* @max 2
|
|
105
209
|
*/
|
|
106
210
|
temperature?: number;
|
|
107
211
|
/** These are the functions that the assistant can execute during the call. */
|
|
108
212
|
functions?: OpenAIFunction[];
|
|
213
|
+
/**
|
|
214
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
215
|
+
* @min 50
|
|
216
|
+
* @max 1000
|
|
217
|
+
*/
|
|
218
|
+
maxTokens?: number;
|
|
109
219
|
}
|
|
110
220
|
|
|
111
221
|
export interface DeepInfraModel {
|
|
222
|
+
/** This is the starting state for the conversation. */
|
|
223
|
+
messages?: OpenAIMessage[];
|
|
112
224
|
provider: "deepinfra";
|
|
113
225
|
/** The key of the model from the custom provider. Ex. cognitivecomputations/dolphin-mixtral-8x7b */
|
|
114
226
|
model: string;
|
|
115
|
-
/** This sets the objective and understanding for the assistant. */
|
|
116
|
-
systemPrompt?: string;
|
|
117
227
|
/**
|
|
118
|
-
* This is the temperature that will be used for calls. Default is
|
|
228
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
119
229
|
* @min 0
|
|
120
230
|
* @max 2
|
|
121
231
|
*/
|
|
122
232
|
temperature?: number;
|
|
123
233
|
/** These are the functions that the assistant can execute during the call. */
|
|
124
234
|
functions?: OpenAIFunction[];
|
|
235
|
+
/**
|
|
236
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
237
|
+
* @min 50
|
|
238
|
+
* @max 1000
|
|
239
|
+
*/
|
|
240
|
+
maxTokens?: number;
|
|
125
241
|
}
|
|
126
242
|
|
|
127
243
|
export interface CustomLLMModel {
|
|
244
|
+
/** This is the starting state for the conversation. */
|
|
245
|
+
messages?: OpenAIMessage[];
|
|
128
246
|
/** This is the provider that will be used for the model. Any service, including your own server, that is compatible with the OpenAI API can be used. */
|
|
129
247
|
provider: "custom-llm";
|
|
130
248
|
/** These is the URL we'll use for the OpenAI client's `baseURL`. Ex. https://openrouter.ai/api/v1 */
|
|
131
249
|
url: string;
|
|
132
250
|
/** The key of the model from the custom provider. Ex. cognitivecomputations/dolphin-mixtral-8x7b */
|
|
133
251
|
model: string;
|
|
134
|
-
/** This sets the objective and understanding for the assistant. */
|
|
135
|
-
systemPrompt?: string;
|
|
136
252
|
/**
|
|
137
|
-
* This is the temperature that will be used for calls. Default is
|
|
253
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
254
|
+
* @min 0
|
|
255
|
+
* @max 2
|
|
256
|
+
*/
|
|
257
|
+
temperature?: number;
|
|
258
|
+
/** These are the functions that the assistant can execute during the call. */
|
|
259
|
+
functions?: OpenAIFunction[];
|
|
260
|
+
/**
|
|
261
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
262
|
+
* @min 50
|
|
263
|
+
* @max 1000
|
|
264
|
+
*/
|
|
265
|
+
maxTokens?: number;
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
export interface GroqModel {
|
|
269
|
+
/** This is the starting state for the conversation. */
|
|
270
|
+
messages?: OpenAIMessage[];
|
|
271
|
+
/** The key of the model from the custom provider. Ex. cognitivecomputations/dolphin-mixtral-8x7b */
|
|
272
|
+
model: "mixtral-8x7b-32768";
|
|
273
|
+
provider: "groq";
|
|
274
|
+
/**
|
|
275
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
138
276
|
* @min 0
|
|
139
277
|
* @max 2
|
|
140
278
|
*/
|
|
141
279
|
temperature?: number;
|
|
142
280
|
/** These are the functions that the assistant can execute during the call. */
|
|
143
281
|
functions?: OpenAIFunction[];
|
|
282
|
+
/**
|
|
283
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
284
|
+
* @min 50
|
|
285
|
+
* @max 1000
|
|
286
|
+
*/
|
|
287
|
+
maxTokens?: number;
|
|
144
288
|
}
|
|
145
289
|
|
|
146
290
|
export interface DeepgramTranscriber {
|
|
@@ -166,18 +310,14 @@ export interface DeepgramTranscriber {
|
|
|
166
310
|
}
|
|
167
311
|
|
|
168
312
|
export interface ElevenLabsVoice {
|
|
169
|
-
/**
|
|
170
|
-
* This is the voice provider that will be used.
|
|
171
|
-
*
|
|
172
|
-
* Pro Voices: `11labs`, `playht`
|
|
173
|
-
*
|
|
174
|
-
* Basic Voices: `rime-ai`, `deepgram`
|
|
175
|
-
*/
|
|
313
|
+
/** This is the voice provider that will be used. */
|
|
176
314
|
provider: "11labs";
|
|
177
315
|
/** This is the provider-specific ID that will be used. Ensure the Voice is present in your 11Labs Voice Library. */
|
|
178
316
|
voiceId:
|
|
179
317
|
| "burt"
|
|
318
|
+
| "marissa"
|
|
180
319
|
| "andrea"
|
|
320
|
+
| "sarah"
|
|
181
321
|
| "phillip"
|
|
182
322
|
| "steve"
|
|
183
323
|
| "joseph"
|
|
@@ -194,53 +334,62 @@ export interface ElevenLabsVoice {
|
|
|
194
334
|
* Defines the stability for voice settings.
|
|
195
335
|
* @min 0
|
|
196
336
|
* @max 1
|
|
197
|
-
* @
|
|
337
|
+
* @example 0.5
|
|
198
338
|
*/
|
|
199
339
|
stability?: number;
|
|
200
340
|
/**
|
|
201
341
|
* Defines the similarity boost for voice settings.
|
|
202
342
|
* @min 0
|
|
203
343
|
* @max 1
|
|
204
|
-
* @
|
|
344
|
+
* @example 0.75
|
|
205
345
|
*/
|
|
206
346
|
similarityBoost?: number;
|
|
207
347
|
/**
|
|
208
348
|
* Defines the style for voice settings.
|
|
209
|
-
* @
|
|
349
|
+
* @min 0
|
|
350
|
+
* @max 1
|
|
351
|
+
* @example 0
|
|
210
352
|
*/
|
|
211
|
-
style?:
|
|
353
|
+
style?: number;
|
|
212
354
|
/**
|
|
213
355
|
* Defines the use speaker boost for voice settings.
|
|
214
|
-
* @
|
|
356
|
+
* @example false
|
|
215
357
|
*/
|
|
216
358
|
useSpeakerBoost?: boolean;
|
|
359
|
+
/**
|
|
360
|
+
* Defines the optimize streaming latency for voice settings.
|
|
361
|
+
* @min 1
|
|
362
|
+
* @max 4
|
|
363
|
+
* @example 4
|
|
364
|
+
*/
|
|
365
|
+
optimizeStreamingLatency?: number;
|
|
217
366
|
}
|
|
218
367
|
|
|
219
368
|
export interface OpenAIModel {
|
|
369
|
+
/** This is the starting state for the conversation. */
|
|
370
|
+
messages?: OpenAIMessage[];
|
|
220
371
|
/** This is the provider that will be used for the model. */
|
|
221
372
|
provider: "openai";
|
|
222
373
|
/** This is the OpenAI model that will be used. */
|
|
223
374
|
model: "gpt-4" | "gpt-3.5-turbo";
|
|
224
|
-
/** This sets the objective and understanding for the assistant. */
|
|
225
|
-
systemPrompt?: string;
|
|
226
375
|
/**
|
|
227
|
-
* This is the temperature that will be used for calls. Default is
|
|
376
|
+
* This is the temperature that will be used for calls. Default is 0 to leverage caching for lower latency.
|
|
228
377
|
* @min 0
|
|
229
378
|
* @max 2
|
|
230
379
|
*/
|
|
231
380
|
temperature?: number;
|
|
232
381
|
/** These are the functions that the assistant can execute during the call. */
|
|
233
382
|
functions?: OpenAIFunction[];
|
|
383
|
+
/**
|
|
384
|
+
* This is the max number of tokens that the assistant will be allowed to generate in each turn of the conversation. Default is 250.
|
|
385
|
+
* @min 50
|
|
386
|
+
* @max 1000
|
|
387
|
+
*/
|
|
388
|
+
maxTokens?: number;
|
|
234
389
|
}
|
|
235
390
|
|
|
236
391
|
export interface PlayHTVoice {
|
|
237
|
-
/**
|
|
238
|
-
* This is the voice provider that will be used.
|
|
239
|
-
*
|
|
240
|
-
* Pro Voices: `11labs`, `playht`, `openai`
|
|
241
|
-
*
|
|
242
|
-
* Basic Voices: `rime-ai`, `deepgram`
|
|
243
|
-
*/
|
|
392
|
+
/** This is the voice provider that will be used. */
|
|
244
393
|
provider: "playht";
|
|
245
394
|
/** This is the provider-specific ID that will be used. */
|
|
246
395
|
voiceId:
|
|
@@ -259,52 +408,46 @@ export interface PlayHTVoice {
|
|
|
259
408
|
* This is the speed multiplier that will be used.
|
|
260
409
|
* @min 0
|
|
261
410
|
* @max 5
|
|
262
|
-
* @
|
|
411
|
+
* @example null
|
|
263
412
|
*/
|
|
264
413
|
speed?: number;
|
|
265
414
|
/**
|
|
266
|
-
* A floating point number between 0,
|
|
415
|
+
* A floating point number between 0, exclusive, and 2, inclusive. If equal to null or not provided, the model's default temperature will be used. The temperature parameter controls variance. Lower temperatures result in more predictable results, higher temperatures allow each run to vary more, so the voice may sound less like the baseline voice.
|
|
267
416
|
* @min 0.1
|
|
268
417
|
* @max 2
|
|
269
|
-
* @
|
|
418
|
+
* @example null
|
|
270
419
|
*/
|
|
271
420
|
temperature?: number;
|
|
272
421
|
/**
|
|
273
422
|
* An emotion to be applied to the speech.
|
|
274
|
-
* @
|
|
423
|
+
* @example null
|
|
275
424
|
*/
|
|
276
425
|
emotion?: "female_happy" | "female_sad" | "female_angry" | "female_fearful" | "female_disgust" | "female_surprised";
|
|
277
426
|
/**
|
|
278
427
|
* A number between 1 and 6. Use lower numbers to reduce how unique your chosen voice will be compared to other voices.
|
|
279
428
|
* @min 1
|
|
280
429
|
* @max 6
|
|
281
|
-
* @
|
|
430
|
+
* @example null
|
|
282
431
|
*/
|
|
283
432
|
voiceGuidance?: number;
|
|
284
433
|
/**
|
|
285
434
|
* A number between 1 and 30. Use lower numbers to to reduce how strong your chosen emotion will be. Higher numbers will create a very emotional performance.
|
|
286
435
|
* @min 1
|
|
287
436
|
* @max 30
|
|
288
|
-
* @
|
|
437
|
+
* @example null
|
|
289
438
|
*/
|
|
290
439
|
styleGuidance?: number;
|
|
291
440
|
/**
|
|
292
441
|
* A number between 1 and 2. This number influences how closely the generated speech adheres to the input text. Use lower values to create more fluid speech, but with a higher chance of deviating from the input text. Higher numbers will make the generated speech more accurate to the input text, ensuring that the words spoken align closely with the provided text.
|
|
293
442
|
* @min 1
|
|
294
443
|
* @max 2
|
|
295
|
-
* @
|
|
444
|
+
* @example null
|
|
296
445
|
*/
|
|
297
446
|
textGuidance?: number;
|
|
298
447
|
}
|
|
299
448
|
|
|
300
449
|
export interface RimeAIVoice {
|
|
301
|
-
/**
|
|
302
|
-
* This is the voice provider that will be used.
|
|
303
|
-
*
|
|
304
|
-
* Pro Voices: `11labs`, `playht`, `openai`
|
|
305
|
-
*
|
|
306
|
-
* Basic Voices: `rime-ai`, `deepgram`
|
|
307
|
-
*/
|
|
450
|
+
/** This is the voice provider that will be used. */
|
|
308
451
|
provider: "rime-ai";
|
|
309
452
|
/** This is the provider-specific ID that will be used. */
|
|
310
453
|
voiceId:
|
|
@@ -322,19 +465,13 @@ export interface RimeAIVoice {
|
|
|
322
465
|
/**
|
|
323
466
|
* This is the speed multiplier that will be used.
|
|
324
467
|
* @min 0
|
|
325
|
-
* @
|
|
468
|
+
* @example null
|
|
326
469
|
*/
|
|
327
470
|
speed?: number;
|
|
328
471
|
}
|
|
329
472
|
|
|
330
473
|
export interface OpenAIVoice {
|
|
331
|
-
/**
|
|
332
|
-
* This is the voice provider that will be used.
|
|
333
|
-
*
|
|
334
|
-
* Pro Voices: `11labs`, `playht`, `openai`
|
|
335
|
-
*
|
|
336
|
-
* Basic Voices: `rime-ai`, `deepgram`
|
|
337
|
-
*/
|
|
474
|
+
/** This is the voice provider that will be used. */
|
|
338
475
|
provider: "openai";
|
|
339
476
|
/** This is the provider-specific ID that will be used. */
|
|
340
477
|
voiceId: "alloy" | "echo" | "fable" | "onyx" | "nova" | "shimmer" | string;
|
|
@@ -342,23 +479,19 @@ export interface OpenAIVoice {
|
|
|
342
479
|
* This is the speed multiplier that will be used.
|
|
343
480
|
* @min 0.25
|
|
344
481
|
* @max 4
|
|
345
|
-
* @
|
|
482
|
+
* @example null
|
|
346
483
|
*/
|
|
347
484
|
speed?: number;
|
|
348
485
|
}
|
|
349
486
|
|
|
487
|
+
export interface AzureVoice {
|
|
488
|
+
/** This is the voice provider that will be used. */
|
|
489
|
+
provider: "azure";
|
|
490
|
+
/** This is the provider-specific ID that will be used. */
|
|
491
|
+
voiceId: "andrew" | "brian" | "emma" | string;
|
|
492
|
+
}
|
|
493
|
+
|
|
350
494
|
export interface CreateAssistantDTO {
|
|
351
|
-
/**
|
|
352
|
-
* This is the name of the assistant. This is just for your own reference.
|
|
353
|
-
* @maxLength 100
|
|
354
|
-
* @default null
|
|
355
|
-
*/
|
|
356
|
-
name?: string;
|
|
357
|
-
/**
|
|
358
|
-
* These are the options for the assistant's transcriber.
|
|
359
|
-
* @default null
|
|
360
|
-
*/
|
|
361
|
-
transcriber?: DeepgramTranscriber;
|
|
362
495
|
/** These are the options for the assistant's LLM. */
|
|
363
496
|
model?:
|
|
364
497
|
| OpenAIModel
|
|
@@ -367,16 +500,16 @@ export interface CreateAssistantDTO {
|
|
|
367
500
|
| OpenRouterModel
|
|
368
501
|
| PerplexityAIModel
|
|
369
502
|
| DeepInfraModel
|
|
503
|
+
| GroqModel
|
|
370
504
|
| CustomLLMModel;
|
|
371
505
|
/**
|
|
372
506
|
* These are the options for the assistant's voice.
|
|
373
507
|
* @default {"provider":"playht","voiceId":"jennifer"}
|
|
374
508
|
*/
|
|
375
|
-
voice?: ElevenLabsVoice | PlayHTVoice | RimeAIVoice | DeepgramVoice | OpenAIVoice;
|
|
509
|
+
voice?: AzureVoice | ElevenLabsVoice | PlayHTVoice | RimeAIVoice | DeepgramVoice | OpenAIVoice;
|
|
376
510
|
/**
|
|
377
511
|
* This sets the spoken language of the user. The assistant will do its best to respond in the same language.
|
|
378
512
|
* When using a language other than `en-*`, only `11labs` voices will pronounce the words correctly. There will also be ~1sec of additional latency.
|
|
379
|
-
* @default null
|
|
380
513
|
*/
|
|
381
514
|
language?:
|
|
382
515
|
| "en"
|
|
@@ -394,84 +527,115 @@ export interface CreateAssistantDTO {
|
|
|
394
527
|
| "pt-BR"
|
|
395
528
|
| "es"
|
|
396
529
|
| "es-419";
|
|
397
|
-
/** This is the number to forward to if assistant runs into issues. */
|
|
398
|
-
forwardingPhoneNumber?: string;
|
|
399
530
|
/**
|
|
400
|
-
* This is the
|
|
401
|
-
*
|
|
402
|
-
* If unspecified, it will wait for the user to speak.
|
|
403
|
-
* @maxLength 1000
|
|
404
|
-
* @default "Hey there!"
|
|
531
|
+
* This is the number to forward to if assistant runs into issues.
|
|
532
|
+
* @example null
|
|
405
533
|
*/
|
|
406
|
-
|
|
534
|
+
forwardingPhoneNumber?: string;
|
|
407
535
|
/**
|
|
408
|
-
* This
|
|
409
|
-
*
|
|
410
|
-
* If unspecified, it will hang up.
|
|
411
|
-
* @maxLength 1000
|
|
412
|
-
* @default null
|
|
536
|
+
* This sets whether the assistant's calls are recorded. Defaults to true.
|
|
537
|
+
* @example true
|
|
413
538
|
*/
|
|
414
|
-
|
|
539
|
+
recordingEnabled?: boolean;
|
|
415
540
|
/**
|
|
416
|
-
* This
|
|
417
|
-
*
|
|
418
|
-
* If unspecified, it will hang up without saying anything.
|
|
419
|
-
* @maxLength 400
|
|
420
|
-
* @default null
|
|
541
|
+
* This sets whether the assistant will be able to hang up the call. Defaults to false.
|
|
542
|
+
* @example false
|
|
421
543
|
*/
|
|
422
|
-
|
|
544
|
+
endCallFunctionEnabled?: boolean;
|
|
423
545
|
/**
|
|
424
|
-
* This sets whether the
|
|
546
|
+
* This sets whether the assistant can dial digits on the keypad. Defaults to false.
|
|
425
547
|
* @default null
|
|
426
548
|
*/
|
|
427
|
-
|
|
549
|
+
dialKeypadFunctionEnabled?: boolean;
|
|
428
550
|
/**
|
|
429
|
-
*
|
|
430
|
-
* @
|
|
551
|
+
* When this is enabled, no logs, recordings, or transcriptions will be stored. At the end of the call, you will still receive an end-of-call-report message to store on your server. Defaults to false.
|
|
552
|
+
* @example false
|
|
431
553
|
*/
|
|
432
|
-
|
|
554
|
+
hipaaEnabled?: boolean;
|
|
433
555
|
/**
|
|
434
|
-
*
|
|
435
|
-
* @
|
|
556
|
+
* These are the messages that will be sent to the Client SDKs. Default is ['transcript', 'hang', 'function-call', 'speech-update', 'metadata', 'conversation-update']
|
|
557
|
+
* @example ["transcript","hang","function-call","speech-update","metadata","conversation-update"]
|
|
436
558
|
*/
|
|
437
|
-
|
|
559
|
+
clientMessages?:
|
|
560
|
+
| "status-update"
|
|
561
|
+
| "speech-update"
|
|
562
|
+
| "transcript"
|
|
563
|
+
| "hang"
|
|
564
|
+
| "function-call"
|
|
565
|
+
| "metadata"
|
|
566
|
+
| "conversation-update";
|
|
438
567
|
/**
|
|
439
|
-
*
|
|
440
|
-
* @
|
|
568
|
+
* These are the messages that will be sent to your Server URL. Default is ['end-of-call-report', 'status-update', 'hang', 'function-call']
|
|
569
|
+
* @example ["end-of-call-report","status-update","hang","function-call"]
|
|
441
570
|
*/
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
571
|
+
serverMessages?:
|
|
572
|
+
| "status-update"
|
|
573
|
+
| "transcript"
|
|
574
|
+
| "hang"
|
|
575
|
+
| "function-call"
|
|
576
|
+
| "end-of-call-report"
|
|
577
|
+
| "conversation-update";
|
|
447
578
|
/**
|
|
448
579
|
* How many seconds of silence to wait before ending the call. Defaults to 30.
|
|
449
580
|
* @min 10
|
|
450
581
|
* @max 600
|
|
451
|
-
* @
|
|
582
|
+
* @example 30
|
|
452
583
|
*/
|
|
453
584
|
silenceTimeoutSeconds?: number;
|
|
454
585
|
/**
|
|
455
586
|
* The minimum number of seconds after user speech to wait before the assistant starts speaking. Defaults to 0.4.
|
|
456
587
|
* @min 0
|
|
457
|
-
* @max
|
|
458
|
-
* @
|
|
588
|
+
* @max 2
|
|
589
|
+
* @example 0.4
|
|
459
590
|
*/
|
|
460
591
|
responseDelaySeconds?: number;
|
|
461
|
-
}
|
|
462
|
-
|
|
463
|
-
export interface Assistant {
|
|
464
592
|
/**
|
|
465
593
|
* This is the name of the assistant. This is just for your own reference.
|
|
466
594
|
* @maxLength 100
|
|
467
|
-
* @default null
|
|
468
595
|
*/
|
|
469
596
|
name?: string;
|
|
597
|
+
/** These are the options for the assistant's transcriber. */
|
|
598
|
+
transcriber?: DeepgramTranscriber;
|
|
470
599
|
/**
|
|
471
|
-
*
|
|
472
|
-
*
|
|
600
|
+
* This is the first message that the assistant will say. This can also be a URL to a containerized audio file (mp3, wav, etc.).
|
|
601
|
+
*
|
|
602
|
+
* If unspecified, it will wait for the user to speak.
|
|
603
|
+
* @maxLength 1000
|
|
473
604
|
*/
|
|
474
|
-
|
|
605
|
+
firstMessage?: string;
|
|
606
|
+
/**
|
|
607
|
+
* This is the message that the assistant will say if the call is forwarded to voicemail.
|
|
608
|
+
*
|
|
609
|
+
* If unspecified, it will hang up.
|
|
610
|
+
* @maxLength 1000
|
|
611
|
+
*/
|
|
612
|
+
voicemailMessage?: string;
|
|
613
|
+
/**
|
|
614
|
+
* This is the message that the assistant will say if it ends the call.
|
|
615
|
+
*
|
|
616
|
+
* If unspecified, it will hang up without saying anything.
|
|
617
|
+
* @maxLength 400
|
|
618
|
+
*/
|
|
619
|
+
endCallMessage?: string;
|
|
620
|
+
/** This list contains phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. */
|
|
621
|
+
endCallPhrases?: string[];
|
|
622
|
+
/**
|
|
623
|
+
* This is the URL Vapi will communicate with via HTTP GET and POST Requests. This is used for retrieving context, function calling, and end-of-call reports.
|
|
624
|
+
*
|
|
625
|
+
* All requests will be sent with the call object among other things relevant to that message. You can find more details in the Server URL documentation.
|
|
626
|
+
*
|
|
627
|
+
* This overrides the serverUrl set on the org.
|
|
628
|
+
*/
|
|
629
|
+
serverUrl?: string;
|
|
630
|
+
/**
|
|
631
|
+
* This is the secret you can set that Vapi will send with every request to your server. Will be sent as a header called x-vapi-secret.
|
|
632
|
+
*
|
|
633
|
+
* This overrides the serverUrlSecret set on the org.
|
|
634
|
+
*/
|
|
635
|
+
serverUrlSecret?: string;
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
export interface Assistant {
|
|
475
639
|
/** These are the options for the assistant's LLM. */
|
|
476
640
|
model?:
|
|
477
641
|
| OpenAIModel
|
|
@@ -480,16 +644,16 @@ export interface Assistant {
|
|
|
480
644
|
| OpenRouterModel
|
|
481
645
|
| PerplexityAIModel
|
|
482
646
|
| DeepInfraModel
|
|
647
|
+
| GroqModel
|
|
483
648
|
| CustomLLMModel;
|
|
484
649
|
/**
|
|
485
650
|
* These are the options for the assistant's voice.
|
|
486
651
|
* @default {"provider":"playht","voiceId":"jennifer"}
|
|
487
652
|
*/
|
|
488
|
-
voice?: ElevenLabsVoice | PlayHTVoice | RimeAIVoice | DeepgramVoice | OpenAIVoice;
|
|
653
|
+
voice?: AzureVoice | ElevenLabsVoice | PlayHTVoice | RimeAIVoice | DeepgramVoice | OpenAIVoice;
|
|
489
654
|
/**
|
|
490
655
|
* This sets the spoken language of the user. The assistant will do its best to respond in the same language.
|
|
491
656
|
* When using a language other than `en-*`, only `11labs` voices will pronounce the words correctly. There will also be ~1sec of additional latency.
|
|
492
|
-
* @default null
|
|
493
657
|
*/
|
|
494
658
|
language?:
|
|
495
659
|
| "en"
|
|
@@ -507,70 +671,112 @@ export interface Assistant {
|
|
|
507
671
|
| "pt-BR"
|
|
508
672
|
| "es"
|
|
509
673
|
| "es-419";
|
|
510
|
-
/** This is the number to forward to if assistant runs into issues. */
|
|
511
|
-
forwardingPhoneNumber?: string;
|
|
512
674
|
/**
|
|
513
|
-
* This is the
|
|
514
|
-
*
|
|
515
|
-
* If unspecified, it will wait for the user to speak.
|
|
516
|
-
* @maxLength 1000
|
|
517
|
-
* @default "Hey there!"
|
|
675
|
+
* This is the number to forward to if assistant runs into issues.
|
|
676
|
+
* @example null
|
|
518
677
|
*/
|
|
519
|
-
|
|
678
|
+
forwardingPhoneNumber?: string;
|
|
520
679
|
/**
|
|
521
|
-
* This
|
|
522
|
-
*
|
|
523
|
-
* If unspecified, it will hang up.
|
|
524
|
-
* @maxLength 1000
|
|
525
|
-
* @default null
|
|
680
|
+
* This sets whether the assistant's calls are recorded. Defaults to true.
|
|
681
|
+
* @example true
|
|
526
682
|
*/
|
|
527
|
-
|
|
683
|
+
recordingEnabled?: boolean;
|
|
528
684
|
/**
|
|
529
|
-
* This
|
|
530
|
-
*
|
|
531
|
-
* If unspecified, it will hang up without saying anything.
|
|
532
|
-
* @maxLength 400
|
|
533
|
-
* @default null
|
|
685
|
+
* This sets whether the assistant will be able to hang up the call. Defaults to false.
|
|
686
|
+
* @example false
|
|
534
687
|
*/
|
|
535
|
-
|
|
688
|
+
endCallFunctionEnabled?: boolean;
|
|
536
689
|
/**
|
|
537
|
-
* This sets whether the
|
|
690
|
+
* This sets whether the assistant can dial digits on the keypad. Defaults to false.
|
|
538
691
|
* @default null
|
|
539
692
|
*/
|
|
540
|
-
|
|
693
|
+
dialKeypadFunctionEnabled?: boolean;
|
|
541
694
|
/**
|
|
542
|
-
*
|
|
543
|
-
* @
|
|
695
|
+
* When this is enabled, no logs, recordings, or transcriptions will be stored. At the end of the call, you will still receive an end-of-call-report message to store on your server. Defaults to false.
|
|
696
|
+
* @example false
|
|
544
697
|
*/
|
|
545
|
-
|
|
698
|
+
hipaaEnabled?: boolean;
|
|
546
699
|
/**
|
|
547
|
-
*
|
|
548
|
-
* @
|
|
700
|
+
* These are the messages that will be sent to the Client SDKs. Default is ['transcript', 'hang', 'function-call', 'speech-update', 'metadata', 'conversation-update']
|
|
701
|
+
* @example ["transcript","hang","function-call","speech-update","metadata","conversation-update"]
|
|
549
702
|
*/
|
|
550
|
-
|
|
703
|
+
clientMessages?:
|
|
704
|
+
| "status-update"
|
|
705
|
+
| "speech-update"
|
|
706
|
+
| "transcript"
|
|
707
|
+
| "hang"
|
|
708
|
+
| "function-call"
|
|
709
|
+
| "metadata"
|
|
710
|
+
| "conversation-update";
|
|
551
711
|
/**
|
|
552
|
-
*
|
|
553
|
-
* @
|
|
712
|
+
* These are the messages that will be sent to your Server URL. Default is ['end-of-call-report', 'status-update', 'hang', 'function-call']
|
|
713
|
+
* @example ["end-of-call-report","status-update","hang","function-call"]
|
|
554
714
|
*/
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
715
|
+
serverMessages?:
|
|
716
|
+
| "status-update"
|
|
717
|
+
| "transcript"
|
|
718
|
+
| "hang"
|
|
719
|
+
| "function-call"
|
|
720
|
+
| "end-of-call-report"
|
|
721
|
+
| "conversation-update";
|
|
560
722
|
/**
|
|
561
723
|
* How many seconds of silence to wait before ending the call. Defaults to 30.
|
|
562
724
|
* @min 10
|
|
563
725
|
* @max 600
|
|
564
|
-
* @
|
|
726
|
+
* @example 30
|
|
565
727
|
*/
|
|
566
728
|
silenceTimeoutSeconds?: number;
|
|
567
729
|
/**
|
|
568
730
|
* The minimum number of seconds after user speech to wait before the assistant starts speaking. Defaults to 0.4.
|
|
569
731
|
* @min 0
|
|
570
|
-
* @max
|
|
571
|
-
* @
|
|
732
|
+
* @max 2
|
|
733
|
+
* @example 0.4
|
|
572
734
|
*/
|
|
573
735
|
responseDelaySeconds?: number;
|
|
736
|
+
/**
|
|
737
|
+
* This is the name of the assistant. This is just for your own reference.
|
|
738
|
+
* @maxLength 100
|
|
739
|
+
*/
|
|
740
|
+
name?: string;
|
|
741
|
+
/** These are the options for the assistant's transcriber. */
|
|
742
|
+
transcriber?: DeepgramTranscriber;
|
|
743
|
+
/**
|
|
744
|
+
* This is the first message that the assistant will say. This can also be a URL to a containerized audio file (mp3, wav, etc.).
|
|
745
|
+
*
|
|
746
|
+
* If unspecified, it will wait for the user to speak.
|
|
747
|
+
* @maxLength 1000
|
|
748
|
+
*/
|
|
749
|
+
firstMessage?: string;
|
|
750
|
+
/**
|
|
751
|
+
* This is the message that the assistant will say if the call is forwarded to voicemail.
|
|
752
|
+
*
|
|
753
|
+
* If unspecified, it will hang up.
|
|
754
|
+
* @maxLength 1000
|
|
755
|
+
*/
|
|
756
|
+
voicemailMessage?: string;
|
|
757
|
+
/**
|
|
758
|
+
* This is the message that the assistant will say if it ends the call.
|
|
759
|
+
*
|
|
760
|
+
* If unspecified, it will hang up without saying anything.
|
|
761
|
+
* @maxLength 400
|
|
762
|
+
*/
|
|
763
|
+
endCallMessage?: string;
|
|
764
|
+
/** This list contains phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. */
|
|
765
|
+
endCallPhrases?: string[];
|
|
766
|
+
/**
|
|
767
|
+
* This is the URL Vapi will communicate with via HTTP GET and POST Requests. This is used for retrieving context, function calling, and end-of-call reports.
|
|
768
|
+
*
|
|
769
|
+
* All requests will be sent with the call object among other things relevant to that message. You can find more details in the Server URL documentation.
|
|
770
|
+
*
|
|
771
|
+
* This overrides the serverUrl set on the org.
|
|
772
|
+
*/
|
|
773
|
+
serverUrl?: string;
|
|
774
|
+
/**
|
|
775
|
+
* This is the secret you can set that Vapi will send with every request to your server. Will be sent as a header called x-vapi-secret.
|
|
776
|
+
*
|
|
777
|
+
* This overrides the serverUrlSecret set on the org.
|
|
778
|
+
*/
|
|
779
|
+
serverUrlSecret?: string;
|
|
574
780
|
/** This is the unique identifier for the assistant. */
|
|
575
781
|
id: string;
|
|
576
782
|
/** This is the unique identifier for the org that this assistant belongs to. */
|
|
@@ -588,17 +794,6 @@ export interface Assistant {
|
|
|
588
794
|
}
|
|
589
795
|
|
|
590
796
|
export interface UpdateAssistantDTO {
|
|
591
|
-
/**
|
|
592
|
-
* This is the name of the assistant. This is just for your own reference.
|
|
593
|
-
* @maxLength 100
|
|
594
|
-
* @default null
|
|
595
|
-
*/
|
|
596
|
-
name?: string;
|
|
597
|
-
/**
|
|
598
|
-
* These are the options for the assistant's transcriber.
|
|
599
|
-
* @default null
|
|
600
|
-
*/
|
|
601
|
-
transcriber?: DeepgramTranscriber;
|
|
602
797
|
/** These are the options for the assistant's LLM. */
|
|
603
798
|
model?:
|
|
604
799
|
| OpenAIModel
|
|
@@ -607,16 +802,16 @@ export interface UpdateAssistantDTO {
|
|
|
607
802
|
| OpenRouterModel
|
|
608
803
|
| PerplexityAIModel
|
|
609
804
|
| DeepInfraModel
|
|
805
|
+
| GroqModel
|
|
610
806
|
| CustomLLMModel;
|
|
611
807
|
/**
|
|
612
808
|
* These are the options for the assistant's voice.
|
|
613
809
|
* @default {"provider":"playht","voiceId":"jennifer"}
|
|
614
810
|
*/
|
|
615
|
-
voice?: ElevenLabsVoice | PlayHTVoice | RimeAIVoice | DeepgramVoice | OpenAIVoice;
|
|
811
|
+
voice?: AzureVoice | ElevenLabsVoice | PlayHTVoice | RimeAIVoice | DeepgramVoice | OpenAIVoice;
|
|
616
812
|
/**
|
|
617
813
|
* This sets the spoken language of the user. The assistant will do its best to respond in the same language.
|
|
618
814
|
* When using a language other than `en-*`, only `11labs` voices will pronounce the words correctly. There will also be ~1sec of additional latency.
|
|
619
|
-
* @default null
|
|
620
815
|
*/
|
|
621
816
|
language?:
|
|
622
817
|
| "en"
|
|
@@ -634,70 +829,112 @@ export interface UpdateAssistantDTO {
|
|
|
634
829
|
| "pt-BR"
|
|
635
830
|
| "es"
|
|
636
831
|
| "es-419";
|
|
637
|
-
/** This is the number to forward to if assistant runs into issues. */
|
|
638
|
-
forwardingPhoneNumber?: string;
|
|
639
832
|
/**
|
|
640
|
-
* This is the
|
|
641
|
-
*
|
|
642
|
-
* If unspecified, it will wait for the user to speak.
|
|
643
|
-
* @maxLength 1000
|
|
644
|
-
* @default "Hey there!"
|
|
833
|
+
* This is the number to forward to if assistant runs into issues.
|
|
834
|
+
* @example null
|
|
645
835
|
*/
|
|
646
|
-
|
|
836
|
+
forwardingPhoneNumber?: string;
|
|
647
837
|
/**
|
|
648
|
-
* This
|
|
649
|
-
*
|
|
650
|
-
* If unspecified, it will hang up.
|
|
651
|
-
* @maxLength 1000
|
|
652
|
-
* @default null
|
|
838
|
+
* This sets whether the assistant's calls are recorded. Defaults to true.
|
|
839
|
+
* @example true
|
|
653
840
|
*/
|
|
654
|
-
|
|
841
|
+
recordingEnabled?: boolean;
|
|
655
842
|
/**
|
|
656
|
-
* This
|
|
657
|
-
*
|
|
658
|
-
* If unspecified, it will hang up without saying anything.
|
|
659
|
-
* @maxLength 400
|
|
660
|
-
* @default null
|
|
843
|
+
* This sets whether the assistant will be able to hang up the call. Defaults to false.
|
|
844
|
+
* @example false
|
|
661
845
|
*/
|
|
662
|
-
|
|
846
|
+
endCallFunctionEnabled?: boolean;
|
|
663
847
|
/**
|
|
664
|
-
* This sets whether the
|
|
848
|
+
* This sets whether the assistant can dial digits on the keypad. Defaults to false.
|
|
665
849
|
* @default null
|
|
666
850
|
*/
|
|
667
|
-
|
|
851
|
+
dialKeypadFunctionEnabled?: boolean;
|
|
668
852
|
/**
|
|
669
|
-
*
|
|
670
|
-
* @
|
|
853
|
+
* When this is enabled, no logs, recordings, or transcriptions will be stored. At the end of the call, you will still receive an end-of-call-report message to store on your server. Defaults to false.
|
|
854
|
+
* @example false
|
|
671
855
|
*/
|
|
672
|
-
|
|
856
|
+
hipaaEnabled?: boolean;
|
|
673
857
|
/**
|
|
674
|
-
*
|
|
675
|
-
* @
|
|
858
|
+
* These are the messages that will be sent to the Client SDKs. Default is ['transcript', 'hang', 'function-call', 'speech-update', 'metadata', 'conversation-update']
|
|
859
|
+
* @example ["transcript","hang","function-call","speech-update","metadata","conversation-update"]
|
|
676
860
|
*/
|
|
677
|
-
|
|
861
|
+
clientMessages?:
|
|
862
|
+
| "status-update"
|
|
863
|
+
| "speech-update"
|
|
864
|
+
| "transcript"
|
|
865
|
+
| "hang"
|
|
866
|
+
| "function-call"
|
|
867
|
+
| "metadata"
|
|
868
|
+
| "conversation-update";
|
|
678
869
|
/**
|
|
679
|
-
*
|
|
680
|
-
* @
|
|
870
|
+
* These are the messages that will be sent to your Server URL. Default is ['end-of-call-report', 'status-update', 'hang', 'function-call']
|
|
871
|
+
* @example ["end-of-call-report","status-update","hang","function-call"]
|
|
681
872
|
*/
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
873
|
+
serverMessages?:
|
|
874
|
+
| "status-update"
|
|
875
|
+
| "transcript"
|
|
876
|
+
| "hang"
|
|
877
|
+
| "function-call"
|
|
878
|
+
| "end-of-call-report"
|
|
879
|
+
| "conversation-update";
|
|
687
880
|
/**
|
|
688
881
|
* How many seconds of silence to wait before ending the call. Defaults to 30.
|
|
689
882
|
* @min 10
|
|
690
883
|
* @max 600
|
|
691
|
-
* @
|
|
884
|
+
* @example 30
|
|
692
885
|
*/
|
|
693
886
|
silenceTimeoutSeconds?: number;
|
|
694
887
|
/**
|
|
695
888
|
* The minimum number of seconds after user speech to wait before the assistant starts speaking. Defaults to 0.4.
|
|
696
889
|
* @min 0
|
|
697
|
-
* @max
|
|
698
|
-
* @
|
|
890
|
+
* @max 2
|
|
891
|
+
* @example 0.4
|
|
699
892
|
*/
|
|
700
893
|
responseDelaySeconds?: number;
|
|
894
|
+
/**
|
|
895
|
+
* This is the name of the assistant. This is just for your own reference.
|
|
896
|
+
* @maxLength 100
|
|
897
|
+
*/
|
|
898
|
+
name?: string;
|
|
899
|
+
/** These are the options for the assistant's transcriber. */
|
|
900
|
+
transcriber?: DeepgramTranscriber;
|
|
901
|
+
/**
|
|
902
|
+
* This is the first message that the assistant will say. This can also be a URL to a containerized audio file (mp3, wav, etc.).
|
|
903
|
+
*
|
|
904
|
+
* If unspecified, it will wait for the user to speak.
|
|
905
|
+
* @maxLength 1000
|
|
906
|
+
*/
|
|
907
|
+
firstMessage?: string;
|
|
908
|
+
/**
|
|
909
|
+
* This is the message that the assistant will say if the call is forwarded to voicemail.
|
|
910
|
+
*
|
|
911
|
+
* If unspecified, it will hang up.
|
|
912
|
+
* @maxLength 1000
|
|
913
|
+
*/
|
|
914
|
+
voicemailMessage?: string;
|
|
915
|
+
/**
|
|
916
|
+
* This is the message that the assistant will say if it ends the call.
|
|
917
|
+
*
|
|
918
|
+
* If unspecified, it will hang up without saying anything.
|
|
919
|
+
* @maxLength 400
|
|
920
|
+
*/
|
|
921
|
+
endCallMessage?: string;
|
|
922
|
+
/** This list contains phrases that, if spoken by the assistant, will trigger the call to be hung up. Case insensitive. */
|
|
923
|
+
endCallPhrases?: string[];
|
|
924
|
+
/**
|
|
925
|
+
* This is the URL Vapi will communicate with via HTTP GET and POST Requests. This is used for retrieving context, function calling, and end-of-call reports.
|
|
926
|
+
*
|
|
927
|
+
* All requests will be sent with the call object among other things relevant to that message. You can find more details in the Server URL documentation.
|
|
928
|
+
*
|
|
929
|
+
* This overrides the serverUrl set on the org.
|
|
930
|
+
*/
|
|
931
|
+
serverUrl?: string;
|
|
932
|
+
/**
|
|
933
|
+
* This is the secret you can set that Vapi will send with every request to your server. Will be sent as a header called x-vapi-secret.
|
|
934
|
+
*
|
|
935
|
+
* This overrides the serverUrlSecret set on the org.
|
|
936
|
+
*/
|
|
937
|
+
serverUrlSecret?: string;
|
|
701
938
|
}
|
|
702
939
|
|
|
703
940
|
export interface CreateCustomerDTO {
|
|
@@ -708,6 +945,11 @@ export interface CreateCustomerDTO {
|
|
|
708
945
|
* @maxLength 40
|
|
709
946
|
*/
|
|
710
947
|
name?: string;
|
|
948
|
+
/**
|
|
949
|
+
* This is the extension that will be dialed after the call is answered.
|
|
950
|
+
* @maxLength 30
|
|
951
|
+
*/
|
|
952
|
+
extension?: string;
|
|
711
953
|
}
|
|
712
954
|
|
|
713
955
|
export interface ImportTwilioPhoneNumberDTO {
|
|
@@ -737,43 +979,54 @@ export interface Call {
|
|
|
737
979
|
status?: "queued" | "ringing" | "in-progress" | "forwarding" | "ended";
|
|
738
980
|
/** This is the explanation for how the call ended. */
|
|
739
981
|
endedReason?:
|
|
740
|
-
| "assistant-ended-call"
|
|
741
982
|
| "assistant-error"
|
|
742
|
-
| "assistant-forwarded-call"
|
|
743
|
-
| "assistant-join-timed-out"
|
|
744
983
|
| "assistant-not-found"
|
|
745
|
-
| "customer-busy"
|
|
746
|
-
| "customer-ended-call"
|
|
747
|
-
| "customer-did-not-answer"
|
|
748
984
|
| "db-error"
|
|
749
|
-
| "exceeded-max-duration"
|
|
750
|
-
| "manually-canceled"
|
|
751
985
|
| "no-server-available"
|
|
752
|
-
| "pipeline-error-custom-llm-response-was-invalid"
|
|
753
|
-
| "pipeline-error-custom-llm-request-failed"
|
|
754
986
|
| "pipeline-error-extra-function-failed"
|
|
755
987
|
| "pipeline-error-first-message-failed"
|
|
756
988
|
| "pipeline-error-function-filler-failed"
|
|
757
989
|
| "pipeline-error-function-failed"
|
|
758
|
-
| "pipeline-error-llm-failed"
|
|
990
|
+
| "pipeline-error-openai-llm-failed"
|
|
991
|
+
| "pipeline-error-azure-openai-llm-failed"
|
|
992
|
+
| "pipeline-error-together-ai-llm-failed"
|
|
993
|
+
| "pipeline-error-anyscale-llm-failed"
|
|
994
|
+
| "pipeline-error-openrouter-llm-failed"
|
|
995
|
+
| "pipeline-error-perplexity-ai-llm-failed"
|
|
996
|
+
| "pipeline-error-deepinfra-llm-failed"
|
|
997
|
+
| "pipeline-error-runpod-llm-failed"
|
|
998
|
+
| "pipeline-error-groq-llm-failed"
|
|
759
999
|
| "pipeline-error-openai-voice-failed"
|
|
760
1000
|
| "pipeline-error-deepgram-transcriber-failed"
|
|
761
1001
|
| "pipeline-error-deepgram-voice-failed"
|
|
762
1002
|
| "pipeline-error-eleven-labs-voice-failed"
|
|
763
1003
|
| "pipeline-error-eleven-labs-voice-not-found"
|
|
1004
|
+
| "pipeline-error-eleven-labs-quota-exceeded"
|
|
764
1005
|
| "pipeline-error-playht-voice-failed"
|
|
1006
|
+
| "pipeline-error-azure-voice-failed"
|
|
765
1007
|
| "pipeline-error-rime-ai-voice-failed"
|
|
766
1008
|
| "server-shutdown"
|
|
767
|
-
| "silence-timed-out"
|
|
768
|
-
| "twilio-failed-to-connect-call"
|
|
769
1009
|
| "twilio-closed-websocket"
|
|
1010
|
+
| "twilio-failed-to-connect-call"
|
|
770
1011
|
| "unknown-error"
|
|
1012
|
+
| "assistant-ended-call"
|
|
1013
|
+
| "assistant-said-end-call-phrase"
|
|
1014
|
+
| "assistant-forwarded-call"
|
|
1015
|
+
| "assistant-join-timed-out"
|
|
1016
|
+
| "customer-busy"
|
|
1017
|
+
| "customer-ended-call"
|
|
1018
|
+
| "customer-did-not-answer"
|
|
1019
|
+
| "customer-did-not-give-microphone-permission"
|
|
1020
|
+
| "exceeded-max-duration"
|
|
1021
|
+
| "manually-canceled"
|
|
1022
|
+
| "pipeline-error-custom-llm-llm-failed"
|
|
1023
|
+
| "silence-timed-out"
|
|
771
1024
|
| "voicemail";
|
|
772
1025
|
/**
|
|
773
1026
|
* This is the maximum number of seconds that the call will last. When the call reaches this duration, it will be ended.
|
|
774
1027
|
* @min 10
|
|
775
1028
|
* @max 3600
|
|
776
|
-
* @
|
|
1029
|
+
* @example 1800
|
|
777
1030
|
*/
|
|
778
1031
|
maxDurationSeconds?: number;
|
|
779
1032
|
/** This is the unique identifier for the call. */
|
|
@@ -802,10 +1055,14 @@ export interface Call {
|
|
|
802
1055
|
endedAt?: string;
|
|
803
1056
|
/** This is the cost of the call in USD. */
|
|
804
1057
|
cost?: number;
|
|
1058
|
+
/** This is the cost of the call in USD. */
|
|
1059
|
+
costBreakdown?: object;
|
|
805
1060
|
/** This is the transcript of the call. */
|
|
806
1061
|
transcript?: string;
|
|
807
1062
|
/** This is the URL of the recording of the call. */
|
|
808
1063
|
recordingUrl?: string;
|
|
1064
|
+
/** This is the URL of the recording of the call in two channels. */
|
|
1065
|
+
stereoRecordingUrl?: string;
|
|
809
1066
|
/** This is the summary of the call. */
|
|
810
1067
|
summary?: string;
|
|
811
1068
|
/** These are the messages that were spoken during the call. */
|
|
@@ -850,6 +1107,8 @@ export interface Call {
|
|
|
850
1107
|
* Only relevant for `outboundPhoneCall` and `inboundPhoneCall` type.
|
|
851
1108
|
*/
|
|
852
1109
|
phoneNumber?: ImportTwilioPhoneNumberDTO;
|
|
1110
|
+
/** This is the metadata associated with the call. */
|
|
1111
|
+
metadata?: object;
|
|
853
1112
|
}
|
|
854
1113
|
|
|
855
1114
|
export interface CreateOutboundCallDTO {
|
|
@@ -857,7 +1116,7 @@ export interface CreateOutboundCallDTO {
|
|
|
857
1116
|
* This is the maximum number of seconds that the call will last. When the call reaches this duration, it will be ended.
|
|
858
1117
|
* @min 10
|
|
859
1118
|
* @max 3600
|
|
860
|
-
* @
|
|
1119
|
+
* @example 1800
|
|
861
1120
|
*/
|
|
862
1121
|
maxDurationSeconds?: number;
|
|
863
1122
|
/** This is the assistant that will be used for the call. To use a transient assistant, use `assistant` instead. */
|
|
@@ -888,6 +1147,8 @@ export interface CreateOutboundCallDTO {
|
|
|
888
1147
|
* Only relevant for `outboundPhoneCall` and `inboundPhoneCall` type.
|
|
889
1148
|
*/
|
|
890
1149
|
phoneNumber?: ImportTwilioPhoneNumberDTO;
|
|
1150
|
+
/** This is the metadata associated with the call. */
|
|
1151
|
+
metadata?: object;
|
|
891
1152
|
}
|
|
892
1153
|
|
|
893
1154
|
export interface CreateWebCallDTO {
|
|
@@ -895,6 +1156,8 @@ export interface CreateWebCallDTO {
|
|
|
895
1156
|
assistantId?: string;
|
|
896
1157
|
/** This is the assistant that will be used for the call. To use an existing assistant, use `assistantId` instead. */
|
|
897
1158
|
assistant?: CreateAssistantDTO;
|
|
1159
|
+
/** This is the metadata associated with the call. */
|
|
1160
|
+
metadata?: object;
|
|
898
1161
|
}
|
|
899
1162
|
|
|
900
1163
|
export interface TwilioCredential {
|
|
@@ -1404,6 +1667,23 @@ export interface UpdatePhoneNumberDTO {
|
|
|
1404
1667
|
assistantId?: string;
|
|
1405
1668
|
}
|
|
1406
1669
|
|
|
1670
|
+
export interface Metrics {
|
|
1671
|
+
orgId: string;
|
|
1672
|
+
rangeStart: string;
|
|
1673
|
+
rangeEnd: string;
|
|
1674
|
+
bill: number;
|
|
1675
|
+
billWithinBillingLimit: boolean;
|
|
1676
|
+
billDailyBreakdown: object;
|
|
1677
|
+
callActive: string;
|
|
1678
|
+
callActiveWithinConcurrencyLimit: boolean;
|
|
1679
|
+
callMinutes: string;
|
|
1680
|
+
callMinutesDailyBreakdown: object;
|
|
1681
|
+
callMinutesAverage: string;
|
|
1682
|
+
callMinutesAverageDailyBreakdown: object;
|
|
1683
|
+
callCount: string;
|
|
1684
|
+
callCountDailyBreakdown: object;
|
|
1685
|
+
}
|
|
1686
|
+
|
|
1407
1687
|
export type QueryParamsType = Record<string | number, any>;
|
|
1408
1688
|
export type ResponseFormat = keyof Omit<Body, "body" | "bodyUsed">;
|
|
1409
1689
|
|
|
@@ -1450,7 +1730,7 @@ export enum ContentType {
|
|
|
1450
1730
|
}
|
|
1451
1731
|
|
|
1452
1732
|
export class HttpClient<SecurityDataType = unknown> {
|
|
1453
|
-
public baseUrl: string = "https://api.vapi.ai";
|
|
1733
|
+
public baseUrl: string = "https://west-api.vapi.ai";
|
|
1454
1734
|
private securityData: SecurityDataType | null = null;
|
|
1455
1735
|
private securityWorker?: ApiConfig<SecurityDataType>["securityWorker"];
|
|
1456
1736
|
private abortControllers = new Map<CancelToken, AbortController>();
|
|
@@ -1617,7 +1897,7 @@ export class HttpClient<SecurityDataType = unknown> {
|
|
|
1617
1897
|
/**
|
|
1618
1898
|
* @title Vapi API
|
|
1619
1899
|
* @version 1.0
|
|
1620
|
-
* @baseUrl https://api.vapi.ai
|
|
1900
|
+
* @baseUrl https://west-api.vapi.ai
|
|
1621
1901
|
* @contact
|
|
1622
1902
|
*
|
|
1623
1903
|
* API for building voice assistants
|
|
@@ -1653,10 +1933,61 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
|
|
|
1653
1933
|
* @request GET:/assistant
|
|
1654
1934
|
* @secure
|
|
1655
1935
|
*/
|
|
1656
|
-
assistantControllerFindAll: (
|
|
1936
|
+
assistantControllerFindAll: (
|
|
1937
|
+
query?: {
|
|
1938
|
+
/**
|
|
1939
|
+
* This is the maximum number of items to return. Defaults to 100.
|
|
1940
|
+
* @min 0
|
|
1941
|
+
* @max 1000
|
|
1942
|
+
*/
|
|
1943
|
+
limit?: number;
|
|
1944
|
+
/**
|
|
1945
|
+
* This will return items where the createdAt is greater than the specified value.
|
|
1946
|
+
* @format date-time
|
|
1947
|
+
*/
|
|
1948
|
+
createdAtGt?: string;
|
|
1949
|
+
/**
|
|
1950
|
+
* This will return items where the createdAt is less than the specified value.
|
|
1951
|
+
* @format date-time
|
|
1952
|
+
*/
|
|
1953
|
+
createdAtLt?: string;
|
|
1954
|
+
/**
|
|
1955
|
+
* This will return items where the createdAt is greater than or equal to the specified value.
|
|
1956
|
+
* @format date-time
|
|
1957
|
+
*/
|
|
1958
|
+
createdAtGe?: string;
|
|
1959
|
+
/**
|
|
1960
|
+
* This will return items where the createdAt is less than or equal to the specified value.
|
|
1961
|
+
* @format date-time
|
|
1962
|
+
*/
|
|
1963
|
+
createdAtLe?: string;
|
|
1964
|
+
/**
|
|
1965
|
+
* This will return items where the updatedAt is greater than the specified value.
|
|
1966
|
+
* @format date-time
|
|
1967
|
+
*/
|
|
1968
|
+
updatedAtGt?: string;
|
|
1969
|
+
/**
|
|
1970
|
+
* This will return items where the updatedAt is less than the specified value.
|
|
1971
|
+
* @format date-time
|
|
1972
|
+
*/
|
|
1973
|
+
updatedAtLt?: string;
|
|
1974
|
+
/**
|
|
1975
|
+
* This will return items where the updatedAt is greater than or equal to the specified value.
|
|
1976
|
+
* @format date-time
|
|
1977
|
+
*/
|
|
1978
|
+
updatedAtGe?: string;
|
|
1979
|
+
/**
|
|
1980
|
+
* This will return items where the updatedAt is less than or equal to the specified value.
|
|
1981
|
+
* @format date-time
|
|
1982
|
+
*/
|
|
1983
|
+
updatedAtLe?: string;
|
|
1984
|
+
},
|
|
1985
|
+
params: RequestParams = {},
|
|
1986
|
+
) =>
|
|
1657
1987
|
this.request<Assistant[], any>({
|
|
1658
1988
|
path: `/assistant`,
|
|
1659
1989
|
method: "GET",
|
|
1990
|
+
query: query,
|
|
1660
1991
|
secure: true,
|
|
1661
1992
|
format: "json",
|
|
1662
1993
|
...params,
|
|
@@ -1748,10 +2079,63 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
|
|
|
1748
2079
|
* @request GET:/call
|
|
1749
2080
|
* @secure
|
|
1750
2081
|
*/
|
|
1751
|
-
callControllerFindAll: (
|
|
2082
|
+
callControllerFindAll: (
|
|
2083
|
+
query?: {
|
|
2084
|
+
/** This will return calls with the specified assistantId. */
|
|
2085
|
+
assistantId?: string;
|
|
2086
|
+
/**
|
|
2087
|
+
* This is the maximum number of items to return. Defaults to 100.
|
|
2088
|
+
* @min 0
|
|
2089
|
+
* @max 1000
|
|
2090
|
+
*/
|
|
2091
|
+
limit?: number;
|
|
2092
|
+
/**
|
|
2093
|
+
* This will return items where the createdAt is greater than the specified value.
|
|
2094
|
+
* @format date-time
|
|
2095
|
+
*/
|
|
2096
|
+
createdAtGt?: string;
|
|
2097
|
+
/**
|
|
2098
|
+
* This will return items where the createdAt is less than the specified value.
|
|
2099
|
+
* @format date-time
|
|
2100
|
+
*/
|
|
2101
|
+
createdAtLt?: string;
|
|
2102
|
+
/**
|
|
2103
|
+
* This will return items where the createdAt is greater than or equal to the specified value.
|
|
2104
|
+
* @format date-time
|
|
2105
|
+
*/
|
|
2106
|
+
createdAtGe?: string;
|
|
2107
|
+
/**
|
|
2108
|
+
* This will return items where the createdAt is less than or equal to the specified value.
|
|
2109
|
+
* @format date-time
|
|
2110
|
+
*/
|
|
2111
|
+
createdAtLe?: string;
|
|
2112
|
+
/**
|
|
2113
|
+
* This will return items where the updatedAt is greater than the specified value.
|
|
2114
|
+
* @format date-time
|
|
2115
|
+
*/
|
|
2116
|
+
updatedAtGt?: string;
|
|
2117
|
+
/**
|
|
2118
|
+
* This will return items where the updatedAt is less than the specified value.
|
|
2119
|
+
* @format date-time
|
|
2120
|
+
*/
|
|
2121
|
+
updatedAtLt?: string;
|
|
2122
|
+
/**
|
|
2123
|
+
* This will return items where the updatedAt is greater than or equal to the specified value.
|
|
2124
|
+
* @format date-time
|
|
2125
|
+
*/
|
|
2126
|
+
updatedAtGe?: string;
|
|
2127
|
+
/**
|
|
2128
|
+
* This will return items where the updatedAt is less than or equal to the specified value.
|
|
2129
|
+
* @format date-time
|
|
2130
|
+
*/
|
|
2131
|
+
updatedAtLe?: string;
|
|
2132
|
+
},
|
|
2133
|
+
params: RequestParams = {},
|
|
2134
|
+
) =>
|
|
1752
2135
|
this.request<Call[], any>({
|
|
1753
2136
|
path: `/call`,
|
|
1754
2137
|
method: "GET",
|
|
2138
|
+
query: query,
|
|
1755
2139
|
secure: true,
|
|
1756
2140
|
format: "json",
|
|
1757
2141
|
...params,
|
|
@@ -1928,7 +2312,57 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
|
|
|
1928
2312
|
* @request GET:/credential
|
|
1929
2313
|
* @secure
|
|
1930
2314
|
*/
|
|
1931
|
-
credentialControllerFindAll: (
|
|
2315
|
+
credentialControllerFindAll: (
|
|
2316
|
+
query?: {
|
|
2317
|
+
/**
|
|
2318
|
+
* This is the maximum number of items to return. Defaults to 100.
|
|
2319
|
+
* @min 0
|
|
2320
|
+
* @max 1000
|
|
2321
|
+
*/
|
|
2322
|
+
limit?: number;
|
|
2323
|
+
/**
|
|
2324
|
+
* This will return items where the createdAt is greater than the specified value.
|
|
2325
|
+
* @format date-time
|
|
2326
|
+
*/
|
|
2327
|
+
createdAtGt?: string;
|
|
2328
|
+
/**
|
|
2329
|
+
* This will return items where the createdAt is less than the specified value.
|
|
2330
|
+
* @format date-time
|
|
2331
|
+
*/
|
|
2332
|
+
createdAtLt?: string;
|
|
2333
|
+
/**
|
|
2334
|
+
* This will return items where the createdAt is greater than or equal to the specified value.
|
|
2335
|
+
* @format date-time
|
|
2336
|
+
*/
|
|
2337
|
+
createdAtGe?: string;
|
|
2338
|
+
/**
|
|
2339
|
+
* This will return items where the createdAt is less than or equal to the specified value.
|
|
2340
|
+
* @format date-time
|
|
2341
|
+
*/
|
|
2342
|
+
createdAtLe?: string;
|
|
2343
|
+
/**
|
|
2344
|
+
* This will return items where the updatedAt is greater than the specified value.
|
|
2345
|
+
* @format date-time
|
|
2346
|
+
*/
|
|
2347
|
+
updatedAtGt?: string;
|
|
2348
|
+
/**
|
|
2349
|
+
* This will return items where the updatedAt is less than the specified value.
|
|
2350
|
+
* @format date-time
|
|
2351
|
+
*/
|
|
2352
|
+
updatedAtLt?: string;
|
|
2353
|
+
/**
|
|
2354
|
+
* This will return items where the updatedAt is greater than or equal to the specified value.
|
|
2355
|
+
* @format date-time
|
|
2356
|
+
*/
|
|
2357
|
+
updatedAtGe?: string;
|
|
2358
|
+
/**
|
|
2359
|
+
* This will return items where the updatedAt is less than or equal to the specified value.
|
|
2360
|
+
* @format date-time
|
|
2361
|
+
*/
|
|
2362
|
+
updatedAtLe?: string;
|
|
2363
|
+
},
|
|
2364
|
+
params: RequestParams = {},
|
|
2365
|
+
) =>
|
|
1932
2366
|
this.request<
|
|
1933
2367
|
(
|
|
1934
2368
|
| ({
|
|
@@ -1975,6 +2409,7 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
|
|
|
1975
2409
|
>({
|
|
1976
2410
|
path: `/credential`,
|
|
1977
2411
|
method: "GET",
|
|
2412
|
+
query: query,
|
|
1978
2413
|
secure: true,
|
|
1979
2414
|
format: "json",
|
|
1980
2415
|
...params,
|
|
@@ -2252,10 +2687,61 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
|
|
|
2252
2687
|
* @request GET:/phone-number
|
|
2253
2688
|
* @secure
|
|
2254
2689
|
*/
|
|
2255
|
-
phoneNumberControllerFindAll: (
|
|
2690
|
+
phoneNumberControllerFindAll: (
|
|
2691
|
+
query?: {
|
|
2692
|
+
/**
|
|
2693
|
+
* This is the maximum number of items to return. Defaults to 100.
|
|
2694
|
+
* @min 0
|
|
2695
|
+
* @max 1000
|
|
2696
|
+
*/
|
|
2697
|
+
limit?: number;
|
|
2698
|
+
/**
|
|
2699
|
+
* This will return items where the createdAt is greater than the specified value.
|
|
2700
|
+
* @format date-time
|
|
2701
|
+
*/
|
|
2702
|
+
createdAtGt?: string;
|
|
2703
|
+
/**
|
|
2704
|
+
* This will return items where the createdAt is less than the specified value.
|
|
2705
|
+
* @format date-time
|
|
2706
|
+
*/
|
|
2707
|
+
createdAtLt?: string;
|
|
2708
|
+
/**
|
|
2709
|
+
* This will return items where the createdAt is greater than or equal to the specified value.
|
|
2710
|
+
* @format date-time
|
|
2711
|
+
*/
|
|
2712
|
+
createdAtGe?: string;
|
|
2713
|
+
/**
|
|
2714
|
+
* This will return items where the createdAt is less than or equal to the specified value.
|
|
2715
|
+
* @format date-time
|
|
2716
|
+
*/
|
|
2717
|
+
createdAtLe?: string;
|
|
2718
|
+
/**
|
|
2719
|
+
* This will return items where the updatedAt is greater than the specified value.
|
|
2720
|
+
* @format date-time
|
|
2721
|
+
*/
|
|
2722
|
+
updatedAtGt?: string;
|
|
2723
|
+
/**
|
|
2724
|
+
* This will return items where the updatedAt is less than the specified value.
|
|
2725
|
+
* @format date-time
|
|
2726
|
+
*/
|
|
2727
|
+
updatedAtLt?: string;
|
|
2728
|
+
/**
|
|
2729
|
+
* This will return items where the updatedAt is greater than or equal to the specified value.
|
|
2730
|
+
* @format date-time
|
|
2731
|
+
*/
|
|
2732
|
+
updatedAtGe?: string;
|
|
2733
|
+
/**
|
|
2734
|
+
* This will return items where the updatedAt is less than or equal to the specified value.
|
|
2735
|
+
* @format date-time
|
|
2736
|
+
*/
|
|
2737
|
+
updatedAtLe?: string;
|
|
2738
|
+
},
|
|
2739
|
+
params: RequestParams = {},
|
|
2740
|
+
) =>
|
|
2256
2741
|
this.request<PhoneNumber[], any>({
|
|
2257
2742
|
path: `/phone-number`,
|
|
2258
2743
|
method: "GET",
|
|
2744
|
+
query: query,
|
|
2259
2745
|
secure: true,
|
|
2260
2746
|
format: "json",
|
|
2261
2747
|
...params,
|
|
@@ -2317,4 +2803,42 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
|
|
|
2317
2803
|
...params,
|
|
2318
2804
|
}),
|
|
2319
2805
|
};
|
|
2806
|
+
metrics = {
|
|
2807
|
+
/**
|
|
2808
|
+
* No description
|
|
2809
|
+
*
|
|
2810
|
+
* @tags Metrics
|
|
2811
|
+
* @name MetricsControllerFindAll
|
|
2812
|
+
* @summary List Metrics
|
|
2813
|
+
* @request GET:/metrics
|
|
2814
|
+
* @secure
|
|
2815
|
+
*/
|
|
2816
|
+
metricsControllerFindAll: (
|
|
2817
|
+
query?: {
|
|
2818
|
+
/**
|
|
2819
|
+
* This will include calls with a createdAt timestamp greater than or equal to the specified value.
|
|
2820
|
+
*
|
|
2821
|
+
* If not provided, defaults to the org's current period start.
|
|
2822
|
+
* @format date-time
|
|
2823
|
+
*/
|
|
2824
|
+
rangeStart?: string;
|
|
2825
|
+
/**
|
|
2826
|
+
* This will include calls with a createdAt timestamp less than the specified value.
|
|
2827
|
+
*
|
|
2828
|
+
* If not provided, the default value will be the current timestamp.
|
|
2829
|
+
* @format date-time
|
|
2830
|
+
*/
|
|
2831
|
+
rangeEnd?: string;
|
|
2832
|
+
},
|
|
2833
|
+
params: RequestParams = {},
|
|
2834
|
+
) =>
|
|
2835
|
+
this.request<Metrics[], any>({
|
|
2836
|
+
path: `/metrics`,
|
|
2837
|
+
method: "GET",
|
|
2838
|
+
query: query,
|
|
2839
|
+
secure: true,
|
|
2840
|
+
format: "json",
|
|
2841
|
+
...params,
|
|
2842
|
+
}),
|
|
2843
|
+
};
|
|
2320
2844
|
}
|