gatewaybackends/gateway
gateway surface
TypeScript / Hono BFF, auth, tenancy, OpenAPI
- Stability
- Stable
- Scope
- Request-scoped
- Boundary
- backends/gateway
gatewaybackends/gateway
Type-safe200 OKGET /v1/gatewayGET /v1/gatewayTotal latency
36 ms
p50
15 ms
p95
55 ms
RPS
1.7k
Endpoints
OpenAPI 3.1| Route | Status | Latency |
|---|---|---|
GET/v1/gateway | 200 | 15 ms |
GET/v1/gateway/:id | 200 | 19 ms |
POST/v1/gateway | 201 | 24 ms |
GET/v1/health | 200 | 6 ms |
Response shape
JSON{
"id": string,
"slug": "gateway",
"data": gateway[],
"meta": { total: number }
}backends/gatewayOpenAPI + typed routes
Usagerouter.ts
typescriptrouter.ts
1import { createApp } from "@nebutra/gateway-core";
2import { tenancy, rateLimit } from "@nebutra/gateway-core/middleware";
3
4const app = createApp()
5 .use(tenancy())
6 .use(rateLimit({ rps: 100 }));
7
8app.get("/v1/posts", async (c) => {
9 return c.json({ tenant: c.var.tenant.id });
10});