mysteriumnetwork / payments-smart-contracts

Smart contracts for payments flow
GNU General Public License v3.0
30 stars 15 forks source link

Mysterium Network payments Build Status

Set of smart contracts needed for mysterium identity registration and working with payment channels (using payment hubs).

Documentation

Setup and test

We're using truffle for smart contract compilation and running tests.

  1. Install dependencies
npm install
  1. Run local ethereum node, e.g. ganache. Make sure to use version greater than 6.12.2.
npx ganache-cli --port 8545 --mnemonic "amused glory pen avocado toilet dragon entry kitchen cliff retreat canyon danger"
  1. Run tests
npm test
  1. Testing migration/deployment
    npm run migrate

MainNet deployment

Registry smart contract:

Hermes smart contract

Implementation addresses:

Testnet3 deployment (ethereum Görli and polygon Mumbai testnets)

MYSTT test token:

Registry smart contract:

Hermes smart contract:

Implementation addresses:

All v3 related Smart Contracts are deployed by Hermes Operator

Building golang bindings

To be able easily call these smart contract out of any software writen in Go you need to generate golang bindings and import payments package into your software.

  1. Tag newest version of smart contracts on GitHub
  2. CI will build artifacts
  3. Go to payments repo and in go.gen set tag and which artifacts to build.
  4. Run mage generate.