{"id":20841230,"url":"https://github.com/iotexproject/iotex-antenna-java","last_synced_at":"2025-05-08T22:09:10.216Z","repository":{"id":45156810,"uuid":"183577193","full_name":"iotexproject/iotex-antenna-java","owner":"iotexproject","description":"IoTeX SDK in Java. (formerly: IoTeX Android SDK)","archived":false,"fork":false,"pushed_at":"2024-12-23T10:10:51.000Z","size":1080,"stargazers_count":6,"open_issues_count":3,"forks_count":4,"subscribers_count":16,"default_branch":"master","last_synced_at":"2025-05-08T22:08:52.346Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/iotexproject.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":"2019-04-26T07:11:00.000Z","updated_at":"2025-04-23T22:30:27.000Z","dependencies_parsed_at":"2022-07-13T16:50:30.908Z","dependency_job_id":null,"html_url":"https://github.com/iotexproject/iotex-antenna-java","commit_stats":null,"previous_names":["iotexproject/iotex-android-sdk"],"tags_count":22,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iotexproject%2Fiotex-antenna-java","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iotexproject%2Fiotex-antenna-java/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iotexproject%2Fiotex-antenna-java/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iotexproject%2Fiotex-antenna-java/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iotexproject","download_url":"https://codeload.github.com/iotexproject/iotex-antenna-java/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253154975,"owners_count":21862622,"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":[],"created_at":"2024-11-18T01:19:20.754Z","updated_at":"2025-05-08T22:09:10.211Z","avatar_url":"https://github.com/iotexproject.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# IoTeX Antenna Java\n\n[![LICENSE](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](LICENSE)\n\nWelcome to the official Java implementation of IoTeX Antenna Java! IoTeX is building the next generation of the decentralized \nnetwork for IoT powered by scalability- and privacy-centric blockchains. Please refer to IoTeX\n[whitepaper](https://iotex.io/academics) for details.\n\n## Get started\n\n### Build protoc\n\n```\nprotoc --proto_path=src/main/proto --java_out=src/main/java src/main/proto/proto/*/*.proto\nprotoc --plugin=/opt/homebrew/bin/protoc-gen-grpc-java \\\n    --grpc-java_out=\"src/main/java\" --proto_path=src/main/proto src/main/proto/proto/api/api.proto\n```\n\n### Install By Maven\n\n```\n\u003cdependency\u003e\n  \u003cgroupId\u003ecom.github.iotexproject\u003c/groupId\u003e\n  \u003cartifactId\u003eiotex-antenna-java\u003c/artifactId\u003e\n  \u003cversion\u003e0.6.3\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n### Install by Gradle\n\n```\nimplementation 'com.github.iotexproject:iotex-antenna-java:0.6.3'\n```\n\n\n### Sample\n\nChainID specification:\n- 1: mainnet\n- 2: testnet\n\n```java\n// create account from private key\nAccount account = IotexAccount.create(IotexAccountTest.TEST_PRIVATE);\nIOTX iotx = new IOTX(\"api.testnet.iotex.one:80\", 2);\n\n// create KeyStore file\nKeystoreFile walletFile = Keystore.createStandard(\"123456\", Numeric.toBigInt(account.privateKey()));\n\n// transfer\nTransferRequest request = new TransferRequest();\nrequest.setNonce(1l); // optional, can be null\nrequest.setGasLimit(100000l); // optional, can be null\nrequest.setGasPrice(\"1000000000000\"); // optional, can be null\nrequest.setAccount(account);\nrequest.setAmount(\"100\");\nrequest.setRecipient(\"io13zt8sznez2pf0q0hqdz2hyl938wak2fsjgdeml\");\nrequest.setPayload(\"68656c6c6f20776f726c6421\"); // optional, can be null\n\nString hash = iotx.sendTransfer(request);\n\n// contract deploy\nContract contract = new Contract(iotx.currentProvider(), CONTRACT_ABI, Numeric.hexStringToByteArray(CONTRACT_BIN));\nString hash = contract.deploy(null, 100000l, \"1000000000000\", account, \"0\", 5);\n\n// contract execute\nContract contract = new Contract(provider, CONTRACT_ADDRESS, CONTRACT_ABI);\nString hash = contract.execute(null, 100000l, \"1000000000000\", account, \"set\", \"0\", 10);\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiotexproject%2Fiotex-antenna-java","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiotexproject%2Fiotex-antenna-java","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiotexproject%2Fiotex-antenna-java/lists"}