{"id":21151163,"url":"https://github.com/web3j/web3j-eth2","last_synced_at":"2025-07-09T09:31:50.522Z","repository":{"id":57741101,"uuid":"307501521","full_name":"web3j/web3j-eth2","owner":"web3j","description":"Web3j integrations for Ethereum 2.0 (Eth2) network","archived":false,"fork":false,"pushed_at":"2021-12-15T10:55:52.000Z","size":698,"stargazers_count":10,"open_issues_count":2,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-05-01T09:43:04.619Z","etag":null,"topics":["blockchain","eth2","ethereum","web3j"],"latest_commit_sha":null,"homepage":"https://www.web3labs.com","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/web3j.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-10-26T20:52:51.000Z","updated_at":"2024-05-01T09:43:04.620Z","dependencies_parsed_at":"2022-09-06T23:31:18.428Z","dependency_job_id":null,"html_url":"https://github.com/web3j/web3j-eth2","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3j%2Fweb3j-eth2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3j%2Fweb3j-eth2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3j%2Fweb3j-eth2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3j%2Fweb3j-eth2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/web3j","download_url":"https://codeload.github.com/web3j/web3j-eth2/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225531383,"owners_count":17483793,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["blockchain","eth2","ethereum","web3j"],"created_at":"2024-11-20T10:14:09.527Z","updated_at":"2024-11-20T10:14:10.070Z","avatar_url":"https://github.com/web3j.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cimg src=\"Web3j-Eth2.png\" alt=\"Web3j Ethereum 2.0\" width=\"200\"/\u003e\n\nWeb3j - Ethereum 2.0\n====================\n\nThis project contains Ethereum 2.0 related modules.\n\nAt the moment it only contains the Beacon Node API client.\n\n## Beacon Node API Client\n\nWeb3j client library for the [Eth2 Beacon Node API](https://ethereum.github.io/eth2.0-APIs/).\n\n### Dependencies\n\n* [JAX-RS 2.1](https://github.com/eclipse-ee4j/jaxrs-api/tree/2.1-Maintenance) (Java RESTful Web Services)\n* [Jackson Annotations 2.11](https://github.com/FasterXML/jackson-annotations)\n* [Jersey Client 2.32](https://github.com/eclipse-ee4j/jersey)\n\n### Quickstart\n\nYou can add the library to your project using either Gradle or Maven.\n\n#### Maven\n\n```xml\n\u003cdependency\u003e\n  \u003cgroupId\u003eorg.web3j.eth2\u003c/groupId\u003e\n  \u003cartifactId\u003ebeacon-node-api\u003c/artifactId\u003e\n  \u003cversion\u003e1.0.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n#### Gradle\n\n```groovy\nimplementation 'org.web3j.eth2:beacon-node-api:1.0.0'\n```\n\nCreate a service pointing to your Beacon Chain node:\n\n```java\nvar service = new BeaconNodeService(\"http://public-mainnet-node.ethereum.org/api\");\n```\n\nBuild a client instance using the client factory:\n\n```java\nvar client = BeaconNodeClientFactory.build(service);\n```\n\nThat's it! You can start using the client to call the node endpoints, for instance:\n\n```java\nclient.getBeacon().getBlocks().findById(NamedBlockId.HEAD);\n```\n\n### Test and build\n\nRun this command on a console:\n\n```shell\n./gradlew build\n```\n\n#### Integration tests\n\nThis library is tested against different Beacon Node API nodes to ensure that it works on all of them.\nAt the moment the tests run against [Lighthouse](https://github.com/sigp/lighthouse) and\n[Teku](https://github.com/Consensys/teku/).\n\nOther Beacon Node implementations providing Docker images such as\n[Nimbus](https://github.com/status-im/nimbus-eth2) and [Prysm](https://github.com/prysmaticlabs/prysm) will be included\nin the future.\n\nTo run the integration tests, you'll need [Docker](https://www.docker.com/products/docker-desktop) running.\nUnless you pull the images manually, you will also need to define these variables in order to pull the Docker images\nfrom the [Docker Hub](https://hub.docker.com/) registry:\n\n- `registry.username`\n- `registry.password`\n\nCheck the [Docker client API](https://github.com/docker-java/docker-java/blob/master/docs/getting_started.md#instantiating-a-dockerclientconfig)\nfor more information on configuration options.\n\nRun this command on a console:\n\n```shell\n./gradlew integrationTest\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb3j%2Fweb3j-eth2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fweb3j%2Fweb3j-eth2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb3j%2Fweb3j-eth2/lists"}