HTTP web3 wrapper for polkamarkets-js
Setup WEB3_PROVIDER env variable (e.g., Infura for Ethereum dapps)
yarn install
yarn dev
Smart Contract Method Queries:
// method - method name (example: getMarketData)
// args - method arguments, comma separated (example: 1,2)
// contractAddress - smart contract address (example: 0xDcBe79f74c98368141798eA0b7b979B9bA54b026)
http://localhost:3333/call?contract=predictionMarket&method=${method}&args=${args}&address=${contractAddress}
Smart Contract Event Queries:
// eventName - event name (example: MarketActionTx)
// filter - event filter json (example: {"marketId":"1"})
// contractAddress - smart contract address (example: 0xDcBe79f74c98368141798eA0b7b979B9bA54b026)
http://localhost:3333/events?contract=predictionMarket&eventName=${eventName}&address=${contractAddress}&filter=${filter}
openssl genrsa -out private_key.pem 4096openssl rsa -pubout -in private_key.pem -out public_key.pemContributions are welcomed but we ask to red existing code guidelines, specially the code format. Please review Contributor guidelines
The usage of ETH in all methods or params means using the native currency of that blockchain, example BSC in Binance Chain would still be nominated as ETH