@vercaemer/rate-limiter

Basic rate limiter for Cloudflare Durable Objects with no dependencies.


License
MIT
Install
npm install @vercaemer/rate-limiter@0.1.0

Documentation

@vercaemer/rate-limiting

A no-dependencies minimal rate limiter for Cloudflare Durable Objects

Currently it supports:

  • Sliding Window Rate Limiting
  • Multiple limits per request
  • Caching limited keys to save usage

To do:

  • Fixed Window Rate Limiting

See example for usage.

Contributing

To install dependencies:

bun install

To run:

bun run src/index.ts

This project was created using bun init in bun v1.0.14. Bun is a fast all-in-one JavaScript runtime.