SolanaConnection

1type SolanaConnection = object;

Defined in: account-kit/core/src/types.ts:77

Properties

PropertyTypeDescription

adapters?

WalletAdapter[] | "detect"

Array of Solana wallet adapters to be used for connecting to wallets. Set to “detect” to auto-detect installed wallets, or provide explicit adapters. These adapters will be made available in the React context for wallet selection.

Example

1import { PhantomWalletAdapter, SolflareWalletAdapter } from "@solana/wallet-adapter-wallets";
2
3// Auto-detect installed wallets
4const config = createConfig({
5 // ... other config
6 solana: {
7 connection: solanaConnection,
8 adapters: "detect"
9 }
10});
11
12// Explicit wallet configuration
13const config = createConfig({
14 // ... other config
15 solana: {
16 connection: solanaConnection,
17 adapters: [
18 new PhantomWalletAdapter(),
19 new SolflareWalletAdapter(),
20 ]
21 }
22});

connection

SolanaWeb3Connection

policyId?

string