cole
CDCloudflare Developers
•Created by cole on 2/25/2025 in #workers-help
Variables not available in pages build?

3 replies
CDCloudflare Developers
•Created by cole on 2/21/2025 in #workers-help
Websockets with Workers
Howdy y'all! I have a worker that is functioning as a websocket server. Everything works fantastically:
- locally / in dev
- in production if I use a CLI to interact
The second I wire up a browser to it, things start failing though. And what's worse, the failing has almost no details anywhere that I can find. The connection succeeds and then immediately closes. No logs on the backend, and logs on the frontend are code 1006 ("i dunno what happened").
Has anyone seen this before? Any ideas where to dig in? It feels like either browser security (no luck on making CORS permissive) or something strange Cloudflare is doing.
9 replies
CDCloudflare Developers
•Created by cole on 1/11/2024 in #workers-help
R2 Access Via Domain is Down?

32 replies
CDCloudflare Developers
•Created by cole on 12/28/2023 in #workers-help
form data with itty-router-openapi
I have a form submission going through a worker built with itty-router-openapi. If I submit the data via a POST request with standard
application/json
, everything works swimmingly. Use data.body
just like the examples, etc.
However, if I submit the data as a application/x-www-form-urlencoded
, then I get nothing.
Moreover, if I try to read FormData()
off of the request, then I get "body has already been read." Presumably the body is read during the body sanitization / verification / schema-matching done by itty-router.
Any recommendations for which direction to go here? Is there a way to access FormData
through itty-router-openapi
?
https://github.com/cloudflare/itty-router-openapi2 replies