Skip to content

Commit acfcd34

Browse files
author
Andrei Berlin
committed
Remove unsafe from Rate Limiting API bindings
1 parent cc8c0bb commit acfcd34

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/content/docs/workers/runtime-apis/bindings/rate-limit.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ First, add a [binding](/workers/runtime-apis/bindings) to your Worker that gives
3030
```toml
3131
main = "src/index.js"
3232

33-
[[unsafe.bindings]]
33+
[[ratelimits]]
3434
name = "MY_RATE_LIMITER"
3535
type = "ratelimit"
3636
# 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
104104
main = "src/index.js"
105105

106106
# Free user rate limiting
107-
[[unsafe.bindings]]
107+
[[ratelimits]]
108108
name = "FREE_USER_RATE_LIMITER"
109109
type = "ratelimit"
110110
namespace_id = "1001"
111111
simple = { limit = 100, period = 60 }
112112

113113
# Paid user rate limiting
114-
[[unsafe.bindings]]
114+
[[ratelimits]]
115115
name = "PAID_USER_RATE_LIMITER"
116116
type = "ratelimit"
117117
namespace_id = "1002"
@@ -135,7 +135,7 @@ For example, to apply a rate limit of 1500 requests per minute, you would define
135135
<WranglerConfig>
136136

137137
```toml
138-
[[unsafe.bindings]]
138+
[[ratelimits]]
139139
name = "MY_RATE_LIMITER"
140140
type = "ratelimit"
141141
namespace_id = "1001"

0 commit comments

Comments
 (0)