finds.dev← search

// the find

w3cj/stoker

★ 440 · TypeScript · MIT · updated Aug 2025

Utilities for hono and @hono/zod-openapi

stoker is a small utility belt for building type-safe REST APIs with Hono and @hono/zod-openapi. It fills the gaps that @hono/zod-openapi leaves open: typed HTTP status constants that play nicely with Hono's StatusCode type, sensible default error handlers, and schema helpers that cut down the boilerplate on every route definition. Aimed squarely at developers already committed to the Hono ecosystem.

The http-status-codes module solves a real and specific problem — @hono/zod-openapi's type system rejects the enum exports from the popular http-status-codes package, so having individually typed constants that satisfy Hono's StatusCode union is genuinely useful, not just cosmetic. The json-content and json-content-required helpers eliminate a surprisingly verbose pattern you'd otherwise copy-paste across every route. The defaultHook for validation errors is the kind of thing every Hono+zod-openapi project writes once and then forgets about — having it pre-built and tested saves that yak shave. The getParamsSchema factory handles uuid/nanoid/cuid/cuid2/ulid variants cleanly, which matters when you're mixing ID schemes across a codebase.

The json-content-one-of helper ships with a visible warning in its own README that the TypeScript types from @hono/zod-openapi are wrong when you use it — that's a published footgun. The middleware set is thin: not-found, on-error, and serve-emoji-favicon; anything beyond the basics you're on your own. There's no pagination helper despite list endpoints being the most boilerplate-heavy part of any CRUD API. With 440 stars, it's not widely adopted, and it sits entirely downstream of both Hono and @hono/zod-openapi — a breaking change in either can strand this package.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →