/**
 * Azure DevOps Area Path Mapper
 *
 * Fetches, parses, and maps ADO area paths to SpecWeave project IDs.
 * Supports hierarchical area paths with granularity selection:
 * - Top-level only (e.g., Backend, Frontend)
 * - Two-level (e.g., Backend-API, Backend-Database)
 * - Full tree (all levels)
 *
 * Enables multi-project organization in ADO
 *
 * @module integrations/ado/area-path-mapper
 */
import type { Logger } from '../../utils/logger.js';
export interface AreaPathNode {
    id: string;
    name: string;
    path: string;
    level: number;
    parentPath?: string;
    children?: AreaPathNode[];
    hasChildren: boolean;
}
export interface AdoCredentials {
    organization: string;
    pat: string;
}
export type AreaPathGranularity = 'top-level' | 'two-level' | 'full-tree';
export interface AreaPathMapperOptions {
    credentials: AdoCredentials;
    project: string;
    logger?: Logger;
}
/**
 * Area Path Mapper for Azure DevOps
 *
 * Fetches hierarchical area path structures and maps them to SpecWeave project IDs.
 */
export declare class AreaPathMapper {
    private credentials;
    private project;
    private logger;
    private apiVersion;
    constructor(options: AreaPathMapperOptions);
    /**
     * Fetch area path tree from ADO
     *
     * Fetches the full hierarchical area path structure for the project.
     * Uses $depth=10 to get deep hierarchies.
     *
     * @returns Root area path node with children
     */
    fetchAreaPaths(): Promise<AreaPathNode>;
    /**
     * Parse area path tree recursively
     *
     * Converts ADO API response to normalized AreaPathNode tree structure.
     *
     * @param node - Raw ADO API node
     * @param level - Current depth level (0 = root)
     * @param parentPath - Parent area path
     * @returns Parsed area path node
     */
    parseAreaPathTree(node: any, level: number, parentPath: string): AreaPathNode;
    /**
     * Map area path to SpecWeave project ID
     *
     * Converts hierarchical area path to kebab-case project ID.
     * Excludes root project name.
     *
     * Examples:
     * - "Platform/Backend/API" → "backend-api"
     * - "Platform/Frontend" → "frontend"
     * - "Platform" → "platform"
     *
     * @param areaPath - Full area path (e.g., "Platform/Backend/API")
     * @returns Kebab-case project ID
     */
    mapToProjectId(areaPath: string): string;
    /**
     * Convert string to kebab-case
     *
     * @param str - Input string
     * @returns Kebab-case string
     */
    private toKebabCase;
    /**
     * Flatten area paths with granularity selection
     *
     * Extracts nodes at specific level(s) from the tree.
     *
     * @param root - Root area path node
     * @param granularity - Desired granularity level
     * @returns Flattened array of nodes
     */
    flattenAreaPaths(root: AreaPathNode, granularity: AreaPathGranularity): AreaPathNode[];
    /**
     * Get nodes at specific level
     *
     * Recursively collects nodes at the target depth level.
     * If a branch doesn't reach the target level, includes the deepest node in that branch.
     *
     * @param node - Current node
     * @param targetLevel - Target depth level
     * @returns Nodes at target level (or deepest available)
     */
    private getNodesByLevel;
    /**
     * Get all nodes (flatten entire tree)
     *
     * @param node - Root node
     * @returns All nodes in tree
     */
    private getAllNodes;
    /**
     * Prompt user for granularity selection
     *
     * Interactive CLI prompt to select area path granularity.
     *
     * @param areaPathTree - Area path tree for preview
     * @returns Selected granularity
     */
    promptAreaPathGranularity(areaPathTree: AreaPathNode): Promise<AreaPathGranularity>;
    /**
     * Get area path suggestions for project
     *
     * Analyzes area path tree and suggests best granularity based on structure.
     *
     * @param areaPathTree - Area path tree
     * @returns Suggested granularity with reasoning
     */
    suggestGranularity(areaPathTree: AreaPathNode): {
        suggested: AreaPathGranularity;
        reasoning: string;
    };
}
//# sourceMappingURL=area-path-mapper.d.ts.map