Skip to content

Latest commit

 

History

History
54 lines (38 loc) · 975 Bytes

README.md

File metadata and controls

54 lines (38 loc) · 975 Bytes

BoltDB REST API GoDoc

Adds restful API on top of BoltDB.

Building

  1. Install gpm
  2. Install dependencies:
$ git clone https://github.com/marconi/boltapi && cd boltapi
$ gpm
$ make build && make install

Running

$ boltapi -dbpath=./app.db

You can change what port the API listens with -port param.

Endpoints

Exposes the following endpoints:

Buckets endpoint

/api/v1/buckets

GET  - List buckets
POST - Add bucket

Bucket endpoint

/api/v1/buckets/<name>

GET    - List bucket items
POST   - Add item on the bucket
DELETE - Delete bucket

Bucket item endpoint

/api/v1/buckets/<name>/<key>

GET    - Retrieve item
PUT    - Update item
DELETE - Delete item

You can also check the tests for sample usage of these endpoints.