import { Journal } from "./journal.js";
import { AudioResponse, ChaosConfig, EmbeddingFixtureOpts, FalQueueOpts, Fixture, FixtureFileEntry, FixtureFileResponse, FixtureMatch, FixtureOpts, ImageResponse, JournalEntry, MockServerOptions, Mountable, RecordConfig, ResponseFactory, TranscriptionResponse, VideoResponse } from "./types.js";
import { SearchResult } from "./search.js";
import { RerankResult } from "./rerank.js";
import { ModerationResult } from "./moderation.js";

//#region src/llmock.d.ts
declare class LLMock {
  private fixtures;
  private searchFixtures;
  private rerankFixtures;
  private moderationFixtures;
  private mounts;
  private serverInstance;
  private options;
  constructor(options?: MockServerOptions);
  addFixture(fixture: Fixture): this;
  addFixtures(fixtures: Fixture[]): this;
  prependFixture(fixture: Fixture): this;
  getFixtures(): readonly Fixture[];
  loadFixtureFile(filePath: string): this;
  loadFixtureDir(dirPath: string): this;
  /**
   * Add fixtures from a JSON string or pre-parsed array of fixture entries.
   * Validates all fixtures and throws if any have severity "error".
   */
  addFixturesFromJSON(input: string | FixtureFileEntry[]): this;
  clearFixtures(): this;
  on(match: FixtureMatch, response: FixtureFileResponse | ResponseFactory, opts?: FixtureOpts): this;
  onMessage(pattern: string | RegExp, response: FixtureFileResponse | ResponseFactory, opts?: FixtureOpts): this;
  onEmbedding(pattern: string | RegExp, response: FixtureFileResponse | ResponseFactory, opts?: EmbeddingFixtureOpts): this;
  onJsonOutput(pattern: string | RegExp, jsonContent: object | string, opts?: FixtureOpts): this;
  onToolCall(name: string, response: FixtureFileResponse | ResponseFactory, opts?: FixtureOpts): this;
  onToolResult(id: string, response: FixtureFileResponse | ResponseFactory, opts?: FixtureOpts): this;
  onTurn(turn: number, pattern: string | RegExp, response: FixtureFileResponse | ResponseFactory, opts?: FixtureOpts): this;
  onImage(prompt: string | RegExp, response: ImageResponse): this;
  onSpeech(input: string | RegExp, response: AudioResponse): this;
  onTranscription(response: TranscriptionResponse): this;
  onTranslation(response: TranscriptionResponse): this;
  onVideo(prompt: string | RegExp, response: VideoResponse): this;
  onAudio(input: string | RegExp, response: AudioResponse): this;
  onSoundEffect(text: string | RegExp, response: AudioResponse): this;
  onMusic(prompt: string | RegExp, response: AudioResponse): this;
  onElevenLabsTTS(text: string | RegExp, response: AudioResponse): this;
  onFalAudio(prompt: string | RegExp, response: AudioResponse, model?: string): this;
  onFalQueue(modelOrPrompt: string | RegExp, response: unknown, opts?: FalQueueOpts): this;
  onFalRun(modelOrPrompt: string | RegExp, response: unknown, opts?: FalQueueOpts): this;
  /**
   * Register a fal.ai image fixture. Wraps an `ImageResponse` (the shape used
   * by `onImage` and OpenAI/Azure image fixtures) into fal's image envelope
   * before storing it as a `RawJSONResponse`. Defaults `width`/`height` to
   * 1024 when the fixture's `ImageItem` doesn't carry them.
   */
  onFalImage(modelOrPrompt: string | RegExp, response: ImageResponse, opts?: FalQueueOpts): this;
  /**
   * Register a fal.ai video fixture. Wraps a `VideoResponse` into fal's video
   * envelope (`{ video: { url, content_type, file_name, file_size }, seed }`)
   * before storing it as a `RawJSONResponse`.
   */
  onFalVideo(modelOrPrompt: string | RegExp, response: VideoResponse, opts?: FalQueueOpts): this;
  onSearch(pattern: string | RegExp, results: SearchResult[]): this;
  onRerank(pattern: string | RegExp, results: RerankResult[]): this;
  onModerate(pattern: string | RegExp, result: ModerationResult): this;
  /**
   * Queue a one-shot error that will be returned for the next matching
   * request, then automatically removed. Implemented as an internal fixture
   * with a `predicate` that always matches (so it fires first) and spliced
   * at the front of the fixture list.
   */
  nextRequestError(status: number, errorBody?: {
    message?: string;
    type?: string;
    code?: string;
  }): this;
  mount(path: string, handler: Mountable): this;
  getRequests(): JournalEntry[];
  getLastRequest(): JournalEntry | null;
  clearRequests(): void;
  resetMatchCounts(testId?: string): this;
  setChaos(config: ChaosConfig): this;
  clearChaos(): this;
  enableRecording(config: RecordConfig): this;
  disableRecording(): this;
  reset(): this;
  start(): Promise<string>;
  stop(): Promise<void>;
  get journal(): Journal;
  get url(): string;
  get baseUrl(): string;
  get port(): number;
  static create(options?: MockServerOptions): Promise<LLMock>;
}
//# sourceMappingURL=llmock.d.ts.map
//#endregion
export { LLMock };
//# sourceMappingURL=llmock.d.ts.map