(Demo code and video available at http://fsharpforfunandprofit.com/cap/)
We all want to produce modular and robust code that is easy to test and refactor, and we have design principles such as SOLID that help us do that.
In this talk I'll look at a very different approach to design using "capabilities" and the principle of least authority. I'll show how using these design techniques throughout your core domain (and not just at your API boundary) also leads to well-designed and modular code.
I'll demonstrate how to design and use a capability based approach, how capabilities can be quickly combined and restricted easily, and how capabilities are a natural fit with a REST API that uses HATEAOS.