Solana Blockchain Skill for Hermes Agent: Wallet, Tokens, NFTs, and Network Stats
Query Solana wallets, tokens, txs, and NFTs in USD.
Written by Neura Market from the official Hermes Agent documentation for Solana. Commands, paths, and version numbers are reproduced from the source unchanged.
Read the official documentationThis skill gives Hermes Agent the ability to query live Solana on-chain data and enrich it with USD pricing from CoinGecko. You get eight commands covering wallet portfolios, token metadata, transaction inspection, recent activity, NFT holdings, whale transfers, network health, and price lookups. No API keys are required, and the entire helper script uses only Python's standard library. Reach for this when a user asks about a Solana balance, a specific transaction, a token's details, or wants to monitor large transfers on the network.
What it does
The skill wraps a single Python script that talks to the Solana public RPC and CoinGecko's free API. It returns structured data that Hermes Agent can present to the user: SOL and SPL token balances with USD values, transaction histories with balance changes, token metadata including top holders, NFT lists, whale alerts for large SOL transfers, live network stats like TPS and epoch, and quick price checks for known tokens. The script handles rate limiting and retries automatically, so the agent can focus on answering the user.
Before you start
- Python 3 must be installed on the system where Hermes Agent runs. The script uses only
urllib,json, andargparsefrom the standard library. No pip install is needed. - The default RPC endpoint is
https://api.mainnet-beta.solana.com. For production use or higher rate limits, set the environment variableSOLANA_RPC_URLto a private endpoint from Helius, QuickNode, or Triton. - CoinGecko's free API is rate-limited to roughly 10-30 requests per minute. Each token price lookup consumes one request. If a wallet holds many tokens, some prices may not resolve. Use the
--no-pricesflag to skip CoinGecko entirely and get faster, RPC-only results. - The script path is
~/.hermes/skills/blockchain/solana/scripts/solana_client.py. All commands assume you are running from that directory or using the full path.
Quick reference
python3 solana_client.py wallet <address> [--limit N] [--all] [--no-prices]
python3 solana_client.py tx <signature>
python3 solana_client.py token <mint_address>
python3 solana_client.py activity <address> [--limit N]
python3 solana_client.py nft <address>
python3 solana_client.py whales [--min-sol N]
python3 solana_client.py stats
python3 solana_client.py price <mint_or_symbol>
Procedure
0. Setup Check
python3 --version
# Optional: set a private RPC for better rate limits
export SOLANA_RPC_URL="https://api.mainnet-beta.solana.com"
# Confirm connectivity
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py stats
1. Wallet Portfolio
Get SOL balance, SPL token holdings with USD values, NFT count, and portfolio total. Tokens sorted by value, dust filtered, known tokens labeled by name (BONK, JUP, USDC, etc.).
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py \
wallet 9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM
Flags:
--limit N, show top N tokens (default: 20)--all, show all tokens, no dust filter, no limit--no-prices, skip CoinGecko price lookups (faster, RPC-only)
Output includes: SOL balance + USD value, token list with prices sorted by value, dust count, NFT summary, total portfolio value in USD.
2. Transaction Details
Inspect a full transaction by its base58 signature. Shows balance changes in both SOL and USD.
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py \
tx 5j7s8K...your_signature_here
Output: slot, timestamp, fee, status, balance changes (SOL + USD), program invocations.
3. Token Info
Get SPL token metadata, current price, market cap, supply, decimals, mint/freeze authorities, and top 5 holders.
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py \
token DezXAZ8z7PnrnRJjz3wXBoRgixCa6xjnB7YaB1pPB263
Output: name, symbol, decimals, supply, price, market cap, top 5 holders with percentages.
4. Recent Activity
List recent transactions for an address (default: last 10, max: 25).
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py \
activity 9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM --limit 25
5. NFT Portfolio
List NFTs owned by a wallet (heuristic: SPL tokens with amount=1, decimals=0).
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py \
nft 9WzDXwBbmkg8ZTbNMqUxvQRAyrZzDsGYdLVL9zYtAWWM
Note: Compressed NFTs (cNFTs) are not detected by this heuristic.
6. Whale Detector
Scan the most recent block for large SOL transfers with USD values.
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py \
whales --min-sol 500
Note: scans the latest block only, point-in-time snapshot, not historical.
7. Network Stats
Live Solana network health: current slot, epoch, TPS, supply, validator version, SOL price, and market cap.
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py stats
8. Price Lookup
Quick price check for any token by mint address or known symbol.
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py price BONK
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py price JUP
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py price SOL
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py price DezXAZ8z7PnrnRJjz3wXBoRgixCa6xjnB7YaB1pPB263
Known symbols: SOL, USDC, USDT, BONK, JUP, WETH, JTO, mSOL, stSOL, PYTH, HNT, RNDR, WEN, W, TNSR, DRIFT, bSOL, JLP, WIF, MEW, BOME, PENGU.
When not to use it
This skill is not designed for historical analysis, deep DeFi protocol interactions, or tracking compressed NFTs. If the user needs to query transactions older than about two days, the public RPC will not return them. For programmatic trading, staking, or swapping, you need a dedicated wallet and a transaction builder, not a read-only query tool.
Limits and gotchas
- CoinGecko rate-limits, free tier allows ~10-30 requests/minute. Price lookups use 1 request per token. Wallets with many tokens may not get prices for all of them. Use
--no-pricesfor speed. - Public RPC rate-limits, Solana mainnet public RPC limits requests. For production use, set SOLANA_RPC_URL to a private endpoint (Helius, QuickNode, Triton).
- NFT detection is heuristic, amount=1 + decimals=0. Compressed NFTs (cNFTs) and Token-2022 NFTs won't appear.
- Whale detector scans latest block only, not historical. Results vary by the moment you query.
- Transaction history, public RPC keeps ~2 days. Older transactions may not be available.
- Token names, ~25 well-known tokens are labeled by name. Others show abbreviated mint addresses. Use the
tokencommand for full info. - Retry on 429, both RPC and CoinGecko calls retry up to 2 times with exponential backoff on rate-limit errors.
Verification
# Should print current Solana slot, TPS, and SOL price
python3 ~/.hermes/skills/blockchain/solana/scripts/solana_client.py stats