Explore projects
TypeScriptadvancedweb
Distributed Rate Limiter as a Service
Distributed HTTP rate limiting service with sliding window algorithm, Redis backend, TypeScript SDK, and metrics dashboard.
5 steps
Project steps
- 01
Sliding window Redis
Implement the sliding window algorithm with sorted sets in Redis.
- 02
HTTP API Fastify
POST /check endpoint: {key, limit, window} → {allowed, remaining, resetAt}.
- 03
SDK TypeScript
Publish an npm package with a type-safe client and retry logic.
- 04
Multi-tenancy
Isolate limits per API key with Redis namespaces.
- 05
Prometheus Metrics
Expose /metrics with counters per key, p99 latency, rejected rate.
Recommended resources
Ready to build this?
Fork the repo on GitHub and start building. A mentor will review your code when you open a PR.
5 steps
Tech stack
Node.jsTypeScriptRedisFastifyPrometheusGrafana