Prompt Buddy logoPrompt Buddy

cloudflare · Cloudflare Workers Docs

Workers Modify response

A guide on how to fetch and modify immutable response properties by creating a copy of the response object within a Cloudflare Worker.

Import to Prompt Buddy

Derived skill

Files assembled from official documentation

Viewing SKILL.md

Workers Modify response

A guide on how to fetch and modify immutable response properties by creating a copy of the response object within a Cloudflare Worker.

When To Use

Use when you need to change headers, status codes, or body content of a response that is otherwise immutable in a Cloudflare Worker environment.

Reference Files

FileContainsUse For
SKILL.mdEntry point: scope, routing table, and workflow.Start here.
docs/workers-examples-modify-response-workflow-guide.mdA markdown guide demonstrating how to fetch and modify immutable response properties by creating a copy within a Cloudflare Worker.Questions about a markdown guide demonstrating how to fetch and modify immutable response properties by creating a copy within a Clou...
examples/workers-examples-modify-response-cloudflare-workers-modify-response-java.textA JavaScript example demonstrating how to construct a new Response object to modify immutable response properties in a Cloudflare Worker.Exact payloads, commands, or snippets shown in A JavaScript example demonstrating how to construct a new Response object to modify immutable response properties in...
examples/workers-examples-modify-response-cloudflare-workers-modify-response.textA JavaScript example demonstrating how to construct a new Response object to modify immutable response properties in a Cloudflare Worker.Exact payloads, commands, or snippets shown in A JavaScript example demonstrating how to construct a new Response object to modify immutable response properties in...
examples/workers-examples-modify-response-cloudflare-workers-python-modify-respon.textA Python example demonstrating how to create a new Response object to modify immutable headers in a Cloudflare Worker.Exact payloads, commands, or snippets shown in A Python example demonstrating how to create a new Response object to modify immutable headers in a Cloudflare Worker.
examples/workers-examples-modify-response-cloudflare-workers-hono-modify-response.textA Hono framework example demonstrating how to create a new response object to modify immutable response headers in a Cloudflare Worker.Exact payloads, commands, or snippets shown in A Hono framework example demonstrating how to create a new response object to modify immutable response headers in a...

What This Skill Covers

  • Fetch and modify response properties which are immutable by creating a copy first.
  • Main sections: Tags.

Workflow

  1. Open the most relevant file under docs/ for the exact documented workflow and wording.
  2. Open schemas/ files for exact structured contracts.
  3. Open examples/ files for concrete requests, commands, snippets, and manifests.
  4. Do not add behavior or configuration that is not present in the attached source files.

Canonical source: https://developers.cloudflare.com/workers/examples/modify-response