audiopod 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,780 @@
1
+ /**
2
+ * AudioPod SDK Type Definitions
3
+ */
4
+ type JobStatus = "PENDING" | "PROCESSING" | "COMPLETED" | "FAILED" | "CANCELLED";
5
+ interface PaginationParams {
6
+ skip?: number;
7
+ limit?: number;
8
+ }
9
+ interface TranscriptionCreateParams {
10
+ urls?: string[];
11
+ url?: string;
12
+ language?: string;
13
+ speakerDiarization?: boolean;
14
+ minSpeakers?: number;
15
+ maxSpeakers?: number;
16
+ wordTimestamps?: boolean;
17
+ }
18
+ interface TranscriptionSegment {
19
+ id: number;
20
+ start: number;
21
+ end: number;
22
+ text: string;
23
+ speaker_label?: string;
24
+ confidence?: number;
25
+ }
26
+ interface TranscriptionJob {
27
+ id: number;
28
+ job_id?: number;
29
+ status: JobStatus;
30
+ source_urls?: string[];
31
+ language?: string;
32
+ detected_language?: string;
33
+ transcript_path?: string;
34
+ total_duration?: number;
35
+ estimated_duration?: number;
36
+ estimated_credits?: number;
37
+ error_message?: string;
38
+ created_at?: string;
39
+ completed_at?: string;
40
+ display_name?: string;
41
+ }
42
+ interface Voice$1 {
43
+ id: number;
44
+ name: string;
45
+ description?: string;
46
+ preview_url?: string;
47
+ is_public?: boolean;
48
+ created_at?: string;
49
+ }
50
+ interface VoiceCreateParams {
51
+ name: string;
52
+ audioFile: string;
53
+ description?: string;
54
+ }
55
+ interface TTSCreateParams {
56
+ text: string;
57
+ voiceId: number;
58
+ speed?: number;
59
+ }
60
+ interface TTSJob {
61
+ id: number;
62
+ status: JobStatus;
63
+ output_url?: string;
64
+ output_path?: string;
65
+ error_message?: string;
66
+ created_at?: string;
67
+ completed_at?: string;
68
+ }
69
+ type MusicTask = "text2music" | "prompt2instrumental" | "lyric2vocals" | "text2rap" | "text2samples" | "audio2audio" | "songbloom";
70
+ interface MusicCreateParams {
71
+ prompt: string;
72
+ lyrics?: string;
73
+ duration?: number;
74
+ task?: MusicTask;
75
+ genre?: string;
76
+ displayName?: string;
77
+ }
78
+ interface MusicJob {
79
+ id: number;
80
+ task: MusicTask;
81
+ status: JobStatus;
82
+ output_url?: string;
83
+ output_urls?: Record<string, string>;
84
+ audio_duration?: number;
85
+ display_name?: string;
86
+ thumbnail_url?: string;
87
+ error_message?: string;
88
+ created_at?: string;
89
+ completed_at?: string;
90
+ }
91
+ type StemType = "vocals" | "drums" | "bass" | "other" | "piano" | "guitar" | "kick" | "snare" | "hihat";
92
+ type StemMode = "single" | "two" | "four" | "six" | "producer" | "studio" | "mastering";
93
+ type SingleStem = "vocals" | "drums" | "bass" | "guitar" | "piano" | "other";
94
+ interface StemExtractionParams {
95
+ /** Path to local audio file */
96
+ file?: string;
97
+ /** URL of audio/video (YouTube, SoundCloud, etc.) */
98
+ url?: string;
99
+ /** Separation mode (default: 'four') */
100
+ mode?: StemMode;
101
+ /** For mode='single', which stem to extract */
102
+ stem?: SingleStem;
103
+ }
104
+ interface StemExtractionJob {
105
+ id: number;
106
+ status: JobStatus;
107
+ source_type?: "FILE" | "URL";
108
+ input_path?: string;
109
+ stem_paths?: Record<string, string>;
110
+ stem_types?: StemType[];
111
+ task_id?: string;
112
+ quality_scores?: Record<string, number>;
113
+ download_urls?: Record<string, string>;
114
+ error_message?: string;
115
+ created_at?: string;
116
+ updated_at?: string;
117
+ completed_at?: string;
118
+ original_filename?: string;
119
+ display_name?: string;
120
+ }
121
+ interface StemModeInfo {
122
+ mode: StemMode;
123
+ description: string;
124
+ stem_count: number;
125
+ outputs?: string[];
126
+ note?: string;
127
+ }
128
+ interface ModesResponse {
129
+ modes: StemModeInfo[];
130
+ pricing: string;
131
+ }
132
+ interface DenoiseParams {
133
+ file?: string;
134
+ url?: string;
135
+ }
136
+ interface DenoiseJob {
137
+ id: number;
138
+ status: JobStatus;
139
+ output_url?: string;
140
+ output_path?: string;
141
+ video_output_url?: string;
142
+ is_video?: boolean;
143
+ stats?: Record<string, any>;
144
+ error_message?: string;
145
+ created_at?: string;
146
+ completed_at?: string;
147
+ display_name?: string;
148
+ }
149
+ type SpeakerJobType = "diarization" | "extraction";
150
+ interface SpeakerDiarizeParams {
151
+ file?: string;
152
+ url?: string;
153
+ numSpeakers?: number;
154
+ }
155
+ interface SpeakerSegment {
156
+ speaker: string;
157
+ start: number;
158
+ end: number;
159
+ }
160
+ interface SpeakerJob {
161
+ id: number;
162
+ job_type: SpeakerJobType;
163
+ status: JobStatus;
164
+ num_speakers?: number;
165
+ speakers?: string[];
166
+ segments?: SpeakerSegment[];
167
+ output_path?: string;
168
+ output_url?: string;
169
+ error_message?: string;
170
+ created_at?: string;
171
+ completed_at?: string;
172
+ display_name?: string;
173
+ }
174
+ interface WalletBalance {
175
+ balance_cents: number;
176
+ balance_usd: string;
177
+ total_topup_cents: number;
178
+ total_topup_usd: string;
179
+ total_spent_cents: number;
180
+ total_spent_usd: string;
181
+ low_balance_warning: boolean;
182
+ warning_threshold_cents: number;
183
+ }
184
+ interface UsageLog {
185
+ id: string;
186
+ service_type: string;
187
+ duration_seconds: number;
188
+ duration_minutes: number;
189
+ amount_cents: number;
190
+ amount_usd: string;
191
+ job_id?: string;
192
+ api_key_id?: string;
193
+ created_at?: string;
194
+ }
195
+ interface UsageHistory {
196
+ page: number;
197
+ limit: number;
198
+ logs: UsageLog[];
199
+ }
200
+ interface ServicePricing {
201
+ rate_per_minute: string;
202
+ rate_per_hour: string;
203
+ cents_per_minute: number;
204
+ description: string;
205
+ }
206
+ interface PricingInfo {
207
+ services: Record<string, ServicePricing>;
208
+ wallet: {
209
+ minimum_topup_cents: number;
210
+ maximum_topup_cents: number;
211
+ currency: string;
212
+ };
213
+ }
214
+ interface CostEstimate {
215
+ service_type: string;
216
+ duration_seconds: number;
217
+ cost_cents: number;
218
+ cost_usd: string;
219
+ }
220
+
221
+ /**
222
+ * Transcription Service - Speech-to-Text
223
+ */
224
+
225
+ declare class Transcription {
226
+ private client;
227
+ constructor(client: AudioPod);
228
+ /**
229
+ * Create a transcription job from URL(s)
230
+ *
231
+ * @example
232
+ * ```typescript
233
+ * const job = await client.transcription.create({
234
+ * url: 'https://youtube.com/watch?v=...',
235
+ * speakerDiarization: true,
236
+ * });
237
+ * ```
238
+ */
239
+ create(params: TranscriptionCreateParams): Promise<TranscriptionJob>;
240
+ /**
241
+ * Upload a file for transcription
242
+ *
243
+ * @example
244
+ * ```typescript
245
+ * const job = await client.transcription.upload({
246
+ * file: './audio.mp3',
247
+ * language: 'en',
248
+ * });
249
+ * ```
250
+ */
251
+ upload(params: {
252
+ file: string;
253
+ language?: string;
254
+ speakerDiarization?: boolean;
255
+ }): Promise<TranscriptionJob>;
256
+ /**
257
+ * Get a transcription job by ID
258
+ */
259
+ get(jobId: number): Promise<TranscriptionJob>;
260
+ /**
261
+ * List transcription jobs
262
+ */
263
+ list(params?: PaginationParams & {
264
+ status?: string;
265
+ }): Promise<TranscriptionJob[]>;
266
+ /**
267
+ * Delete a transcription job
268
+ */
269
+ delete(jobId: number): Promise<void>;
270
+ /**
271
+ * Get transcript content
272
+ *
273
+ * @param format - Output format: 'json', 'txt', 'srt', 'vtt'
274
+ */
275
+ getTranscript(jobId: number, format?: 'json' | 'txt' | 'srt' | 'vtt'): Promise<any>;
276
+ /**
277
+ * Wait for a transcription job to complete
278
+ *
279
+ * @example
280
+ * ```typescript
281
+ * const job = await client.transcription.create({ url: '...' });
282
+ * const result = await client.transcription.waitForCompletion(job.id);
283
+ * console.log(result.status); // 'COMPLETED'
284
+ * ```
285
+ */
286
+ waitForCompletion(jobId: number, timeout?: number): Promise<TranscriptionJob>;
287
+ /**
288
+ * Create and wait for completion in one call
289
+ */
290
+ transcribe(params: TranscriptionCreateParams): Promise<TranscriptionJob>;
291
+ }
292
+
293
+ /**
294
+ * Voice Service - Voice Cloning & Text-to-Speech
295
+ */
296
+
297
+ declare class Voice {
298
+ private client;
299
+ constructor(client: AudioPod);
300
+ /**
301
+ * List all voices
302
+ */
303
+ list(): Promise<Voice$1[]>;
304
+ /**
305
+ * Get a voice by ID
306
+ */
307
+ get(voiceId: number): Promise<Voice$1>;
308
+ /**
309
+ * Create a new voice clone
310
+ *
311
+ * @example
312
+ * ```typescript
313
+ * const voice = await client.voice.create({
314
+ * name: 'My Voice',
315
+ * audioFile: './sample.mp3',
316
+ * });
317
+ * ```
318
+ */
319
+ create(params: VoiceCreateParams): Promise<Voice$1>;
320
+ /**
321
+ * Delete a voice
322
+ */
323
+ delete(voiceId: number): Promise<void>;
324
+ /**
325
+ * Generate speech from text
326
+ *
327
+ * @example
328
+ * ```typescript
329
+ * const job = await client.voice.speak({
330
+ * text: 'Hello, world!',
331
+ * voiceId: 123,
332
+ * });
333
+ * ```
334
+ */
335
+ speak(params: TTSCreateParams): Promise<TTSJob>;
336
+ /**
337
+ * Get TTS job status
338
+ */
339
+ getJob(jobId: number): Promise<TTSJob>;
340
+ /**
341
+ * Wait for TTS job to complete
342
+ */
343
+ waitForCompletion(jobId: number, timeout?: number): Promise<TTSJob>;
344
+ /**
345
+ * Generate speech and wait for completion
346
+ */
347
+ generate(params: TTSCreateParams): Promise<TTSJob>;
348
+ }
349
+
350
+ /**
351
+ * Music Service - AI Music Generation
352
+ */
353
+
354
+ declare class Music {
355
+ private client;
356
+ constructor(client: AudioPod);
357
+ /**
358
+ * Generate music from text
359
+ *
360
+ * @example
361
+ * ```typescript
362
+ * const job = await client.music.create({
363
+ * prompt: 'Upbeat electronic dance music',
364
+ * duration: 30,
365
+ * });
366
+ * ```
367
+ */
368
+ create(params: MusicCreateParams): Promise<MusicJob>;
369
+ /**
370
+ * Generate instrumental music
371
+ */
372
+ instrumental(prompt: string, duration?: number): Promise<MusicJob>;
373
+ /**
374
+ * Generate a song with vocals
375
+ */
376
+ song(prompt: string, lyrics: string, duration?: number): Promise<MusicJob>;
377
+ /**
378
+ * Generate rap music
379
+ */
380
+ rap(prompt: string, lyrics: string, duration?: number): Promise<MusicJob>;
381
+ /**
382
+ * Get a music job by ID
383
+ */
384
+ get(jobId: number): Promise<MusicJob>;
385
+ /**
386
+ * List music jobs
387
+ */
388
+ list(params?: PaginationParams & {
389
+ task?: MusicTask;
390
+ status?: string;
391
+ }): Promise<MusicJob[]>;
392
+ /**
393
+ * Delete a music job
394
+ */
395
+ delete(jobId: number): Promise<void>;
396
+ /**
397
+ * Wait for a music job to complete
398
+ */
399
+ waitForCompletion(jobId: number, timeout?: number): Promise<MusicJob>;
400
+ /**
401
+ * Generate music and wait for completion
402
+ */
403
+ generate(params: MusicCreateParams): Promise<MusicJob>;
404
+ /**
405
+ * Get available genre presets
406
+ */
407
+ getPresets(): Promise<any>;
408
+ }
409
+
410
+ /**
411
+ * Stem Extraction Service - Audio Stem Separation
412
+ *
413
+ * Simple mode-based API for separating audio into individual stems.
414
+ */
415
+
416
+ declare class StemExtraction {
417
+ private client;
418
+ constructor(client: AudioPod);
419
+ /**
420
+ * Extract stems from audio using simple mode selection.
421
+ *
422
+ * @param params.file - Path to local audio file (MP3, WAV, FLAC, M4A, OGG)
423
+ * @param params.url - URL of audio/video (YouTube, SoundCloud, direct link)
424
+ * @param params.mode - Separation mode:
425
+ * - "single": Extract one stem (specify stem param)
426
+ * - "two": Vocals + Instrumental
427
+ * - "four": Vocals, Drums, Bass, Other (default)
428
+ * - "six": Vocals, Drums, Bass, Guitar, Piano, Other
429
+ * - "producer": 8 stems with kick, snare, hihat
430
+ * - "studio": 12 stems for professional mixing
431
+ * - "mastering": 16 stems maximum detail
432
+ * @param params.stem - For mode="single", which stem to extract
433
+ *
434
+ * @example
435
+ * ```typescript
436
+ * // From URL with 6 stems
437
+ * const job = await client.stems.extract({
438
+ * url: 'https://youtube.com/watch?v=VIDEO_ID',
439
+ * mode: 'six'
440
+ * });
441
+ *
442
+ * // From file with 4 stems
443
+ * const job = await client.stems.extract({
444
+ * file: './song.mp3',
445
+ * mode: 'four'
446
+ * });
447
+ *
448
+ * // Extract only vocals
449
+ * const job = await client.stems.extract({
450
+ * url: 'https://youtube.com/watch?v=VIDEO_ID',
451
+ * mode: 'single',
452
+ * stem: 'vocals'
453
+ * });
454
+ * ```
455
+ */
456
+ extract(params: StemExtractionParams): Promise<StemExtractionJob>;
457
+ /**
458
+ * Get the status of a stem extraction job.
459
+ *
460
+ * @param jobId - The job ID returned from extract()
461
+ * @returns Job status with download_urls when completed
462
+ *
463
+ * @example
464
+ * ```typescript
465
+ * const status = await client.stems.status(5512);
466
+ * if (status.status === 'COMPLETED') {
467
+ * console.log(status.download_urls);
468
+ * }
469
+ * ```
470
+ */
471
+ status(jobId: number): Promise<StemExtractionJob>;
472
+ /**
473
+ * Get a stem extraction job by ID
474
+ */
475
+ get(jobId: number): Promise<StemExtractionJob>;
476
+ /**
477
+ * List stem extraction jobs
478
+ *
479
+ * @param params.skip - Number of jobs to skip (pagination)
480
+ * @param params.limit - Maximum jobs to return (default: 50)
481
+ * @param params.status - Filter by status
482
+ */
483
+ list(params?: PaginationParams & {
484
+ status?: string;
485
+ }): Promise<StemExtractionJob[]>;
486
+ /**
487
+ * Delete a stem extraction job
488
+ */
489
+ delete(jobId: number): Promise<void>;
490
+ /**
491
+ * Wait for stem extraction to complete.
492
+ *
493
+ * @param jobId - The job ID to wait for
494
+ * @param timeout - Maximum wait time in milliseconds (default: 600000)
495
+ * @returns Completed job with download_urls
496
+ *
497
+ * @example
498
+ * ```typescript
499
+ * const job = await client.stems.extract({ url: '...', mode: 'six' });
500
+ * const result = await client.stems.waitForCompletion(job.id);
501
+ *
502
+ * for (const [stem, url] of Object.entries(result.download_urls)) {
503
+ * console.log(`${stem}: ${url}`);
504
+ * }
505
+ * ```
506
+ */
507
+ waitForCompletion(jobId: number, timeout?: number): Promise<StemExtractionJob>;
508
+ /**
509
+ * Extract stems and wait for completion (convenience method).
510
+ *
511
+ * @example
512
+ * ```typescript
513
+ * // One-liner: extract and wait
514
+ * const result = await client.stems.separate({
515
+ * url: 'https://youtube.com/watch?v=VIDEO_ID',
516
+ * mode: 'six'
517
+ * });
518
+ * console.log(result.download_urls.vocals);
519
+ * ```
520
+ */
521
+ separate(params: StemExtractionParams, timeout?: number): Promise<StemExtractionJob>;
522
+ /**
523
+ * Get available separation modes.
524
+ *
525
+ * @example
526
+ * ```typescript
527
+ * const modes = await client.stems.modes();
528
+ * modes.modes.forEach(m => {
529
+ * console.log(`${m.mode}: ${m.description}`);
530
+ * });
531
+ * ```
532
+ */
533
+ modes(): Promise<ModesResponse>;
534
+ }
535
+
536
+ /**
537
+ * Denoiser Service - Audio Noise Reduction
538
+ */
539
+
540
+ declare class Denoiser {
541
+ private client;
542
+ constructor(client: AudioPod);
543
+ /**
544
+ * Denoise audio/video
545
+ *
546
+ * @example
547
+ * ```typescript
548
+ * // Denoise from file
549
+ * const job = await client.denoiser.create({
550
+ * file: './noisy-audio.mp3',
551
+ * });
552
+ *
553
+ * // Denoise from URL
554
+ * const job = await client.denoiser.create({
555
+ * url: 'https://example.com/audio.mp3',
556
+ * });
557
+ * ```
558
+ */
559
+ create(params: DenoiseParams): Promise<DenoiseJob>;
560
+ /**
561
+ * Get a denoise job by ID
562
+ */
563
+ get(jobId: number): Promise<DenoiseJob>;
564
+ /**
565
+ * List denoise jobs
566
+ */
567
+ list(params?: PaginationParams & {
568
+ status?: string;
569
+ }): Promise<DenoiseJob[]>;
570
+ /**
571
+ * Delete a denoise job
572
+ */
573
+ delete(jobId: number): Promise<void>;
574
+ /**
575
+ * Wait for denoising to complete
576
+ */
577
+ waitForCompletion(jobId: number, timeout?: number): Promise<DenoiseJob>;
578
+ /**
579
+ * Denoise and wait for completion
580
+ */
581
+ denoise(params: DenoiseParams): Promise<DenoiseJob>;
582
+ }
583
+
584
+ /**
585
+ * Speaker Service - Speaker Diarization & Separation
586
+ */
587
+
588
+ declare class Speaker {
589
+ private client;
590
+ constructor(client: AudioPod);
591
+ /**
592
+ * Create a speaker diarization job
593
+ *
594
+ * @example
595
+ * ```typescript
596
+ * // Diarize from file
597
+ * const job = await client.speaker.diarize({
598
+ * file: './meeting.mp3',
599
+ * numSpeakers: 3,
600
+ * });
601
+ *
602
+ * // Diarize from URL
603
+ * const job = await client.speaker.diarize({
604
+ * url: 'https://youtube.com/watch?v=...',
605
+ * });
606
+ * ```
607
+ */
608
+ diarize(params: SpeakerDiarizeParams): Promise<SpeakerJob>;
609
+ /**
610
+ * Get a speaker job by ID
611
+ */
612
+ get(jobId: number): Promise<SpeakerJob>;
613
+ /**
614
+ * List speaker jobs
615
+ */
616
+ list(params?: PaginationParams & {
617
+ status?: string;
618
+ jobType?: string;
619
+ }): Promise<SpeakerJob[]>;
620
+ /**
621
+ * Delete a speaker job
622
+ */
623
+ delete(jobId: number): Promise<void>;
624
+ /**
625
+ * Wait for speaker job to complete
626
+ */
627
+ waitForCompletion(jobId: number, timeout?: number): Promise<SpeakerJob>;
628
+ /**
629
+ * Diarize and wait for completion
630
+ */
631
+ identify(params: SpeakerDiarizeParams): Promise<SpeakerJob>;
632
+ }
633
+
634
+ /**
635
+ * Wallet Service - API Wallet & Billing
636
+ */
637
+
638
+ declare class Wallet {
639
+ private client;
640
+ constructor(client: AudioPod);
641
+ /**
642
+ * Get current wallet balance
643
+ *
644
+ * @example
645
+ * ```typescript
646
+ * const balance = await client.wallet.getBalance();
647
+ * console.log(`Balance: ${balance.balance_usd}`);
648
+ * ```
649
+ */
650
+ getBalance(): Promise<WalletBalance>;
651
+ /**
652
+ * Get usage history
653
+ */
654
+ getUsage(params?: {
655
+ page?: number;
656
+ limit?: number;
657
+ apiKeyId?: string;
658
+ }): Promise<UsageHistory>;
659
+ /**
660
+ * Get pricing information for all services
661
+ */
662
+ getPricing(): Promise<PricingInfo>;
663
+ /**
664
+ * Estimate cost for an operation
665
+ *
666
+ * @example
667
+ * ```typescript
668
+ * const estimate = await client.wallet.estimateCost({
669
+ * serviceType: 'stem_extraction',
670
+ * durationSeconds: 300,
671
+ * });
672
+ * console.log(`Estimated cost: ${estimate.cost_usd}`);
673
+ * ```
674
+ */
675
+ estimateCost(params: {
676
+ serviceType: string;
677
+ durationSeconds: number;
678
+ }): Promise<CostEstimate>;
679
+ /**
680
+ * Check if balance is sufficient for an operation
681
+ */
682
+ checkBalance(params: {
683
+ serviceType: string;
684
+ durationSeconds: number;
685
+ }): Promise<{
686
+ sufficient: boolean;
687
+ cost: CostEstimate;
688
+ }>;
689
+ }
690
+
691
+ /**
692
+ * AudioPod API Client
693
+ *
694
+ * Clean, minimal API inspired by OpenAI's SDK design.
695
+ */
696
+
697
+ interface AudioPodOptions {
698
+ /** Your AudioPod API key (starts with 'ap_') */
699
+ apiKey?: string;
700
+ /** Base URL for the API (default: https://api.audiopod.ai) */
701
+ baseUrl?: string;
702
+ /** Request timeout in milliseconds (default: 60000) */
703
+ timeout?: number;
704
+ /** Maximum retries for failed requests (default: 2) */
705
+ maxRetries?: number;
706
+ }
707
+ declare class AudioPod {
708
+ private _axios;
709
+ private _apiKey;
710
+ /** Speech-to-text transcription */
711
+ readonly transcription: Transcription;
712
+ /** Voice cloning and text-to-speech */
713
+ readonly voice: Voice;
714
+ /** AI music generation */
715
+ readonly music: Music;
716
+ /** Audio stem separation */
717
+ readonly stems: StemExtraction;
718
+ /** Audio noise reduction */
719
+ readonly denoiser: Denoiser;
720
+ /** Speaker diarization and separation */
721
+ readonly speaker: Speaker;
722
+ /** API wallet and billing */
723
+ readonly wallet: Wallet;
724
+ constructor(options?: AudioPodOptions);
725
+ private _handleError;
726
+ /** @internal Make a GET request */
727
+ get<T = any>(endpoint: string, params?: Record<string, any>): Promise<T>;
728
+ /** @internal Make a POST request */
729
+ post<T = any>(endpoint: string, data?: any): Promise<T>;
730
+ /** @internal Make a POST request with form data (non-file) */
731
+ postForm<T = any>(endpoint: string, data: Record<string, any>): Promise<T>;
732
+ /** @internal Make a DELETE request */
733
+ delete<T = any>(endpoint: string): Promise<T>;
734
+ /** @internal Upload a file */
735
+ upload<T = any>(endpoint: string, filePath: string, fieldName?: string, additionalFields?: Record<string, any>): Promise<T>;
736
+ /** @internal Upload with buffer */
737
+ uploadBuffer<T = any>(endpoint: string, buffer: Buffer, filename: string, fieldName?: string, additionalFields?: Record<string, any>): Promise<T>;
738
+ }
739
+
740
+ /**
741
+ * AudioPod SDK Error Classes
742
+ */
743
+ declare class AudioPodError extends Error {
744
+ constructor(message: string);
745
+ }
746
+ declare class AuthenticationError extends AudioPodError {
747
+ constructor(message?: string);
748
+ }
749
+ declare class APIError extends AudioPodError {
750
+ statusCode?: number;
751
+ constructor(message: string, statusCode?: number);
752
+ }
753
+ declare class RateLimitError extends AudioPodError {
754
+ constructor(message?: string);
755
+ }
756
+ declare class InsufficientBalanceError extends AudioPodError {
757
+ requiredCents?: number;
758
+ availableCents?: number;
759
+ constructor(message?: string, requiredCents?: number, availableCents?: number);
760
+ }
761
+
762
+ /**
763
+ * AudioPod SDK for Node.js
764
+ * Professional Audio Processing powered by AI
765
+ *
766
+ * @example
767
+ * ```typescript
768
+ * import AudioPod from 'audiopod';
769
+ *
770
+ * const client = new AudioPod({ apiKey: 'ap_...' });
771
+ *
772
+ * // Transcribe audio
773
+ * const job = await client.transcription.create({ url: 'https://...' });
774
+ * const result = await client.transcription.waitForCompletion(job.id);
775
+ * ```
776
+ */
777
+
778
+ declare const VERSION = "2.1.0";
779
+
780
+ export { APIError, AudioPod, AudioPodError, type AudioPodOptions, AuthenticationError, type DenoiseJob, type DenoiseParams, InsufficientBalanceError, type ModesResponse, type MusicCreateParams, type MusicJob, RateLimitError, type SingleStem, type SpeakerDiarizeParams, type SpeakerJob, type StemExtractionJob, type StemExtractionParams, type StemMode, type StemModeInfo, type StemType, type TTSCreateParams, type TTSJob, type TranscriptionCreateParams, type TranscriptionJob, type TranscriptionSegment, type UsageLog, VERSION, type Voice$1 as Voice, type VoiceCreateParams, type WalletBalance, AudioPod as default };