Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/libp2p/js-iprs-record
JavaScript IPFS record class implementation
https://github.com/libp2p/js-iprs-record
Last synced: about 1 month ago
JSON representation
JavaScript IPFS record class implementation
- Host: GitHub
- URL: https://github.com/libp2p/js-iprs-record
- Owner: libp2p
- License: mit
- Archived: true
- Created: 2015-07-23T21:01:31.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2018-03-19T05:23:46.000Z (over 6 years ago)
- Last Synced: 2024-04-14T12:09:50.330Z (8 months ago)
- Language: JavaScript
- Homepage:
- Size: 40 KB
- Stars: 7
- Watchers: 20
- Forks: 5
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-peer-to-peer - libp2p-record
README
iprs-record JavaScript implementation
=======================================[![](https://img.shields.io/badge/made%20by-Protocol%20Labs-blue.svg?style=flat-square)](http://ipn.io) [[![](https://img.shields.io/badge/freenode-%23ipfs-blue.svg?style=flat-square)](http://webchat.freenode.net/?channels=%23ipfs)
![Build Status](https://travis-ci.org/diasdavid/js-iprs-record.svg?style=flat-square)](https://travis-ci.org/diasdavid/js-iprs-record)
![](https://img.shields.io/badge/coverage-%3F-yellow.svg?style=flat-square)
[![Dependency Status](https://david-dm.org/diasdavid/js-iprs-record.svg?style=flat-square)](https://david-dm.org/diasdavid/js-iprs-record)
[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square)](https://github.com/feross/standard)> JavaScript IPRS Record implementations follows specification([IPRS](https://github.com/ipfs/specs/tree/master/iprs/README.md)) implementation
**Disclaimer:** This module is way out of date there will be 🐉🐉
# Description# Usage
## Example record
```
// Record is a IPLD object
{
'@context': {
mlink: 'http://merkle-link'
},
scheme: {
mlink:
},
expires: , // datetime at which record expires
value: , // the data that this Record Stores
}
```# Record types
A record type should be identified by its validity scheme and a record validity scheme should be a MerkleDAG object containing its validity checking rules, however, for simplicity, we have developed 4 types of records, in which their validity schemes are hardcoded in this module. To identify which validity scheme to use, we use a enum:
- a - signed, valid within a datetime range
- b - signed, expiring after a Time-To-Live
- c - signed, based on ancestry (chain)
- d - signed, with cryptographic freshnessReference: https://github.com/ipfs/specs/tree/master/iprs/README.md#example-record-types