cloudflare · Cloudflare Workers Docs
Workers Read POST
Demonstrates how to serve an HTML form and process incoming POST requests, including handling JSON data and using request.clone() to prevent errors when accessing the request body multiple times.
Derived skill
Files assembled from official documentation
Viewing SKILL.md
Workers Read POST
Demonstrates how to serve an HTML form and process incoming POST requests, including handling JSON data and using request.clone() to prevent errors when accessing the request body multiple times.
When To Use
Use when you need to implement a worker that accepts form submissions or JSON payloads and requires reading the request body more than once without triggering a TypeError.
Reference Files
| File | Contains | Use For |
|---|---|---|
SKILL.md | Entry point: scope, routing table, and workflow. | Start here. |
docs/workers-examples-read-post-workflow-guide.md | A markdown guide demonstrating how to serve an HTML form and process incoming POST requests containing JSON or form data within a Cloudflare Worker. | Questions about a markdown guide demonstrating how to serve an HTML form and process incoming POST requests containing JSON or form d... |
examples/workers-examples-read-post-cloudflare-workers-read-post-request.text | A JavaScript example demonstrating how to read the body of an incoming POST request within a Cloudflare Worker. | Exact payloads, commands, or snippets shown in A JavaScript example demonstrating how to read the body of an incoming POST request within a Cloudflare Worker. |
examples/workers-examples-read-post-cloudflare-workers-read-post-request-body.text | A JavaScript example demonstrating how to read the body of an incoming POST request within a Cloudflare Worker. | Exact payloads, commands, or snippets shown in A JavaScript example demonstrating how to read the body of an incoming POST request within a Cloudflare Worker. |
examples/workers-examples-read-post-cloudflare-workers-python-read-post-request-b.text | A Python implementation demonstrating how to parse and return request body data from different content types in a Cloudflare Worker. | Exact payloads, commands, or snippets shown in A Python implementation demonstrating how to parse and return request body data from different content types in a Clo... |
examples/workers-examples-read-post-cloudflare-workers-rust-read-post-request.text | A Rust code example demonstrating how to parse a JSON request body from a POST request using the worker crate and serde. | Exact payloads, commands, or snippets shown in A Rust code example demonstrating how to parse a JSON request body from a POST request using the worker crate and serde. |
examples/workers-examples-read-post-cloudflare-workers-hono-read-post-request.text | A TypeScript example using the Hono framework to parse and read the body of an incoming POST request in a Cloudflare Worker. | Exact payloads, commands, or snippets shown in A TypeScript example using the Hono framework to parse and read the body of an incoming POST request in a Cloudflare... |
What This Skill Covers
- Serve an HTML form, then read POST requests. Use also to read JSON or POST data from an incoming request.
- Main sections:
Tags.
Workflow
- Open the most relevant file under
docs/for the exact documented workflow and wording. - Open
schemas/files for exact structured contracts. - Open
examples/files for concrete requests, commands, snippets, and manifests. - Do not add behavior or configuration that is not present in the attached source files.
Canonical source: https://developers.cloudflare.com/workers/examples/read-post
