0.15.0 • Published 2 years ago

ptokens-node-selector v0.15.0

Weekly downloads
100
License
LGPL-3.0
Repository
github
Last release
2 years ago

ptokens-node-selector

Module for selecting a validator node

 


 

Installation:

npm install ptokens-node-selector

 


 

Usage:

import { NodeSelector } from 'ptokens-node-selector'
import { HttpProvider } from 'ptokens-providers' 
import { Node } from 'ptokens-node'

const nodeSelector = new NodeSelector({
  pToken: 'pToken name',
  
  blockchain: 'ETH', //or EOS
  network: 'testnet', //'testnet' or 'mainnet', default 'testnet'

  //if you want to be more detailed
  hostBlockchain: 'ETH',
  hostNetwork: 'testnet_ropsten',
  nativeBlockchain: 'BTC'
  nativeNetwork: 'testnet'
  // optionals
  defaultNode: new Node({
    pToken: 'pBTC',
    blockchain: 'ETH',
    provider: new HttpProvider(
      'node endpoint',
      {
        'Access-Control-Allow-Origin': '*',
        ...
      }
    )
  })
})
0.15.0

2 years ago

0.14.0

3 years ago

0.13.1

3 years ago

0.13.0

3 years ago

0.12.0

3 years ago

0.11.0

3 years ago

0.10.0

3 years ago

0.9.0

3 years ago

0.8.0

3 years ago

0.7.1

4 years ago

0.7.0

4 years ago

0.6.1

4 years ago

0.6.0

4 years ago

0.5.1

4 years ago

0.5.0

4 years ago

0.4.2

4 years ago

0.4.1

4 years ago

0.4.0

4 years ago

0.3.1

4 years ago