What it does
Deposit
Convert public ERC20 tokens into a confidential encrypted balance.
Transfer
Send tokens privately without leaking amounts or balances to the public.
Withdraw
Move funds from the confidential layer back to public ERC20 tokens.
What you can build
Privacy by default unlocks new use cases for open finance that institutions and enterprises require:- Confidential payroll apps - stream salaries to employees and contractors without publishing compensation onchain.
- Confidential token launchpads - let participants contribute privately, hiding contribution sizing from competitors or bots.
- Web wallets with confidential transfers built in - give everyday users privacy by default for their transactions and balances.
- x402 payments with confidential transfers - fast, confidential micro-payments for subscriptions, APIs, or AI agents.
- Treasury management - let DAOs and funds move capital without broadcasting strategy to the market.
Need to shield wallet addresses too, not just amounts? Anonymous transfers route through the Fairycloak relay using numeric account IDs, fully decoupled from any public EVM address - with gasless transfers and withdrawals. See Anonymous Transfers or reach out at hello@fairblock.network to request access.
Installation
Install the Stabletrust SDK into your project:Supported Networks
The SDK currently supports confidential transfers on the following testnets:| Network | Chain ID | Notes |
|---|---|---|
| Ethereum Sepolia | 11155111 | |
| Arbitrum Sepolia | 421614 | |
| Base Sepolia | 84532 | |
| Stable Testnet | 2201 | |
| Arc | 5042002 | |
| Tempo | 42431 | Uses token-based fees like PathUSD |
Quick Start: Code Snippets
The SDK revolves around theConfidentialTransferClient, which handles the cryptographic heavy lifting.
Ensure the account is set up
Before any confidential operation, make sure the user account is initialized onchain. This is a one-time step per user per chain.
Deposit tokens
Deposit tokens to make the balance confidential. Always parse amounts using the token’s decimals (e.g. 6 for USDC).
Transfer confidentially
Send tokens to any recipient. The transferred amount is encrypted and hidden from the public ledger.
Resources
NPM Package
@fairblock/stabletrust
GitHub
stabletrust-sdk source code
Build a full app
Step-by-step Next.js tutorial.
Confidential Builders Program
Apply to build on the Stabletrust SDK.