emeraldpay / polkaj Licence: Apache-2.0 License
Library to access and build for Polkadot using Java
Programming Languages java 68154 projects - #9 most used programming language
Projects that are alternatives of or similar to polkaj polkadot-deployer Tool for deploying polkadot networks
Stars : ✭ 99 (+106.25%)
Mutual labels: polkadot
jupiter Wasm smart contract networks powered by Substrate FRAME Contracts pallet in Polkadot ecosystem.
Stars : ✭ 49 (+2.08%)
Mutual labels: polkadot
subsocial-offchain Off-chain storage for Subsocial blockchain. This app builds user feeds and notifications by subscribing to Substrate events.
Stars : ✭ 24 (-50%)
Mutual labels: polkadot
interbtc-api interBTC TypeScript API
Stars : ✭ 21 (-56.25%)
Mutual labels: polkadot
rmrk-substrate Nested, conditional & Multi-resourced NFTs.
Stars : ✭ 44 (-8.33%)
Mutual labels: polkadot
crunch Crunch is a command-line interface (CLI) and Matrix Bot to claim staking rewards every Era for Substrate-based chains
Stars : ✭ 34 (-29.17%)
Mutual labels: polkadot
polkadot-spec The Polkadot Protocol Specification
Stars : ✭ 127 (+164.58%)
Mutual labels: polkadot
nft-gallery NFT Explorer 🗺 🧭 running on Kusama and Polkadot
Stars : ✭ 281 (+485.42%)
Mutual labels: polkadot
trustbase Smart Contract parachain interoperate with Polkadot and Ethereum
Stars : ✭ 22 (-54.17%)
Mutual labels: polkadot
polkadot-apps Fork of Polkadot.js Apps with Subsocial types.
Stars : ✭ 17 (-64.58%)
Mutual labels: polkadot
polkaswap-web Polkaswap is a non-custodial, cross-chain AMM DEX protocol for swapping tokens based on Polkadot and Kusama relay chains, Polkadot and Kusama parachains, and blockchains directly connected via bridges. Polkaswap removes trusted intermediaries and provides the opportunity for faster trading.
Stars : ✭ 43 (-10.42%)
Mutual labels: polkadot
Astar The dApp hub for blockchains of the future
Stars : ✭ 533 (+1010.42%)
Mutual labels: polkadot
common Utilities and base libraries for use across polkadot-js for Polkadot and Substrate. Includes base libraries, crypto helpers and cross-environment helpers. Full documentation & examples available.
Stars : ✭ 221 (+360.42%)
Mutual labels: polkadot
polkabtc-ui interBTC App - Mint 1:1 backed BTC on Polkadot and Kusama
Stars : ✭ 12 (-75%)
Mutual labels: polkadot
substrate-tcr-ui A react.js frontend for Substrate TCR runtime.
Stars : ✭ 14 (-70.83%)
Mutual labels: polkadot
bittensor Internet-scale Neural Networks
Stars : ✭ 97 (+102.08%)
Mutual labels: polkadot
kyve KYVE - A protocol for verified data-streams
Stars : ✭ 51 (+6.25%)
Mutual labels: polkadot
ts Misc. TypeScript definitions that are not yet available on DefinitelyTyped but required by other projects in this repo. Should be merged with upstream projects or the DT project.
Stars : ✭ 13 (-72.92%)
Mutual labels: polkadot
datdot-node-rust datdot blockchain node in rust
Stars : ✭ 43 (-10.42%)
Mutual labels: polkadot
PolkaJ - Polkadot Java Client
Java client library to use and access API of Polkadot based networks.
Warning
UNDER DEVELOPMENT
Modules
io.emeraldpay.polkaj:polkaj-scale:0.3.0
- SCALE codec implementation
io.emeraldpay.polkaj:polkaj-scale-types:0.3.0
- SCALE mapping for standard Polkadot types
io.emeraldpay.polkaj:polkaj-schnorrkel:0.3.0
- Schnorrkel for Java
io.emeraldpay.polkaj:polkaj-ss58:0.3.0
- SS58 codec to encode/decode addresses and pubkeys
io.emeraldpay.polkaj:polkaj-common-types:0.3.0
- common types (Address, DotAmount, Hash256, etc)
io.emeraldpay.polkaj:polkaj-json-types:0.3.0
- JSON RPC mapping to Java classes
io.emeraldpay.polkaj:polkaj-api-base:0.3.0
- RPC base classes
io.emeraldpay.polkaj:polkaj-api-http:0.3.0
- JSON RPC HTTP client
io.emeraldpay.polkaj:polkaj-api-ws:0.3.0
- JSON RPC WebSocket client
io.emeraldpay.polkaj:polkaj-tx:0.3.0
- Storage access and Extrinsics
Usage
To use development SNAPSHOT versions you need to install the library into the local Maven repository.
Using with Gradle
repositories {
// polkaj public repo
maven { url " https://dl.bintray.com/emerald/polkaj" }
// required for com.github.multiformats:java-multibase library
maven { url ' https://jitpack.io' }
}
dependencies {
implementation ' io.emeraldpay.polkaj:polkaj-api-http:0.3.0'
}
Documentation
See Documentation in ./docs
directory, and a demonstration in ./examples
.
Example
Show current finalized block
PolkadotHttpApi client = PolkadotApi . newBuilder()
.rpcCallAdapter(JavaHttpAdapter . newBuilder(). build())
.build();
Future<Hash256 > hashFuture = client. execute(
PolkadotApi . commands(). getFinalizedHead()
);
Hash256 hash = hashFuture. get();
System . out. println(" Current head: " + hash);
Future<BlockResponseJson > blockFuture = client. execute(
PolkadotApi . commands(). getBlock(hash)
);
BlockResponseJson block = blockFuture. get();
System . out. println(" Current height: " + block. getBlock(). getHeader(). getNumber());
System . out. println(" State hash: " + block. getBlock(). getHeader(). getStateRoot());
client. close();
License
The core project code is released under Apache 2.0 license.
Examples and docs are published under CC0 license + additionally Apache 2.0 for code parts in the examples.
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at
[email protected] .