gmgn-portfolio

Query GMGN wallet portfolio — API Key wallet info, holdings, transaction activity, trading stats, and token balance. Supports sol / bsc / base.

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "gmgn-portfolio" with this command: npx skills add gmgnai/gmgn-skills/gmgnai-gmgn-skills-gmgn-portfolio

Use the gmgn-cli tool to query wallet portfolio data based on the user's request.

Sub-commands

Sub-commandDescription
portfolio infoWallets and main currency balances bound to the API Key
portfolio holdingsWallet token holdings with P&L
portfolio activityTransaction history
portfolio statsTrading statistics (supports batch)
portfolio token-balanceToken balance for a specific token

Supported Chains

sol / bsc / base

Prerequisites

  • .env file with GMGN_API_KEY set
  • Run from the directory where your .env file is located, or set GMGN_HOST in your environment
  • gmgn-cli installed globally: npm install -g gmgn-cli@1.0.1

Usage Examples

# API Key wallet info (no --chain or --wallet needed)
gmgn-cli portfolio info

# Wallet holdings (default sort)
gmgn-cli portfolio holdings --chain sol --wallet <wallet_address>

# Holdings sorted by USD value, descending
gmgn-cli portfolio holdings \
  --chain sol --wallet <wallet_address> \
  --order-by usd_value --direction desc --limit 20

# Include sold-out positions
gmgn-cli portfolio holdings --chain sol --wallet <wallet_address> --sell-out

# Transaction activity
gmgn-cli portfolio activity --chain sol --wallet <wallet_address>

# Activity filtered by type
gmgn-cli portfolio activity --chain sol --wallet <wallet_address> \
  --type buy --type sell

# Activity for a specific token
gmgn-cli portfolio activity --chain sol --wallet <wallet_address> \
  --token <token_address>

# Trading stats (default 7d)
gmgn-cli portfolio stats --chain sol --wallet <wallet_address>

# Trading stats for 30 days
gmgn-cli portfolio stats --chain sol --wallet <wallet_address> --period 30d

# Batch stats for multiple wallets
gmgn-cli portfolio stats --chain sol \
  --wallet <wallet_1> --wallet <wallet_2>

# Token balance
gmgn-cli portfolio token-balance \
  --chain sol --wallet <wallet_address> --token <token_address>

Holdings Options

OptionDescription
--limit <n>Page size (default 20, max 50)
--cursor <cursor>Pagination cursor
--order-by <field>Sort field: usd_value / price / unrealized_profit / realized_profit / total_profit / history_bought_cost / history_sold_income (default usd_value)
--direction <asc|desc>Sort direction (default desc)
--sell-outInclude sold-out positions
--show-smallInclude small-value positions
--hide-abnormalHide abnormal positions
--hide-airdropHide airdrop positions
--hide-closedHide closed positions
--hide-openHide open positions

Activity Options

OptionDescription
--token <address>Filter by token
--limit <n>Page size
--cursor <cursor>Pagination cursor
--type <type>Repeatable: buy / sell / add / remove / transfer

Stats Options

OptionDescription
--period <period>Stats period: 7d / 30d (default 7d)

Notes

  • All portfolio commands use normal auth (API Key only, no signature required)
  • portfolio stats supports multiple --wallet flags for batch queries
  • Use --raw to get single-line JSON for further processing
  • Input validation — Wallet and token addresses are validated against the expected chain format at runtime (sol: base58 32–44 chars; bsc/base/eth: 0x + 40 hex digits). The CLI exits with an error on invalid input.

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

General

gmgn-swap

No summary provided by upstream source.

Repository SourceNeeds Review
General

gmgn-market

No summary provided by upstream source.

Repository SourceNeeds Review
General

gmgn-token

No summary provided by upstream source.

Repository SourceNeeds Review
Web3

precog

Trade on prediction markets. Create a local wallet, list markets, check prices, buy and sell outcome shares. Coming soon: create and fund markets directly from this skill.

Archived SourceRecently Updated