Apollo HTTP Data Source
JSON →apollo-datasource-http is an optimized HTTP data source for Apollo Server, designed to enhance performance when fetching JSON data from REST APIs. Currently at version 0.21.0, it is actively developed with a frequent release cadence, though it explicitly warns that releases are pre-1.0 and may introduce breaking changes. Its key differentiators include leveraging the high-performance Undici HTTP client (claiming up to 60% faster than `apollo-datasource-rest`), integrated request deduplication via LRU caching, configurable request caching with TTL, and `stale-if-error` capabilities. It also supports `AbortController` for manual request cancellation and integrates with Apollo Cache Storage backends for advanced caching strategies. This data source aims to provide a robust and efficient solution for connecting Apollo Server to external HTTP services, offering fine-grained control over request lifecycle and caching behavior through a hook-based API.
Traffic · last 30 days ↓36% vs prev 7d
top countries 🇺🇸 United States · 🇩🇪 Germany · 🇸🇬 Singapore · 🇨🇦 Canada · 🇬🇧 United Kingdom