Cloudflare Developers

CD

Cloudflare Developers

Welcome to the official Cloudflare Developers server. Here you can ask for help and stay updated with the latest news

Join

CF Worker Puppeeter: Cannot read properties of undefined (reading 'fetch')

Hi I'm getting this error still after following the Docs https://developers.cloudflare.com/browser-rendering/get-started/screenshots/ It happens locally with wrangler dev --remote and in production. My src/index.js:...

How to migrate/ set region for worker.

I have observed the following regarding the latency and query response times: * Database Location: AWS ap-south-1 (Mumbai) * Server Location: California (San Francisco) * User Access Sites: Hyderabad, US...

worker route/domain for a cloudflare for plateform user worker

is that possible to bind a custom domain name to a User Worker of my cloudflare for plateform ?

Worker cronjob executions not running

I'm seeing zero scheduled executions of any of my workers via cronjobs over the last hour since 7:30 AM PST
No description

Worker is executed twice for each browser reload

Hello! I'm trying to make a Cloudflare worker in VS Code, but I'm running into a weird behavior with it. My worker has a "fetch" function in "index.ts" which I understand is the entry point for when the worker is called. Inside of that function, I'm calling some functions that fetch more resources and then call an API with a POST request (also with fetch) to process that data....

Send a request to my worker's endpoint from a cron trigger event?

So I set up a cron trigger that should send a request every 15 minutes to one of my worker's routes using fetch with await keyword. However, it seems that the request is never sent (the operation expected is not performed) while it succeeds when I use the Javascript console of any browser.

TypeScript error with global Response object

Hello! So I'm trying to build a Worker with TypeScript. I'm using the regular node-internal "fetch" which seems to return a "global.Response". When I try to make a function that takes that Response as parameter of type "Response", TS complains that Argument of type 'global.Response' is not assignable to parameter of type 'Response'. Type 'Response' is missing the following properties from type 'Response': webSocket, cf, bytes...

Dynamic require of "cloudflare:workers" is not supported

I'm trying to create a cloudflare worker that is accessed via services by another worker. I followed the example here https://developers.cloudflare.com/workers/runtime-apis/bindings/service-bindings/ The worker fails to deploy with the error in the title. I aslo get this warning: â–² [WARNING] The entrypoint src/gemini.ts has exports like an ES Module, but hasn't defined a default export like a module worker normally would. Building the worker using "service-worker" format... Service Worker wrangler toml: ```...

Bind Custom Domain on my worker - Domain not in my CF Account

I would like to be able to bind a custom domain to my cloudflare worker from outside of cloudflare (using namecheap to add the dns records) is there an hacky way to do that ?

Browser Rendering worker re-executes before timing out

👋 I'm running browser rendering to scrape pdfs. Running wrangler dev locally ($ npm run dev -- --remote -e stage --test-scheduled) and triggering scheduled event with $ curl "http://localhost:8787/__scheduled", once the worker execution time hits around 80 seconds, it starts executing all over again as if the curl was called again - but it wasn't called again. Is this by design in workers? cc: @Walshy...

Verify sender in Email Worker

I'm using an email worker to check if the sender is part of a list and, if so, I do some actions. This is working perfectly and I'm amazed about this feature! But now I'm wondering, can I be sure that the email sender is verified? In other words, can someone impersonate an email in the list (assuming they know what are the addresses) potentially causing harmful behaviour?...

How to Deploy a golang api in cloudflare?

I'm working on a golang api and previously I have deployed to digital ocean but now I want to try out cloudflare for the backend deployment.

unknown webhook errors discord http bot

Hey guys, I have a http only bot running on a cf worker and im running into random Unknown webhook problems, mainly for my /meme command, and I have no idea what's wrong or where to go to fix it. Here's the code for my /meme command: https://sourceb.in/yrwYOIxtyS...

A request to the Cloudflare API (/accounts...). Has anyone found a solution to this common problem?

This error occurs when I'm deploying to my production. I 've set up the necessary workers api tokens. But I still get this error. The domain is working properly. I've added my zone id to my .toml set up too. Has anyone found a solution to this common worker problem?...
No description

Protecting worker at *.workers.dev from denial of wallet attacks?

Howdy As far as i investigated, there are two recommended ways I found for protecting the worker... one is WAF rules, i assume this works only on the worker coming through custom domain endpoint, while *.worker.dev endpoint stays unprotected Another being rate limiter, which is kinda not solving the point of not running the worker, as ratelimit is evaluated within the worker...

How can someone fix this sending subject to discord webhook!

can someone help me fix export default { async email(message, env, ctx) { switch (message.from) {...

Email Worker to webhook POST fetch not working in production

Hello, I am trying to send a POST request to a webhook after receiving e-mails, using a Worker. This works in the edit environment; the webhook receives the POST request successfully. But as soon as I publish it live and send an e-mail to it, it doesn't do anything and it tells me Delivery Failed. I have looked at <#1185774979082637432>, and am doing the same approach. (The forward does work though if RegEx is not matched.) Here's some screenshots:
No description