@avallon-labs/sdk 0.0.0-4d940829

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.
@@ -0,0 +1,1244 @@
1
+ import * as swr_mutation from 'swr/mutation';
2
+ import { SWRMutationConfiguration } from 'swr/mutation';
3
+ import * as swr__internal from 'swr/_internal';
4
+ import * as swr from 'swr';
5
+ import { Key, SWRConfiguration } from 'swr';
6
+
7
+ /**
8
+ * Custom fetch wrapper for Orval-generated client.
9
+ * Handles auth (API key or Bearer token) and base URL configuration.
10
+ * Throws AvallonError on non-2xx responses for clean SWR error handling.
11
+ */
12
+ type AvallonConfig = {
13
+ baseUrl?: string;
14
+ apiKey?: string;
15
+ /**
16
+ * Token provider - can be sync or async.
17
+ * Async allows the application to check expiry and refresh before returning.
18
+ */
19
+ getAccessToken?: () => string | null | Promise<string | null>;
20
+ };
21
+ /** Configure the SDK at runtime */
22
+ declare function configure(newConfig: Partial<AvallonConfig>): void;
23
+ /** Get current config */
24
+ declare function getConfig(): AvallonConfig;
25
+ /** Authenticated fetch - adds API key or Bearer token */
26
+ declare function customFetch<T>(url: string, options: RequestInit): Promise<T>;
27
+ /** Unauthenticated fetch - for auth flow endpoints (sign-in, sign-up, etc.) */
28
+ declare function customFetchNoAuth<T>(url: string, options: RequestInit): Promise<T>;
29
+ /** Typed error class for API errors */
30
+ declare class AvallonError extends Error {
31
+ readonly status: number;
32
+ readonly body: {
33
+ data?: unknown;
34
+ message?: string;
35
+ };
36
+ constructor(status: number, body: {
37
+ data?: unknown;
38
+ message?: string;
39
+ });
40
+ /** Validation errors (400) have field-level details */
41
+ get errors(): Array<{
42
+ field: string;
43
+ message: string;
44
+ }> | undefined;
45
+ isValidationError(): boolean;
46
+ isUnauthorized(): boolean;
47
+ isNotFound(): boolean;
48
+ }
49
+
50
+ /**
51
+ * PKCE Utilities
52
+ *
53
+ * Cryptographic helpers for OAuth PKCE flow. Platform-agnostic -
54
+ * works in both Node.js and browsers via Web Crypto API.
55
+ *
56
+ * These utilities can't be generated from OpenAPI - they're
57
+ * client-side crypto that complements the generated auth endpoints.
58
+ *
59
+ * @example
60
+ * ```ts
61
+ * import {
62
+ * generateCodeVerifier,
63
+ * generateCodeChallenge,
64
+ * getV1AuthOauthUrl,
65
+ * postV1AuthOauthExchange,
66
+ * } from "@avallon-labs/sdk";
67
+ *
68
+ * // 1. Generate PKCE pair
69
+ * const verifier = generateCodeVerifier();
70
+ * const challenge = await generateCodeChallenge(verifier);
71
+ *
72
+ * // 2. Get OAuth URL (store verifier for after redirect)
73
+ * sessionStorage.setItem("oauth_verifier", verifier);
74
+ * const { data } = await getV1AuthOauthUrl({
75
+ * provider: "google",
76
+ * redirect_uri: "https://app.example.com/callback",
77
+ * code_challenge: challenge,
78
+ * code_challenge_method: "s256",
79
+ * });
80
+ * window.location.href = data.data.url;
81
+ *
82
+ * // 3. After redirect, exchange code for tokens
83
+ * const verifier = sessionStorage.getItem("oauth_verifier");
84
+ * const tokens = await postV1AuthOauthExchange({
85
+ * code: urlParams.get("code"),
86
+ * code_verifier: verifier,
87
+ * });
88
+ * ```
89
+ */
90
+ /** Generate a cryptographically random code verifier (43-128 chars) */
91
+ declare function generateCodeVerifier(length?: number): string;
92
+ /** Generate S256 code challenge from verifier */
93
+ declare function generateCodeChallenge(verifier: string): Promise<string>;
94
+
95
+ /**
96
+ * Generated by orval v8.1.0 🍺
97
+ * Do not edit manually.
98
+ * Avallon API
99
+ * OpenAPI spec version: 1.0.0
100
+ */
101
+ type CreateAgent200DataAgentBackgroundSounds = (typeof CreateAgent200DataAgentBackgroundSounds)[keyof typeof CreateAgent200DataAgentBackgroundSounds];
102
+ declare const CreateAgent200DataAgentBackgroundSounds: {
103
+ readonly enabled: "enabled";
104
+ readonly disabled: "disabled";
105
+ };
106
+
107
+ /**
108
+ * Generated by orval v8.1.0 🍺
109
+ * Do not edit manually.
110
+ * Avallon API
111
+ * OpenAPI spec version: 1.0.0
112
+ */
113
+ type CreateAgent200DataAgentDirection = (typeof CreateAgent200DataAgentDirection)[keyof typeof CreateAgent200DataAgentDirection];
114
+ declare const CreateAgent200DataAgentDirection: {
115
+ readonly INBOUND: "INBOUND";
116
+ readonly OUTBOUND: "OUTBOUND";
117
+ };
118
+
119
+ /**
120
+ * Generated by orval v8.1.0 🍺
121
+ * Do not edit manually.
122
+ * Avallon API
123
+ * OpenAPI spec version: 1.0.0
124
+ */
125
+ type CreateAgent200DataAgentLanguage = (typeof CreateAgent200DataAgentLanguage)[keyof typeof CreateAgent200DataAgentLanguage];
126
+ declare const CreateAgent200DataAgentLanguage: {
127
+ readonly "en-US": "en-US";
128
+ readonly "de-DE": "de-DE";
129
+ };
130
+
131
+ /**
132
+ * Generated by orval v8.1.0 🍺
133
+ * Do not edit manually.
134
+ * Avallon API
135
+ * OpenAPI spec version: 1.0.0
136
+ */
137
+ type CreateAgent200DataAgentLlmModel = (typeof CreateAgent200DataAgentLlmModel)[keyof typeof CreateAgent200DataAgentLlmModel];
138
+ declare const CreateAgent200DataAgentLlmModel: {
139
+ readonly GPT41: "GPT4.1";
140
+ readonly "AZURE-GPT4o": "AZURE-GPT4o";
141
+ readonly "AZURE-GPT41": "AZURE-GPT4.1";
142
+ readonly "GPT-5": "GPT-5";
143
+ readonly "GPT-5-low": "GPT-5-low";
144
+ readonly "GPT-5-high": "GPT-5-high";
145
+ readonly "GPT-51-chat-latest": "GPT-5.1-chat-latest";
146
+ readonly "GPT-51-no-reasoning": "GPT-5.1-no-reasoning";
147
+ readonly "GEMINI-15-flash": "GEMINI-1.5-flash";
148
+ readonly "GEMINI-25-flash": "GEMINI-2.5-flash";
149
+ readonly "GEMINI-25-flash-lite": "GEMINI-2.5-flash-lite";
150
+ readonly "GEMINI-3-flash": "GEMINI-3-flash";
151
+ };
152
+
153
+ /**
154
+ * Generated by orval v8.1.0 🍺
155
+ * Do not edit manually.
156
+ * Avallon API
157
+ * OpenAPI spec version: 1.0.0
158
+ */
159
+ type CreateAgent200DataAgentSttModel = (typeof CreateAgent200DataAgentSttModel)[keyof typeof CreateAgent200DataAgentSttModel];
160
+ declare const CreateAgent200DataAgentSttModel: {
161
+ readonly "DEEPGRAM-NOVA-2-GENERAL": "DEEPGRAM-NOVA-2-GENERAL";
162
+ readonly "DEEPGRAM-NOVA-3-GENERAL": "DEEPGRAM-NOVA-3-GENERAL";
163
+ readonly "AWS-TRANSCRIBE": "AWS-TRANSCRIBE";
164
+ };
165
+
166
+ /**
167
+ * Generated by orval v8.1.0 🍺
168
+ * Do not edit manually.
169
+ * Avallon API
170
+ * OpenAPI spec version: 1.0.0
171
+ */
172
+ type CreateAgent200DataAgentTtsModel = (typeof CreateAgent200DataAgentTtsModel)[keyof typeof CreateAgent200DataAgentTtsModel];
173
+ declare const CreateAgent200DataAgentTtsModel: {
174
+ readonly eleven_flash_v2_5: "eleven_flash_v2_5";
175
+ readonly eleven_turbo_v2_5: "eleven_turbo_v2_5";
176
+ readonly "sonic-multilingual": "sonic-multilingual";
177
+ readonly "sonic-3": "sonic-3";
178
+ readonly chirp_3: "chirp_3";
179
+ };
180
+
181
+ /**
182
+ * Generated by orval v8.1.0 🍺
183
+ * Do not edit manually.
184
+ * Avallon API
185
+ * OpenAPI spec version: 1.0.0
186
+ */
187
+ type CreateAgent200DataAgentTtsProvider = (typeof CreateAgent200DataAgentTtsProvider)[keyof typeof CreateAgent200DataAgentTtsProvider];
188
+ declare const CreateAgent200DataAgentTtsProvider: {
189
+ readonly elevenlabs: "elevenlabs";
190
+ readonly cartesia: "cartesia";
191
+ readonly google: "google";
192
+ };
193
+
194
+ /**
195
+ * Generated by orval v8.1.0 🍺
196
+ * Do not edit manually.
197
+ * Avallon API
198
+ * OpenAPI spec version: 1.0.0
199
+ */
200
+
201
+ type CreateAgent200DataAgent = {
202
+ id: string;
203
+ tenant_id: string;
204
+ agent_name: string;
205
+ direction: CreateAgent200DataAgentDirection;
206
+ llm_model: CreateAgent200DataAgentLlmModel;
207
+ tts_provider: CreateAgent200DataAgentTtsProvider;
208
+ tts_model: CreateAgent200DataAgentTtsModel;
209
+ language: CreateAgent200DataAgentLanguage;
210
+ tts_voice_id: string;
211
+ stt_model: CreateAgent200DataAgentSttModel;
212
+ transfer_phone_number: string | null;
213
+ background_sounds: CreateAgent200DataAgentBackgroundSounds;
214
+ created_at: string;
215
+ updated_at: string;
216
+ phone_number: string | null;
217
+ dial_pad: boolean;
218
+ end_call: boolean;
219
+ };
220
+
221
+ /**
222
+ * Generated by orval v8.1.0 🍺
223
+ * Do not edit manually.
224
+ * Avallon API
225
+ * OpenAPI spec version: 1.0.0
226
+ */
227
+
228
+ type CreateAgent200Data = {
229
+ agent: CreateAgent200DataAgent;
230
+ };
231
+
232
+ /**
233
+ * Generated by orval v8.1.0 🍺
234
+ * Do not edit manually.
235
+ * Avallon API
236
+ * OpenAPI spec version: 1.0.0
237
+ */
238
+
239
+ type CreateAgent200 = {
240
+ data: CreateAgent200Data;
241
+ message: string;
242
+ };
243
+
244
+ /**
245
+ * Generated by orval v8.1.0 🍺
246
+ * Do not edit manually.
247
+ * Avallon API
248
+ * OpenAPI spec version: 1.0.0
249
+ */
250
+ /**
251
+ * Call direction the agent handles
252
+ */
253
+ type CreateAgentBodyDirection = (typeof CreateAgentBodyDirection)[keyof typeof CreateAgentBodyDirection];
254
+ declare const CreateAgentBodyDirection: {
255
+ readonly OUTBOUND: "OUTBOUND";
256
+ readonly INBOUND: "INBOUND";
257
+ };
258
+
259
+ /**
260
+ * Generated by orval v8.1.0 🍺
261
+ * Do not edit manually.
262
+ * Avallon API
263
+ * OpenAPI spec version: 1.0.0
264
+ */
265
+ /**
266
+ * Language for the agent
267
+ */
268
+ type CreateAgentBodyLanguage = (typeof CreateAgentBodyLanguage)[keyof typeof CreateAgentBodyLanguage];
269
+ declare const CreateAgentBodyLanguage: {
270
+ readonly "en-US": "en-US";
271
+ readonly "de-DE": "de-DE";
272
+ };
273
+
274
+ /**
275
+ * Generated by orval v8.1.0 🍺
276
+ * Do not edit manually.
277
+ * Avallon API
278
+ * OpenAPI spec version: 1.0.0
279
+ */
280
+ /**
281
+ * LLM model for conversation
282
+ */
283
+ type CreateAgentBodyLlmModel = (typeof CreateAgentBodyLlmModel)[keyof typeof CreateAgentBodyLlmModel];
284
+ declare const CreateAgentBodyLlmModel: {
285
+ readonly GPT41: "GPT4.1";
286
+ readonly "AZURE-GPT4o": "AZURE-GPT4o";
287
+ readonly "AZURE-GPT41": "AZURE-GPT4.1";
288
+ readonly "GPT-5": "GPT-5";
289
+ readonly "GPT-5-low": "GPT-5-low";
290
+ readonly "GPT-5-high": "GPT-5-high";
291
+ readonly "GPT-51-chat-latest": "GPT-5.1-chat-latest";
292
+ readonly "GPT-51-no-reasoning": "GPT-5.1-no-reasoning";
293
+ readonly "GEMINI-15-flash": "GEMINI-1.5-flash";
294
+ readonly "GEMINI-25-flash": "GEMINI-2.5-flash";
295
+ readonly "GEMINI-25-flash-lite": "GEMINI-2.5-flash-lite";
296
+ readonly "GEMINI-3-flash": "GEMINI-3-flash";
297
+ };
298
+
299
+ /**
300
+ * Generated by orval v8.1.0 🍺
301
+ * Do not edit manually.
302
+ * Avallon API
303
+ * OpenAPI spec version: 1.0.0
304
+ */
305
+ /**
306
+ * Speech-to-text model
307
+ */
308
+ type CreateAgentBodySttModel = (typeof CreateAgentBodySttModel)[keyof typeof CreateAgentBodySttModel];
309
+ declare const CreateAgentBodySttModel: {
310
+ readonly "DEEPGRAM-NOVA-2-GENERAL": "DEEPGRAM-NOVA-2-GENERAL";
311
+ readonly "DEEPGRAM-NOVA-3-GENERAL": "DEEPGRAM-NOVA-3-GENERAL";
312
+ readonly "AWS-TRANSCRIBE": "AWS-TRANSCRIBE";
313
+ };
314
+
315
+ /**
316
+ * Generated by orval v8.1.0 🍺
317
+ * Do not edit manually.
318
+ * Avallon API
319
+ * OpenAPI spec version: 1.0.0
320
+ */
321
+ /**
322
+ * Text-to-speech model
323
+ */
324
+ type CreateAgentBodyTtsModel = (typeof CreateAgentBodyTtsModel)[keyof typeof CreateAgentBodyTtsModel];
325
+ declare const CreateAgentBodyTtsModel: {
326
+ readonly eleven_flash_v2_5: "eleven_flash_v2_5";
327
+ readonly eleven_turbo_v2_5: "eleven_turbo_v2_5";
328
+ readonly "sonic-multilingual": "sonic-multilingual";
329
+ readonly "sonic-3": "sonic-3";
330
+ readonly chirp_3: "chirp_3";
331
+ };
332
+
333
+ /**
334
+ * Generated by orval v8.1.0 🍺
335
+ * Do not edit manually.
336
+ * Avallon API
337
+ * OpenAPI spec version: 1.0.0
338
+ */
339
+ /**
340
+ * Text-to-speech provider
341
+ */
342
+ type CreateAgentBodyTtsProvider = (typeof CreateAgentBodyTtsProvider)[keyof typeof CreateAgentBodyTtsProvider];
343
+ declare const CreateAgentBodyTtsProvider: {
344
+ readonly elevenlabs: "elevenlabs";
345
+ readonly cartesia: "cartesia";
346
+ readonly google: "google";
347
+ };
348
+
349
+ /**
350
+ * Generated by orval v8.1.0 🍺
351
+ * Do not edit manually.
352
+ * Avallon API
353
+ * OpenAPI spec version: 1.0.0
354
+ */
355
+
356
+ type CreateAgentBody = {
357
+ /**
358
+ * Name for the agent
359
+ * @minLength 1
360
+ */
361
+ agent_name: string;
362
+ /** Call direction the agent handles */
363
+ direction: CreateAgentBodyDirection;
364
+ /** LLM model for conversation */
365
+ llm_model: CreateAgentBodyLlmModel;
366
+ /** Text-to-speech provider */
367
+ tts_provider: CreateAgentBodyTtsProvider;
368
+ /** Text-to-speech model */
369
+ tts_model: CreateAgentBodyTtsModel;
370
+ /** Voice ID from the TTS provider */
371
+ tts_voice_id: "Achernar" | "Achird" | "v3V1d2rk6528UrLKRuy8" | "5c42302c-194b-4d0c-ba1a-8cb485c84ab9" | "e8e5fffb-252c-436d-b842-8879b84445b6" | "f786b574-daa5-4673-aa0c-cbe3e8534c02" | "8d8ce8c9-44a4-46c4-b10f-9a927b99a853" | "5ee9feff-1265-424a-9d7f-8e4d431a12c7" | "b9de4a89-2257-424b-94c2-db18ba68c81a";
372
+ /** Speech-to-text model */
373
+ stt_model: CreateAgentBodySttModel;
374
+ /** Phone number to transfer calls to */
375
+ transfer_phone_number: string | null;
376
+ /** ID of phone number to assign to agent */
377
+ phone_number_id?: string;
378
+ /** Language for the agent */
379
+ language: CreateAgentBodyLanguage;
380
+ /** Whether the agent supports DTMF dial pad input */
381
+ dial_pad?: boolean;
382
+ /** Whether the agent can end the call */
383
+ end_call?: boolean;
384
+ };
385
+
386
+ /**
387
+ * Generated by orval v8.1.0 🍺
388
+ * Do not edit manually.
389
+ * Avallon API
390
+ * OpenAPI spec version: 1.0.0
391
+ */
392
+ type ErrorResponseData = {
393
+ [key: string]: unknown;
394
+ };
395
+
396
+ /**
397
+ * Generated by orval v8.1.0 🍺
398
+ * Do not edit manually.
399
+ * Avallon API
400
+ * OpenAPI spec version: 1.0.0
401
+ */
402
+
403
+ interface ErrorResponse {
404
+ data: ErrorResponseData;
405
+ /** Human-readable error message */
406
+ message: string;
407
+ }
408
+
409
+ /**
410
+ * Generated by orval v8.1.0 🍺
411
+ * Do not edit manually.
412
+ * Avallon API
413
+ * OpenAPI spec version: 1.0.0
414
+ */
415
+ type GetAgent200DataAgentBackgroundSounds = (typeof GetAgent200DataAgentBackgroundSounds)[keyof typeof GetAgent200DataAgentBackgroundSounds];
416
+ declare const GetAgent200DataAgentBackgroundSounds: {
417
+ readonly enabled: "enabled";
418
+ readonly disabled: "disabled";
419
+ };
420
+
421
+ /**
422
+ * Generated by orval v8.1.0 🍺
423
+ * Do not edit manually.
424
+ * Avallon API
425
+ * OpenAPI spec version: 1.0.0
426
+ */
427
+ type GetAgent200DataAgentDirection = (typeof GetAgent200DataAgentDirection)[keyof typeof GetAgent200DataAgentDirection];
428
+ declare const GetAgent200DataAgentDirection: {
429
+ readonly INBOUND: "INBOUND";
430
+ readonly OUTBOUND: "OUTBOUND";
431
+ };
432
+
433
+ /**
434
+ * Generated by orval v8.1.0 🍺
435
+ * Do not edit manually.
436
+ * Avallon API
437
+ * OpenAPI spec version: 1.0.0
438
+ */
439
+ type GetAgent200DataAgentLanguage = (typeof GetAgent200DataAgentLanguage)[keyof typeof GetAgent200DataAgentLanguage];
440
+ declare const GetAgent200DataAgentLanguage: {
441
+ readonly "en-US": "en-US";
442
+ readonly "de-DE": "de-DE";
443
+ };
444
+
445
+ /**
446
+ * Generated by orval v8.1.0 🍺
447
+ * Do not edit manually.
448
+ * Avallon API
449
+ * OpenAPI spec version: 1.0.0
450
+ */
451
+ type GetAgent200DataAgentLlmModel = (typeof GetAgent200DataAgentLlmModel)[keyof typeof GetAgent200DataAgentLlmModel];
452
+ declare const GetAgent200DataAgentLlmModel: {
453
+ readonly GPT41: "GPT4.1";
454
+ readonly "AZURE-GPT4o": "AZURE-GPT4o";
455
+ readonly "AZURE-GPT41": "AZURE-GPT4.1";
456
+ readonly "GPT-5": "GPT-5";
457
+ readonly "GPT-5-low": "GPT-5-low";
458
+ readonly "GPT-5-high": "GPT-5-high";
459
+ readonly "GPT-51-chat-latest": "GPT-5.1-chat-latest";
460
+ readonly "GPT-51-no-reasoning": "GPT-5.1-no-reasoning";
461
+ readonly "GEMINI-15-flash": "GEMINI-1.5-flash";
462
+ readonly "GEMINI-25-flash": "GEMINI-2.5-flash";
463
+ readonly "GEMINI-25-flash-lite": "GEMINI-2.5-flash-lite";
464
+ readonly "GEMINI-3-flash": "GEMINI-3-flash";
465
+ };
466
+
467
+ /**
468
+ * Generated by orval v8.1.0 🍺
469
+ * Do not edit manually.
470
+ * Avallon API
471
+ * OpenAPI spec version: 1.0.0
472
+ */
473
+ type GetAgent200DataAgentSttModel = (typeof GetAgent200DataAgentSttModel)[keyof typeof GetAgent200DataAgentSttModel];
474
+ declare const GetAgent200DataAgentSttModel: {
475
+ readonly "DEEPGRAM-NOVA-2-GENERAL": "DEEPGRAM-NOVA-2-GENERAL";
476
+ readonly "DEEPGRAM-NOVA-3-GENERAL": "DEEPGRAM-NOVA-3-GENERAL";
477
+ readonly "AWS-TRANSCRIBE": "AWS-TRANSCRIBE";
478
+ };
479
+
480
+ /**
481
+ * Generated by orval v8.1.0 🍺
482
+ * Do not edit manually.
483
+ * Avallon API
484
+ * OpenAPI spec version: 1.0.0
485
+ */
486
+ type GetAgent200DataAgentTtsModel = (typeof GetAgent200DataAgentTtsModel)[keyof typeof GetAgent200DataAgentTtsModel];
487
+ declare const GetAgent200DataAgentTtsModel: {
488
+ readonly eleven_flash_v2_5: "eleven_flash_v2_5";
489
+ readonly eleven_turbo_v2_5: "eleven_turbo_v2_5";
490
+ readonly "sonic-multilingual": "sonic-multilingual";
491
+ readonly "sonic-3": "sonic-3";
492
+ readonly chirp_3: "chirp_3";
493
+ };
494
+
495
+ /**
496
+ * Generated by orval v8.1.0 🍺
497
+ * Do not edit manually.
498
+ * Avallon API
499
+ * OpenAPI spec version: 1.0.0
500
+ */
501
+ type GetAgent200DataAgentTtsProvider = (typeof GetAgent200DataAgentTtsProvider)[keyof typeof GetAgent200DataAgentTtsProvider];
502
+ declare const GetAgent200DataAgentTtsProvider: {
503
+ readonly elevenlabs: "elevenlabs";
504
+ readonly cartesia: "cartesia";
505
+ readonly google: "google";
506
+ };
507
+
508
+ /**
509
+ * Generated by orval v8.1.0 🍺
510
+ * Do not edit manually.
511
+ * Avallon API
512
+ * OpenAPI spec version: 1.0.0
513
+ */
514
+
515
+ type GetAgent200DataAgent = {
516
+ id: string;
517
+ tenant_id: string;
518
+ agent_name: string;
519
+ direction: GetAgent200DataAgentDirection;
520
+ llm_model: GetAgent200DataAgentLlmModel;
521
+ tts_provider: GetAgent200DataAgentTtsProvider;
522
+ tts_model: GetAgent200DataAgentTtsModel;
523
+ language: GetAgent200DataAgentLanguage;
524
+ tts_voice_id: string;
525
+ stt_model: GetAgent200DataAgentSttModel;
526
+ transfer_phone_number: string | null;
527
+ background_sounds: GetAgent200DataAgentBackgroundSounds;
528
+ created_at: string;
529
+ updated_at: string;
530
+ phone_number: string | null;
531
+ dial_pad: boolean;
532
+ end_call: boolean;
533
+ };
534
+
535
+ /**
536
+ * Generated by orval v8.1.0 🍺
537
+ * Do not edit manually.
538
+ * Avallon API
539
+ * OpenAPI spec version: 1.0.0
540
+ */
541
+
542
+ type GetAgent200Data = {
543
+ agent: GetAgent200DataAgent;
544
+ };
545
+
546
+ /**
547
+ * Generated by orval v8.1.0 🍺
548
+ * Do not edit manually.
549
+ * Avallon API
550
+ * OpenAPI spec version: 1.0.0
551
+ */
552
+
553
+ type GetAgent200 = {
554
+ data: GetAgent200Data;
555
+ message: string;
556
+ };
557
+
558
+ /**
559
+ * Generated by orval v8.1.0 🍺
560
+ * Do not edit manually.
561
+ * Avallon API
562
+ * OpenAPI spec version: 1.0.0
563
+ */
564
+ type GetV1AuthOauthUrl200Data = {
565
+ url: string;
566
+ };
567
+
568
+ /**
569
+ * Generated by orval v8.1.0 🍺
570
+ * Do not edit manually.
571
+ * Avallon API
572
+ * OpenAPI spec version: 1.0.0
573
+ */
574
+
575
+ type GetV1AuthOauthUrl200 = {
576
+ data: GetV1AuthOauthUrl200Data;
577
+ message: string;
578
+ };
579
+
580
+ /**
581
+ * Generated by orval v8.1.0 🍺
582
+ * Do not edit manually.
583
+ * Avallon API
584
+ * OpenAPI spec version: 1.0.0
585
+ */
586
+ type GetV1AuthOauthUrlCodeChallengeMethod = (typeof GetV1AuthOauthUrlCodeChallengeMethod)[keyof typeof GetV1AuthOauthUrlCodeChallengeMethod];
587
+ declare const GetV1AuthOauthUrlCodeChallengeMethod: {
588
+ readonly plain: "plain";
589
+ readonly s256: "s256";
590
+ };
591
+
592
+ /**
593
+ * Generated by orval v8.1.0 🍺
594
+ * Do not edit manually.
595
+ * Avallon API
596
+ * OpenAPI spec version: 1.0.0
597
+ */
598
+ type GetV1AuthOauthUrlProvider = (typeof GetV1AuthOauthUrlProvider)[keyof typeof GetV1AuthOauthUrlProvider];
599
+ declare const GetV1AuthOauthUrlProvider: {
600
+ readonly google: "google";
601
+ readonly microsoft: "microsoft";
602
+ };
603
+
604
+ /**
605
+ * Generated by orval v8.1.0 🍺
606
+ * Do not edit manually.
607
+ * Avallon API
608
+ * OpenAPI spec version: 1.0.0
609
+ */
610
+
611
+ type GetV1AuthOauthUrlParams = {
612
+ provider: GetV1AuthOauthUrlProvider;
613
+ redirect_uri: string;
614
+ code_challenge_method: GetV1AuthOauthUrlCodeChallengeMethod;
615
+ /**
616
+ * @minLength 1
617
+ */
618
+ code_challenge: string;
619
+ };
620
+
621
+ /**
622
+ * Generated by orval v8.1.0 🍺
623
+ * Do not edit manually.
624
+ * Avallon API
625
+ * OpenAPI spec version: 1.0.0
626
+ */
627
+ type ListAgents200DataAgentsItemBackgroundSounds = (typeof ListAgents200DataAgentsItemBackgroundSounds)[keyof typeof ListAgents200DataAgentsItemBackgroundSounds];
628
+ declare const ListAgents200DataAgentsItemBackgroundSounds: {
629
+ readonly enabled: "enabled";
630
+ readonly disabled: "disabled";
631
+ };
632
+
633
+ /**
634
+ * Generated by orval v8.1.0 🍺
635
+ * Do not edit manually.
636
+ * Avallon API
637
+ * OpenAPI spec version: 1.0.0
638
+ */
639
+ type ListAgents200DataAgentsItemDirection = (typeof ListAgents200DataAgentsItemDirection)[keyof typeof ListAgents200DataAgentsItemDirection];
640
+ declare const ListAgents200DataAgentsItemDirection: {
641
+ readonly INBOUND: "INBOUND";
642
+ readonly OUTBOUND: "OUTBOUND";
643
+ };
644
+
645
+ /**
646
+ * Generated by orval v8.1.0 🍺
647
+ * Do not edit manually.
648
+ * Avallon API
649
+ * OpenAPI spec version: 1.0.0
650
+ */
651
+ type ListAgents200DataAgentsItemLanguage = (typeof ListAgents200DataAgentsItemLanguage)[keyof typeof ListAgents200DataAgentsItemLanguage];
652
+ declare const ListAgents200DataAgentsItemLanguage: {
653
+ readonly "en-US": "en-US";
654
+ readonly "de-DE": "de-DE";
655
+ };
656
+
657
+ /**
658
+ * Generated by orval v8.1.0 🍺
659
+ * Do not edit manually.
660
+ * Avallon API
661
+ * OpenAPI spec version: 1.0.0
662
+ */
663
+ type ListAgents200DataAgentsItemLlmModel = (typeof ListAgents200DataAgentsItemLlmModel)[keyof typeof ListAgents200DataAgentsItemLlmModel];
664
+ declare const ListAgents200DataAgentsItemLlmModel: {
665
+ readonly GPT41: "GPT4.1";
666
+ readonly "AZURE-GPT4o": "AZURE-GPT4o";
667
+ readonly "AZURE-GPT41": "AZURE-GPT4.1";
668
+ readonly "GPT-5": "GPT-5";
669
+ readonly "GPT-5-low": "GPT-5-low";
670
+ readonly "GPT-5-high": "GPT-5-high";
671
+ readonly "GPT-51-chat-latest": "GPT-5.1-chat-latest";
672
+ readonly "GPT-51-no-reasoning": "GPT-5.1-no-reasoning";
673
+ readonly "GEMINI-15-flash": "GEMINI-1.5-flash";
674
+ readonly "GEMINI-25-flash": "GEMINI-2.5-flash";
675
+ readonly "GEMINI-25-flash-lite": "GEMINI-2.5-flash-lite";
676
+ readonly "GEMINI-3-flash": "GEMINI-3-flash";
677
+ };
678
+
679
+ /**
680
+ * Generated by orval v8.1.0 🍺
681
+ * Do not edit manually.
682
+ * Avallon API
683
+ * OpenAPI spec version: 1.0.0
684
+ */
685
+ type ListAgents200DataAgentsItemSttModel = (typeof ListAgents200DataAgentsItemSttModel)[keyof typeof ListAgents200DataAgentsItemSttModel];
686
+ declare const ListAgents200DataAgentsItemSttModel: {
687
+ readonly "DEEPGRAM-NOVA-2-GENERAL": "DEEPGRAM-NOVA-2-GENERAL";
688
+ readonly "DEEPGRAM-NOVA-3-GENERAL": "DEEPGRAM-NOVA-3-GENERAL";
689
+ readonly "AWS-TRANSCRIBE": "AWS-TRANSCRIBE";
690
+ };
691
+
692
+ /**
693
+ * Generated by orval v8.1.0 🍺
694
+ * Do not edit manually.
695
+ * Avallon API
696
+ * OpenAPI spec version: 1.0.0
697
+ */
698
+ type ListAgents200DataAgentsItemTtsModel = (typeof ListAgents200DataAgentsItemTtsModel)[keyof typeof ListAgents200DataAgentsItemTtsModel];
699
+ declare const ListAgents200DataAgentsItemTtsModel: {
700
+ readonly eleven_flash_v2_5: "eleven_flash_v2_5";
701
+ readonly eleven_turbo_v2_5: "eleven_turbo_v2_5";
702
+ readonly "sonic-multilingual": "sonic-multilingual";
703
+ readonly "sonic-3": "sonic-3";
704
+ readonly chirp_3: "chirp_3";
705
+ };
706
+
707
+ /**
708
+ * Generated by orval v8.1.0 🍺
709
+ * Do not edit manually.
710
+ * Avallon API
711
+ * OpenAPI spec version: 1.0.0
712
+ */
713
+ type ListAgents200DataAgentsItemTtsProvider = (typeof ListAgents200DataAgentsItemTtsProvider)[keyof typeof ListAgents200DataAgentsItemTtsProvider];
714
+ declare const ListAgents200DataAgentsItemTtsProvider: {
715
+ readonly elevenlabs: "elevenlabs";
716
+ readonly cartesia: "cartesia";
717
+ readonly google: "google";
718
+ };
719
+
720
+ /**
721
+ * Generated by orval v8.1.0 🍺
722
+ * Do not edit manually.
723
+ * Avallon API
724
+ * OpenAPI spec version: 1.0.0
725
+ */
726
+
727
+ type ListAgents200DataAgentsItem = {
728
+ id: string;
729
+ tenant_id: string;
730
+ agent_name: string;
731
+ direction: ListAgents200DataAgentsItemDirection;
732
+ llm_model: ListAgents200DataAgentsItemLlmModel;
733
+ tts_provider: ListAgents200DataAgentsItemTtsProvider;
734
+ tts_model: ListAgents200DataAgentsItemTtsModel;
735
+ language: ListAgents200DataAgentsItemLanguage;
736
+ tts_voice_id: string;
737
+ stt_model: ListAgents200DataAgentsItemSttModel;
738
+ transfer_phone_number: string | null;
739
+ background_sounds: ListAgents200DataAgentsItemBackgroundSounds;
740
+ created_at: string;
741
+ updated_at: string;
742
+ phone_number: string | null;
743
+ dial_pad: boolean;
744
+ end_call: boolean;
745
+ };
746
+
747
+ /**
748
+ * Generated by orval v8.1.0 🍺
749
+ * Do not edit manually.
750
+ * Avallon API
751
+ * OpenAPI spec version: 1.0.0
752
+ */
753
+
754
+ type ListAgents200Data = {
755
+ agents: ListAgents200DataAgentsItem[];
756
+ /**
757
+ * Total number of agents
758
+ * @minimum -9007199254740991
759
+ * @maximum 9007199254740991
760
+ */
761
+ total: number;
762
+ };
763
+
764
+ /**
765
+ * Generated by orval v8.1.0 🍺
766
+ * Do not edit manually.
767
+ * Avallon API
768
+ * OpenAPI spec version: 1.0.0
769
+ */
770
+
771
+ type ListAgents200 = {
772
+ data: ListAgents200Data;
773
+ message: string;
774
+ };
775
+
776
+ /**
777
+ * Generated by orval v8.1.0 🍺
778
+ * Do not edit manually.
779
+ * Avallon API
780
+ * OpenAPI spec version: 1.0.0
781
+ */
782
+ type ListAgentsParams = {
783
+ /**
784
+ * Filter by exact agent name
785
+ */
786
+ agent_name?: string;
787
+ };
788
+
789
+ /**
790
+ * Generated by orval v8.1.0 🍺
791
+ * Do not edit manually.
792
+ * Avallon API
793
+ * OpenAPI spec version: 1.0.0
794
+ */
795
+ type PostV1AuthRefreshToken200Data = {
796
+ access_token: string;
797
+ refresh_token: string;
798
+ expires_at: string;
799
+ };
800
+
801
+ /**
802
+ * Generated by orval v8.1.0 🍺
803
+ * Do not edit manually.
804
+ * Avallon API
805
+ * OpenAPI spec version: 1.0.0
806
+ */
807
+
808
+ type PostV1AuthRefreshToken200 = {
809
+ data: PostV1AuthRefreshToken200Data;
810
+ message: string;
811
+ };
812
+
813
+ /**
814
+ * Generated by orval v8.1.0 🍺
815
+ * Do not edit manually.
816
+ * Avallon API
817
+ * OpenAPI spec version: 1.0.0
818
+ */
819
+ type PostV1AuthRefreshTokenBody = {
820
+ access_token: string;
821
+ refresh_token: string;
822
+ };
823
+
824
+ /**
825
+ * Generated by orval v8.1.0 🍺
826
+ * Do not edit manually.
827
+ * Avallon API
828
+ * OpenAPI spec version: 1.0.0
829
+ */
830
+ type PostV1AuthSignIn200Data = {
831
+ access_token: string;
832
+ refresh_token: string;
833
+ expires_at: string;
834
+ };
835
+
836
+ /**
837
+ * Generated by orval v8.1.0 🍺
838
+ * Do not edit manually.
839
+ * Avallon API
840
+ * OpenAPI spec version: 1.0.0
841
+ */
842
+
843
+ type PostV1AuthSignIn200 = {
844
+ data: PostV1AuthSignIn200Data;
845
+ message: string;
846
+ };
847
+
848
+ /**
849
+ * Generated by orval v8.1.0 🍺
850
+ * Do not edit manually.
851
+ * Avallon API
852
+ * OpenAPI spec version: 1.0.0
853
+ */
854
+ type PostV1AuthSignInBody = {
855
+ type: "password";
856
+ email: string;
857
+ password: string;
858
+ } | {
859
+ type: "oauth";
860
+ code: string;
861
+ verifier: string;
862
+ } | {
863
+ type: "email_otp";
864
+ /** @pattern ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$ */
865
+ email: string;
866
+ /** @minLength 1 */
867
+ token: string;
868
+ };
869
+
870
+ /**
871
+ * Generated by orval v8.1.0 🍺
872
+ * Do not edit manually.
873
+ * Avallon API
874
+ * OpenAPI spec version: 1.0.0
875
+ */
876
+ type PostV1AuthSignUp200Data = {
877
+ [key: string]: unknown;
878
+ };
879
+
880
+ /**
881
+ * Generated by orval v8.1.0 🍺
882
+ * Do not edit manually.
883
+ * Avallon API
884
+ * OpenAPI spec version: 1.0.0
885
+ */
886
+
887
+ type PostV1AuthSignUp200 = {
888
+ data: PostV1AuthSignUp200Data;
889
+ message: string;
890
+ };
891
+
892
+ /**
893
+ * Generated by orval v8.1.0 🍺
894
+ * Do not edit manually.
895
+ * Avallon API
896
+ * OpenAPI spec version: 1.0.0
897
+ */
898
+ type PostV1AuthSignUpBody = {
899
+ /** @pattern ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$ */
900
+ email: string;
901
+ password: string;
902
+ };
903
+
904
+ type SecondParameter$1<T extends (...args: never) => unknown> = Parameters<T>[1];
905
+ /**
906
+ * List all agents for your tenant.
907
+
908
+ **Filtering:**
909
+
910
+ Filter agents by name using the `agent_name` query parameter (exact match).
911
+
912
+ **Response:**
913
+
914
+ Returns an array of all agents with their configurations and a total count.
915
+ * @summary List agents
916
+ */
917
+ type listAgentsResponse200 = {
918
+ data: ListAgents200;
919
+ status: 200;
920
+ };
921
+ type listAgentsResponse400 = {
922
+ data: ErrorResponse;
923
+ status: 400;
924
+ };
925
+ type listAgentsResponse401 = {
926
+ data: ErrorResponse;
927
+ status: 401;
928
+ };
929
+ type listAgentsResponse500 = {
930
+ data: ErrorResponse;
931
+ status: 500;
932
+ };
933
+ type listAgentsResponseSuccess = listAgentsResponse200 & {
934
+ headers: Headers;
935
+ };
936
+ type listAgentsResponseError = (listAgentsResponse400 | listAgentsResponse401 | listAgentsResponse500) & {
937
+ headers: Headers;
938
+ };
939
+ type listAgentsResponse = listAgentsResponseSuccess | listAgentsResponseError;
940
+ declare const getListAgentsUrl: (params?: ListAgentsParams) => string;
941
+ declare const listAgents: (params?: ListAgentsParams, options?: RequestInit) => Promise<listAgentsResponse>;
942
+ declare const getListAgentsKey: (params?: ListAgentsParams) => readonly ["/v1/agents", ...ListAgentsParams[]];
943
+ type ListAgentsQueryResult = NonNullable<Awaited<ReturnType<typeof listAgents>>>;
944
+ /**
945
+ * @summary List agents
946
+ */
947
+ declare const useListAgents: <TError = ErrorResponse>(params?: ListAgentsParams, options?: {
948
+ swr?: SWRConfiguration<Awaited<ReturnType<typeof listAgents>>, TError> & {
949
+ swrKey?: Key;
950
+ enabled?: boolean;
951
+ };
952
+ request?: SecondParameter$1<typeof customFetch>;
953
+ }) => {
954
+ data: listAgentsResponse | undefined;
955
+ error: TError | undefined;
956
+ mutate: swr.KeyedMutator<listAgentsResponse>;
957
+ isValidating: boolean;
958
+ isLoading: swr__internal.IsLoadingResponse<Data, Config>;
959
+ swrKey: string | false | readonly [any, ...unknown[]] | Record<any, any> | (() => swr.Arguments);
960
+ };
961
+ /**
962
+ * Create a new voice agent with the specified configuration.
963
+
964
+ **Required fields:**
965
+
966
+ All fields in the request body are required except `phone_number_id` and `transfer_phone_number`.
967
+
968
+ **Response:**
969
+
970
+ Returns the created agent with its ID and configuration.
971
+ * @summary Create agent
972
+ */
973
+ type createAgentResponse200 = {
974
+ data: CreateAgent200;
975
+ status: 200;
976
+ };
977
+ type createAgentResponse400 = {
978
+ data: ErrorResponse;
979
+ status: 400;
980
+ };
981
+ type createAgentResponse401 = {
982
+ data: ErrorResponse;
983
+ status: 401;
984
+ };
985
+ type createAgentResponse500 = {
986
+ data: ErrorResponse;
987
+ status: 500;
988
+ };
989
+ type createAgentResponseSuccess = createAgentResponse200 & {
990
+ headers: Headers;
991
+ };
992
+ type createAgentResponseError = (createAgentResponse400 | createAgentResponse401 | createAgentResponse500) & {
993
+ headers: Headers;
994
+ };
995
+ type createAgentResponse = createAgentResponseSuccess | createAgentResponseError;
996
+ declare const getCreateAgentUrl: () => string;
997
+ declare const createAgent: (createAgentBody: CreateAgentBody, options?: RequestInit) => Promise<createAgentResponse>;
998
+ declare const getCreateAgentMutationFetcher: (options?: SecondParameter$1<typeof customFetch>) => (_: Key, { arg }: {
999
+ arg: CreateAgentBody;
1000
+ }) => Promise<createAgentResponse>;
1001
+ declare const getCreateAgentMutationKey: () => readonly ["/v1/agents"];
1002
+ type CreateAgentMutationResult = NonNullable<Awaited<ReturnType<typeof createAgent>>>;
1003
+ /**
1004
+ * @summary Create agent
1005
+ */
1006
+ declare const useCreateAgent: <TError = ErrorResponse>(options?: {
1007
+ swr?: SWRMutationConfiguration<Awaited<ReturnType<typeof createAgent>>, TError, Key, CreateAgentBody, Awaited<ReturnType<typeof createAgent>>> & {
1008
+ swrKey?: string;
1009
+ };
1010
+ request?: SecondParameter$1<typeof customFetch>;
1011
+ }) => {
1012
+ isMutating: boolean;
1013
+ trigger: swr_mutation.TriggerWithArgs<createAgentResponse, TError, string | readonly ["/v1/agents"], CreateAgentBody>;
1014
+ reset: () => void;
1015
+ error: TError | undefined;
1016
+ data: createAgentResponse | undefined;
1017
+ swrKey: string | readonly ["/v1/agents"];
1018
+ };
1019
+ /**
1020
+ * Retrieve a single agent by ID.
1021
+ * @summary Get agent
1022
+ */
1023
+ type getAgentResponse200 = {
1024
+ data: GetAgent200;
1025
+ status: 200;
1026
+ };
1027
+ type getAgentResponse400 = {
1028
+ data: ErrorResponse;
1029
+ status: 400;
1030
+ };
1031
+ type getAgentResponse401 = {
1032
+ data: ErrorResponse;
1033
+ status: 401;
1034
+ };
1035
+ type getAgentResponse404 = {
1036
+ data: ErrorResponse;
1037
+ status: 404;
1038
+ };
1039
+ type getAgentResponse500 = {
1040
+ data: ErrorResponse;
1041
+ status: 500;
1042
+ };
1043
+ type getAgentResponseSuccess = getAgentResponse200 & {
1044
+ headers: Headers;
1045
+ };
1046
+ type getAgentResponseError = (getAgentResponse400 | getAgentResponse401 | getAgentResponse404 | getAgentResponse500) & {
1047
+ headers: Headers;
1048
+ };
1049
+ type getAgentResponse = getAgentResponseSuccess | getAgentResponseError;
1050
+ declare const getGetAgentUrl: (id: string) => string;
1051
+ declare const getAgent: (id: string, options?: RequestInit) => Promise<getAgentResponse>;
1052
+ declare const getGetAgentKey: (id: string) => readonly [`/v1/agents/${string}`];
1053
+ type GetAgentQueryResult = NonNullable<Awaited<ReturnType<typeof getAgent>>>;
1054
+ /**
1055
+ * @summary Get agent
1056
+ */
1057
+ declare const useGetAgent: <TError = ErrorResponse>(id: string, options?: {
1058
+ swr?: SWRConfiguration<Awaited<ReturnType<typeof getAgent>>, TError> & {
1059
+ swrKey?: Key;
1060
+ enabled?: boolean;
1061
+ };
1062
+ request?: SecondParameter$1<typeof customFetch>;
1063
+ }) => {
1064
+ data: getAgentResponse | undefined;
1065
+ error: TError | undefined;
1066
+ mutate: swr.KeyedMutator<getAgentResponse>;
1067
+ isValidating: boolean;
1068
+ isLoading: swr__internal.IsLoadingResponse<Data, Config>;
1069
+ swrKey: string | false | readonly [any, ...unknown[]] | Record<any, any> | (() => swr.Arguments);
1070
+ };
1071
+
1072
+ type SecondParameter<T extends (...args: never) => unknown> = Parameters<T>[1];
1073
+ type postV1AuthSignUpResponse200 = {
1074
+ data: PostV1AuthSignUp200;
1075
+ status: 200;
1076
+ };
1077
+ type postV1AuthSignUpResponse400 = {
1078
+ data: ErrorResponse;
1079
+ status: 400;
1080
+ };
1081
+ type postV1AuthSignUpResponse401 = {
1082
+ data: ErrorResponse;
1083
+ status: 401;
1084
+ };
1085
+ type postV1AuthSignUpResponse500 = {
1086
+ data: ErrorResponse;
1087
+ status: 500;
1088
+ };
1089
+ type postV1AuthSignUpResponseSuccess = postV1AuthSignUpResponse200 & {
1090
+ headers: Headers;
1091
+ };
1092
+ type postV1AuthSignUpResponseError = (postV1AuthSignUpResponse400 | postV1AuthSignUpResponse401 | postV1AuthSignUpResponse500) & {
1093
+ headers: Headers;
1094
+ };
1095
+ type postV1AuthSignUpResponse = postV1AuthSignUpResponseSuccess | postV1AuthSignUpResponseError;
1096
+ declare const getPostV1AuthSignUpUrl: () => string;
1097
+ declare const postV1AuthSignUp: (postV1AuthSignUpBody: PostV1AuthSignUpBody, options?: RequestInit) => Promise<postV1AuthSignUpResponse>;
1098
+ declare const getPostV1AuthSignUpMutationFetcher: (options?: SecondParameter<typeof customFetchNoAuth>) => (_: Key, { arg }: {
1099
+ arg: PostV1AuthSignUpBody;
1100
+ }) => Promise<postV1AuthSignUpResponse>;
1101
+ declare const getPostV1AuthSignUpMutationKey: () => readonly ["/v1/auth/sign-up"];
1102
+ type PostV1AuthSignUpMutationResult = NonNullable<Awaited<ReturnType<typeof postV1AuthSignUp>>>;
1103
+ declare const usePostV1AuthSignUp: <TError = ErrorResponse>(options?: {
1104
+ swr?: SWRMutationConfiguration<Awaited<ReturnType<typeof postV1AuthSignUp>>, TError, Key, PostV1AuthSignUpBody, Awaited<ReturnType<typeof postV1AuthSignUp>>> & {
1105
+ swrKey?: string;
1106
+ };
1107
+ request?: SecondParameter<typeof customFetchNoAuth>;
1108
+ }) => {
1109
+ isMutating: boolean;
1110
+ trigger: swr_mutation.TriggerWithArgs<postV1AuthSignUpResponse, TError, string | readonly ["/v1/auth/sign-up"], PostV1AuthSignUpBody>;
1111
+ reset: () => void;
1112
+ error: TError | undefined;
1113
+ data: postV1AuthSignUpResponse | undefined;
1114
+ swrKey: string | readonly ["/v1/auth/sign-up"];
1115
+ };
1116
+ type postV1AuthSignInResponse200 = {
1117
+ data: PostV1AuthSignIn200;
1118
+ status: 200;
1119
+ };
1120
+ type postV1AuthSignInResponse400 = {
1121
+ data: ErrorResponse;
1122
+ status: 400;
1123
+ };
1124
+ type postV1AuthSignInResponse401 = {
1125
+ data: ErrorResponse;
1126
+ status: 401;
1127
+ };
1128
+ type postV1AuthSignInResponse500 = {
1129
+ data: ErrorResponse;
1130
+ status: 500;
1131
+ };
1132
+ type postV1AuthSignInResponseSuccess = postV1AuthSignInResponse200 & {
1133
+ headers: Headers;
1134
+ };
1135
+ type postV1AuthSignInResponseError = (postV1AuthSignInResponse400 | postV1AuthSignInResponse401 | postV1AuthSignInResponse500) & {
1136
+ headers: Headers;
1137
+ };
1138
+ type postV1AuthSignInResponse = postV1AuthSignInResponseSuccess | postV1AuthSignInResponseError;
1139
+ declare const getPostV1AuthSignInUrl: () => string;
1140
+ declare const postV1AuthSignIn: (postV1AuthSignInBody: PostV1AuthSignInBody, options?: RequestInit) => Promise<postV1AuthSignInResponse>;
1141
+ declare const getPostV1AuthSignInMutationFetcher: (options?: SecondParameter<typeof customFetchNoAuth>) => (_: Key, { arg }: {
1142
+ arg: PostV1AuthSignInBody;
1143
+ }) => Promise<postV1AuthSignInResponse>;
1144
+ declare const getPostV1AuthSignInMutationKey: () => readonly ["/v1/auth/sign-in"];
1145
+ type PostV1AuthSignInMutationResult = NonNullable<Awaited<ReturnType<typeof postV1AuthSignIn>>>;
1146
+ declare const usePostV1AuthSignIn: <TError = ErrorResponse>(options?: {
1147
+ swr?: SWRMutationConfiguration<Awaited<ReturnType<typeof postV1AuthSignIn>>, TError, Key, PostV1AuthSignInBody, Awaited<ReturnType<typeof postV1AuthSignIn>>> & {
1148
+ swrKey?: string;
1149
+ };
1150
+ request?: SecondParameter<typeof customFetchNoAuth>;
1151
+ }) => {
1152
+ isMutating: boolean;
1153
+ trigger: swr_mutation.TriggerWithArgs<postV1AuthSignInResponse, TError, string | readonly ["/v1/auth/sign-in"], PostV1AuthSignInBody>;
1154
+ reset: () => void;
1155
+ error: TError | undefined;
1156
+ data: postV1AuthSignInResponse | undefined;
1157
+ swrKey: string | readonly ["/v1/auth/sign-in"];
1158
+ };
1159
+ type postV1AuthRefreshTokenResponse200 = {
1160
+ data: PostV1AuthRefreshToken200;
1161
+ status: 200;
1162
+ };
1163
+ type postV1AuthRefreshTokenResponse400 = {
1164
+ data: ErrorResponse;
1165
+ status: 400;
1166
+ };
1167
+ type postV1AuthRefreshTokenResponse401 = {
1168
+ data: ErrorResponse;
1169
+ status: 401;
1170
+ };
1171
+ type postV1AuthRefreshTokenResponse500 = {
1172
+ data: ErrorResponse;
1173
+ status: 500;
1174
+ };
1175
+ type postV1AuthRefreshTokenResponseSuccess = postV1AuthRefreshTokenResponse200 & {
1176
+ headers: Headers;
1177
+ };
1178
+ type postV1AuthRefreshTokenResponseError = (postV1AuthRefreshTokenResponse400 | postV1AuthRefreshTokenResponse401 | postV1AuthRefreshTokenResponse500) & {
1179
+ headers: Headers;
1180
+ };
1181
+ type postV1AuthRefreshTokenResponse = postV1AuthRefreshTokenResponseSuccess | postV1AuthRefreshTokenResponseError;
1182
+ declare const getPostV1AuthRefreshTokenUrl: () => string;
1183
+ declare const postV1AuthRefreshToken: (postV1AuthRefreshTokenBody: PostV1AuthRefreshTokenBody, options?: RequestInit) => Promise<postV1AuthRefreshTokenResponse>;
1184
+ declare const getPostV1AuthRefreshTokenMutationFetcher: (options?: SecondParameter<typeof customFetchNoAuth>) => (_: Key, { arg }: {
1185
+ arg: PostV1AuthRefreshTokenBody;
1186
+ }) => Promise<postV1AuthRefreshTokenResponse>;
1187
+ declare const getPostV1AuthRefreshTokenMutationKey: () => readonly ["/v1/auth/refresh-token"];
1188
+ type PostV1AuthRefreshTokenMutationResult = NonNullable<Awaited<ReturnType<typeof postV1AuthRefreshToken>>>;
1189
+ declare const usePostV1AuthRefreshToken: <TError = ErrorResponse>(options?: {
1190
+ swr?: SWRMutationConfiguration<Awaited<ReturnType<typeof postV1AuthRefreshToken>>, TError, Key, PostV1AuthRefreshTokenBody, Awaited<ReturnType<typeof postV1AuthRefreshToken>>> & {
1191
+ swrKey?: string;
1192
+ };
1193
+ request?: SecondParameter<typeof customFetchNoAuth>;
1194
+ }) => {
1195
+ isMutating: boolean;
1196
+ trigger: swr_mutation.TriggerWithArgs<postV1AuthRefreshTokenResponse, TError, string | readonly ["/v1/auth/refresh-token"], PostV1AuthRefreshTokenBody>;
1197
+ reset: () => void;
1198
+ error: TError | undefined;
1199
+ data: postV1AuthRefreshTokenResponse | undefined;
1200
+ swrKey: string | readonly ["/v1/auth/refresh-token"];
1201
+ };
1202
+ type getV1AuthOauthUrlResponse200 = {
1203
+ data: GetV1AuthOauthUrl200;
1204
+ status: 200;
1205
+ };
1206
+ type getV1AuthOauthUrlResponse400 = {
1207
+ data: ErrorResponse;
1208
+ status: 400;
1209
+ };
1210
+ type getV1AuthOauthUrlResponse401 = {
1211
+ data: ErrorResponse;
1212
+ status: 401;
1213
+ };
1214
+ type getV1AuthOauthUrlResponse500 = {
1215
+ data: ErrorResponse;
1216
+ status: 500;
1217
+ };
1218
+ type getV1AuthOauthUrlResponseSuccess = getV1AuthOauthUrlResponse200 & {
1219
+ headers: Headers;
1220
+ };
1221
+ type getV1AuthOauthUrlResponseError = (getV1AuthOauthUrlResponse400 | getV1AuthOauthUrlResponse401 | getV1AuthOauthUrlResponse500) & {
1222
+ headers: Headers;
1223
+ };
1224
+ type getV1AuthOauthUrlResponse = getV1AuthOauthUrlResponseSuccess | getV1AuthOauthUrlResponseError;
1225
+ declare const getGetV1AuthOauthUrlUrl: (params: GetV1AuthOauthUrlParams) => string;
1226
+ declare const getV1AuthOauthUrl: (params: GetV1AuthOauthUrlParams, options?: RequestInit) => Promise<getV1AuthOauthUrlResponse>;
1227
+ declare const getGetV1AuthOauthUrlKey: (params: GetV1AuthOauthUrlParams) => readonly ["/v1/auth/oauth-url", ...GetV1AuthOauthUrlParams[]];
1228
+ type GetV1AuthOauthUrlQueryResult = NonNullable<Awaited<ReturnType<typeof getV1AuthOauthUrl>>>;
1229
+ declare const useGetV1AuthOauthUrl: <TError = ErrorResponse>(params: GetV1AuthOauthUrlParams, options?: {
1230
+ swr?: SWRConfiguration<Awaited<ReturnType<typeof getV1AuthOauthUrl>>, TError> & {
1231
+ swrKey?: Key;
1232
+ enabled?: boolean;
1233
+ };
1234
+ request?: SecondParameter<typeof customFetchNoAuth>;
1235
+ }) => {
1236
+ data: getV1AuthOauthUrlResponse | undefined;
1237
+ error: TError | undefined;
1238
+ mutate: swr.KeyedMutator<getV1AuthOauthUrlResponse>;
1239
+ isValidating: boolean;
1240
+ isLoading: swr__internal.IsLoadingResponse<Data, Config>;
1241
+ swrKey: string | false | readonly [any, ...unknown[]] | Record<any, any> | (() => swr.Arguments);
1242
+ };
1243
+
1244
+ export { type AvallonConfig, AvallonError, type CreateAgent200, type CreateAgent200Data, type CreateAgent200DataAgent, CreateAgent200DataAgentBackgroundSounds, CreateAgent200DataAgentDirection, CreateAgent200DataAgentLanguage, CreateAgent200DataAgentLlmModel, CreateAgent200DataAgentSttModel, CreateAgent200DataAgentTtsModel, CreateAgent200DataAgentTtsProvider, type CreateAgentBody, CreateAgentBodyDirection, CreateAgentBodyLanguage, CreateAgentBodyLlmModel, CreateAgentBodySttModel, CreateAgentBodyTtsModel, CreateAgentBodyTtsProvider, type CreateAgentMutationResult, type ErrorResponse, type ErrorResponseData, type GetAgent200, type GetAgent200Data, type GetAgent200DataAgent, GetAgent200DataAgentBackgroundSounds, GetAgent200DataAgentDirection, GetAgent200DataAgentLanguage, GetAgent200DataAgentLlmModel, GetAgent200DataAgentSttModel, GetAgent200DataAgentTtsModel, GetAgent200DataAgentTtsProvider, type GetAgentQueryResult, type GetV1AuthOauthUrl200, type GetV1AuthOauthUrl200Data, GetV1AuthOauthUrlCodeChallengeMethod, type GetV1AuthOauthUrlParams, GetV1AuthOauthUrlProvider, type GetV1AuthOauthUrlQueryResult, type ListAgents200, type ListAgents200Data, type ListAgents200DataAgentsItem, ListAgents200DataAgentsItemBackgroundSounds, ListAgents200DataAgentsItemDirection, ListAgents200DataAgentsItemLanguage, ListAgents200DataAgentsItemLlmModel, ListAgents200DataAgentsItemSttModel, ListAgents200DataAgentsItemTtsModel, ListAgents200DataAgentsItemTtsProvider, type ListAgentsParams, type ListAgentsQueryResult, type PostV1AuthRefreshToken200, type PostV1AuthRefreshToken200Data, type PostV1AuthRefreshTokenBody, type PostV1AuthRefreshTokenMutationResult, type PostV1AuthSignIn200, type PostV1AuthSignIn200Data, type PostV1AuthSignInBody, type PostV1AuthSignInMutationResult, type PostV1AuthSignUp200, type PostV1AuthSignUp200Data, type PostV1AuthSignUpBody, type PostV1AuthSignUpMutationResult, configure, createAgent, type createAgentResponse, type createAgentResponse200, type createAgentResponse400, type createAgentResponse401, type createAgentResponse500, type createAgentResponseError, type createAgentResponseSuccess, generateCodeChallenge, generateCodeVerifier, getAgent, type getAgentResponse, type getAgentResponse200, type getAgentResponse400, type getAgentResponse401, type getAgentResponse404, type getAgentResponse500, type getAgentResponseError, type getAgentResponseSuccess, getConfig, getCreateAgentMutationFetcher, getCreateAgentMutationKey, getCreateAgentUrl, getGetAgentKey, getGetAgentUrl, getGetV1AuthOauthUrlKey, getGetV1AuthOauthUrlUrl, getListAgentsKey, getListAgentsUrl, getPostV1AuthRefreshTokenMutationFetcher, getPostV1AuthRefreshTokenMutationKey, getPostV1AuthRefreshTokenUrl, getPostV1AuthSignInMutationFetcher, getPostV1AuthSignInMutationKey, getPostV1AuthSignInUrl, getPostV1AuthSignUpMutationFetcher, getPostV1AuthSignUpMutationKey, getPostV1AuthSignUpUrl, getV1AuthOauthUrl, type getV1AuthOauthUrlResponse, type getV1AuthOauthUrlResponse200, type getV1AuthOauthUrlResponse400, type getV1AuthOauthUrlResponse401, type getV1AuthOauthUrlResponse500, type getV1AuthOauthUrlResponseError, type getV1AuthOauthUrlResponseSuccess, listAgents, type listAgentsResponse, type listAgentsResponse200, type listAgentsResponse400, type listAgentsResponse401, type listAgentsResponse500, type listAgentsResponseError, type listAgentsResponseSuccess, postV1AuthRefreshToken, type postV1AuthRefreshTokenResponse, type postV1AuthRefreshTokenResponse200, type postV1AuthRefreshTokenResponse400, type postV1AuthRefreshTokenResponse401, type postV1AuthRefreshTokenResponse500, type postV1AuthRefreshTokenResponseError, type postV1AuthRefreshTokenResponseSuccess, postV1AuthSignIn, type postV1AuthSignInResponse, type postV1AuthSignInResponse200, type postV1AuthSignInResponse400, type postV1AuthSignInResponse401, type postV1AuthSignInResponse500, type postV1AuthSignInResponseError, type postV1AuthSignInResponseSuccess, postV1AuthSignUp, type postV1AuthSignUpResponse, type postV1AuthSignUpResponse200, type postV1AuthSignUpResponse400, type postV1AuthSignUpResponse401, type postV1AuthSignUpResponse500, type postV1AuthSignUpResponseError, type postV1AuthSignUpResponseSuccess, useCreateAgent, useGetAgent, useGetV1AuthOauthUrl, useListAgents, usePostV1AuthRefreshToken, usePostV1AuthSignIn, usePostV1AuthSignUp };