1

I'd like to start developing a solution targeting the Ethereum blockchain but I want to target the Ethereum 2.0 blockchain and I'm not so interested in 1.0 anymore. Can I already do the development using the current web3.js library? Is there an ETH2.0 version? Or perhaps a more low-level solution I can already use for ETH2.0? (JSON RPC API)

  • ETH 2.0 JSON-RPC APIs have not yet been defined, so it is impossible to tell if it works with web3.js. Naturally, it would be the intrerest of the community to maintain as much compatibility as possible. – Mikko Ohtamaa Apr 16 at 15:07
2

Unfortunately web3.js is not compatible with Eth2 APIs.

Eth1 and Eth2 are quite different; they have very different data models for blocks and Eth2 is going to use RESTful HTTP instead of JSON-RPC. I don't expect to see web3.js compatibility anytime soon.

At the present time (mid-April 2020) there is no standard API defined for Ethereum 2.0, however there is a standardisation movement taking place at https://github.com/ethereum/eth2.0-APIs.

Some clients have published their (widely differing) APIs already:

I know Lighthouse will move to match whatever is agreed upon at ethereum/eth2.0-APIs and it seems like other clients will do the same.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.