Launched September 22, 2026
Baklava

Baklava

API Docs That Can't Lie

FreeDocs2,007 impressions#8 of its week

The key idea: 1. if the test passes, the docs are accurate, because the same test verified the behaviour they describe. 2. If the API changes and the test breaks, the docs simply don't publish until it's fixed. 3. Documentation drift becomes structurally impossible. 7 output formats out of the box: OpenAPI/SwaggerUI, TS-REST, oRPC, plain TypeScript fetch client, Postman, sttp, and browsable HTML. Works with Pekko HTTP and http4s, Apache 2.0 licensed.

Baklava generates API documentation directly from your routing tests, ensuring docs stay in sync with code.

for
Scala backend developers using Pekko HTTP or http4s.
pricing
open source
license
Apache-2.0
theiterators/baklava 11 0Scalaupdated a month ago
works withPekko HTTPhttp4sScalaTestSpecs2MUnitScala 2.13

Key features

6 features of Baklava
  • Docs from tests — Capture paths, methods, params, security and responses from your test suite to auto-generate docs.
  • Multiple output formats — Export OpenAPI 3.0, SwaggerUI, HTML, TypeScript contracts (ts-rest, Zod), Postman, sttp and more.
  • Zero-config integration — Add a dependency and Baklava discovers the format automatically, no separate spec files needed.
  • Works with popular Scala stacks — Supports Pekko HTTP, http4s, ScalaTest, Specs2 and MUnit on Scala 2.13 or 3.
  • SBT plugin — Run `sbt test` and documentation is generated in `target/baklava/`.
  • Open source license — Released under Apache 2.0, free to use and modify.

Use cases

  • Generate up-to-date OpenAPI specs for a microservice without maintaining separate YAML files.
  • Provide browsable HTML API docs that always reflect the latest test-verified behavior.
  • Create TypeScript client contracts (ts-rest, Zod) directly from Scala routing tests.
  • Ensure API documentation never drifts by tying it to failing tests.

Baklava vs alternatives

BaklavaSidekoBump.shItdocDemystify
Best forTest-driven API documentationAuto-generated SDKs with docsInternal API catalogNodeJS test-driven docsCode-analysis based docs
PricingOpen sourceSubscriptionSubscriptionFreeFree
DevHunt upvotes6812500
LaunchedSep 2026Jan 2024Feb 2024Jan 2026Jan 2026
  • Baklava vs Sideko: Sideko generates SDKs and docs from code, not from test suites.
  • Baklava vs Bump.sh: Bump.sh provides a central hub for internal APIs with versioning, not test-driven docs.
  • Baklava vs Itdoc: Itdoc creates API docs from NodeJS test code, similar concept but for a different language stack.
  • Baklava vs Demystify: Demystify offers automated API docs without requiring tests, focusing on code analysis.

Baklava FAQ

How does Baklava generate documentation?+

It reads your routing tests—paths, methods, parameters, security and response examples—and produces docs from that information.

Do I need separate OpenAPI files?+

No, Baklava creates OpenAPI 3.0 specs and other formats automatically from the tests.

Which test frameworks are supported?+

ScalaTest, Specs2 and MUnit are supported; you add the corresponding Baklava dependency.

Can I use Baklava with both Pekko HTTP and http4s?+

Yes, Baklava adapts to either framework and to Scala 2.13 or 3.

What output formats are available out of the box?+

OpenAPI/SwaggerUI, browsable HTML, TypeScript fetch client, ts-rest, oRPC, Postman, sttp, and plain TypeScript contracts.

Summarized by DevHunt from theiterators.github.io · Sep 27, 2026. Details may change; check the official site.