Eidoo ETH API service wrapper.
Eidoo ETH API is an Ethereum node gateway that can be used to read or submit changes of the Ethereum network state.
For release notes, please see the CHANGELOG.
If you want you can install it with npm:
npm install --save eidoo/ethapi-lib
or if you prefer using yarn:
yarn add eidoo/ethapi-lib
Then within your application, you can reference to the lib with the following:
const { EidooEthApiLib } = require('@eidoo/ethapi-lib')
const ethApiConfig = {
host: 'eidoo-api-1.eidoo.io',
port: 443,
useTLS: true,
}
const ethApiLibClient = new EidooEthApiLib(ethApiConfig)
const { nonce } = await ethApiLibClient.getAddressNonceAsync(EOA)
const { transactions } = await ethApiLibClient.getAccountTxsDetailsAsync(EOAorSCaddress)
const { gas, gasPrices } = await ethApiLibClient.getEstimateGasAsync(transactionObject)
const transactionCall = await ethApiLibClient.transactionCallAsync(transactionObject)
const { hash } = await ethApiLibClient.sendRawTransactionAsync(signedTransactionData)
yarn install
Install the dependencies, then run yarn test
:
yarn install
yarn test
You can run unit tests only using yarn test:unit
.