Wallet Adapters
How ChainPortal SDK abstracts wallet connections across 6 blockchain ecosystems.
Overview
The SDK includes 7 wallet adapters that provide a unified interface for interacting with different blockchain wallets. Each adapter translates SDK operations into ecosystem-specific wallet calls.
Adapter Architecture
Setup Steps
Install provider packages
Add the wallet provider packages for each ecosystem you want to support (wagmi, @solana/wallet-adapter-react, etc.).
Wrap your app in providers
Add each ecosystem's provider to your root layout. Non-EVM providers must always be present — they cannot be conditionally rendered.
Create the adapter
Inside a component, call createEVMAdapter() or the equivalent for your ecosystem, passing the connected wallet client.
Pass to SDK hooks
The SDK hooks automatically detect the active adapter from context — no manual wiring needed.
Creating an Adapter
Adapter Interface
All adapters implement this shared interface:
Provider Setup
Each ecosystem needs its own provider wrapping your app:
Important: Non-EVM providers (Aptos, Cosmos, SUI, Solana) must ALWAYS wrap children -- they cannot be conditionally rendered. Pages using their hooks crash during Next.js SSG prerendering if providers are missing.