Transports
ZAP is the native wire between services; HTTP and WebSocket appear only at the edge.
Transports
ZAP is the wire, not a library bolted onto TCP. The transport layer answers one question — how do two peers exchange ZAP frames — the same way for native RPC, an HTTP bridge, and a full zip application, because they all sit on the same wire.
The law: ZAP inside, HTTP/WS only at the edge
Internal service ↔ service traffic is ZAP. HTTPS and WebSocket appear only at the edge — the single point where the system talks to something it does not control.
Inside a cluster or a mesh, both peers are trusted and speak ZAP: zero-copy framing, capability-based authority, and a post-quantum handshake at the transport layer instead of a per-call bearer token. At the edge — a browser, a partner API — you terminate ZAP and translate to the classical protocol the outside world expects.
Outside world ──HTTPS / WSS──▶ [ edge: the only translator ] ──ZAP──▶ services ──ZAP──▶ servicesThree ways onto the wire
| Surface | Package | Use it when |
|---|---|---|
| Native ZAP RPC | zap-proto/go | Greenfield service ↔ service — define .zap interfaces, generate code, use ZAP's capability model. |
| HTTP over ZAP | zap-proto/http | You have net/http handlers or http.Client code and want the ZAP wire underneath, unchanged (X-Wing hybrid PQ handshake). |
| zip | zap-proto/zip | A full web framework — Sinatra-style routes, typed handlers, OpenAPI + MCP — ZAP primary and HTTP extra from one Listen. |
Under ZAP the network is a value — TCP, Unix socket, TLS, and QUIC — reached through transport.Listen(network, addr, dispatch) and transport.Dial(network, addr) in the Go runtime, or the client and server that codegen emits from your schema.
In the browser and at the edge
Browser → server is TLS 1.3 (recent Chrome and Safari ship the X25519MLKEM768 KEM), running over wss://. The X-Wing handshake terminates at the server, so end-to-end PQ ZAP from a browser needs a server-side terminator:
Browser ──(wss:// + TLS 1.3 hybrid KEM)──▶ Edge Worker ──(ZAP over X-Wing)──▶ OriginThe Edge Worker (any V8 isolate runtime) is that terminator — the browser sees fetch, the Worker holds the persistent ZAP connection upstream.
Learn more
The full transport reference lives on the developer portal: