import type { AppChannelManager } from "./AppChannelManager";
import type { ServiceInfo, ConnectResult } from "@edenapp/types";
/**
 * AppChannelHandler
 *
 * IPC handler for AppBus operations.
 * Exposes service registration and channel connection
 * via Eden's decorator-based IPC system.
 */
export declare class AppChannelHandler {
    private channelManager;
    constructor(channelManager: AppChannelManager);
    /**
     * Register a service that this app exposes
     * Requires "appbus/expose" permission
     */
    handleRegister(args: {
        serviceName: string;
        description?: string;
        allowedClients?: string[];
        _callerAppId: string;
        _callerWebContentsId: number;
    }): Promise<{
        success: boolean;
        error?: string;
    }>;
    /**
     * Unregister a service
     * Requires "appbus/expose" permission
     */
    handleUnregister(args: {
        serviceName: string;
        _callerAppId: string;
    }): Promise<{
        success: boolean;
    }>;
    /**
     * List all available services
     * No permission required
     */
    handleList(): Promise<{
        services: ServiceInfo[];
    }>;
    /**
     * List services by app ID
     * No permission required
     */
    handleListByApp(args: {
        appId: string;
    }): Promise<{
        services: ServiceInfo[];
    }>;
    /**
     * Connect to another app's service
     * Creates MessageChannel and transfers ports directly to both apps
     * Requires "appbus/connect" permission
     */
    handleConnect(args: {
        targetAppId: string;
        serviceName: string;
        _callerAppId: string;
        _callerWebContentsId: number;
    }): Promise<ConnectResult>;
}
//# sourceMappingURL=AppChannelHandler.d.ts.map