npm stats
  • Search
  • About
  • Repo
  • Sponsor
  • more
    • Search
    • About
    • Repo
    • Sponsor

Made by Antonio Ramirez

blobbee

1.0.0

@mafintosh

npmSnykSocket
Downloads:1
$ npm install blobbee
DailyWeeklyMonthlyYearly

blobbee

Content addressed store on top of bee2

API

b = new Blobbee(store, opts)

Make a new one. Store should be a Corestore or a Bee2 instance. Options include

  • inlineValueSize = 128 - inline blobs smaller than this in the tree node.

key = await b.put(blobBuffer)

Insert a buffer. Returns the key, which is a hash.

blob = await b.get(key)

Get a blob buffer from a hash.

await b.delete(key)

Delete a blob.

batch = b.write()

Insert multiple.

key = batch.tryPut(blob)

Queue a put.

batch.tryDelete(key)

Queue a delete.

await batch.flush()

Flush the batch.

Additional it echoes most of the control flow api from Hyperbee2 (snapshot etc).

LICENSE

Apache-2.0