import { AbstractTTSClient } from "../core/abstract-tts"; import type { SpeakOptions, TTSCredentials, UnifiedVoice } from "../types"; export interface CartesiaTTSOptions extends SpeakOptions { model?: string; voice?: string; format?: "mp3" | "wav" | "ogg" | "opus" | "aac" | "flac" | "pcm"; outputDir?: string; outputFile?: string; returnWordBoundaries?: boolean; onEnd?: () => void; providerOptions?: Record; } export interface CartesiaTTSCredentials extends TTSCredentials { apiKey?: string; baseURL?: string; model?: string; properties?: Record | string; propertiesJson?: string; } export declare class CartesiaTTSClient extends AbstractTTSClient { private apiKey; private baseUrl; private model; private outputFormat; constructor(credentials?: CartesiaTTSCredentials); private applyCredentialProperties; private processAudioTags; private prepareText; setModel(model: string): void; setVoice(voiceId: string): void; getProperty(property: string): any; setProperty(property: string, value: any): void; checkCredentials(): Promise; protected getRequiredCredentials(): string[]; protected _getVoices(): Promise; protected _mapVoicesToUnified(rawVoices: any[]): Promise; synthToBytes(text: string, options?: CartesiaTTSOptions): Promise; synthToBytestream(text: string, options?: CartesiaTTSOptions): Promise<{ audioStream: ReadableStream; wordBoundaries: Array<{ text: string; offset: number; duration: number; }>; }>; }