web3.js - Ethereum JavaScript API¶
web3.js is a collection of libraries which allow you to interact with a local or remote ethereum node, using a HTTP or IPC connection.
The following documentation will guide you through installing and running web3.js, as well as providing a API reference documentation with examples.
Contents:
User Documentation
API Reference
- Web3
- web3.eth
- Note on checksum addresses
- subscribe
- Contract
- Iban
- personal
- accounts
- ens
- abi
- net
- setProvider
- providers
- givenProvider
- currentProvider
- BatchRequest
- extend
- defaultAccount
- defaultBlock
- defaultHardfork
- defaultChain
- defaultCommon
- transactionBlockTimeout
- transactionConfirmationBlocks
- transactionPollingTimeout
- getProtocolVersion
- isSyncing
- getCoinbase
- isMining
- getHashrate
- getGasPrice
- getAccounts
- getBlockNumber
- getBalance
- getStorageAt
- getCode
- getBlock
- getBlockTransactionCount
- getBlockUncleCount
- getUncle
- getTransaction
- getTransactionFromBlock
- getTransactionReceipt
- getTransactionCount
- sendTransaction
- sendSignedTransaction
- sign
- signTransaction
- call
- estimateGas
- getPastLogs
- getWork
- submitWork
- getChainId
- getNodeInfo
- web3.eth.subscribe
- web3.eth.Contract
- new contract
- = Properties =
- defaultAccount
- defaultBlock
- defaultHardfork
- defaultChain
- defaultCommon
- transactionBlockTimeout
- transactionConfirmationBlocks
- transactionPollingTimeout
- options
- options.address
- options.jsonInterface
- = Methods =
- clone
- deploy
- methods
- methods.myMethod.call
- methods.myMethod.send
- methods.myMethod.estimateGas
- methods.myMethod.encodeABI
- = Events =
- once
- events
- events.allEvents
- getPastEvents
- web3.eth.accounts
- web3.eth.personal
- web3.eth.ens
- web3.eth.Iban
- web3.eth.abi
- web3.*.net
- web3.bzz
- web3.shh
- setProvider
- providers
- givenProvider
- currentProvider
- BatchRequest
- extend
- getId
- isListening
- getPeerCount
- getVersion
- getInfo
- setMaxMessageSize
- setMinPoW
- markTrustedPeer
- newKeyPair
- addPrivateKey
- deleteKeyPair
- hasKeyPair
- getPublicKey
- getPrivateKey
- newSymKey
- addSymKey
- generateSymKeyFromPassword
- hasSymKey
- getSymKey
- deleteSymKey
- post
- subscribe
- clearSubscriptions
- newMessageFilter
- deleteMessageFilter
- getFilterMessages
- web3.utils
- Bloom Filters
- randomHex
- _
- BN
- isBN
- isBigNumber
- sha3
- soliditySha3
- isHex
- isHexStrict
- isAddress
- toChecksumAddress
- checkAddressChecksum
- toHex
- toBN
- hexToNumberString
- hexToNumber
- numberToHex
- hexToUtf8
- hexToAscii
- utf8ToHex
- asciiToHex
- hexToBytes
- bytesToHex
- toWei
- fromWei
- unitMap
- padLeft
- padRight
- toTwosComplement