I am about to build a web application that shares resources through a Restful API.
It struck me that CouchDB already has a good Restful API layer.
So why would I create my own one.
Couldn’t I just let other web applications use my resources (json documents) on CouchDB through it’s Restful API directly instead of node.js being the middleman?
Or will I need some logic in between CouchDB and 3rd party web applications?
Haven’t yet used CouchDB so I don’t know if it’s capable of handling advanced authorization and if the “design document javascript” applications are as good as “node.js javascript”.
There are several reason why you want to build your own thin layer in between:
For myself, I built a RESTful API using CouchDB and node.js. Due to the fact that both use JSON, the necessary overhead is still very small, but you have the full flexibility of your 100% own middle tier code.