Multichain Guide
IBEX FI API â Multichain Derivation & RPC Guide
This document explains how IBEx.Fi derives public addresses across multiple blockchain families and which RPC interfaces are needed for read/write operations.
The guide is implementationâagnostic and focuses on: (1) how addresses are obtained, (2) what RPC endpoints you need to query balances and broadcast transactions, and (3) integration notes per chain family.
1) Derivation model (summary)
- PRF first: When available, WebAuthn PRF (aka hmacâsecret) yields a deterministic 32âbyte master per credential. No private key is ever exposed.
- Sealed fallback: If PRF is unavailable, a random 32âbyte master is generated once, sealed at rest (AESâGCM), and unlocked in RAM after a successful passkey authentication.
- Family separation: Each family uses HKDF with a distinct info label (e.g.,
evm:global,bitcoin:global,solana:global,cosmos:<hrp>``, âŚ) to derive independent keys. - Exposure:
- Signâup returns the full set of derived public addresses (eoaAddresses).
- Signâin returns a filtered set controlled by
WALLET_TYPE_SIGNIN(CSV of types).
Supported families (current): EVM, Bitcoin (P2WPKH, P2TR), Solana, Cosmos, Polkadot, Tezos (tz1/tz2/tz3), Near, Stellar, Cardano.
2) Runtime outputs
API responses include:
eoaAddress: EVM address (compat).prfCapable: whether PRF was used for this credential.eoaAddresses: array of\{ type, address \}entries, wheretypeâ { EVM, SOLANA, BITCOIN_P2WPKH, BITCOIN_P2TR, COSMOS, POLKADOT, TEZOS_TZ1, TEZOS_TZ2, TEZOS_TZ3, NEAR, STELLAR, CARDANO }.
3) Chain families â RPC requirements
Below is a concise âwhat you need to talk to the chainâ for reads (balance, UTXOs, state) and writes (broadcast signed payloads). Libraries are suggestions; you can use equivalents.
3.1 EVM (Ethereum and EVMâcompatible)
- Address: secp256k1 EOA. Same address across all EVM chains.
- Read RPC (JSONâRPC):
eth_getBalance,eth_call,eth_getLogs,eth_getTransactionReceipt, etc.- Endpoint: any EVM JSONâRPC (HTTPS). In IBEx, we proxy per chain via
WEB3_URL/<chainId>/rpc.
- Write RPC:
eth_sendRawTransaction(EOA flow) or ERCâ4337 bundler endpoints if using account abstraction.- Bundler/Paymaster (optional):
POST /rpc/bundler,POST /rpc/paymaster(IBEx proxy), or direct provider.
- Notes:
- Gas pricing/1559 parameters required when locally signing EOA txs.
- If you use Safe 4337, youâll form UserOperations instead of raw legacy txs.
3.2 Bitcoin (UTXO)
- Addresses:
- P2WPKH bech32 (v0):
bc1q...(testnettb1q...). - P2TR Taproot bech32m (v1):
bc1p...(testnettb1p...).
- P2WPKH bech32 (v0):
- Read RPC options:
- Bitcoin Core JSONâRPC:
listunspent,gettxout,estimatesmartfee,getrawtransaction. - Or Esplora REST / Electrum for UTXO discovery and mempool/broadcast.
- Bitcoin Core JSONâRPC:
- Write RPC:
- Build PSBT (bitcoinjs / @scure/btcâsigner), sign (ECDSA or BIP340 Schnorr for Taproot), finalize, then:
- Bitcoin Core:
sendrawtransactionor EsploraPOST /tx.
- Notes:
- Fee estimation:
estimatesmartfeeor external estimator. - Always handle change outputs and RBF/CPFP policy.
- Fee estimation:
3.3 Solana
- Address: ed25519 base58.
- Read RPC (JSONâRPC):
getBalance,getAccountInfo,getProgramAccounts, etc. - Write RPC:
sendTransaction(base64 encoded signed tx). RequiresrecentBlockhash, fee payer, and compiled message. - Endpoint: any Solana JSONâRPC (HTTPS). Public RPCs or private providers.
3.4 Cosmos (Cosmos SDK chains)
- Address: secp256k1 bech32 with chain HRP (e.g.,
cosmos1...,osmo1...). - Read RPC:
- LCD REST:
/cosmos/bank/v1beta1/balances/\{address\}etc. - Tendermint RPC:
/abci_query,/status.
- LCD REST:
- Write RPC:
- Build proto/amino Tx, sign with secp256k1, broadcast via
/cosmos/tx/v1beta1/txs(broadcast_mode/mode=sync|async|block). - Inputs required: chainâid, accountNumber, sequence, gasPrice.
- Build proto/amino Tx, sign with secp256k1, broadcast via
- Endpoint: LCD (REST) + Tendermint (RPC) or gRPC gateways.
3.5 Polkadot/Substrate
- Address: SS58 (ed25519 in our default; sr25519 also common).
- Read RPC: Substrate JSONâRPC (WebSocket strongly recommended) via Polkadot.js API (state queries, storage maps).
- Write RPC: signed extrinsics submitted over WS RPC (
author_submitExtrinsic). - Endpoint: chainâs WS endpoint (e.g.,
wss://...).
3.6 Tezos
- Addresses:
- tz1 (ed25519), tz2 (secp256k1), tz3 (p256). We derive all three; tz1 is the default most wallets use.
- Read RPC: node RPC (e.g.,
/chains/main/blocks/head/context/contracts/\{address\}) or indexers (TzKT). - Write RPC: forge operation (manager ops), sign, inject via
/injection/operation. - Endpoint: node RPC or indexer for reads; node RPC for writes.
3.7 Near
- Address: ed25519 implicit account (hex of pubkey) or named accounts (not derived by us).
- Read RPC: JSONâRPC
query(view methods, account state). - Write RPC:
broadcast_tx_commit/broadcast_tx_asyncwith signed transaction (requires nonce, recent block hash). - Endpoint: Near JSONâRPC.
3.8 Stellar
- Address: StrKey
G...(ed25519 public key). - Read RPC: Horizon REST (
/accounts/\{addr\},/effects,/payments). - Write RPC: submit signed XDR via
POST /transactions. - Endpoint: Horizon server for the target network.
3.9 Cardano
- Address: bech32
addr1...(enterprise address in our baseline). - Read RPC: Ogmios/Kupo or indexers (Blockfrost REST). UTXO model similar to Bitcoin but different serialization.
- Write RPC: build CBOR tx (cardanoâserializationâlib), sign, submit via node (
submitTx) or Blockfrost/tx/submit. - Endpoint: Cardano node service or Blockfrost.
4) Safe (contract wallets) vs EOA
- Safe per chain: Safe (Gnosis Safe) is a smart account deployed per chain. IBEx exposes:
primarySafeAddress: Safe on the effective chain (header/query or default).safeAddresses/safeAddress: list/mapping of Safes across chains (when multichain is requested).
- EOA per family: A deterministic EOA/public address is computed for each family and exposed via
eoaAddresses. For EVM, this can be used directly for raw EOA flows (or to control a Safe depending on your setup).
5) Operational checklist per family
- EVM
- JSONâRPC URL (HTTPS).
- Decide between EOA raw txs vs ERCâ4337 (bundler/paymaster).
- Gas policy, nonce management.
- Bitcoin
- UTXO provider (Core, Esplora, Electrum) + fee estimator.
- PSBT build/sign/finalize + broadcast.
- Solana
- JSONâRPC URL.
- Fetch recent blockhash; compile & sign message;
sendTransaction.
- Cosmos
- LCD/Tendermint endpoints; chainâid.
- Account sequence, gas price, broadcast endpoint.
- Polkadot
- WS RPC; metadata chain; signed extrinsics.
- Tezos
- Node RPC; forge manager operations; inject.
- Near
- JSONâRPC; get nonce & recent block hash; broadcast mode.
- Stellar
- Horizon base URL; build XDR; submit.
- Cardano
- Node or Blockfrost; CBOR tx build; submit.
6) Security notes
- Keys never persist in plaintext at rest on the server; PRF or sealed fallback only.
- Derivations per family use distinct HKDF info labels to avoid crossâfamily key reuse.
- Rate limiting, audit logs, and shortâlived inâRAM usage are recommended for any serverâside signing flows.
7) Environment & filtering
WALLET_TYPE_SIGNIN(CSV) controls which\{ type, address \}entries are exposed at signâin (no effect on signâup).- EVM chain routing in IBEx is based on
WEB3_URL/<chainId>/rpc(plus optional bundler/paymaster proxies).
If you need concrete code samples (build/sign/broadcast) per family, reach out; we can provide minimal examples using the libraries listed above.