/**
 * Documentation search for B2C Commerce Script API.
 *
 * Provides functions for downloading documentation from B2C instances
 * and searching bundled documentation locally.
 *
 * ## Download Documentation
 *
 * Use {@link downloadDocs} to download documentation from a B2C instance:
 *
 * ```typescript
 * import { downloadDocs } from '@salesforce/b2c-tooling-sdk/docs';
 * import { B2CInstance } from '@salesforce/b2c-tooling-sdk';
 *
 * const instance = B2CInstance.fromEnvironment();
 * const result = await downloadDocs(instance, { outputDir: './docs' });
 * console.log(`Downloaded ${result.fileCount} files`);
 * ```
 *
 * ## Search Bundled Docs
 *
 * Use {@link searchDocs} and {@link readDocByQuery} to search and read bundled documentation:
 *
 * ```typescript
 * import { searchDocs, readDocByQuery } from '@salesforce/b2c-tooling-sdk/docs';
 *
 * // Search for documentation
 * const results = searchDocs('ProductMgr');
 * results.forEach(r => console.log(r.entry.id, r.score));
 *
 * // Read a specific doc by fuzzy query
 * const doc = readDocByQuery('dw.catalog.ProductMgr');
 * if (doc) {
 *   console.log(doc.content);
 * }
 * ```
 *
 * @module docs
 */
export type { DocEntry, SearchIndex, SearchResult, SchemaEntry, SchemaIndex, SchemaSearchResult } from './types.js';
export { searchDocs, readDoc, readDocByQuery, listDocs, loadSearchIndex } from './search.js';
export { listSchemas, readSchema, readSchemaByQuery, searchSchemas } from './schema.js';
export { downloadDocs } from './download.js';
export type { DownloadDocsOptions, DownloadDocsResult } from './download.js';
