export { serializeTelefunctionResult }; export type { TelefuncId }; import { type ValueShields, type ShieldLogConfig } from '../shield.js'; import { type StreamTransport } from '../../../wire-protocol/constants.js'; import { type RequestContext } from '../context/requestContext.js'; import type { Context } from '../context/context.js'; import type { Readable } from 'node:stream'; type TelefuncId = { telefunctionName: string; telefuncFilePath: string; }; type SerializeResult = { type: 'text'; body: string; } | { type: 'streaming'; body: Readable | ReadableStream>; streamTransport: StreamTransport; }; declare function serializeTelefunctionResult(runContext: { telefunctionReturn: unknown; telefunctionName: string; telefuncFilePath: string; telefunctionAborted: boolean; context: Context; requestContext: RequestContext; abortSignal: AbortSignal; streamTransport: StreamTransport; useNodeStream: boolean; serverConfig: { log: { shieldErrors: ShieldLogConfig; }; }; valueShields?: ValueShields; }): SerializeResult;