Getting started
Guardrail reads OpenAPI and writes the code you would have written.
Guardrail is a code generation tool for OpenAPI / Swagger specs. It produces high-quality Scala and Java for the frameworks you already run: http4s, akka-http, Dropwizard, and Spring MVC.
Install a plugin
- sbt-guardrail
- guardrail-maven-plugin
- guardrail-gradle-plugin
- CLI via coursier:
cs install guardrail
New plugins call the functions on GuardrailRunner and write the returned files. Deduplicate that sequence — Guardrail does not guarantee uniqueness across runs.
Where to go next
- What is Guardrail?
- Annotated sample specification
- Scala backends and Java backends
- Sample repositories under the guardrail-sample topic
Need help getting started or migrating? Write hello@guardrail.dev.