import type { FasedAgentConfig } from "../config/config.js";
type FederationLogger = {
    info?: (message: string) => void;
    warn?: (message: string) => void;
    error?: (message: string) => void;
};
type FederationAccessToken = {
    tokenId: string;
    nodeId: string;
    handle: string;
    issuedAt: string;
    expiresAt: string;
    scopes: string[];
    signature: string;
    trustState?: "pending" | "verified" | "revoked" | "blocked";
    hostedState?: "disabled" | "pending" | "ready" | "missing";
    paidFlowEligible?: boolean;
    zrokToken?: string;
    agentSlug?: string;
    publicUrl?: string;
    bondId?: string;
    bondWallet?: {
        chain: string;
        address: string;
    };
    bondStatus?: "missing" | "active" | "unlocking" | "unlocked";
    bondTier?: "none" | "basic-bond" | "operator-bond";
    bondAmountRaw?: string;
    bondUnlockAvailableAt?: string;
    bondQuotaBand?: "standard" | "boosted" | "operator";
    bondDerivedScopes?: string[];
};
type AutoConnectResult = {
    enabled: boolean;
    handle?: string;
    baseUrl?: string;
    nodeEndpoint?: string;
    reason?: string;
};
export type PersistedFederationBondProof = {
    challengeId: string;
    bondId: string;
    walletId: string;
    walletAddress: string;
    handle: string;
    nodeId: string;
    federationBaseUrl: string;
    expiresAt: string;
    payload: string;
    payloadBase64: string;
    signatureBase64: string;
    signedAt: string;
    verifiedAt?: string;
    bondStatus?: "missing" | "active" | "unlocking" | "unlocked";
    bondTier?: "none" | "basic-bond" | "operator-bond";
    bondAmountRaw?: string;
    bondUnlockAvailableAt?: string;
    bondQuotaBand?: "standard" | "boosted" | "operator";
    bondDerivedScopes?: string[];
};
export declare function loadPersistedFederationBondProof(env: NodeJS.ProcessEnv): Promise<PersistedFederationBondProof | null>;
export declare function createFederationBondProof(opts?: {
    env?: NodeJS.ProcessEnv;
    cfg?: FasedAgentConfig;
    log?: FederationLogger;
    bondId?: string;
    walletId?: string;
    amountRaw?: string;
    tier?: "none" | "basic-bond" | "operator-bond";
}): Promise<PersistedFederationBondProof>;
export declare function submitFederationBondProof(opts?: {
    env?: NodeJS.ProcessEnv;
    cfg?: FasedAgentConfig;
    log?: FederationLogger;
    proof?: PersistedFederationBondProof;
}): Promise<{
    proof: PersistedFederationBondProof;
    token: FederationAccessToken;
}>;
export declare function createAndSubmitFederationBondProof(opts?: {
    env?: NodeJS.ProcessEnv;
    cfg?: FasedAgentConfig;
    log?: FederationLogger;
    bondId?: string;
    walletId?: string;
    amountRaw?: string;
    tier?: "none" | "basic-bond" | "operator-bond";
}): Promise<{
    proof: PersistedFederationBondProof;
    token: FederationAccessToken;
}>;
export declare function runFederationAutoConnectOnce(opts?: {
    env?: NodeJS.ProcessEnv;
    log?: FederationLogger;
}): Promise<AutoConnectResult>;
export declare function startFederationAutoConnect(opts?: {
    env?: NodeJS.ProcessEnv;
    log?: FederationLogger;
}): {
    stop: () => void;
    state: AutoConnectResult;
} | null;
export {};
