If a worker configuration has assets and service binding both, then the service throws 500

It seems that it's not possible to have assets and service bindings both and not sure if there is a way to get it working. Docs don't mention this so not sure if this is by design or I am missing something. i.e. This doesn't work
{
"name": "worker_a",
"main": "./request-handlers/worker-a.ts",
"compatibility_date": "2025-07-08",
"assets": {
"binding": "ASSETS",
"directory": "./public"
},
"services": [
{
"binding": "WORKER_B",
"service": "worker_b"
}
]
}
{
"name": "worker_a",
"main": "./request-handlers/worker-a.ts",
"compatibility_date": "2025-07-08",
"assets": {
"binding": "ASSETS",
"directory": "./public"
},
"services": [
{
"binding": "WORKER_B",
"service": "worker_b"
}
]
}
but this does
{
"name": "worker_a",
"main": "./request-handlers/worker-a.ts",
"compatibility_date": "2025-07-08",
"services": [
{
"binding": "WORKER_B",
"service": "worker_b"
}
]
}
{
"name": "worker_a",
"main": "./request-handlers/worker-a.ts",
"compatibility_date": "2025-07-08",
"services": [
{
"binding": "WORKER_B",
"service": "worker_b"
}
]
}
1 Reply
Walshy
Walshy5mo ago
What error are you seeing exactly? This should work fine

Did you find this page helpful?