export type RuntimeContractBoundary = "input" | "contract" | "governance" | "runtime-state" | "scope";
export type RuntimeContractGate = {
    accepted: boolean;
    reason?: string;
};
export type RuntimeContractSeverity = "info" | "warning" | "recoverable" | "fatal";
export type RuntimeContractErrorCode = "MISSING_RUNTIME_ID" | "MISSING_CONTRACT_ID" | "MISSING_ERROR_CODE" | "CONTRACT_REJECTED" | "GOVERNANCE_REJECTED" | "RUNTIME_NOT_READY";
export type RuntimeContractError = {
    code: RuntimeContractErrorCode | string;
    message: string;
    boundary: RuntimeContractBoundary;
    severity: RuntimeContractSeverity;
    runtimeId?: string;
    contractId?: string;
    safeForApplication: true;
    internalDetailExposed: false;
};
export type RuntimeErrorContractRequest = {
    runtimeId: string;
    contractId: string;
    errorCode: string;
    message?: string;
    boundary?: RuntimeContractBoundary;
    severity?: RuntimeContractSeverity;
    runtimeReady?: boolean;
    contract?: RuntimeContractGate;
    governance?: RuntimeContractGate;
    internalDetail?: unknown;
};
export type RuntimeErrorContractResult = {
    ok: true;
    errorContract: RuntimeContractError;
    events: readonly string[];
} | {
    ok: false;
    error: RuntimeContractError;
    events: readonly string[];
};
export declare function defineRuntimeErrorContract(request: RuntimeErrorContractRequest): RuntimeErrorContractResult;
