When comparing Apiary vs Nested-Routes, the Slant community recommends Nested-Routes for most people. In the question“What are the best Haskell web frameworks for building RESTful web services?” Nested-Routes is ranked 9th while Apiary is ranked 11th. The most important reason people chose Nested-Routes is:
If you have a data encoding you would like to allow as a path chunk, you can do so by routing with an attoparsec parser or regular expression _directly_.
Ranked in these QuestionsQuestion Ranking
Pros
Pro Automatically generates API documentation
Apiary generates comprehensive HTML documentation based on your API routes.
Pro Type-level routes
Apiary provides type modeling, down to URL parameters, ensuring type safety.
Pro Embed Attoparsec parsers and regular expressions in a routable url
If you have a data encoding you would like to allow as a path chunk, you can do so by routing with an attoparsec parser or regular expression directly.
Pro Nesting of Handlers
The ability to give a handler child handlers turns a list of handlers into a tree of handlers - much easier to maintain.
Pro Simple and Concise
Routing a RESTful api is very literal in Nested-Routes.
Cons
Con Mediocre documentation
Users must rely primarily on the example project and auto-generated API documentation (Haddocks). The author of Apiary is not a native English speaker and openly acknowledges this issue.
Con Complicated Types
There is a lot of advanced language extensions in use for the engine - if you have a typo somewhere, the errors are practically impossible to understand.