Skip to main content
The Phantom skill makes your AI assistant an expert at building frontend Solana applications. It combines Phantom Connect SDK — React, React Native, and vanilla JS wallet integration — with Helius infrastructure for transaction submission, fee optimization, asset queries, and real-time updates. When installed, the AI automatically reads the right reference files and calls the right MCP tools based on what you ask — no manual tool selection needed.
Claude Code: /helius:phantom (via plugin) or auto-invoked (standalone). Codex: $helius-phantom (auto-discovered from .agents/skills/). API / Cursor / ChatGPT: Use the pre-built system prompt variants.

What It Covers

The Phantom skill routes the AI across both Phantom SDKs and Helius tools:
DomainReference FilesMCP Tools Used
Wallet Connection — Reactreact-sdk.md
Wallet Connection — Browserbrowser-sdk.md
Wallet Connection — React Nativereact-native-sdk.md
Transactionstransactions.md, helius-sender.mdgetPriorityFeeEstimate, getSenderInfo
Token Gatingtoken-gating.md, helius-das.mdgetAssetsByOwner, searchAssets, getAsset
NFT Mintingnft-minting.md, helius-sender.mdgetAsset, getPriorityFeeEstimate
Crypto Paymentspayments.md, helius-enhanced-transactions.mdparseTransactions, getPriorityFeeEstimate
Frontend Securityfrontend-security.md
Portfolio Displayhelius-das.md, helius-wallet-api.mdgetAssetsByOwner, getWalletBalances, getTokenBalances
Real-Time Updateshelius-websockets.mdtransactionSubscribe, accountSubscribe
Transaction Historyhelius-enhanced-transactions.mdparseTransactions, getTransactionHistory
Integration Patternsintegration-patterns.mdMultiple (pattern-dependent)

Key Rules

The Phantom skill enforces critical patterns that prevent common frontend mistakes:
  • Always use @phantom/react-sdk for React (never window.phantom.solana or @solana/wallet-adapter-react)
  • Always use @phantom/browser-sdk for vanilla JS and @phantom/react-native-sdk for React Native
  • Never expose Helius API keys in client code — only https://sender.helius-rpc.com/fast is browser-safe without an API key
  • Proxy everything else through your backend — never open Helius WebSockets directly from the browser
  • Always submit transactions via Helius Sender with skipPreflight: true, maxRetries: 0, and a Jito tip
  • Use getPriorityFeeEstimate MCP tool — never hardcode priority fees

Composite Patterns

The skill provides five end-to-end reference patterns for complex applications:
  1. Swap UI — Aggregator → Phantom sign → Helius Sender submit
  2. Portfolio Viewer — Phantom connection → backend proxy → DAS/Wallet API
  3. Real-time Dashboard — Phantom connection → server WebSocket → client relay
  4. Token Transfer — Build VersionedTransaction → Phantom sign → Sender submit
  5. NFT Gallery — Phantom wallet → backend DAS query → display NFTs

Prerequisites

This skill requires the Helius MCP server. For embedded wallets (Google/Apple sign-in), you also need a Phantom Portal account with an App ID and allowlisted redirect URLs. If you install via the Claude Code plugin, the MCP server starts automatically. For standalone installation, add it manually:
claude mcp add helius npx helius-mcp@latest

Standalone Installation

If you want the Phantom skill without the full plugin, install it directly:
1

Clone the repository

git clone https://github.com/helius-labs/core-ai.git
cd core-ai/helius-skills/helius-phantom
2

Run the install script

./install.sh
This installs the skill and its reference files to ~/.claude/skills/helius-phantom/.Options:
  • ./install.sh --project — install to the current project (.claude/skills/helius-phantom/)
  • ./install.sh --path /custom/path — install to a custom directory
3

Install the Helius MCP server

claude mcp add helius npx helius-mcp@latest
4

Set your API key

export HELIUS_API_KEY=YOUR_API_KEY
Or use the setHeliusApiKey MCP tool inside Claude Code. If you need a new account, see Helius CLI or use the autonomous signup flow via MCP tools.

Example Prompts

Once installed, ask in plain English:
  • “Build a swap UI with Phantom wallet”
  • “Build a portfolio viewer that shows tokens after connecting Phantom”
  • “How do I proxy my Helius API key in Next.js?”
  • “Build a real-time dashboard with wallet connection”
  • “Add token gating to my React app using Phantom”
  • “Build an NFT minting page with Phantom and Metaplex Core”
The AI picks the right tools and reads the right reference files automatically.

What’s Included

The skill installs two components:
  • SKILL.md — Routing logic, rules, and expert context that guide the AI’s behavior
  • prompts/ — Pre-built system prompt variants (openai.developer.md, claude.system.md, full.md) — see platform setup
  • references/ — 16 deep documentation files:
    • react-sdk.md — Phantom React SDK (@phantom/react-sdk)
    • browser-sdk.md — Phantom Browser SDK (@phantom/browser-sdk)
    • react-native-sdk.md — Phantom React Native SDK (@phantom/react-native-sdk)
    • transactions.md — Transaction signing patterns
    • token-gating.md — Token-gated access control
    • nft-minting.md — NFT minting with Phantom
    • payments.md — Crypto payment flows
    • frontend-security.md — API key proxying and CORS
    • integration-patterns.md — End-to-end composite patterns
    • helius-das.md — DAS API reference
    • helius-sender.md — Sender reference
    • helius-priority-fees.md — Priority fee reference
    • helius-wallet-api.md — Wallet API reference
    • helius-websockets.md — WebSocket reference
    • helius-enhanced-transactions.md — Enhanced Transactions reference
    • helius-onboarding.md — Account setup reference

Learn More