import type { BaseConnector } from '../../connector/BaseConnector.js';
import type { BaseExecutionContext } from '../../execution/base.js';
import type { ConnectorRegistry } from '../../registry/connector/definitions.js';
import type { ScopedConnectorRegistry } from '../../registry/connector/scoped.js';
import type { ConnectorConfig, ConnectorEventListener, ConnectorExecuteParams, ConnectorExecuteResult, ConnectorInstance, CredentialVault, EnvironmentDescriptor, ExecutionContextConfig, ResolvedConnectorConfig, ScopeChain } from '../../types/connector/index.js';
import type { ConnectorId, EnvironmentId } from '../../types/ids/index.js';
import { ConnectorManager } from './lifecycle.js';
export interface EnvironmentConnectorSetup {
    environment: EnvironmentDescriptor;
    scopeChain: ScopeChain;
    executionContext?: ExecutionContextConfig;
    connectorOverrides?: Record<ConnectorId, Partial<ConnectorConfig>>;
}
export interface EnvironmentConnectorManagerConfig {
    connectorRegistry: ConnectorRegistry;
    scopedRegistry: ScopedConnectorRegistry;
    credentialVault?: CredentialVault;
}
export declare class EnvironmentConnectorManager {
    private environments;
    private connectorRegistry;
    private scopedRegistry;
    private credentialVault;
    private listeners;
    private log;
    constructor(config: EnvironmentConnectorManagerConfig);
    registerEnvironment(setup: EnvironmentConnectorSetup): void;
    initializeEnvironment(envId: EnvironmentId): Promise<void>;
    unregisterEnvironment(envId: EnvironmentId): Promise<void>;
    getEnvironment(envId: EnvironmentId): EnvironmentDescriptor | undefined;
    listEnvironments(): EnvironmentDescriptor[];
    resolveConnectorConfig(envId: EnvironmentId, connectorId: ConnectorId): ResolvedConnectorConfig | undefined;
    createConnectorFromScope(envId: EnvironmentId, connectorId: ConnectorId, connector: BaseConnector<unknown>): Promise<ConnectorInstance>;
    connect(envId: EnvironmentId, instanceId: import('../../types/ids/index.js').ConnectorInstanceId): Promise<void>;
    disconnect(envId: EnvironmentId, instanceId: import('../../types/ids/index.js').ConnectorInstanceId): Promise<void>;
    execute(envId: EnvironmentId, params: ConnectorExecuteParams): Promise<ConnectorExecuteResult>;
    healthCheck(envId: EnvironmentId, instanceId: import('../../types/ids/index.js').ConnectorInstanceId): Promise<boolean>;
    listInstances(envId: EnvironmentId): ConnectorInstance[];
    listConnectedInstances(envId: EnvironmentId): ConnectorInstance[];
    getExecutionContext(envId: EnvironmentId): BaseExecutionContext | undefined;
    getConnectorManager(envId: EnvironmentId): ConnectorManager;
    getScopedRegistry(): ScopedConnectorRegistry;
    getCredentialVault(): CredentialVault | undefined;
    teardownAll(): Promise<void>;
    on(listener: ConnectorEventListener): void;
    off(listener: ConnectorEventListener): void;
    private emit;
    private getEnvironmentOrThrow;
}
//# sourceMappingURL=environment.d.ts.map