Requirements
- React 18+ or Next.js 13+
- Node.js 18+
- A Cavos App ID from the Dashboard
Installation
- npm
- yarn
- pnpm
Configuration
CavosProvider
Wrap your application withCavosProvider at the root level:
Configuration Options
| Property | Type | Required | Default | Description |
|---|---|---|---|---|
appId | string | Yes | - | Your Cavos App ID |
network | ’sepolia’ | ‘mainnet’ | No | ’sepolia’ | Target Starknet network |
paymasterApiKey | string | No | Cavos shared key | Custom AVNU Paymaster API key |
starknetRpcUrl | string | No | Alchemy RPC | Custom Starknet RPC URL |
enableLogging | boolean | No | false | Enable SDK debug logging |
Next.js App Router
For Next.js 13+ with App Router, mark the provider as a client component:Passkey Modal Customization
The SDK includes a built-in passkey modal for wallet creation. Customize it via config:Exports
The package exports:| Export | Description |
|---|---|
CavosProvider | React context provider |
useCavos | Main hook for SDK access |
CavosSDK | Direct SDK class (advanced) |
WalletManager | Wallet operations (advanced) |
TransactionManager | Transaction execution (advanced) |

