[Integrations](https://spiral.ai/integrations) › [opencode](https://spiral.ai/integrations/opencode) › [GMGN trending tokens](https://spiral.ai/integrations/opencode/gmgn-trending-tokens)

# How to Use GMGN trending tokens in opencode

Returns ranked tokens with market data such as volume, liquidity, market cap, holder counts, and price changes. Use it to build a market shortlist before investigating individual tokens.

|  |  |
| --- | --- |
| Model | GMGN trending tokens |
| Available through | Alexandria |
| Category | Finance |
| Price | $0.00873 per call. |
| Returns | json |
| Runs | In the background |
| Setup | About 2 minutes, no API key |

## Prompts to try with GMGN trending tokens in opencode

- Use GMGN trending tokens to fetch the top 20 Solana tokens by one-hour volume, then add a table of liquidity, volume, market cap, and holder counts to this project's research dashboard.
- Use GMGN trending tokens for Base over one hour and 24 hours, then add a comparison of tokens appearing in both volume-ranked lists.
- Use GMGN trending tokens to look this up and give me the result as a table. Save the result in ./assets.
- Pull the latest numbers from GMGN trending tokens and tell me what changed since last week.
- Check GMGN trending tokens and summarize what you find in three bullet points.

## How to set up GMGN trending tokens in opencode

Pick the way that suits you. Each takes about two minutes.

### Use Spiral's MCP server

1. **Add the server**: Leave out `--global` to add Spiral to the current project only. No header and no client ID or secret: opencode registers itself with Spiral.

```bash
opencode mcp add spiral --global --url https://api.spiral.ai/mcp
```

2. **Sign in**: Your browser opens. Sign in to Spiral, pick the organization and click Authorize, then return to the terminal. No API key. Inside opencode, `/mcps` starts the same sign-in.

```bash
opencode mcp auth spiral
```

3. **Check it**: Spiral shows as connected.

```bash
opencode mcp list
```

### Use the Spiral skill

1. **Send opencode this message**: Your agent reads Spiral's skill and sets itself up.

```
set up https://spiral.ai/SKILL.md
```

2. **Sign in or paste a key**: Approve Spiral in the browser, or give the agent a key from the console.

### Use the Spiral CLI

1. **Install and sign in**: Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

```bash
npx -y spiral-cli@latest init
```

### Call the Spiral API

1. **Create an API key**: In the console, under API keys.

2. **Run GMGN trending tokens**: One request; the result comes back by polling or a webhook.

```bash
curl https://api.spiral.ai/v1/runs \
  -H "Authorization: Bearer $SPIRAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "provider": "alexandria",
    "model": "gmgn-ai/crypto/trending_tokens",
    "input": {
      "chain": "sol"
    }
  }'
```

Then paste one of the prompts above: opencode finds GMGN trending tokens on Spiral, shows the price and runs it.

Setup guide in the docs: https://spiral.ai/docs/quickstarts/opencode

## GMGN trending tokens tools and prices

- [GMGN · Trending tokens](https://spiral.ai/tools/alexandria/gmgn-ai/crypto/trending_tokens) (Alexandria): $0.00873 per call.

## Settings you can ask for

| Setting | Allowed values | Default | Description |
| --- | --- | --- | --- |
| chain | sol, eth, base, bsc, tron, monad | sol | Chain slug as gmgn.ai uses it in its URLs (sol, eth, base, bsc, tron, monad). Default sol. |
| limit | 1 to 100 | 20 | Maximum tokens. |
| period | 1m, 5m, 1h, 6h, 24h | 1h | Ranking window. |
| sort_by | swaps, volume, market_cap, liquidity, holder_count, price_change_percent, open_timestamp | swaps | Ranking field. |
| direction | desc, asc | desc | direction |

## What can you do with GMGN trending tokens in opencode?

Build an internal GMGN research dashboard with token liquidity, aggregate wallet performance, and public treasury summaries. Add comparisons across observation times and measurement windows so analysts can see what changed.

### Internal market dashboard

Combine token liquidity and volume, aggregate wallet leaderboard statistics, and a public treasury's wallet performance in one research view.

### Morning research brief

Prepare an internal briefing with the most active tokens, the distribution of ranked wallet returns, and a separate performance summary for a public organization wallet.

### Compare short and long windows

Compare short-window token activity with longer-window trends. Separately compare seven-day and 30-day wallet performance to identify results that depend heavily on the measurement window.

### Review changes in a research watchlist

Compare successive observations of token liquidity, aggregate leaderboard performance, and a public treasury's reported profit figures. Flag changes for an analyst's review.

### Screen token liquidity

Build a token shortlist using reported liquidity, volume, and holder counts. Show those measures together so a busy market does not get judged by transaction count alone.

## Overview

- [Alexandria](https://spiral.ai/providers/alexandria)
- [All opencode guides](https://spiral.ai/integrations/opencode)

## GMGN trending tokens in other agents

- [Amp](https://spiral.ai/integrations/amp/gmgn-trending-tokens)
- [ChatGPT](https://spiral.ai/integrations/chatgpt/gmgn-trending-tokens)
- [Claude](https://spiral.ai/integrations/claude-desktop/gmgn-trending-tokens)
- [Claude Code](https://spiral.ai/integrations/claude-code/gmgn-trending-tokens)
- [Cline](https://spiral.ai/integrations/cline/gmgn-trending-tokens)
- [Codex](https://spiral.ai/integrations/codex/gmgn-trending-tokens)
- [Cursor](https://spiral.ai/integrations/cursor/gmgn-trending-tokens)
- [Devin](https://spiral.ai/integrations/devin/gmgn-trending-tokens)
- [dots](https://spiral.ai/integrations/dots/gmgn-trending-tokens)
- [Factory Droid](https://spiral.ai/integrations/factory-droid/gmgn-trending-tokens)
- [Gemini](https://spiral.ai/integrations/gemini/gmgn-trending-tokens)
- [Gemini CLI](https://spiral.ai/integrations/gemini-cli/gmgn-trending-tokens)
- [Google Antigravity](https://spiral.ai/integrations/antigravity/gmgn-trending-tokens)
- [goose](https://spiral.ai/integrations/goose/gmgn-trending-tokens)
- [Grok](https://spiral.ai/integrations/grok/gmgn-trending-tokens)
- [Grok Build](https://spiral.ai/integrations/grok-build/gmgn-trending-tokens)
- [Hermes](https://spiral.ai/integrations/hermes/gmgn-trending-tokens)
- [Instinct](https://spiral.ai/integrations/instinct/gmgn-trending-tokens)
- [Manus](https://spiral.ai/integrations/manus/gmgn-trending-tokens)
- [Muse](https://spiral.ai/integrations/muse/gmgn-trending-tokens)
- [Muse Code](https://spiral.ai/integrations/muse-code/gmgn-trending-tokens)
- [n8n](https://spiral.ai/integrations/n8n/gmgn-trending-tokens)
- [Notion](https://spiral.ai/integrations/notion/gmgn-trending-tokens)
- [OpenClaw](https://spiral.ai/integrations/openclaw/gmgn-trending-tokens)
- [Perplexity](https://spiral.ai/integrations/perplexity/gmgn-trending-tokens)
- [Raycast](https://spiral.ai/integrations/raycast/gmgn-trending-tokens)
- [VS Code](https://spiral.ai/integrations/vscode/gmgn-trending-tokens)
- [Windsurf](https://spiral.ai/integrations/windsurf/gmgn-trending-tokens)
- [Zapier](https://spiral.ai/integrations/zapier/gmgn-trending-tokens)

## More opencode guides

- [GMGN token trades](https://spiral.ai/integrations/opencode/gmgn-token-trades)
- [GMGN wallet performance](https://spiral.ai/integrations/opencode/gmgn-wallet-performance)
- [GMGN token trader profits](https://spiral.ai/integrations/opencode/gmgn-token-trader-profits)
- [GMGN wallet rankings](https://spiral.ai/integrations/opencode/gmgn-wallet-rankings)
- [GMGN token search](https://spiral.ai/integrations/opencode/gmgn-token-search)
- [GlobeNewswire latest press releases](https://spiral.ai/integrations/opencode/globenewswire-latest-press-releases)

## Questions about GMGN trending tokens in opencode

**Can opencode use GMGN trending tokens?**

Yes. Add Spiral to opencode as an MCP server, and opencode can find and run GMGN trending tokens like any built-in tool.

**How much does GMGN trending tokens cost in opencode?**

$0.00873 per call. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your opencode plan is separate.

**Do I need an Alexandria account to use GMGN trending tokens in opencode?**

No. Spiral runs GMGN trending tokens on its own Alexandria account. You sign in to Spiral once and never paste a key.

**How long does it take to set up GMGN trending tokens in opencode?**

About two minutes: add the server, then sign in, then check it.

**Does opencode wait while GMGN trending tokens runs?**

GMGN trending tokens runs in the background. opencode starts the run, checks on it and gives you the json when it's ready.

**What activity does GMGN measure?**

GMGN covers activity generated by compatible third-party blockchain applications. Its token and wallet statistics describe the blockchain activity the platform monitors.

**Where does GMGN get its data?**

GMGN says its on-chain transaction data and token security information come from multiple third-party providers. Alexandria reads the anonymous JSON API behind GMGN's terminal.

**Are GMGN security indicators immediately current?**

GMGN warns that honeypot detection information can appear with a delay. A displayed security indicator therefore does not establish the contract's current state.

**Does a favorable security check prove a token is safe?**

No. GMGN explicitly says its token security checks cannot guarantee 100% accuracy and recommends comparing multiple security tools.

**What reuse does GMGN's standard license cover?**

GMGN's standard license permits reproducing portions of its services for personal or internal business purposes, subject to its agreement.

