Skip to main content
Use the SNS RPC methods to turn wallet addresses into .sol display names or resolve a domain to its owner. Batch primary-domain lookups when rendering a holder list or leaderboard.
Each SNS RPC method costs 1 credit per call. Twitter/X handles (.twitter) are not supported.

RPC endpoint

All examples use JSON-RPC 2.0 over HTTP:

Get a wallet’s primary domain

Use getPrimaryDomain for the wallet’s primary .sol display name.
When a domain exists:
When no primary domain exists, domain is null:
In UI, use the domain as the label when present, and fall back to a shortened wallet address when domain is null.

Batch primary domains

Use getMultiplePrimaryDomains for a list of wallets: The method accepts up to 100 wallets and returns results in the same order as the input list.
Example response:
Because the response preserves input order, you can merge it back into a wallet list by array index:

Get all domains owned by a wallet

Use getAllDomains to list the .sol domains owned by a wallet.
Response:
If the wallet has no domains, domains is an empty array.

Resolve a domain to an owner

Use resolveSolDomain to resolve a .sol name to its owner wallet.
Response:
If the domain is not found, value is null. resolveSolDomain supports root .sol domains like name.sol and one-level subdomains like sub.parent.sol.

Example: wallet identity helper

This helper uses primary domains for display and keeps the wallet address available for linking, copying, or transaction actions.

Choosing the right SNS method

PnL V2 already includes SNS identity in supported wallet and token analytics responses. Use these RPC methods when you need SNS resolution directly from the Solana RPC surface.

UI and product tips

  • Always keep the wallet address available, even when showing a domain.
  • Treat domain: null as a normal result, not an error.
  • Use batch resolution for tables and feeds instead of calling getPrimaryDomain in a loop.
  • Show .sol names as labels, but copy and link the underlying wallet address.
  • For user search, resolve .sol names first, then continue with the returned owner wallet.

getMultiplePrimaryDomains

Batch primary .sol domains for up to 100 wallets.

SNS wallet names

See where SNS identity appears in PnL V2 responses.