Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@oceanprotocol/keeper-contracts

Package Overview
Dependencies
Maintainers
6
Versions
99
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@oceanprotocol/keeper-contracts

Integration of SEAs, DID and OceanToken in Solidity

  • 0.11.1
  • Source
  • npm
  • Socket score

Version published
Maintainers
6
Created
Source

banner

keeper-contracts

💧 Integration of SEAs, DID and OceanToken in Solidity oceanprotocol.com

DockerhubTravisCIAscribeGreenkeeper
Docker Build StatusBuild Statusjs ascribeGreenkeeper badge

🐲🦑 THERE BE DRAGONS AND SQUIDS. This is in alpha state and you can expect running into problems. If you run into them, please open up a new issue. 🦑🐲


Table of Contents


Get Started

For local development of keeper-contracts you can either use Docker, or setup the development environment on your machine.

Docker

The simplest way to get started with is barge, a docker compose application to run Ocean Protocol.

Local development

As a pre-requisite, you need:

  • Node.js
  • npm

Clone the project and install all dependencies:

git clone git@github.com:oceanprotocol/keeper-contracts.git
cd keeper-contracts/

# install dependencies
npm i

# install RPC client globally
npm install -g ganache-cli

Compile the solidity contracts:

npm run compile

In a new terminal, launch an Ethereum RPC client, e.g. ganache-cli:

ganache-cli

Switch back to your other terminal and deploy the contracts:

npm run deploy:development

# for redeployment run this instead
npm run clean
npm run compile
npm run deploy:development

Upgrade contracts [optional]:

npm run upgrade

Testing

Run tests with npm run test, e.g.:

npm run test -- test/unit/agreements/AgreementStoreManager.Test.js

Code Linting

Linting is setup for JavaScript with ESLint & Solidity with Ethlint.

Code style is enforced through the CI test process, builds will fail if there're any linting errors.

Networks

Testnets

Duero Testnet

The contract addresses deployed on Ocean's Duero Test Network:

ContractVersionAddress
AccessSecretStoreConditionv0.11.10x38e26f97AcCc0f6f0bA70b6304d89781449BAc11
AgreementStoreManagerv0.11.10x10f763D50600462F7253dc721dC895754b3Aee26
ConditionStoreManagerv0.11.10x10083113a47E6689D5C526D9e814bA42752BE09c
DIDRegistryv0.11.10xb1eA341724Fdcd53CA39d7DE3264bB89E6120BE4
DIDRegistryLibraryv0.11.10xcb7D122Af3C861a87C9fBb17F1B52b7C501c1062
Dispenserv0.11.10xe76548A5b24AF890093A4C8423D542bcA1752CB8
EpochLibraryv0.11.10x2B4d53BE84964983932dD6167155052201892c0A
EscrowAccessSecretStoreTemplatev0.11.10xBd7e5fFf4Eb8d67111227C9541080a74c634d643
EscrowRewardv0.11.10xEb30f990F8F3a784F9eD3A594021D3764af00469
HashLockConditionv0.11.10x4939063413A7a9B79d5437de73ed6d9996F92629
LockRewardConditionv0.11.10x53F89846832a793bF988B604b2489f74E6D22648
OceanTokenv0.11.10xFEBfC7dA1cAf52E4207501ad6df6B19EcDA4614b
SignConditionv0.11.10x127c9A80A61b5BB6b97EE796CACDFbc201969447
TemplateStoreManagerv0.11.10x6d3d30BB9074c1e3013A8b99A2e22a3FF5966EA2
ThresholdConditionv0.11.10xe940DBA354d444aA9Af0723A46a277ea6Ac36DE1
WhitelistingConditionv0.11.10x453c7912d4e33B3348961810296FE55a6adE20B2
Nile Testnet

The contract addresses deployed on Ocean's Nile Beta Network:

ContractVersionAddress
AccessSecretStoreConditionv0.11.10x45DE141F8Efc355F1451a102FB6225F1EDd2921d
AgreementStoreManagerv0.11.10x62f84700b1A0ea6Bfb505aDC3c0286B7944D247C
ConditionStoreManagerv0.11.10x39b0AA775496C5ebf26f3B81C9ed1843f09eE466
DIDRegistryv0.11.10x4A0f7F763B1A7937aED21D63b2A78adc89c5Db23
DIDRegistryLibraryv0.11.10x82281775C6AB73E85b7a7e0CEe62910729d1cF95
Dispenserv0.11.10x865396b7ddc58C693db7FCAD1168E3BD95Fe3368
EpochLibraryv0.11.10x787Cf4627F3F2bf5B8e9Da619aba59CB997A19B4
EscrowAccessSecretStoreTemplatev0.11.10xfA16d26e9F4fffC6e40963B281a0bB08C31ed40C
EscrowRewardv0.11.10xeD4Ef53376C6f103d2d7029D7E702e082767C6ff
HashLockConditionv0.11.10xB5f2e45e8aD4a1339D542f2defd5095B98054590
LockRewardConditionv0.11.10xE30FC30c678437e0e8F78C52dE9db8E2752781a0
OceanTokenv0.11.10x9861Da395d7da984D5E8C712c2EDE44b41F777Ad
SignConditionv0.11.10x5a4301F8a7a8A13485621b9B4C82B1E66c112ee2
TemplateStoreManagerv0.11.10x9768c8ae44f1dc81cAA98F48792aA5730cAd2F73
ThresholdConditionv0.11.10xf29a50080163Fb2938E2024f19681Ac2FB8745De
WhitelistingConditionv0.11.10x9Db7fE5A18Ff4fb1746c290192EDE67a64EB4385
Kovan Testnet

Deprecated: The kovan network is deprecated and will be removed in the next version.


The contract addresses deployed on Kovan testnet:

ContractVersionAddress
AccessSecretStoreConditionv0.10.30x9Ee06Ac392FE11f1933a51B48D1d07dd97f1dec7
AgreementStoreManagerv0.10.30x412d4F57425b41FE027e06b9f37D569dcAE2eAa4
ConditionStoreManagerv0.10.30xA5f5BaB34DE3782A71D37d0B334217Ded341cd64
DIDRegistryv0.10.30x9254f7c8f1176C685871E7A8A99E11e96775F488
DIDRegistryLibraryv0.10.30xf22aEF1421CCd4f0A0D0BB1f7fe03233384c69B4
Dispenserv0.10.30x5B92243133094210F504dF6B9D54fD70E7B281DC
EpochLibraryv0.10.30x44Ca6882823a2d7864376893A4BCF3eB377693e4
EscrowAccessSecretStoreTemplatev0.10.30xe0Afe9a948f9Fa39524c8d29a98d75409018ABf0
EscrowRewardv0.10.30xa182ff844c71803Bf767c3AB4180B3bfFADa6B2B
HashLockConditionv0.10.30x11ef2D50868c1f1063ba0141aCD53691A0293c25
LockRewardConditionv0.10.30x2a2A2C5fF51C5f1c84547FC7a194c00F82763432
OceanTokenv0.10.30xB57C4D626548eB8AC0B82b086721516493E2908d
SignConditionv0.10.30x7B8B2756de9Ab474ddbCc87047117a2A16419194
TemplateStoreManagerv0.10.30xD20307e2620Bb8a60991f43c52b64f981103A829

Mainnets

Pacific Mainnet

The contract addresses deployed on Pacific Mainnet:

ContractVersionAddress
AccessSecretStoreConditionv0.11.10x7FC6520Af3F0800d76A3e2FfE7b838c945ADBFE4
AgreementStoreManagerv0.11.10x44665ee68779eC83202702C091279661336F5F8a
ConditionStoreManagerv0.11.10xbD1dEd7ef05c31F81C54e913a23Da69E77d3e0EE
DIDRegistryv0.11.10x1f0E059a50356D8617980F8fa21a53F723072712
DIDRegistryLibraryv0.11.10x2eBD03c446e11EA4eC58eC092b3906a816828D2f
EpochLibraryv0.11.10xBCc5b375AB7ca0AB45b00F3dA24eC8b3b5aEe031
EscrowAccessSecretStoreTemplatev0.11.10x9BF43606d833489fbD568ace13f535fC41130c28
EscrowRewardv0.11.10x656Aa3D9b37A6eA770701ae2c612f760d9254A66
HashLockConditionv0.11.10x5Eef92d570996ED20Cb60fE41475f594299Ec21C
LockRewardConditionv0.11.10x7bf64DaCc7929A1e5466f7d9E575128abf1875f8
OceanTokenv0.11.10x012578f9381e876A9E2a9111Dfd436FF91A451ae
SignConditionv0.11.10xB74172078ABb029FaD809335d82241371b998708
TemplateStoreManagerv0.11.10xF2Cf3761c166c6D85d07299427821D18A4329cd1
ThresholdConditionv0.11.10xeD2A0787885f4ef781E35c5808F3C786fc8C1817
WhitelistingConditionv0.11.10x5b4c3B48062bDCa9DaA5441c5F5A9D557bFE3356

Ethereum Mainnet


Deprecated: The ethereum mainnet network is deprecated and will be removed in the next version.


The contract addresses deployed on Ethereum Mainnet:

ContractVersionAddress
AccessSecretStoreConditionv0.10.30x57e299517B6E5637cE9da15E4372f42a63c7e099
AgreementStoreManagerv0.10.30x5E98B9EfABe192aB02a9B39D9B44A22C88A625BD
ConditionStoreManagerv0.10.30x031A0B2FE74086e5963CD5Ac27Bd1451A40Fe593
DIDRegistryv0.10.30xC4A1D6d4778C9A17D5e37797dA2FaB48FA9d01f6
DIDRegistryLibraryv0.10.30xFb4231AF132A8E160292022eBd8ea4292104B1Da
EpochLibraryv0.10.30xb5096b69638689eE2dC7CA56Babaf7d8521a7Abb
EscrowAccessSecretStoreTemplatev0.10.30xa713D8F4791512a599A98f5DcaCC6401D6c76e5f
EscrowRewardv0.10.30xB950FE753871dc8b79284d76EA4A213db4697578
HashLockConditionv0.10.30x860761Dbbe9b8377A2933a1093B39167B907befF
LockRewardConditionv0.10.30xD41161D8f2CE5Ec95465F4b2fBD00Cfea186204C
SignConditionv0.10.30xEE33DCDBE6aF6197dD01907cfc4296BFC0448B16
TemplateStoreManagerv0.10.30x04DD5364b12131ae870Ec54bd539b5Cb94B9DC36

Packages

To facilitate the integration of the Ocean Protocol's keeper-contracts there are Python, JavaScript and Java packages ready to be integrated. Those libraries include the Smart Contract ABI's. Using these packages helps to avoid compiling the Smart Contracts and copying the ABI's manually to your project. In that way the integration is cleaner and easier. The packages provided currently are:

The packages contains all the content from the doc/ and artifacts/ folders.

In JavaScript they can be used like this:

Install the keeper-contracts npm package.

npm install @oceanprotocol/keeper-contracts

Load the ABI of the OceanToken contract on the nile network:

const OceanToken = require('@oceanprotocol/keeper-contracts/artifacts/OceanToken.nile.json')

The structure of the artifacts is:

{
  "abi": "...",
  "bytecode": "0x60806040523...",
  "address": "0x45DE141F8Efc355F1451a102FB6225F1EDd2921d",
  "version": "v0.9.1"
}

Documentation

Contributing

See the page titled "Ways to Contribute" in the Ocean Protocol documentation.

Prior Art

This project builds on top of the work done in open source projects:

License

Copyright 2018 Ocean Protocol Foundation

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

FAQs

Package last updated on 28 Aug 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc