Skip to content

Releases: adonisjs/limiter

Add support for weighted rate limiting

13 Mar 01:42

Choose a tag to compare

3.0.1 (2026-03-13)

What's Changed

New Contributors

Full Changelog: v3.0.0...v3.0.1

Tag as latest

25 Feb 09:48

Choose a tag to compare

3.0.0 (2026-02-25)

Check all 3.0.0 pre-releases to get a better sense of the changes

Full Changelog: v2.4.0...v3.0.0

Multi limiter to act on multiple limiters together

28 Oct 10:42

Choose a tag to compare

3.0.0-next.1 (2025-10-28)

In specific scenarios, we may want to act on multiple limiters in a single go, and this is where the Multi Limiter can simplify the code. For example, during login, you should prevent numerous invalid requests based on both the user's IP address and email address.

In this scenario, instead of creating 2 limiters, running the action, and, on failure, consuming one point per limiter, you can encapsulate the entire logic using the Multi Limiter and the penalize method. For example:

const ipKey = `login_${request.ip()}`
const emailKey = `login_${request.ip()}_${payload.email}`

const loginLimiter = limiter.multi([
{ duration: '1 min', requests: 10, key: ipKey },
{ duration: '1 min', requests: 5, blockDuration: '20 mins', key: emailKey },
])

await loginLimiter.penalize(() => {
  return User.verifyCredentials(payload.email, payload.password)
})

Features

  • add multi limiter to execute an action on multiple limiters (7d35687)

Full Changelog: v3.0.0-next.0...v3.0.0-next.1

Target v7

22 Sep 12:38

Choose a tag to compare

Target v7 Pre-release
Pre-release

3.0.0-next.0 (2025-09-22)

Full Changelog: v2.4.0...v3.0.0-next.0

Add support for SQLite

15 Apr 06:22

Choose a tag to compare

2.4.0 (2025-04-15)

Features

What's Changed

New Contributors

Full Changelog: v2.3.3...v2.4.0

Update dependencies

23 Dec 05:18

Choose a tag to compare

2.3.3 (2024-12-23)

Full Changelog: v2.3.2...v2.3.3

Fix X-RateLimit-Reset header to use ISO date time strings

02 Aug 05:58

Choose a tag to compare

  • fix: format X-RateLimit-Reset header as an ISO string e7c4fbd
  • chore: update dependencies 3fa97e1

Full Changelog: v2.3.1...v2.3.2

Update dependencies

22 Jun 11:23

Choose a tag to compare

Full Changelog: v2.3.0...v2.3.1

Final set of improvements during the public release

07 Feb 05:57

Choose a tag to compare

  • refactor: make deleteInMemoryBlockedKeys method optional b7df37b
  • refactor: block keys via penalize method 49489e5
  • refactor: allow duration to be optional during set method 115ed7b
  • refactor: return error from penalize method instead of throwing it 8418a83
  • refactor: make attempt method return early if all requests have been exhausted 225a675

Full Changelog: v2.2.1...v2.3.0

Improvements to decrement and penalize methods

06 Feb 18:03

Choose a tag to compare

  • refactor: clear key when penalize method gets successful response 2133576
  • refactor: make decrement method safe from getting into negative values 1479c80

Full Changelog: v2.2.0...v2.2.1