/**
 * Claude Code Connector
 * Specialized subprocess connector for Claude Code CLI
 */
import type { TrajectoryStep } from '../../../types/index.js';
import { SubprocessConnector } from '../../../services/connectors/subprocess/SubprocessConnector.js';
import type { ConnectorAuth, ConnectorRequest, ConnectorProgressCallback, SubprocessConfig } from '../../../services/connectors/types.js';
/**
 * MCP server definition for Claude Code --mcp-config flag
 */
export interface ClaudeCodeMCPServer {
    command: string;
    args?: string[];
    env?: Record<string, string>;
}
/**
 * Configuration options for Claude Code connector
 * Passed via agent.connectorConfig in agent-health.config.ts
 */
export interface ClaudeCodeConnectorConfig {
    env?: Record<string, string>;
    dangerouslySkipPermissions?: boolean;
    allowedTools?: string[];
    disallowedTools?: string[];
    appendSystemPrompt?: string;
    systemPrompt?: string;
    /** Path to a standard MCP config JSON file (passed to --mcp-config) */
    mcpConfigPath?: string;
    /** Inline MCP server definitions (used when mcpConfigPath is not set) */
    mcpServers?: Record<string, ClaudeCodeMCPServer>;
    strictMcpConfig?: boolean;
    usePromptArg?: boolean;
    workingDir?: string;
    timeout?: number;
    additionalArgs?: string[];
}
/**
 * Claude Code CLI Connector
 * Invokes Claude Code as a subprocess for agent evaluation
 */
export declare class ClaudeCodeConnector extends SubprocessConnector {
    readonly type: "claude-code";
    readonly name = "Claude Code CLI";
    traceContext: {
        propagateEnv: boolean;
        serviceName: string;
    };
    private outputBuffer;
    private thinkingBuffer;
    private textBuffer;
    private isInThinking;
    constructor(config?: Partial<SubprocessConfig>);
    /**
     * Build prompt for Claude Code
     * Structures the input to get the best RCA results
     */
    buildPayload(request: ConnectorRequest): string;
    /**
     * Parse Claude Code streaming output (stream-json format)
     * Each line is a JSON object with type and content
     */
    protected parseStreamingOutput(chunk: string, trajectory: TrajectoryStep[], onProgress?: ConnectorProgressCallback): void;
    /**
     * Parse a single JSON event from stream-json output
     */
    private parseJsonEvent;
    /**
     * Parse final output for Claude Code
     */
    parseResponse(data: {
        stdout: string;
        stderr: string;
        exitCode: number;
    }): TrajectoryStep[];
    /**
     * Reset state for new execution
     */
    private resetState;
    /**
     * Flush remaining buffers when the subprocess stream ends.
     */
    protected onBeforeStreamEnd(trajectory: TrajectoryStep[], onProgress?: ConnectorProgressCallback): void;
    /**
     * Build CLI args from ClaudeCodeConnectorConfig
     */
    private buildConfigArgs;
    /**
     * Override execute to reset state and apply connectorConfig
     */
    execute(endpoint: string, request: ConnectorRequest, auth: ConnectorAuth, onProgress?: ConnectorProgressCallback, onRawEvent?: (event: any) => void): Promise<import('../types.js').ConnectorResponse>;
    /**
     * Health check - verify claude command exists
     */
    healthCheck(endpoint: string, auth: ConnectorAuth): Promise<boolean>;
}
/**
 * Create a Claude Code connector with specific Bedrock configuration
 */
export declare function createBedrockClaudeCodeConnector(): ClaudeCodeConnector;
/**
 * Default instance for convenience
 */
export declare const claudeCodeConnector: ClaudeCodeConnector;
//# sourceMappingURL=ClaudeCodeConnector.d.ts.map