import type { ExtensionAPI, ExtensionContext } from "@earendil-works/pi-coding-agent"; import { Type, type Static } from "typebox"; import type { RuntimeResponse } from "../tools/code-mode/types.ts"; export { REMOTE_DELIVERY_MESSAGE, REMOTE_DELIVERY_RECEIVER } from "./remote-delivery-protocol.ts"; declare const SCHEMA: Type.TUnion<[Type.TObject<{ protocol: Type.TLiteral<1>; origin: Type.TLiteral<"host">; id: Type.TString; sourceCallId: Type.TString; cellId: Type.TString; scope: Type.TString; status: Type.TUnion<[Type.TLiteral<"yielded">, Type.TLiteral<"result">, Type.TLiteral<"terminated">]>; errorText: Type.TOptional; contextNotesSaved: Type.TOptional; outputs: Type.TArray>; imageNotice: Type.TOptional; images: Type.TArray; mimeType: Type.TString; data: Type.TString; detail: Type.TOptional, Type.TLiteral<"high">, Type.TLiteral<"original">]>>; }>>; }>, Type.TObject<{ origin: Type.TLiteral<"host">; id: Type.TString; sourceCallId: Type.TString; cellId: Type.TString; scope: Type.TString; status: Type.TUnion<[Type.TLiteral<"yielded">, Type.TLiteral<"result">, Type.TLiteral<"terminated">]>; errorText: Type.TOptional; contextNotesSaved: Type.TOptional; outputs: Type.TArray>; imageNotice: Type.TOptional; images: Type.TArray; mimeType: Type.TString; data: Type.TString; detail: Type.TOptional, Type.TLiteral<"high">, Type.TLiteral<"original">]>>; }>>; protocol: Type.TLiteral<2>; originalExecCallId: Type.TString; }>]>; export type RemoteDelivery = Static; export declare function readRemoteDelivery(input: unknown): RemoteDelivery; export declare function appendRemoteDelivery(pi: ExtensionAPI, response: RuntimeResponse, sourceCallId: string, scope: string, ctx: ExtensionContext): string; export declare function remoteDeliveryItems(delivery: RemoteDelivery, blockImages?: boolean): unknown[]; export declare function validateRemoteDelivery(delivery: RemoteDelivery, account: () => string | undefined, ctx?: ExtensionContext, baseUrl?: string): void; /** Resolve the source on the event's canonical ancestry, including compacted-out records. */ export declare function remoteDeliverySource(delivery: RemoteDelivery, ctx: { sessionManager: Pick; }): "exec" | "wait";