Use external wallet mode when the agent should be tied to an address you control. Abstraxn stores the address on the agent record but does not connect wallet providers, provision a server wallet, or return an accessKey.
The default Agent Kit mode is server (managed Abstraxn wallet). This page covers external only. For Abstraxn server wallet / server-signer flows see SDK quickstart.

When to use external wallet

Use external when…Use server wallet when…
Users bring their own wallet (browser extension, mobile, embedded)You want Abstraxn-managed signing
You already have custody / signing infraYou need accessKey + Abstraxn server wallet flows
You must not store Abstraxn wallet secretsMCP tools sign via server-signer (transfer, x402)

Prerequisites

  • Node.js 18+
  • @abstraxn/agent-kit v1.0.3+
  • Abstraxn API key (x-api-key)
  • A wallet stack in your app that can expose evmAddress / solanaAddress (and sign txs if you register ERC-8004 identity)

Wallet connection in your app (optional)

Agent Kit only needs the address strings at createAgent() time. How users connect a wallet is entirely up to you — pick any provider below, read their guide, then pass the connected address into Agent Kit.
Provider / stackUse forDocs
PrivyEmbedded + external wallets, authPrivy docs
MetaMaskBrowser extension (EVM)Connect with MetaMask
WalletConnectMobile & multi-wallet (EVM)WalletConnect docs
viemHeadless EVM signing (backend or frontend)viem docs
ethersEVM signing (v6)ethers docs
Abstraxn Wallets (React)MetaMask / WalletConnect in a React appExternal wallet hooks
These links are optional. Abstraxn does not require a specific provider. After the user connects, call createAgent({ evmAddress, … }) (or solanaAddress). For ERC-8004, use the same wallet to sign — see On-chain identity.

Configure the client

import { AgentKitClient } from '@abstraxn/agent-kit';

const agentKit = new AgentKitClient({
  apiKey: process.env.ABSTRAXN_API_KEY!,
  wallet: 'external',
});
getWalletMode() returns 'external' when configured. You can also keep wallet: 'server' on the client and pass wallet: 'external' on a single createAgent() call.

Create an agent

const { agent, wallet } = await agentKit.createAgent({
  name: 'Trading Assistant',
  description: 'Uses the user-owned wallet',
  userIdentity: '[email protected]',
  evmAddress: '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
  // solanaAddress: '...', // optional — at least one address required
});

console.log(wallet.type);       // 'external'
console.log(wallet.evmAddress); // persisted on the agent
console.log(agent.id);

Response shape

FieldExternal wallet
wallet.type'external'
wallet.evmAddressYour normalized EVM address
wallet.solanaAddressOptional
wallet.accessKeyNot set
wallet.organizationIdNot set
Do not expect or store an accessKey for external agents. All on-chain signing is your responsibility.

Validation rules

  • At least one of evmAddress or solanaAddress is required.
  • EVM addresses are normalized to 0x + 40 hex characters (lowercase).
  • createAgentDirect() is equivalent: creates the agent with addresses only (no server-signer).

Per-call override

const { agent, wallet } = await agentKit.createAgent({
  wallet: 'external',
  evmAddress: '0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb',
  name: 'My Agent',
  description: '...',
  userIdentity: '[email protected]',
});

What external wallet does not do

  • Does not call Abstraxn server-signer or managed wallet provisioning
  • Does not return accessKey or organizationId
  • getServerSigner() is for server wallet integrations only
  • registerAgentIdentity() requires server wallet credentials — use on-chain identity (external) instead
  • MCP transfer and autonomous x402 signing require a server wallet accessKey on your backend

FAQ

Can I use MetaMask instead of a private key in signTransaction? Yes. See On-chain identity (external) for prepare/confirm with MetaMask or WalletConnect. Can I register with Solana only? Yes — pass solanaAddress on createAgent (with or without evmAddress). ERC-8004 registry examples in the SDK are EVM-focused; confirm Solana registry support with your Abstraxn deployment if needed. Why does prepare fail for my chainId? The Agent Kit backend must have IdentityRegistry configured for that chainId. Use a supported chain or contact support.

Next steps

On-chain identity

Register ERC-8004 with your own signer.

API reference

Client config, methods, and types.

SDK quickstart (server wallet)

Default managed wallet + accessKey flow.

ERC-8004 identity

Supported chainIds and registry addresses.