API first with Swagger and Scala
summary
Company uses an API‑first workflow: author OpenAPI/Swagger specs and run an sbt/Play plugin to spec -> code generation that emits models, controllers, validators and runnable test data. Generated artifacts include inheritance-aware Scala case classes, parameter constraints (min/max), and automated validation tests; running the test suite regenerates stubs so missing implementations show as failing tests. Prototype sits in production at a large online clothing retailer and reduces cross-team coupling while allowing guarded manual overrides that risk divergence.
AI-written summary · about
chapters (10)
- 0:00Introduction
- 3:18Autonomous team principles
- 7:33REST and architecture
- 11:52Swagger specs
- 14:14Code generation demo
- 23:35Generated code structure
- 27:53Tests and validation
- 34:10Plugin architecture
- 37:49Prototype and future
- 38:35Q&A
related talks
49mBeautiful APIs with Scala, Scalatra, Swagger, and Akka
36mScale By The Bay 2018 Unconference: Devon Stewart
39mAPI Development in 2017
35mAPI-First! Contract-First! Make API development great again!
14mReal-World Enterprise REST API Design
16mAPI-First Development with OpenAPI — You Should Practice It!?
33mDocumenting REST APIs with Swagger
59mDriving better outcomes through API first development
