Designing with capabilities
summary
Argues that applying the Principle of Least Authority to APIs yields smaller, safer interfaces and shows it with F# code, a working tic‑tac‑toe demo and an HTML/HATEOAS demo that remove illegal moves instead of returning errors. Demonstrates dependency‑injection-as‑authority, transforming capabilities for auditing, revocable capabilities, and once‑only use, and shows delegation to an email service so it can read exactly one customer. Demos run and fix the double‑move and over‑broad‑access bugs.
AI-written summary · about
chapters (15)
- 0:00Introduction and welcome
- 1:53Talk overview and goals
- 3:15Security and software design principles
- 13:35Tic-tac-toe API demo
- 17:44Capability-based design explained
- 21:38Capability-based API demo
- 25:51Hypermedia as engine of application state
- 31:31Capabilities in internal code design
- 36:49Injecting capabilities instead of interfaces
- 40:18Transforming capabilities
- 42:48Capability transformation demos
- 46:41Delegating capabilities
- 52:21Delegation demo and email service
- 55:08Benefits of capability-based design
- 57:15Q&A session begins
