0.1.6 • Published 7 years ago

db-plumbing-rest-server v0.1.6

Weekly downloads
22
License
SEE LICENSE IN LI...
Repository
github
Last release
7 years ago

Software Plumbers DB Plumbing (REST Server)

REST interface to db-plumbing-map or db-plumbing-mongo document stores.

Tl;DR

const app=express()

let store = new Store(Object, object=>object.key);

app.use(new Router(store).routes())

and the following methods of store will be exposed as service endpoints:

RouteHTTPmethod
/findAll/:indexGETfindAll
/removeAll/:indexGETremoveAll
/items/:uidGETfind
/items/:uidPUTupdate
/items/:uidDELETEremove
/bulkPOSTbulk

The store supports remove, find by criteria, and remove by criteria operations. It also supports a bulked update operation based on the typed-patch library.

This implementation is intended to exppose data provided by db-plumbing-mongo or db-plumbing-map.

For the latest API documentation see The Software Plumbers Site