From acfcd342973cbeb4d0db58c0de2559e3dddd7867 Mon Sep 17 00:00:00 2001 From: Andrei Berlin Date: Wed, 3 Sep 2025 15:04:38 +0200 Subject: [PATCH] Remove unsafe from Rate Limiting API bindings --- .../docs/workers/runtime-apis/bindings/rate-limit.mdx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/content/docs/workers/runtime-apis/bindings/rate-limit.mdx b/src/content/docs/workers/runtime-apis/bindings/rate-limit.mdx index 20d305ad49aa99..f41796d5b507a8 100644 --- a/src/content/docs/workers/runtime-apis/bindings/rate-limit.mdx +++ b/src/content/docs/workers/runtime-apis/bindings/rate-limit.mdx @@ -30,7 +30,7 @@ First, add a [binding](/workers/runtime-apis/bindings) to your Worker that gives ```toml main = "src/index.js" -[[unsafe.bindings]] +[[ratelimits]] name = "MY_RATE_LIMITER" type = "ratelimit" # An identifier you define, that is unique to your Cloudflare account. @@ -104,14 +104,14 @@ For example, here is how you can define two rate limiting configurations for fre main = "src/index.js" # Free user rate limiting -[[unsafe.bindings]] +[[ratelimits]] name = "FREE_USER_RATE_LIMITER" type = "ratelimit" namespace_id = "1001" simple = { limit = 100, period = 60 } # Paid user rate limiting -[[unsafe.bindings]] +[[ratelimits]] name = "PAID_USER_RATE_LIMITER" type = "ratelimit" namespace_id = "1002" @@ -135,7 +135,7 @@ For example, to apply a rate limit of 1500 requests per minute, you would define ```toml -[[unsafe.bindings]] +[[ratelimits]] name = "MY_RATE_LIMITER" type = "ratelimit" namespace_id = "1001"