10.3.0
The Event Log API was designed to provide an alternative to the native eth_getLogs.
(any)
(any)
(any)
(any)
(any)
(any)
(any)
(any)
(any)
(any)
(any)
returns the status of a specific transaction hash
(any)
(string)
fromBlock
(string)
toBlock
(string)
topic (32 Bytes per topic)
(string)
and|or between topic0 & topic1
(string)
topic (32 Bytes per topic)
(string)
and|or between topic1 & topic2
(string)
topic (32 Bytes per topic)
(string)
and|or between topic2 & topic3
(string)
topic (32 Bytes per topic)
(string)
and|or between topic0 & topic2
Promise<object>
:
https://etherscan.io/apis#logs
Returns the number of most recent block
Promise<integer>
:
var block = api.proxy.eth_blockNumber();
Returns information about a block by block number.
(string)
Tag to look up
Promise<integer>
:
var blockNumber = api.proxy.eth_getBlockByNumber('0x10d4f');
Returns information about a uncle by block number.
Promise<object>
:
var res = api.proxy.eth_getUncleByBlockNumberAndIndex('0x210A9B', '0x0');
Returns the number of transactions in a block from a block matching the given block number
(string)
Tag to look up
Promise<object>
:
var res = api.proxy.eth_getBlockTransactionCountByNumber('0x10FB78');
Returns the information about a transaction requested by transaction hash
(any)
(string)
Transaction hash
Promise<object>
:
var res = api.proxy.eth_getTransactionByHash('0x1e2910a262b1008d0616a0beb24c1a491d78771baa54a33e66065e03b1f46bc1');
Returns information about a transaction by block number and transaction index position
Promise<object>
:
var res = api.proxy.eth_getTransactionByBlockNumberAndIndex('0x10d4f', '0x0');
Returns the number of transactions sent from an address
(string)
Address of the transaction
Promise<object>
:
var res = api.proxy.eth_getTransactionCount('0x2910543af39aba0cd09dbb2d50200b3e800a63d2', 'latest');
Creates new message call transaction or a contract creation for signed transactions
(string)
Serialized Message
Promise<object>
:
var res = api.proxy.eth_sendRawTransaction('0xf904808000831cfde080');
Returns the receipt of a transaction by transaction hash
(string)
Transaction hash
Promise<object>
:
var ret = api.proxy.eth_getTransactionReceipt('0x1e2910a262b1008d0616a0beb24c1a491d78771baa54a33e66065e03b1f46bc1');
Executes a new message call immediately without creating a transaction on the block chain
Promise<object>
:
var res = api.proxy.eth_call('0xAEEF46DB4855E25702F8237E8f403FddcaF931C0', '0x70a08231000000000000000000000000e16359506c028e51f16be38986ec5746251e9724', 'latest');
Returns code at a given address
Promise<object>
:
var res = api.proxy.eth_getCode('0xf75e354c5edc8efed9b59ee9f67a80845ade7d0c', 'latest');
Returns the value from a storage position at a given address.
Promise<object>
:
var res = api.proxy.eth_getStorageAt('0x6e03d9cce9d60f3e9f2597e13cd4c54c55330cfd', '0x0', 'latest');
Returns the current price per gas in wei. var gasprice = api.proxy.eth_gasPrice();
Promise<object>
:
Makes a call or transaction, which won't be added to the blockchain and returns the used gas, which can be used for estimating the used gas
(string)
Address to get code from
(string)
Storage position
(string)
??
(string)
??
Promise<object>
:
Returns the supply of Tokens
Promise<object>
:
var supply = api.stats.tokensupply(null, '0x57d90b64a1a57749b0f932f1a3395792e12e7055');
Returns total supply of ether var supply = api.stats.ethsupply();
Promise<integer>
:
Returns the price of ether now
Promise<integer>
:
var price = api.stats.ethprice();
Find the block reward for a given address and block
Promise<object>
:
returns the status of a specific transaction hash
(string)
Transaction hash
Promise<object>
:
Returns the ABI/Interface of a given contract
(string)
Contract address
Promise<object>
:
api.contract
.getabi('0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413')
.then(console.log)
Returns the Sourcecode of a given verified contract
(string)
Contract address
Promise<object>
:
api.contract
.getsourcecode('0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413')
.then(console.log)
Returns the amount of Tokens a specific account owns.
(string)
Contract address
(string)
Name of the token
(string)
Contract address
Promise<object>
:
var supply = api.account.tokenbalance(
'0x4366ddc115d8cf213c564da36e64c8ebaa30cdbd',
'',
'0xe0b7927c4af23765cb51314a0e0521a9645f0e2a' // DGD contract address
);
Returns the balance of a sepcific account
(string)
Address
Promise<object>
:
var balance = api.account.balance('0xde0b295669a9fd93d5f28d9ec85e40f4cb697bae');
Get a list of internal transactions
(string)
Transaction hash. If specified then address will be ignored
(string)
Transaction address
(string)
start looking here
(string)
end looking there
(string)
Sort asc/desc
Promise<object>
:
var txlist = api.account.txlistinternal('0x40eb908387324f2b575b4879cd9d7188f69c8fc9d87c901b9e2daaea4b442170');
Get a list of transactions for a specfic address
(string)
Transaction address
(string)
start looking here
(string)
end looking there
(number)
Page number
(number)
Max records to return
(string)
Sort asc/desc
Promise<object>
:
var txlist = api.account.txlist('0xde0b295669a9fd93d5f28d9ec85e40f4cb697bae', 1, 'latest', 1, 100, 'asc');
Get a list of blocks that a specific account has mineds
(string)
Transaction hash
var txlist = api.account.getminedblocks('0x9dd134d14d1e65f84b706d6f205cd5b1cd03a46b');
[BETA] Get a list of "ERC20 - Token Transfer Events" by Address
(string)
Account address
(string)
Address of ERC20 token contract (if not specified lists transfers for all tokens)
(string)
start looking here
(string)
end looking there
(number)
Page number
(number)
Max records to return
(string)
Sort asc/desc
Promise<object>
:
var txlist = api.account.tokentx('0xde0b295669a9fd93d5f28d9ec85e40f4cb697bae', '0x5F988D968cb76c34C87e6924Cc1Ef1dCd4dE75da', 1, 'latest', 'asc');
[BETA] Get a list of "ERC721 - Token Transfer Events" by Address
(string)
Account address
(string)
Address of ERC721 token contract (if not specified lists transfers for all tokens)
(string)
start looking here
(string)
end looking there
(number)
Page number
(number)
Max records to return
(string)
Sort asc/desc
Promise<object>
:
var txlist = api.account.tokenftntx('0xde0b295669a9fd93d5f28d9ec85e40f4cb697bae', '0x5F988D968cb76c34C87e6924Cc1Ef1dCd4dE75da', 1, 'latest', 'asc');
gets the correct urls of the backend
(string)
any
:
Url of backend
string
:
(any)
Promise<any>
: