[Integrations](https://spiral.ai/integrations) › [opencode](https://spiral.ai/integrations/opencode) › [DeFiLlama stablecoin supply history](https://spiral.ai/integrations/opencode/defillama-stablecoin-supply-history)

# How to Use DeFiLlama stablecoin supply history in opencode

Returns historical circulating supply for a stablecoin across all chains or on one chain. Use it to measure supply growth or contraction over time, after finding the asset in the stablecoin rankings.

|  |  |
| --- | --- |
| Model | DeFiLlama stablecoin supply history |
| 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 DeFiLlama stablecoin supply history in opencode

- Use DeFiLlama stablecoin supply history for USDT, asset ID 1, on Ethereum and add a chart of the available supply observations.
- Use DeFiLlama stablecoin supply history for USDC, asset ID 2, on Ethereum and Arbitrum, then add a comparison of supply changes to the analytics module.
- Use DeFiLlama stablecoin supply history to look this up and give me the result as a table. Save the result in ./assets.
- Pull the latest numbers from DeFiLlama stablecoin supply history and tell me what changed since last week.
- Check DeFiLlama stablecoin supply history and summarize what you find in three bullet points.

## How to set up DeFiLlama stablecoin supply history 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 DeFiLlama stablecoin supply history**: 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": "defillama-com/crypto/stablecoin_history",
    "input": {
      "id": "<id>"
    }
  }'
```

Then paste one of the prompts above: opencode finds DeFiLlama stablecoin supply history on Spiral, shows the price and runs it.

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

## DeFiLlama stablecoin supply history tools and prices

- [DeFiLlama · Stablecoin history](https://spiral.ai/tools/alexandria/defillama-com/crypto/stablecoin_history) (Alexandria): $0.00873 per call.

## Settings you can ask for

| Setting | Allowed values | Default | Description |
| --- | --- | --- | --- |
| to | 0 to … | — | Latest point, unix seconds. |
| from | 0 to … | — | Earliest point, unix seconds. |
| chain |  | — | Chain name as DeFiLlama writes it (e.g. `Ethereum`); omit for the all-chain total. |
| limit | 1 to 4000 | 90 | Maximum points returned, newest first (1..4000, default 90). |

## What can you do with DeFiLlama stablecoin supply history in opencode?

Build a research view that puts stablecoin supply beside DeFi pool APY and TVL. A coding agent can connect current listings to historical series and add comparisons to the project's existing charts.

### Weekly Ethereum stablecoin report

Combine current stablecoin supply rankings with supply changes, then compare current stablecoin pool APYs with their historical APY and TVL. Produce a research brief that separates asset supply from pool activity.

### Compare chains

Compare USDC supply on Ethereum and Arbitrum alongside USDC pool APYs and TVL. Use the historical series to see whether the current differences persisted over the available period.

### USDC research brief

Identify USDC in the stablecoin listing, examine its supply history, and compare pools using USDC. Add pool histories to show how their yields and deposited value changed.

### Review a market event

Examine stablecoin supply and pool APY and TVL before and after a selected event date. Use current listings to identify the assets and pools, then describe the historical changes without assuming the event caused them.

### Stablecoin supply concentration

Compare current USDT and USDC circulating amounts, then calculate how each asset's supply changed over the available historical period.

## Overview

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

## DeFiLlama stablecoin supply history in other agents

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

## More opencode guides

- [DeFiLlama stablecoin market cap by chain](https://spiral.ai/integrations/opencode/defillama-stablecoin-market-cap-by-chain)
- [DeFiLlama stablecoin supply rankings](https://spiral.ai/integrations/opencode/defillama-stablecoin-supply-rankings)
- [DeFiLlama protocol fees and volume rankings](https://spiral.ai/integrations/opencode/defillama-protocol-fees-and-volume-rankings)
- [DeFiLlama token price history](https://spiral.ai/integrations/opencode/defillama-token-price-history)
- [DeFiLlama protocol fees and volume history](https://spiral.ai/integrations/opencode/defillama-protocol-fees-and-volume-history)
- [DeFiLlama token prices](https://spiral.ai/integrations/opencode/defillama-token-prices)

## Questions about DeFiLlama stablecoin supply history in opencode

**Can opencode use DeFiLlama stablecoin supply history?**

Yes. Add Spiral to opencode as an MCP server, and opencode can find and run DeFiLlama stablecoin supply history like any built-in tool.

**How much does DeFiLlama stablecoin supply history 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 DeFiLlama stablecoin supply history in opencode?**

No. Spiral runs DeFiLlama stablecoin supply history on its own Alexandria account. You sign in to Spiral once and never paste a key.

**How long does it take to set up DeFiLlama stablecoin supply history in opencode?**

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

**Does opencode wait while DeFiLlama stablecoin supply history runs?**

DeFiLlama stablecoin supply history runs in the background. opencode starts the run, checks on it and gives you the json when it's ready.

**How fresh are DeFiLlama's stablecoin and yield figures?**

DeFiLlama documents hourly updates for stablecoin supply, yield APY, and pool TVL. These figures follow an hourly collection schedule rather than updating with every transaction.

**Where does DeFiLlama get yield data?**

Its yield adapters use on-chain calls or subgraphs. DeFiLlama accepts centralized API data only when there is no other way to obtain it, such as off-chain gauge weights.

**Does DeFiLlama show boosted yields?**

Its stated methodology targets minimum attainable yield. It uses unboosted APY and excludes locked rewards and yield that requires holding an additional token.

**Can I request history using just a ticker?**

DeFiLlama identifies stablecoins and yield pools separately: its documented stablecoin IDs include 1 for USDT and 2 for USDC, while yield history uses an identifier from the pool listing. Resolve the asset or pool first to select the intended historical series.

**Can I examine a current figure over time?**

DeFiLlama provides stablecoin history for a specific chain and historical APY and TVL for an individual yield pool. Match the chain and asset or pool before comparing a current result with its history.

