/** * IPFS service for accessing beacon data from IPFS/IPNS */ import type { BeaconData, BeaconComparison, IPFSConfig, IPFSBeaconRequest, ServiceResult, RequestOptions } from '../types'; /** * IPFS service class for beacon data access */ export declare class BeaconService { private config; private gateway; private debug; constructor(config?: IPFSConfig, debug?: boolean); /** * Validates if a path is a valid IPFS/IPNS path * @param path - Path to validate * @returns True if valid IPFS/IPNS path */ private isValidPath; /** * Reads beacon data from IPFS gateway * @param path - IPFS/IPNS path * @param timeout - Request timeout * @returns Promise resolving to beacon data */ private readViaGateway; /** * Reads beacon data from IPFS API * @param path - IPFS/IPNS path * @param timeout - Request timeout * @returns Promise resolving to beacon data */ private readViaApi; /** * Parses beacon JSON data * @param jsonText - Raw JSON text * @returns Parsed beacon data */ private parseBeacon; /** * Compares beacon data from different sources * @param gateway - Gateway beacon data * @param api - API beacon data * @returns Comparison result */ private compareBeaconData; /** * Reads beacon data from multiple sources * @param path - IPFS/IPNS path * @param sources - Sources to read from * @param timeout - Request timeout * @returns Promise resolving to beacon data from all sources */ private readFromSources; /** * Gets beacon data from IPFS/IPNS * @param request - Beacon request parameters * @param options - Request options * @returns Promise resolving to beacon data */ getBeacon(request: IPFSBeaconRequest, options?: RequestOptions): Promise>; /** * Gets beacon data with automatic fallback * @param path - IPFS/IPNS path * @param options - Request options * @returns Promise resolving to beacon data */ getBeaconWithFallback(path: string, options?: RequestOptions): Promise>; /** * Gets beacon data with block traversal * @param request - Beacon request parameters with block traversal * @param options - Request options * @returns Promise resolving to beacon data at specified block */ getBeaconWithBlockTraversal(request: IPFSBeaconRequest & { block?: number | 'INF'; }, options?: RequestOptions): Promise>; /** * Updates IPFS configuration * @param newConfig - New IPFS configuration */ updateConfig(newConfig: Partial): void; } //# sourceMappingURL=ipfs.d.ts.map