Skip to content
sproutboat
Esc
↑↓navigate↵open⌘Jpreview
On this page

Service bindings

Call another of your projects on the same server over loopback.

Configuration

"services": [{ "binding": "PEER", "service": "quote-service" }]

Usage

const res = env.PEER.fetch(new Request("https://peer/random"));

service is the target project’s name. The call goes to the server’s edge over loopback with the target’s hostname, so it uses the same routing, process pool and logs as a public request. It does not leave the server, so the outbound allowlist does not apply.

Constraints

Was this page helpful?