Skip to content

Latest commit

 

History

History
15 lines (11 loc) · 9.58 KB

updatekeyratelimit.md

File metadata and controls

15 lines (11 loc) · 9.58 KB

UpdateKeyRatelimit

Unkey comes with per-key ratelimiting out of the box. Set null to disable.

Fields

Field Type Required Description
limit int ✔️ The total amount of requests allowed in a single window.
type Optional[models.UpdateKeyType] : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Fast ratelimiting doesn't add latency, while consistent ratelimiting is more accurate.
Deprecated, use 'async' instead

Learn more
async_ Optional[bool] Asnyc ratelimiting doesn't add latency, while sync ratelimiting is slightly more accurate.

Learn more
refill_rate Optional[int] : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

How many tokens to refill during each refillInterval.
Deprecated, use 'limit' instead.
refill_interval Optional[int] : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Determines the speed at which tokens are refilled, in milliseconds.
Deprecated, use 'duration'
duration Optional[int] The duration of each ratelimit window, in milliseconds.
This field will become required in a future version.