cloudflare_worker_route_create
Map a URL pattern to a Cloudflare Worker script for a zone. Provide zone, pattern, and script name to create the route.
Instructions
Create a Workers route that maps a URL pattern to a Worker script for a zone.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"zone_id": "<zone_id>",
"pattern": "<pattern>",
"script": "<script>"
},
"name": "cloudflare_worker_route_create"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| script | Yes | Worker script name to route to | |
| pattern | Yes | URL pattern to match (e.g., '*.example.com/api/*') | |
| zone_id | Yes | Zone ID (32-char hex) or zone name (e.g., 'example.com') |