import { i as GuardedFetchResult } from "../../fetch-guard-BKvfwdRa.js";
import { c as fetchWithTimeoutGuarded, n as ProviderOperationTimeoutMs } from "../../provider-http-IPpRt60N.js";
import { t as GeneratedVideoAsset } from "../../video-generation-2nEgnGTC.js";
//#region extensions/xai/video-generation-transport.d.ts
type XaiVideoRequestPolicy = {
  allowPrivateNetwork: boolean;
  dispatcherPolicy?: NonNullable<Parameters<typeof fetchWithTimeoutGuarded>[4]>["dispatcherPolicy"];
};
declare function fetchXaiVideoResponse(params: {
  url: string;
  init: RequestInit;
  stage: "poll" | "download";
  requestFailedMessage: string;
  auditContext: string;
  timeoutMs?: ProviderOperationTimeoutMs;
  defaultTimeoutMs: number;
  fetchFn: typeof fetch;
} & XaiVideoRequestPolicy): Promise<GuardedFetchResult>;
declare function downloadXaiVideo(params: {
  url: string;
  timeoutMs?: ProviderOperationTimeoutMs;
  defaultTimeoutMs: number;
  fetchFn: typeof fetch;
  maxBytes: number;
} & XaiVideoRequestPolicy): Promise<GeneratedVideoAsset>;
//#endregion
export { XaiVideoRequestPolicy, downloadXaiVideo, fetchXaiVideoResponse };