Every backend eventually meets the team that wants gRPC. And every time, the answer used to be the same: add a proxy in front of it, or spin up a separate service that speaks gRPC while the rest of your app speaks HTTP. You wanted typed RPC calls; you ended up operating a second thing to translate between them.
Yatta JS 1.0.5 ships a gRPC-Web handler inside the same process as everything else. It is a backend-as-a-server for Bun: database, auth, mail, storage, realtime, jobs, and observability in one process — and the wire protocols come with it. yatta.js/grpcweb answers at /grpc-web with unary calls, a protobuf codec, framing, trailers, a client, and a health check. No Envoy sidecar, no translation service, no second deploy to keep in sync with your API.
It is one of six wire protocols that answer on a fresh yatta init with nothing configured: gRPC-Web, WebDAV, DNS over HTTPS, WebFinger, OAuth 2.0, and OIDC, plus an MCP server whose tools are generated from your collections. Each one is also importable, so you can mount it yourself with your own options when the defaults are not what you want.
A handler is just a map of methods:
import { createGrpcWebHandler, GrpcError, GrpcStatus } from "yatta.js/grpcweb";
const grpc = createGrpcWebHandler({
"shop.Catalog/Get": async () => {
throw new GrpcError(GrpcStatus.NOT_FOUND, "no such item");
},
});
The part I keep coming back to is what disappears when the protocol stops being a separate system. The RPC methods live next to the collections and the database they already query. There is no proxy config to drift out of sync with the API, and no second service whose version of the schema is last month's. The same process that serves your REST routes serves your gRPC-Web calls, under the same single command that starts everything else.
The honest boundary: this is unary calls, not streaming, and it is the same single-process story as the rest of Yatta JS — the right call at solo and small-team scale, not a claim that it replaces a dedicated gRPC fleet. Most side projects never need that fleet. They need the typed call without the proxy, and that is what ships.
Yatta JS is open source under MIT, version 1.0.5 on npm as yatta.js — install it with npm i yatta.js. Docs: https://yatta.js.org — Code: https://github.com/psrockstar098/yatta.js
What protocol did your last side project have to bolt on as a second service — gRPC, WebDAV, or something else?
Top comments (1)
Dropping the Envoy sidecar is the part that caught my eye — for a solo project, one less service to keep in sync is a real win. The unary-only boundary is honest too. Do you have streaming on the roadmap, or is that deliberately out of scope for Yatta's single-process story?