Skip to Content
Supported ChainSolana

Solana API

Access Solana blockchain data through the Spectrum API. Solana is a high-throughput blockchain using the Solana Virtual Machine (SVM) with sub-second finality. Spectrum supports a focused set of Solana endpoints including block slots, native and SPL token balances, and JSON-RPC passthrough.

PropertyValue
Slugsolana
TypeSVM
Native TokenSOL
Address FormatBase58

Available methods

Solana supports a subset of the full Spectrum API. Token metadata, portfolio, ENS, NFTs, and contract read endpoints are not available for Solana.

MethodDescription
getBlockHeightLatest Solana slot number
getBalanceSOL balance for a wallet
getTokenBalanceSPL token balance
rpcProxyRaw Solana JSON-RPC passthrough
getChainHealthSolana RPC health check

Quick start

curl -X POST https://your-endpoint.simplystaking.xyz/v1 \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_KEY" \
{
  "jsonrpc": "2.0",
  "method": "getBlockHeight",
  "params": {
    "chain": "solana"
  },
  "id": 1
}
{ "jsonrpc": "2.0", "result": { "chain": "solana", "height": 312456789 }, "id": 1 }

Get a Solana wallet balance

Solana uses base58-encoded addresses instead of the 0x-prefixed addresses used by EVM chains.

curl -X POST https://your-endpoint.simplystaking.xyz/v1 \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_KEY" \
{
  "jsonrpc": "2.0",
  "method": "getBalance",
  "params": {
    "chain": "solana",
    "address": "vines1vzrYbzLMRdu58ou5XTby4qAqVRLmqo36NKPTg"
  },
  "id": 1
}
{ "jsonrpc": "2.0", "result": { "chain": "solana", "address": "vines1vzrYbzLMRdu58ou5XTby4qAqVRLmqo36NKPTg", "token": "SOL", "balance": "42.5" }, "id": 1 }

Get an SPL token balance

curl -X POST https://your-endpoint.simplystaking.xyz/v1 \
  -H "Content-Type: application/json" \
  -H "X-API-Key: YOUR_KEY" \
{
  "jsonrpc": "2.0",
  "method": "getTokenBalance",
  "params": {
    "chain": "solana",
    "address": "vines1vzrYbzLMRdu58ou5XTby4qAqVRLmqo36NKPTg",
    "token": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"
  },
  "id": 1
}

SDK

import { Spectrum } from '@spectrum-nodes/sdk'; const spectrum = new Spectrum({ api: 'https://your-endpoint.simplystaking.xyz/YOUR_API_KEY/' }); // Get the latest Solana slot const block = await spectrum.core.getBlockHeight('solana'); console.log(block.height); // Get a wallet's SOL balance const balance = await spectrum.tokens.getBalance( 'solana', 'vines1vzrYbzLMRdu58ou5XTby4qAqVRLmqo36NKPTg' ); console.log(balance.balance); // Get an SPL token balance (e.g., USDC) const usdc = await spectrum.tokens.getTokenBalance( 'solana', 'vines1vzrYbzLMRdu58ou5XTby4qAqVRLmqo36NKPTg', 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v' ); console.log(usdc.balance);

Endpoint differences from EVM chains

  • Block height returns the current slot number instead of a block number.
  • Addresses use base58 encoding (e.g., vines1vzrYbzLMRdu58ou5XTby4qAqVRLmqo36NKPTg) instead of 0x-prefixed hex.
  • Token balances use SPL mint addresses instead of ERC-20 contract addresses.
  • Token metadata, portfolio, NFTs, and contract read endpoints are not supported.