import * as react_jsx_runtime from 'react/jsx-runtime'; import * as react from 'react'; import { ReactNode, RefObject, Component, ErrorInfo, CSSProperties, ComponentType } from 'react'; import { AudioPlayoutOptions, VideoPlayoutOptions, SessionStatsOptions, SessionInterface, SessionDocument, SessionStream, SessionPhase, SessionStatus, SessionDiagnostic, SessionStatsSample, CameraWarpOptions, CameraWarp, CaptureController, ReferenceImage, ActivationEvent, PrewakeResult, RuntimeAvailability } from '@urun-sh/core'; export { ActivationEvent, ActivationState, App as AppInterface, AppOptions, AudioPlayoutOptions, InboundStatsSample, PrewakeResult, PrewakeStatus, RuntimeAvailability, SessionDocument, Session as SessionInterface, SessionPhase, SessionPhaseName, SessionStatsOptions, SessionStatsSample, SessionStream, VideoPlayoutOptions, describeSessionPhase, isWakingPhase } from '@urun-sh/core'; import { ZodSchema, z } from 'zod'; import { StoreApi } from 'zustand/vanilla'; interface UrunProviderProps { baseUrl?: string; orgId?: string; app?: string; appId?: string; jwt?: string; authProvider?: string; tokenEndpoint?: string; errorFallback?: ReactNode | ((error: Error) => ReactNode); eventsUrl?: string; sessionKey?: string; releaseOnLeave?: boolean; audioPlayout?: AudioPlayoutOptions; videoPlayout?: VideoPlayoutOptions; sessionStats?: SessionStatsOptions; confirmOnLeave?: boolean; sessionId?: string; onConnected?: () => void; onDisconnected?: () => void; onError?: (error: Error) => void; canvasRef?: RefObject; renderMode?: 'canvas' | 'dom'; fallback?: ReactNode | ((error: Error) => ReactNode); children: ReactNode; } declare function UrunProvider({ baseUrl, orgId, app, appId, jwt, authProvider, eventsUrl, sessionKey, tokenEndpoint, releaseOnLeave, audioPlayout: audioPlayoutProp, videoPlayout: videoPlayoutProp, sessionStats: sessionStatsProp, confirmOnLeave, fallback, errorFallback, children, }: UrunProviderProps): react_jsx_runtime.JSX.Element; interface UrunErrorBoundaryProps { fallback?: ReactNode | ((error: Error) => ReactNode); children: ReactNode; } interface UrunErrorBoundaryState { error: Error | null; } declare class UrunErrorBoundary extends Component { constructor(props: UrunErrorBoundaryProps); static getDerivedStateFromError(error: Error): UrunErrorBoundaryState; componentDidCatch(error: Error, info: ErrorInfo): void; render(): string | number | bigint | boolean | Iterable | Promise> | Iterable | null | undefined> | react_jsx_runtime.JSX.Element | null | undefined; } type UrunAccessToken = string | null | undefined; interface UrunAccessTokenOptions { forceRefresh?: boolean; reason?: 'initial' | 'unauthorized' | 'background'; } type UrunAccessTokenProvider = (options?: UrunAccessTokenOptions) => UrunAccessToken | Promise; interface UrunAuthContextValue { getAccessToken: UrunAccessTokenProvider; } interface UrunAuthProviderProps { getAccessToken: UrunAccessTokenProvider; children: ReactNode; } declare function UrunAuthProvider({ getAccessToken, children }: UrunAuthProviderProps): react_jsx_runtime.JSX.Element; declare const UrunJwtProvider: typeof UrunAuthProvider; declare function useUrunAuth(): UrunAuthContextValue | null; type UrunAuthMode = 'workos' | 'jwt'; declare function urunPublicEnv(name: string): string | undefined; declare function authMode(): UrunAuthMode; declare function usesWorkOSAuth(): boolean; declare const OPERATOR_TOKEN_STORAGE_KEY = "urun.operator_token"; declare const OPERATOR_CHORD_LABEL = "\u2318\u21E7\u23CE (Ctrl+Shift+Enter)"; declare function readOperatorToken(): string | null; declare function useOperatorOverride(onTrigger: (token: string) => void): void; declare function useConfirmOnLeave(enabled?: boolean): void; type Unsubscribe = () => void; type ReactSessionDocument> = Omit & { get(): T; get(path: string, defaultValue?: unknown): unknown; set(patch: Partial & Record): void; on(event: 'change', handler: (snapshot: T) => void): Unsubscribe; }; type ReactSessionStream = SessionStream; interface ReactSession extends Omit { doc>(name: string): ReactSessionDocument; stream(name: string): ReactSessionStream; readonly phase: SessionPhase; readonly status: SessionStatus; onDiagnostic(handler: (diagnostic: SessionDiagnostic) => void): Unsubscribe; onStats(handler: (sample: SessionStatsSample) => void): Unsubscribe; } type ReactApp = Record) => ReactSession>; declare function useApp(): ReactApp; interface SessionRequestOptions { signal?: AbortSignal; channel?: string; metadata?: Record; } interface RequestStream extends AsyncIterable { readonly id: string; cancel(): void; } interface RequestCapableSession { request(payload: TReq, options?: SessionRequestOptions): Promise; requestStream(payload: TReq, options?: SessionRequestOptions): RequestStream; } interface UseRequestOptions extends Omit { onSuccess?: (data: unknown) => void; onError?: (error: Error) => void; } interface UseRequestResult { mutate: (payload: TReq) => void; mutateAsync: (payload: TReq) => Promise; data: TRes | undefined; error: Error | null; isPending: boolean; reset: () => void; } declare function useRequest(session: RequestCapableSession, options?: UseRequestOptions): UseRequestResult; interface UseCompletionOptions extends Omit { parseChunk?: (chunk: TChunk) => string; buildPayload?: (prompt: string) => unknown; onFinish?: (completion: string) => void; onError?: (error: Error) => void; } interface UseCompletionResult { completion: string; complete: (prompt: string) => Promise; stop: () => void; isStreaming: boolean; error: Error | null; } declare function useCompletion(session: RequestCapableSession, options?: UseCompletionOptions): UseCompletionResult; type ChatRole = 'system' | 'user' | 'assistant'; interface ChatMessage { id: string; role: ChatRole; content: string; } interface UseChatOptions extends Omit { initialMessages?: Array & { id?: string; }>; parseChunk?: (chunk: TChunk) => string; buildPayload?: (messages: Array<{ role: ChatRole; content: string; }>) => unknown; onFinish?: (message: ChatMessage) => void; onError?: (error: Error) => void; } interface UseChatResult { messages: ChatMessage[]; input: string; setInput: (value: string) => void; sendMessage: (message?: string) => Promise; stop: () => void; isStreaming: boolean; error: Error | null; } declare function useChat(session: RequestCapableSession, options?: UseChatOptions): UseChatResult; interface InputPresenceSession { presence: { setField(field: string, value: unknown): void; }; } interface UseInputPresenceOptions { field?: string; hz?: number; documentTarget?: Document | null; windowTarget?: Window | null; } interface InputPresenceControls { engage(surface: HTMLElement): void; engageTouch(): void; release(): void; engaged: boolean; heldKeys: string[]; pressKey(key: string): void; releaseKey(key: string): void; movePointer(dx: number, dy: number): void; } declare function useInputPresence(session: InputPresenceSession | null | undefined, options?: UseInputPresenceOptions): InputPresenceControls; interface VideoStreamSource { readonly track: MediaStreamTrack | null; on(event: 'track', handler: (track: MediaStreamTrack | null) => void): () => void; } interface VideoSessionSource { stream(name: string): VideoStreamSource; } interface VideoHandle { readonly element: HTMLVideoElement | null; readonly live: boolean; readonly framed: boolean; unlock(): void; readonly unlocked: boolean; } interface FrameMarker { rtpTimestamp?: number | null; ptsMs?: number | null; } interface VideoProps { session?: VideoSessionSource | null; stream?: string; track?: MediaStreamTrack | null; audioStream?: string | false; muted?: boolean; mirror?: boolean; objectFit?: CSSProperties['objectFit']; className?: string; style?: CSSProperties; videoClassName?: string; placeholder?: ReactNode; poster?: ReactNode; children?: ReactNode; onTrack?: (track: MediaStreamTrack | null) => void; onFirstFrame?: () => void; frameMarker?: FrameMarker | null; onFrameMarkerReached?: () => void; onFrameMarkerUnsupported?: () => void; onUnlockChange?: (unlocked: boolean) => void; } declare const Video: react.ForwardRefExoticComponent>; interface ReprojectedVideoWarpOptions extends CameraWarpOptions { enabled?: boolean; overscan?: number; captureInput?: boolean; documentTarget?: Document | null; } interface ReprojectedVideoProps extends VideoProps { warp?: ReprojectedVideoWarpOptions; } interface ReprojectedVideoHandle { readonly video: VideoHandle | null; readonly canvas: HTMLCanvasElement | null; readonly warp: CameraWarp; readonly lastDrawTs: number; } declare const ReprojectedVideo: react.ForwardRefExoticComponent>; interface RegisteredComponent { component: ComponentType; schema: ZodSchema; } declare function registerComponent(name: string, component: ComponentType, schema: ZodSchema): void; interface ComponentRendererProps { name: string; props: unknown; fallback?: ReactNode; } declare function ComponentRenderer({ name, props, fallback }: ComponentRendererProps): react_jsx_runtime.JSX.Element; declare const ProgressCardSchema: z.ZodObject<{ step: z.ZodNumber; total: z.ZodNumber; label: z.ZodOptional; variant: z.ZodDefault>; }, "strip", z.ZodTypeAny, { step: number; total: number; variant: "error" | "default" | "success"; label?: string | undefined; }, { step: number; total: number; label?: string | undefined; variant?: "error" | "default" | "success" | undefined; }>; type ProgressCardProps = z.input; declare function useProgressCard(props: ProgressCardProps): { step: number; total: number; label: string | undefined; variant: "error" | "default" | "success"; percentage: number; isComplete: boolean; }; declare function ProgressCard(props: ProgressCardProps): react_jsx_runtime.JSX.Element; declare const StatusBadgeSchema: z.ZodObject<{ state: z.ZodEnum<["thinking", "generating", "idle", "error"]>; message: z.ZodOptional; }, "strip", z.ZodTypeAny, { state: "error" | "idle" | "thinking" | "generating"; message?: string | undefined; }, { state: "error" | "idle" | "thinking" | "generating"; message?: string | undefined; }>; type StatusBadgeProps = z.infer; declare function useStatusBadge(props: StatusBadgeProps): { state: "error" | "idle" | "thinking" | "generating"; message: string; isActive: boolean; }; declare function StatusBadge(props: StatusBadgeProps): react_jsx_runtime.JSX.Element; declare const TextStreamSchema: z.ZodObject<{ text: z.ZodString; streaming: z.ZodDefault; }, "strip", z.ZodTypeAny, { text: string; streaming: boolean; }, { text: string; streaming?: boolean | undefined; }>; type TextStreamProps = z.input; declare function useTextStream(props: TextStreamProps): { text: string; streaming: boolean; isEmpty: boolean; }; declare function TextStream(props: TextStreamProps): react_jsx_runtime.JSX.Element; declare const ImageFrameSchema: z.ZodObject<{ src: z.ZodString; alt: z.ZodOptional; caption: z.ZodOptional; }, "strip", z.ZodTypeAny, { src: string; caption?: string | undefined; alt?: string | undefined; }, { src: string; caption?: string | undefined; alt?: string | undefined; }>; type ImageFrameProps = z.infer; declare function useImageFrame(props: ImageFrameProps): { src: string; alt: string; caption: string | undefined; }; declare function ImageFrame(props: ImageFrameProps): react_jsx_runtime.JSX.Element; declare const MetricsPanelSchema: z.ZodObject<{ metrics: z.ZodArray; unit: z.ZodOptional; }, "strip", z.ZodTypeAny, { value: string | number; label: string; unit?: string | undefined; }, { value: string | number; label: string; unit?: string | undefined; }>, "many">; }, "strip", z.ZodTypeAny, { metrics: { value: string | number; label: string; unit?: string | undefined; }[]; }, { metrics: { value: string | number; label: string; unit?: string | undefined; }[]; }>; type MetricsPanelProps = z.infer; interface EnrichedMetric { label: string; value: string | number; unit?: string; displayValue: string; } declare function useMetricsPanel(props: MetricsPanelProps): { metrics: EnrichedMetric[]; }; declare function MetricsPanel(props: MetricsPanelProps): react_jsx_runtime.JSX.Element; interface TextStreamSource { messages(): AsyncIterable; } interface TextSessionLike { stream(name: string): TextStreamSource; } declare function textDelta(frame: unknown): string; declare class TextStreamError extends Error { name: string; } interface TextMeter { chars: number; tokens: number; tokensPerSecond: number; elapsedMs: number; done: boolean; } declare const DEFAULT_SMOOTH_CHARS_PER_FRAME = 3; declare const DEFAULT_SMOOTH_THRESHOLD = 240; interface UseTextOptions { session: TextSessionLike | null | undefined; stream: string; smooth?: boolean; smoothCharsPerFrame?: number; smoothThreshold?: number; onDone?: (text: string) => void; onError?: (error: Error) => void; onMeter?: (meter: TextMeter) => void; } interface UseTextResult { ref: (element: HTMLElement | null) => void; meterRef: RefObject; getText: () => string; } declare function useText(options: UseTextOptions): UseTextResult; declare function useTextMeter(meterRef: RefObject, intervalMs?: number): TextMeter; interface TextProps extends UseTextOptions { className?: string; style?: CSSProperties; } declare function Text(props: TextProps): react_jsx_runtime.JSX.Element; interface ScopedStreamSource { readonly track: MediaStreamTrack | null; on(event: 'track', handler: (track: MediaStreamTrack | null) => void): () => void; attach(track: MediaStreamTrack): Promise; detach(): Promise; attachVideo(track: MediaStreamTrack): Promise; detachVideo(): Promise; } interface ScopedSession { stream(name: string): ScopedStreamSource; whenLive(options?: { timeout?: number; signal?: AbortSignal; }): Promise; readonly status?: SessionStatus; onRecovery?(hook: () => void): () => void; } interface SessionProps { session: ScopedSession | null; children: ReactNode; } declare function Session({ session, children }: SessionProps): react_jsx_runtime.JSX.Element; declare function useSession(): ScopedSession; type ImageProps = Omit & { stream?: string; }; type ImageHandle = VideoHandle; declare const Image: react.ForwardRefExoticComponent & { stream?: string; } & react.RefAttributes>; interface AudioStreamSource { readonly track: MediaStreamTrack | null; on(event: 'track', handler: (track: MediaStreamTrack | null) => void): () => void; } interface AudioSessionSource { stream(name: string): AudioStreamSource; } interface AudioHandle { unlock(): void; readonly unlocked: boolean; readonly element: HTMLAudioElement | null; } interface AudioProps { session?: AudioSessionSource | null; stream?: string; track?: MediaStreamTrack | null; controls?: boolean; className?: string; onTrack?: (track: MediaStreamTrack | null) => void; onUnlockChange?: (unlocked: boolean) => void; onAudioElement?: (el: HTMLAudioElement | null) => void; } declare const Audio: react.ForwardRefExoticComponent>; declare const UrunAudio: react.ForwardRefExoticComponent>; type UrunAudioProps = AudioProps; type UrunAudioHandle = AudioHandle; type UrunAudioStreamSource = AudioStreamSource; type UrunAudioSessionSource = AudioSessionSource; interface VoiceStreamSource extends AudioStreamSource { attach(track: MediaStreamTrack): Promise; detach(): Promise; } interface VoiceSessionSource { stream(name: string): VoiceStreamSource; whenLive(options?: { timeout?: number; signal?: AbortSignal; }): Promise; readonly status?: SessionStatus; onRecovery?(hook: () => void): () => void; } interface VoiceHandle { start(): Promise; stop(): Promise; readonly active: boolean; readonly micStream: MediaStream | null; unlock(): void; readonly audio: AudioHandle | null; } interface VoiceProps { session?: VoiceSessionSource | null; stream?: string; playback?: boolean; constraints?: MediaTrackConstraints; connectTimeoutMs?: number; attempts?: number; retryDelayMs?: number; onActiveChange?: (active: boolean) => void; onError?: (error: Error) => void; onMicStream?: (stream: MediaStream | null) => void; onTrack?: (track: MediaStreamTrack | null) => void; onUnlockChange?: (unlocked: boolean) => void; capture?: CaptureController; } declare const DEFAULT_VOICE_CONSTRAINTS: MediaTrackConstraints; declare const Voice: react.ForwardRefExoticComponent>; declare const UrunVoice: react.ForwardRefExoticComponent>; type UrunVoiceProps = VoiceProps; type UrunVoiceHandle = VoiceHandle; type UrunVoiceStreamSource = VoiceStreamSource; type UrunVoiceSessionSource = VoiceSessionSource; interface MicHandle { start(): Promise; stop(): Promise; readonly active: boolean; readonly micStream: MediaStream | null; } interface MicProps { session?: VoiceSessionSource | null; stream?: string; constraints?: MediaTrackConstraints; autoStart?: boolean; visible?: boolean; className?: string; onActiveChange?: (active: boolean) => void; onError?: (error: Error) => void; onMicStream?: (stream: MediaStream | null) => void; capture?: CaptureController; } declare const Mic: react.ForwardRefExoticComponent>; interface CameraStreamSource { attachVideo(track: MediaStreamTrack): Promise; detachVideo(): Promise; } interface CameraSessionSource { stream(name: string): CameraStreamSource; whenLive(options?: { timeout?: number; signal?: AbortSignal; }): Promise; readonly status?: SessionStatus; } type CameraFacing = 'user' | 'environment'; interface CapturePhotoOptions { maxSize?: number; type?: 'image/png' | 'image/jpeg'; quality?: number; } interface CameraHandle { start(options?: { facingMode?: CameraFacing; }): Promise; stop(): Promise; flip(): Promise; setFacingMode(mode: CameraFacing): Promise; capturePhoto(options?: CapturePhotoOptions): Promise; readonly active: boolean; readonly facingMode: CameraFacing; readonly stream: MediaStream | null; readonly element: HTMLVideoElement | null; } interface CameraProps { session?: CameraSessionSource | null; stream?: string | false; constraints?: MediaTrackConstraints; front?: boolean; back?: boolean; facingMode?: CameraFacing; autoStart?: boolean; mirror?: boolean | 'auto'; connectTimeoutMs?: number; visible?: boolean; className?: string; videoClassName?: string; onActiveChange?: (active: boolean) => void; onError?: (error: Error) => void; onStream?: (stream: MediaStream | null) => void; onTrack?: (track: MediaStreamTrack | null) => void; children?: ReactNode; flipControl?: boolean | 'auto'; flipControlClassName?: string; onDevices?: (devices: MediaDeviceInfo[]) => void; capture?: CaptureController; } declare const DEFAULT_CAMERA_CONSTRAINTS: MediaTrackConstraints; declare const Camera: react.ForwardRefExoticComponent>; interface UrunCameraProps extends Omit { session: CameraSessionSource; preview?: boolean; } declare const UrunCamera: react.ForwardRefExoticComponent>; type UrunCameraHandle = CameraHandle; type UrunCameraFacing = CameraFacing; type UrunCameraStreamSource = CameraStreamSource; type UrunCameraSessionSource = CameraSessionSource; interface ReferenceImageCameraSource { capturePhoto(options?: CapturePhotoOptions): Promise; } interface UseReferenceImageOptions { maxSize?: number; type?: 'image/png' | 'image/jpeg'; quality?: number; onChange?: (reference: ReferenceImage | null) => void; } interface UseReferenceImageResult { reference: ReferenceImage | null; previewUrl: string | null; pick(file: Blob): Promise; capture(camera: ReferenceImageCameraSource): Promise; clear(): void; busy: boolean; error: string | null; cameraAvailable: boolean; } declare function useReferenceImage(options?: UseReferenceImageOptions): UseReferenceImageResult; interface UseUrunAudioLevelOptions { fftSize?: number; intervalMs?: number; speakingThreshold?: number; } interface UrunAudioLevel { level: number; speaking: boolean; } declare function useUrunAudioLevel(source: MediaStream | MediaStreamTrack | null | undefined, options?: UseUrunAudioLevelOptions): UrunAudioLevel; declare function getUrunAudioContext(): AudioContext | null; declare function resumeUrunAudioContext(): void; interface WorkbenchStreamSource { readonly track: MediaStreamTrack | null; on(event: 'track', handler: (track: MediaStreamTrack | null) => void): () => void; messages(): AsyncIterable; } interface WorkbenchDocSource { get(path?: string, defaultValue?: unknown): unknown; set(patch: Record): void; on(event: 'change', handler: (snapshot: unknown) => void): () => void; readonly synced: boolean; onSynced(handler: () => void): () => void; } interface WorkbenchSession { readonly id: string; readonly phase: SessionPhase; onPhase(handler: (phase: SessionPhase) => void): () => void; onActivation?(handler: (event: ActivationEvent) => void): () => void; stream(name: string): WorkbenchStreamSource; doc(key: string): WorkbenchDocSource; } declare function useSessionTrack(session: WorkbenchSession | null, name: string): MediaStreamTrack | null; type DeepPartial = { [K in keyof T]?: T[K] extends readonly unknown[] ? T[K] : T[K] extends object ? DeepPartial : T[K]; }; type DocPatch = DeepPartial & Record; interface DocState> { doc: T; synced: boolean; set: (patch: DocPatch) => void; } interface DocStore> extends Pick>, 'getState' | 'getInitialState' | 'subscribe'> { (selector: (state: DocState) => U): U; (): DocState; set(patch: DocPatch): void; bind(): () => void; unbind(): void; } interface CreateDocStoreOptions { bind?: boolean; } declare function createDocStore>(doc: WorkbenchDocSource | null, options?: CreateDocStoreOptions): DocStore; interface UseSessionDocResult { snapshot: T | null; synced: boolean; set: (patch: Partial & Record) => void; } declare function useSessionDoc>(session: WorkbenchSession | null, key: string): UseSessionDocResult; declare function useSessionDoc, U = unknown>(session: WorkbenchSession | null, key: string, selector: (state: DocState) => U): U; type DocHost = Pick; declare function useDocStore>(session: DocHost | null, key: string): DocStore; declare const DEFAULT_LOG_CAP = 200; declare function pushCapped(list: readonly T[], entry: T, cap?: number): T[]; interface StreamMessageEntry { at: number; payload: unknown; } interface SpineEntry { at: number; kind: 'phase' | 'track' | 'doc'; text: string; } declare function formatPayload(payload: unknown): string; type JsonObjectParse = { ok: true; value: Record; } | { ok: false; error: string; }; declare function parseJsonObject(text: string): JsonObjectParse; interface UseStreamMessagesOptions { cap?: number; } declare function useStreamMessages(session: WorkbenchSession | null, name: string, options?: UseStreamMessagesOptions): StreamMessageEntry[]; interface UrunStreamTailProps { session: WorkbenchSession | null; name: string; cap?: number; className?: string; } declare function UrunStreamTail({ session, name, cap, className }: UrunStreamTailProps): react_jsx_runtime.JSX.Element; declare function DocPatchForm({ placeholder, buttonLabel, disabled, onApply, }: { placeholder?: string; buttonLabel: string; disabled?: boolean; onApply: (patch: Record, raw: string) => void; }): react_jsx_runtime.JSX.Element; interface UrunDocPanelProps { session: WorkbenchSession | null; docKey: string; editable?: boolean; patchPlaceholder?: string; className?: string; } declare function UrunDocPanel({ session, docKey, editable, patchPlaceholder, className, }: UrunDocPanelProps): react_jsx_runtime.JSX.Element; interface UrunControlSenderProps { session: WorkbenchSession | null; docKey?: string; cap?: number; className?: string; } declare function UrunControlSender({ session, docKey, cap, className, }: UrunControlSenderProps): react_jsx_runtime.JSX.Element; interface UrunEventSpineProps { session: WorkbenchSession | null; trackNames?: string[]; docKeys?: string[]; cap?: number; className?: string; } declare function UrunEventSpine({ session, trackNames, docKeys, cap, className, }: UrunEventSpineProps): react_jsx_runtime.JSX.Element; declare function useSessionPhase(session: WorkbenchSession | null): SessionPhase | null; interface UrunSessionStatusProps { session: WorkbenchSession | null; className?: string; } declare function UrunSessionStatus({ session, className }: UrunSessionStatusProps): react_jsx_runtime.JSX.Element; interface UrunSessionGateProps { session: WorkbenchSession | null; children: ReactNode; fallback?: (phase: SessionPhase | null) => ReactNode; onStartOver?: () => void; className?: string; } declare function UrunSessionGate({ session, children, fallback, onStartOver, className, }: UrunSessionGateProps): react_jsx_runtime.JSX.Element; declare function useSessionEndsAt(session: WorkbenchSession | null): Date | null; interface UrunSessionClockProps { session: WorkbenchSession | null; urgentMs?: number; className?: string; } declare function UrunSessionClock({ session, urgentMs, className }: UrunSessionClockProps): react_jsx_runtime.JSX.Element | null; interface UrunSessionEndedProps { session: WorkbenchSession | null; onNewSession?: () => void; children?: (phase: SessionPhase) => ReactNode; className?: string; } declare function UrunSessionEnded({ session, onNewSession, children, className }: UrunSessionEndedProps): react_jsx_runtime.JSX.Element | null; interface SessionIdleState { warning: boolean; deadlineEpochS: number | null; idleSinceEpochS: number | null; } type TouchableSession = WorkbenchSession & { touch?: () => void; }; declare function useSessionIdle(session: TouchableSession | null): SessionIdleState | null; interface UrunIdleWarningProps { session: TouchableSession | null; onStillHere?: () => void; className?: string; } declare function UrunIdleWarning({ session, onStillHere, className }: UrunIdleWarningProps): react_jsx_runtime.JSX.Element | null; interface UseUrunPrewakeOptions { app?: string; function: string; intervalS?: number; } declare function useUrunPrewake(options: UseUrunPrewakeOptions): PrewakeResult | null; interface SessionWake { waking: boolean; phase: SessionPhase | null; state?: RuntimeAvailability['state']; reason?: string; since?: number; seconds: number; } declare function useSessionWake(session: WorkbenchSession | null): SessionWake; interface UrunSessionWakingProps { session: WorkbenchSession | null; render?: (wake: SessionWake) => ReactNode; className?: string; } declare function UrunSessionWaking({ session, render, className }: UrunSessionWakingProps): react_jsx_runtime.JSX.Element | null; interface ActivationProgress { event: ActivationEvent | null; elapsedMs: number; } declare function useActivation(session: WorkbenchSession | null, streamName?: string): ActivationProgress; interface SessionStatsSource { onStats?(handler: (sample: SessionStatsSample) => void): () => void; } declare function useSessionStats(session: SessionStatsSource | null): SessionStatsSample | null; interface UrunActivationOverlayProps { session: WorkbenchSession | null; stream?: string; videoElement?: HTMLVideoElement | null; render?: (progress: ActivationProgress) => ReactNode; className?: string; } declare function UrunActivationOverlay({ session, stream, videoElement, render, className, }: UrunActivationOverlayProps): react_jsx_runtime.JSX.Element | null; export { type ActivationProgress, Audio, type AudioHandle, type AudioProps, type AudioSessionSource, type AudioStreamSource, Camera, type CameraFacing, type CameraHandle, type CameraProps, type CameraSessionSource, type CameraStreamSource, type CapturePhotoOptions, type ChatMessage, type ChatRole, ComponentRenderer, type CreateDocStoreOptions, DEFAULT_CAMERA_CONSTRAINTS, DEFAULT_LOG_CAP, DEFAULT_SMOOTH_CHARS_PER_FRAME, DEFAULT_SMOOTH_THRESHOLD, DEFAULT_VOICE_CONSTRAINTS, type DeepPartial, type DocPatch, DocPatchForm, type DocState, type DocStore, type FrameMarker, Image, ImageFrame, ImageFrameSchema, type ImageHandle, type ImageProps, type InputPresenceControls, type InputPresenceSession, type JsonObjectParse, MetricsPanel, MetricsPanelSchema, Mic, type MicHandle, type MicProps, OPERATOR_CHORD_LABEL, OPERATOR_TOKEN_STORAGE_KEY, ProgressCard, ProgressCardSchema, type ReactApp, type ReactSession, type ReactSessionDocument, type ReactSessionStream, type ReferenceImageCameraSource, type RegisteredComponent, ReprojectedVideo, type ReprojectedVideoHandle, type ReprojectedVideoProps, type ReprojectedVideoWarpOptions, type RequestCapableSession, type RequestStream, type ScopedSession, type ScopedStreamSource, Session, type SessionIdleState, type SessionProps, type SessionRequestOptions, type SessionStatsSource, type SessionWake, type SpineEntry, StatusBadge, StatusBadgeSchema, type StreamMessageEntry, Text, type TextMeter, type TextProps, type TextSessionLike, TextStream, TextStreamError, TextStreamSchema, type TextStreamSource, type UrunAccessToken, type UrunAccessTokenProvider, UrunActivationOverlay, type UrunActivationOverlayProps, UrunAudio, type UrunAudioHandle, type UrunAudioLevel, type UrunAudioProps, type UrunAudioSessionSource, type UrunAudioStreamSource, type UrunAuthContextValue, type UrunAuthMode, UrunAuthProvider, type UrunAuthProviderProps, UrunCamera, type UrunCameraFacing, type UrunCameraHandle, type UrunCameraProps, type UrunCameraSessionSource, type UrunCameraStreamSource, UrunControlSender, type UrunControlSenderProps, UrunDocPanel, type UrunDocPanelProps, UrunErrorBoundary, UrunEventSpine, type UrunEventSpineProps, UrunIdleWarning, type UrunIdleWarningProps, UrunJwtProvider, UrunProvider, UrunSessionClock, type UrunSessionClockProps, UrunSessionEnded, type UrunSessionEndedProps, UrunSessionGate, type UrunSessionGateProps, UrunSessionStatus, type UrunSessionStatusProps, UrunSessionWaking, type UrunSessionWakingProps, UrunStreamTail, type UrunStreamTailProps, UrunVoice, type UrunVoiceHandle, type UrunVoiceProps, type UrunVoiceSessionSource, type UrunVoiceStreamSource, type UseChatOptions, type UseChatResult, type UseCompletionOptions, type UseCompletionResult, type UseInputPresenceOptions, type UseReferenceImageOptions, type UseReferenceImageResult, type UseRequestOptions, type UseRequestResult, type UseSessionDocResult, type UseStreamMessagesOptions, type UseTextOptions, type UseTextResult, type UseUrunAudioLevelOptions, type UseUrunPrewakeOptions, Video, type VideoHandle, type VideoProps, type VideoSessionSource, type VideoStreamSource, Voice, type VoiceHandle, type VoiceProps, type VoiceSessionSource, type VoiceStreamSource, type WorkbenchDocSource, type WorkbenchSession, type WorkbenchStreamSource, authMode, createDocStore, formatPayload, getUrunAudioContext, parseJsonObject, pushCapped, readOperatorToken, registerComponent, resumeUrunAudioContext, textDelta, urunPublicEnv, useActivation, useApp, useChat, useCompletion, useConfirmOnLeave, useDocStore, useImageFrame, useInputPresence, useMetricsPanel, useOperatorOverride, useProgressCard, useReferenceImage, useRequest, useSession, useSessionDoc, useSessionEndsAt, useSessionIdle, useSessionPhase, useSessionStats, useSessionTrack, useSessionWake, useStatusBadge, useStreamMessages, useText, useTextMeter, useTextStream, useUrunAudioLevel, useUrunAuth, useUrunPrewake, usesWorkOSAuth };