{"id":13766781,"url":"https://github.com/web3labs/quorum-sample","last_synced_at":"2025-05-10T22:31:20.444Z","repository":{"id":114053422,"uuid":"175812720","full_name":"web3labs/quorum-sample","owner":"web3labs","description":"Sample Token Project for Quorum","archived":false,"fork":false,"pushed_at":"2021-02-10T09:32:14.000Z","size":535,"stargazers_count":12,"open_issues_count":0,"forks_count":6,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-05-18T18:00:12.035Z","etag":null,"topics":["blockchain","ethereum","java","java8","quorum","web3j"],"latest_commit_sha":null,"homepage":"https://www.web3labs.com","language":"Java","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/web3labs.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,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2019-03-15T12:04:09.000Z","updated_at":"2022-06-03T09:23:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"9e0e3ade-d0bc-4d09-a7b1-af5746c76875","html_url":"https://github.com/web3labs/quorum-sample","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3labs%2Fquorum-sample","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3labs%2Fquorum-sample/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3labs%2Fquorum-sample/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/web3labs%2Fquorum-sample/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/web3labs","download_url":"https://codeload.github.com/web3labs/quorum-sample/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253492529,"owners_count":21916959,"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","ethereum","java","java8","quorum","web3j"],"created_at":"2024-08-03T16:01:00.833Z","updated_at":"2025-05-10T22:31:20.117Z","avatar_url":"https://github.com/web3labs.png","language":"Java","funding_links":[],"categories":["Educational Resources"],"sub_categories":["Built on Quorum"],"readme":"# Quorum Token Java Sample\n\nThis project demonstrates the creation and management of a private token on a Quorum network.\n \nQuorum privacy is used, only certain members of the network are privy to the \ntoken that has been created.\n\nIt is written in Java using [web3j](https://web3j.io) which is maintained by \n[Web3 Labs](https://www.web3labs.com).\n\n\n## Prerequisites\n\nA Quorum network running with at least 3 transaction nodes. Check next section for an example of a ready to use network.\n\nYou will need the following details for each node:\n- Node URL, `http://\u003cnode-url\u003e:\u003cnode-port\u003e`\n- Transaction enclave address, `\u003cbase64 encoded public key\u003e`\n\n## Quorum-dev-quickstart\n\nAs an example of a Quorum network that can be used with this sample project, we have the [Quorum-dev-quickstart](https://docs.goquorum.consensys.net/en/stable/Tutorials/Quorum-Dev-Quickstart/).\nThis, will spin up a network of 3 members with their private transactions managers and will let you demo privacy groups and how they work.\n\n## Running the application\n\nYou will need to update the \n[TokenApplication](src/main/java/com/web3labs/quorum/token/TokenApplication.java#L33) \nclass with details of the URL for each of your transaction nodes and their associated public keys.\n\n```java\n// FIXME: Add node URL and transaction node keys here\nNode nodeA = createAndUnlockAccount(\"nodeA\", \"http://\u003cnode-url\u003e\", \"\u003ctransaction node key\u003e\");\nNode nodeB = createAndUnlockAccount(\"nodeB\", \"http://\u003cnode-url\u003e\", \"\u003ctransaction node key\u003e\");\nNode nodeZ = createAndUnlockAccount(\"nodeZ\", \"http://\u003cnode-url\u003e\", \"\u003ctransaction node key\u003e\");\n```\n\nWhere your node url would be similar to `https://\u003capp\u003e.\u003cyourdomain\u003e.com:3200/{}` and \nthe nodekey would be a base64 encoded public key such as \n`V4pb2lVRMwLZXGGmm/Ee3Y2U7BTlQ+BO8abrktMbSSQ=`.\n\nThen to run the application, simply type:\n\n```bash\n./gradlew run\n```\n\nThe application logs the different activities it completes, which are as follows:\n\n1. Create an Ethereum account on nodes A, B and Z.\n1. Deploy a Quorum Token (symbol QT) contract that is visible only to nodes A, and B but not Z.\n1. Transfer QT to accounts associated with nodes A, B, Z.\n1. Display all account balances.\n1. Demonstrate that node Z cannot see the QT assigned to its account.\n1. Decrease the supply of QT.\n1. Display all account balances.\n\nThere are also a couple of \n[integration tests](src/test/java/com/web3labs/quorum/token/TokenApplicationIT.java) \nyou can use to test the application.\n\n## Viewing contracts and transactions\n\nThe Web3 Labs blockchain explorer provides an easy to use UI for browsing transaction \nand contract details.\n\n```bash\ngit clone https://github.com/blk-io/epirus-free.git\ncd epirus-free\nNODE_ENDPOINT=http://\u003cnode-url\u003e docker-compose up\n```\n\nYou may access the blockchain explorer via http://localhost.\n\n![Latest blocks](images/blocks.png)\n\nYou can then browse the smart contract that was created by obtaining the token contract address, \nwhich is logged as follows:\n\n```bash\n19:53:10.853 [main] INFO  c.w.quorum.token.TokenApplication - Quorum Token (QT) created at contract address 0x\u003ccontract-address\u003e, by account 0x\u003ccreation-account\u003e\n```\n\nYou can view the contract itself via the url `http://localhost:5000/contract/0x\u003ccontract-address\u003e`:\n\n![Contract](images/contract.png)\n\nYou can also view the private transactions:\n\n![Private transactions](images/transactions.png)\n\nAnd details of those transactions:\n\n![Transaction details](images/transaction.png)\n\nIf you wish to learn more about our Epirus contract registry and blockchain explorer, \nincluding our production-ready SaaS offerings which include features such as authentication \nand BI integrations please [contact us](mailto:hi@web3labs.com).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb3labs%2Fquorum-sample","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fweb3labs%2Fquorum-sample","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fweb3labs%2Fquorum-sample/lists"}