Shamwari is fully open-source under the MIT licence. The complete Java protocol codebase, five technical volumes, full REST API at the testnet node, and client binaries are all available now. Testnet is live across all three BetaChains. Build the next generation of quantum-safe financial infrastructure.
Download the client, connect to the testnet node, and query the REST API immediately. No account required for read operations. Submit transactions by providing your Dilithium-signed payload.
# 1. Get the current block on CAPITAL chain
curl "https://wallet.shamwari.network/api?requestType=getBlock&chain=CAPITAL"
# 2. Query an account's balance
curl "https://wallet.shamwari.network/api?requestType=getAccount&account=SHAMWARI-XXXX-XXXX-XXXX-XXXXX"
# 3. Get active insurance products on ZIMBABWE chain
curl "https://wallet.shamwari.network/api?requestType=getInsuranceProducts&chain=5&status=ACTIVE"
# 4. Submit a signed transaction (POST with your Dilithium-signed attachment)
curl -X POST "https://wallet.shamwari.network/shamwari" -d "requestType=sendMoney&chain=5&recipient=SHAMWARI-XXXX-XXXX-XXXX-XXXXX&amountNQT=1000&secretPhrase=..."The testnet API is publicly accessible. Read operations require no authentication. Transaction submission requires a valid Dilithium-signed payload. The secretPhrase parameter in the example above is only for testnet prototyping while production integrations sign client-side and submit signed bytes only.
Shamwari exposes a single REST endpoint at each node for all protocol operations. All queries use HTTP GET with requestType and chain parameters. Transaction submissions use HTTP POST. JSON request and response format throughout.
Every transaction submission follows the same pattern. The wallet SDK handles steps 1–3 automatically.
The most frequently used API endpoints across all six protocol systems. Full parameter documentation and response schemas available in the documentation.
| Endpoint (requestType) | Method | System | Description |
|---|---|---|---|
| getBlock | GET | Infrastructure | Get block by height or ID. Include transactions=true to include full transaction list. |
| getAccount | GET | Identity | Full account info: balances, account type, permissions, domain, certificate status. |
| sendMoney | POST | ShamwariPay | CURRENCY_PAYMENT transaction. Params: chain, recipient, amountNQT, currencyId. |
| publishExchangeOffer | POST | ShamwariPay | Place a currency exchange offer on the DEX. Params: chain, currencyId, rateQNTPerUnit, limit. |
| loanOffer | POST | ShamwariPay | Create a loan offer. Params: chain, currency, amount, interestRate, collateral, term. |
| getOpenOrders | GET | Totem Exchange | Query order book for a Totem/currency pair. Params: chain, asset, currency. |
| placeAskOrder | POST | Totem Exchange | Place a sell order for a Totem asset. Params: chain, asset, currency, quantityQNT, priceNQT. |
| getInsuranceProducts | GET | Insurance | List insurance products on a chain. Params: chain, status (optional), issuerId (optional). |
| applyForPolicy | POST | Insurance | Apply for an insurance policy. Params: chain, insuranceId, coverageAmount. |
| submitClaim | POST | Insurance | Submit an insurance claim. Params: chain, policyId, claimAmount, description. |
| listProduct | POST | Commerce | Create a product listing. Params: chain, name, price, currency, fulfilmentMode, deadline. |
| getPurchases | GET | Commerce | List purchases for a buyer or merchant. Params: chain, account, status. |
| deliverGoods | POST | Commerce | Submit DELIVERY_CONFIRMATION. Params: chain, purchase, deliveryData (encrypted). |
| createService | POST | Subscriptions | Register a subscription service. Params: chain, name, price, period, assetType. |
| subscribe | POST | Subscriptions | Subscribe to a service. Params: chain, serviceId. |
| getSubscriptions | GET | Subscriptions | List subscriptions for an account. Params: chain, account, status. |
| issueCertificate | POST | Certificates | Issue a Shamwari certificate. DEVELOPER account required. Params: chain, subjectKey, type, expiry. |
| getCertificate | GET | Certificates | Get certificate by ID. Returns status, issuer, subject, validity period. |
| grantPermission | POST | Chain Control | Grant CHAIN_USER or CHAIN_ADMIN permission. CHAIN_ADMIN required. Params: chain, recipient. |
| getPermission | GET | Chain Control | Query permission status for an account. Params: chain, account. |
| getAccountInfo | GET | Identity | Get decryptable AccountInfo for an account. Returns encrypted payload if set. |
| setAccountInfo | POST | Identity | Set account metadata (AccountInfo). Params: chain, name, description, encryptedData. |
Five comprehensive technical volumes cover the entire Shamwari protocol — from blockchain architecture and consensus to cryptography, all financial systems, and the full API reference.
Build the integration depth that fits your use case — from a lightweight REST API connection to running your own full protocol node.
Integrate Shamwari operations into any application via the REST API. Account creation, transaction submission, balance queries, order book data, insurance product queries, and certificate verification which are all accessible over HTTP with JSON responses. No SDK required. Works from any language or environment.
The Java implementation of the Shamwari protocol includes a complete client SDK for JVM-based applications. The SDK handles key management, transaction construction, Dilithium signing, and Kyber encryption natively. Suitable for Android applications, enterprise middleware, JVM microservices, and Spring Boot backends.
Run a complete Shamwari node to participate in consensus, earn forging rewards, or operate as a Binder (fee-abstraction service provider). Full nodes hold the complete blockchain state, validate all transactions, and independently verify all compliance operations. Required for Binder operation and institutional deployments.
Everything in the Shamwari protocol is accessible via the REST API.
The Java SDK wraps the protocol operations in typed, documented Java interfaces.
Example code for the most common Shamwari integration operations. All examples use the public testnet API URL. Replace with your production node URL for mainnet.
// Java- derive PQC keypair from BIP39 seed phrase
String seedPhrase = ShamwariAccount.generateSeedPhrase(24); // 24-word BIP39
ShamwariQKP qkp = ShamwariAccount.qkpFromSeed(seedPhrase);
// Dilithium signing key (2528 bytes private, 1312 bytes public)
byte[] dilithiumPubKey = qkp.getDilithiumPublicKey();
byte[] dilithiumPrivKey = qkp.getDilithiumPrivateKey(); // NEVER send this
// Kyber encryption key (1632 bytes private, 800 bytes public)
byte[] kyberPubKey = qkp.getKyberPublicKey();
// Derive account ID from Dilithium public key hash
String accountId = ShamwariAccount.getAccountId(dilithiumPubKey);
System.out.println("Account: " + accountId); // SHAMWARI-XXXX-XXXX-XXXX-XXXXX// Java - sign and submit CURRENCY_PAYMENT on ZIMBABWE chain
ShamwariAPI api = new ShamwariAPI("https://wallet.shamwari.network");
// Build unsigned transaction
JSONObject unsignedTx = api.getUnsignedTransaction(Map.of(
"requestType", "sendMoney",
"chain", "ZIMBABWE",
"recipient", "S-DEST-ACCT-ID",
"amountNQT", "100000", // 10,000 ZWG (1 decimal = 10,000 QNT)
"currencyId", "ZWG_CURRENCY_ID",
"deadline", "1440"
));
// Sign with Dilithium key
byte[] txBytes = Hex.decode(unsignedTx.getString("unsignedTransactionBytes"));
byte[] signature = ShamwariCrypto.dilithiumSign(txBytes, qkp.getDilithiumPrivateKey());
// Broadcast
JSONObject result = api.broadcastTransaction(
unsignedTx.getString("unsignedTransactionBytes"),
Hex.toHexString(signature)
);
System.out.println("TX Hash: " + result.getString("transaction"));// Java - Kyber-encrypt a delivery address for a PURCHASES transaction
String deliveryAddress = "123 Harare Road, Avondale, Zimbabwe";
JSONObject merchantInfo = api.getAccount("S-MERCHANT-ACCT-ID", "ZIMBABWE");
byte[] merchantKyberPubKey = Base64.decode(merchantInfo.getString("kyberPublicKey"));
// Kyber KEM + AES-256-GCM hybrid encryption
ShamwariEncryptedData encryptedPayload = ShamwariCrypto.encryptToPublicKey(
deliveryAddress.getBytes(StandardCharsets.UTF_8),
merchantKyberPubKey
);
// Include encrypted payload in PURCHASES transaction attachment
JSONObject purchase = api.getUnsignedTransaction(Map.of(
"requestType", "purchase",
"chain", "ZIMBABWE",
"goods", "PRODUCT_LISTING_ID",
"priceNQT", "500000",
"encryptedData", encryptedPayload.toHex(),
"kyberCipherText", encryptedPayload.getCipherTextHex()
));// Java — subscribe to a recurring service
String serviceId = "SERVICE_ID_FROM_GETSERVICES";
JSONObject unsignedTx = api.getUnsignedTransaction(Map.of(
"requestType", "subscribe",
"chain", "ZIMBABWE",
"serviceId", serviceId,
"deadline", "1440"
));
byte[] txBytes = Hex.decode(unsignedTx.getString("unsignedTransactionBytes"));
byte[] sig = ShamwariCrypto.dilithiumSign(txBytes, qkp.getDilithiumPrivateKey());
api.broadcastTransaction(unsignedTx.getString("unsignedTransactionBytes"), Hex.toHexString(sig));
// Check subscription status
JSONObject sub = api.getSubscriptions("ZIMBABWE", myAccountId, "ACTIVE");
System.out.println("Subscribed until block: " + sub.getJSONArray("subscriptions")
.getJSONObject(0).getInt("expirationHeight"));The Shamwari testnet runs all three production BetaChains with mainnet-identical configuration. All 70+ transaction types are available. Test tokens are free. The testnet does not correlate to the mainnet exactly.
All testnet endpoints are publicly accessible.
Testnet uses identical protocol configuration with minor operational differences.
Shamwari nodes validate transactions, forge blocks, and earn WEALTH forging rewards. Binder nodes additionally operate the fee-abstraction service for BetaChain users and earn fee revenue from day one of mainnet.
Nodes participating in block forging earn WEALTH (FXT) token rewards proportional to their forging stake.
Binder nodes earn the spread between the FXT fee they pay on FxtChain and the BetaChain fees they collect from users.
Open source, well-documented, running on testnet. Start building the next generation of quantum-safe financial infrastructure for emerging markets.