Request from worker to worker fails
Hello,
I have two workers. One of them is scheduled cron job which is suppose check health of another worker (api) every 6 hours. When I hit my api from the web app or postman it replies and everything is fine but in that scheduled cron worker requests to api are failing I’m getting 404’s. I’m using public url (ending *.worker.dev) to hit api from scheduled worker. What am I doing wrong ?
1 Reply
You need to use service bindings.
https://developers.cloudflare.com/workers/runtime-apis/bindings/service-bindings/