/lowdb-rest-boilerplate

Boilerplate for simple RESTful api, with authentication/authorization, using lowdb

Primary LanguageJavaScriptMIT LicenseMIT

lowdb-rest-boilerplate

under construction

REST verb API calls
GET_LIST GET http://my.api.url/posts?sort=["title","ASC"]&range=[0, 24]&filter={"title":"bar"}
GET_ONE GET http://my.api.url/posts/123
CREATE POST http://my.api.url/posts/123
UPDATE PUT http://my.api.url/posts/123
DELETE DELETE http://my.api.url/posts/123
GET_MANY GET http://my.api.url/posts?filter={ids:[123,456,789]}
GET_MANY_REFERENCE GET http://my.api.url/posts?filter={author_id:345}

Usefull for query creation: can-param (libraries like superagent also have such tools built-in)

Query values example: filter: { fieldOne }