export type RuntimeContractBoundary = "input" | "contract" | "governance" | "runtime-state";
export type RuntimeContractGate = {
    accepted: boolean;
    reason?: string;
};
export type RuntimeContractCallerKind = "application" | "official-module" | "runtime-surface";
export type RuntimeContractCaller = {
    kind: RuntimeContractCallerKind;
    id: string;
};
export type RuntimePublicContractErrorCode = "MISSING_RUNTIME_ID" | "MISSING_CALLER" | "RUNTIME_NOT_READY" | "CONTRACT_REJECTED" | "GOVERNANCE_REJECTED";
export type RuntimePublicContractError = {
    code: RuntimePublicContractErrorCode;
    message: string;
    boundary: RuntimeContractBoundary;
    publicSafe: true;
};
export type RuntimePublicContractRequest = {
    runtimeId?: string;
    caller?: RuntimeContractCaller;
    runtimeReady?: boolean;
    requestedSurfaces?: readonly string[];
    contract?: RuntimeContractGate;
    governance?: RuntimeContractGate;
};
export type RuntimePublicContractSnapshot = {
    runtimeId: string;
    caller: RuntimeContractCaller;
    exposure: "public";
    allowedSurfaces: readonly string[];
    readonly: true;
    unsafeSideEffects: false;
};
export type RuntimePublicContractResult = {
    ok: true;
    contract: RuntimePublicContractSnapshot;
    events: readonly string[];
} | {
    ok: false;
    error: RuntimePublicContractError;
    events: readonly string[];
};
export declare function defineRuntimePublicContract(request?: RuntimePublicContractRequest): RuntimePublicContractResult;
