import { type CustomInterfaceDefinition, type CustomInterfaceError, type CustomInterfaceGate } from "./customInterfaceDefiner.js";
export type CustomInterfaceManagerErrorCode = CustomInterfaceError["code"] | "DUPLICATE_INTERFACE" | "INTERFACE_NOT_FOUND" | "INTERFACE_DISABLED";
export type ManagedCustomInterfaceStatus = "registered" | "disabled";
export type CustomInterfaceManagerError = Omit<CustomInterfaceError, "code"> & {
    code: CustomInterfaceManagerErrorCode;
};
export type CustomInterfaceManagerDescriptor = {
    definition: CustomInterfaceDefinition;
    status?: ManagedCustomInterfaceStatus;
};
export type ManagedCustomInterface = CustomInterfaceDefinition & {
    status: ManagedCustomInterfaceStatus;
};
export type CustomInterfaceResolveResult = {
    ok: true;
    interface: ManagedCustomInterface;
    events: readonly string[];
} | {
    ok: false;
    error: CustomInterfaceManagerError;
    events: readonly string[];
};
export type CustomInterfaceManager = {
    interfaces: readonly ManagedCustomInterface[];
    list: () => readonly ManagedCustomInterface[];
    has: (interfaceId: string) => boolean;
    resolve: (interfaceId: string) => CustomInterfaceResolveResult;
};
export type CustomInterfaceManagerRequest = {
    interfaces?: readonly CustomInterfaceManagerDescriptor[];
    contract?: CustomInterfaceGate;
    governance?: CustomInterfaceGate;
};
export type CustomInterfaceManagerResult = {
    ok: true;
    manager: CustomInterfaceManager;
    events: readonly string[];
} | {
    ok: false;
    error: CustomInterfaceManagerError;
    events: readonly string[];
};
export declare function createCustomInterfaceManager(request?: CustomInterfaceManagerRequest): CustomInterfaceManagerResult;
