Worker Bindings Example

Hi All,

I’m setting up a few services. Some workers need to talk to other workers. I don’t understand the BINDINGS part. I want the workers to be bound and zero outside influence. The Documentation assumes a certain level of understanding, and I’m not getting it.


Main worker → Email Worker.

I’ve been coding for the past 12 hours and I’m kinda spent. It doesn’t make sense to me.

What is an example of what the main worker would look like?

const send = await SEND_EMAIL.fetch()

What does the callee (email worker) look like?

addEventListener("fetch", event => {

export function handleRequest(request) {...}

I don’t get it. Any help would be appreciated.