Home / Servers / Cloudflare API / worker_environment_put_script_content
Replace Worker Environment Script Content
An MCP tool from the Cloudflare API server, hosted on mcp.hjlabs.in.
Replace Worker Environment Script Content Replace Worker script content for an environment. [PUT /accounts/{account_id}/workers/services/{service_name}/environments/{environment_name}/content]
Name on the gateway: cloudflare_api__worker_environment_put_script_content · may change things.
Parameters
| Name | Type | Description |
|---|---|---|
account_id required | string | account_id parameter |
service_name required | string | service_name parameter |
environment_name required | string | environment_name parameter |
files | array | An array of modules (often JavaScript files)… |
metadata required | object | JSON-encoded metadata about the uploaded parts… |
How to call it
Through the Smart Gateway, any client can run it by name with call_tool, or let the gateway find it with search_tools:
{
"name": "cloudflare_api__worker_environment_put_script_content",
"arguments": {
"account_id": "…",
"service_name": "…",
"environment_name": "…",
"metadata": "…"
}
}Or connect the Cloudflare API server directly, which lists 3,127 tools including this one:
claude mcp add --transport http hj-cloudflare-api https://mcp.hjlabs.in/mcp/cloudflare-api \
--header "Authorization: Bearer YOUR_API_KEY"Try asking
Use the replace worker environment script content tool with account_id set to ….