/** * Shared article-fetch service * * Consolidates the duplicated fetch-parse-tokenize pipeline that was in * both get-article.ts and batch-get-articles.ts into a single function. * * Key optimization: metadata and content are fetched in parallel via * Promise.all when the cache misses. */ import type { CacheProvider } from './interfaces/cache.js'; import type { ServerContext } from '../types/context.js'; import type { FetchArticleResult, FetchArticleOptions } from '../types.js'; import { type TopicResolverInput } from './topic-resolver.js'; export declare function fetchArticleFromFt(cache: CacheProvider, mapId: string, contentId: string, articleUrl: string, options: FetchArticleOptions, cacheTtl?: number): Promise; /** * Full article retrieval pipeline: * 1. Resolve mapId + contentId (skip if already provided) * 2. Try provider shortcuts (articleProvider) * 3. Fall back to FT API via fetchArticleFromFt * * Both get-article and batch-get-articles delegate here. */ export declare function resolveAndFetchArticle(ctx: ServerContext, input: TopicResolverInput, options: FetchArticleOptions): Promise; //# sourceMappingURL=article-service.d.ts.map