Restricting worker access?

Hi, is it possible to restrict the domain that workers are called from?
4 Replies
neuner
neuner8mo ago
yes you can add different routes to your worker or reject traffic in the worker based on the hostname
Nick
NickOP8mo ago
hey neu, thanks for the reply - is that by firewall rule?
Beny
Beny8mo ago
No it's configured on the worker itself. You can read about it here: https://developers.cloudflare.com/workers/configuration/routing/routes/#set-up-a-route
Cloudflare Docs
Routes · Cloudflare Workers docs
Routes allow users to map a URL pattern to a Worker. When a request comes in to the Cloudflare network that matches the specified URL pattern, your …
Nick
NickOP8mo ago
Thanks a lot Beny, I'll have a read
Want results from more Discord servers?
Add your server