/** * FHIR Package Registry API Client * * Communicates with packages.fhir.org to fetch package metadata and download tarballs. * * API Endpoints: * - List versions: GET https://packages.fhir.org/ * - Download: GET https://packages.fhir.org// * - Search by canonical: GET https://packages.fhir.org?canonical= */ import type { PackageInfo, PackageManifest } from './package-registry-types.js'; export type { PackageInfo, PackageManifest, PackageVersion } from './package-registry-types.js'; export declare class PackageRegistryClient { private fhirRegistryUrl; private simplifierUrl; private timeout; private manifestCache; constructor(timeout?: number, // Reduced from 30s to 10s to prevent hangs maxCacheEntries?: number); /** * Fetch package manifest (list of versions) * Tries Simplifier.net first for UK Core packages, then FHIR registry */ fetchPackageManifest(packageId: string): Promise; /** * Fetch from a specific registry URL */ private fetchFromRegistry; /** * Determine if package should try Simplifier.net first */ private shouldUseSimplifier; /** * Get package info for a specific version (or latest) */ getPackageInfo(packageId: string, version?: string): Promise; /** * Download package tarball */ downloadPackageTarball(packageId: string, version: string, maxBytes?: number): Promise; /** * Detect package ID from profile URL * First tries known patterns, then falls back to generic ProfilePackageMapper */ detectPackageForProfile(profileUrl: string): Promise; private registryName; /** * Clear cache */ clearCache(): void; getCacheStats(): { size: number; maxSize: number; packageIds: string[]; hits: number; misses: number; evictions: number; staleEvictions: number; }; } export declare const packageRegistryClient: PackageRegistryClient; //# sourceMappingURL=package-registry-client.d.ts.map