import type { PageContent, PageNode, PageWriteInput, PageSearchHit } from '../../shared/types.js';
export declare class PagesService {
    readonly root: string;
    constructor(cwd: string, pagesDir?: string);
    ensureRoot(): Promise<void>;
    listTree(): Promise<PageNode[]>;
    listMarkdownFiles(): Promise<string[]>;
    read(relPath: string): Promise<PageContent>;
    write(relPath: string, input: PageWriteInput): Promise<PageContent>;
    remove(relPath: string): Promise<void>;
    search(query: string, limit?: number): Promise<PageSearchHit[]>;
    exists(relPath: string): Promise<boolean>;
    private resolveSafe;
    private collectMd;
    private walk;
}
