import type { AgentProject } from '../agent-project/agent-project.js';
/**
 * Merges integration configuration for API calls.
 * - If no local config is defined (undefined), preserves server-side config entirely.
 * - If local config is defined, merges it on top of server-side config (local wins per-key).
 */
export declare function mergeIntegrationConfig(current: Record<string, unknown> | undefined, desired: Record<string, unknown> | undefined): Record<string, unknown>;
export interface FetchServerConfigsResult {
    configs: Record<string, Record<string, unknown>>;
    enabledStates: Record<string, boolean>;
    /**
     * Per-integration *authorization* state on the target bot, from `getBot`: `true` when the
     * cloud integration has an `identifier` (the OAuth/connection flow was completed). Distinct
     * from `enabledStates`: a managed-OAuth integration can be `enabled` yet unauthorized
     * (toggled on, never connected), which Cloud's `register` hook hard-fails on. Codegen uses
     * this to leave an unauthorized auth-gated integration inert (`enabled: false`) instead of
     * letting the whole `bp` deploy/dev boot abort. A missing alias means the integration is not
     * on the cloud bot yet (treated as unauthorized). Mirrors `bp`'s own
     * `isAuthorized = !!integration.identifier`.
     */
    authorizedStates: Record<string, boolean>;
    fetched: boolean;
    skipped: boolean;
    error?: string;
}
/**
 * Fetches current integration configurations from the server for a given bot.
 *
 * When `targetBotId` is provided, fetches from that specific bot (used during
 * deploy/build to fetch from the production bot). Otherwise falls back to
 * devId → botId resolution (used during adk dev to fetch from the dev bot).
 */
export declare function fetchServerIntegrationConfigs(project: AgentProject, targetBotId?: string): Promise<FetchServerConfigsResult>;
export type FetchServerPluginConfigsResult = {
    configs: Record<string, Record<string, unknown>>;
    fetched: boolean;
    skipped: boolean;
    error?: string;
};
export declare function fetchServerPluginConfigs(project: AgentProject, targetBotId?: string): Promise<FetchServerPluginConfigsResult>;
//# sourceMappingURL=config-utils.d.ts.map