Defillama

ToolByIronHubVersion0.2.1

DefiLlama DeFi analytics — protocol/chain TVL, token prices, stablecoin circulation, yield/APY pools, DEX volumes, and fees/revenue from the free open API. No API key, no auth setup.

DeFiAnalyticsResearch

Use Cases

  • Rank protocols/chains by TVL and pull their TVL history
  • Price any token by contract address or CoinGecko id, current or historical
  • Screen 15k+ yield pools by chain/project/symbol and chart a pool's APY
  • Compare DEX volumes, fees, and revenue across protocols and chains
Install
$ironclaw ironhub install defillama

Description

DefiLlama Tool

Install and configure

Install the tool from IronHub. For a manual package import, open Extensions → Registry → Import, select the tool archive, and click Install.

No credential or paid DefiLlama account is required.

Each operation is exposed as a named capability with its own input schema. Use only the parameters shown for that capability in the examples below.

This package declares no credentials. Network egress remains restricted to the hosts declared by each capability.

A sandboxed WASM tool that gives an IronClaw agent access to DefiLlama — TVL, prices, stablecoins, yields, volumes, and fees — via the free open API. No API key, no credentials, no setup.

Defillama tool

Free API only. DefiLlama Pro places its API key in the URL path. This package intentionally uses the free API and never accepts credentials as capability input.

Capabilities

All list/history outputs are summarized, sorted, and downsampled — several DefiLlama endpoints return multi-MB payloads (7k+ protocols, 15k+ pools, years of daily points) that would otherwise flood the model context. limit defaults to 20 (max 100); points (time-series length) defaults to 90 (max 500).

TVL

CapabilityRequiredOptionalNotes
list_protocolsquery, category, chain, limitSorted by TVL desc.
get_protocolprotocolpointsMetadata + current per-chain TVL + downsampled TVL history.
protocol_tvlprotocolCurrent TVL as one number.
list_chainslimitAll chains by TVL.
chain_tvl_historychain, pointsOmit chain for the all-chains total.

Token prices

coins is a comma-separated list of {chain}:{address} or coingecko:{id}, e.g. coingecko:ethereum,bsc:0x762539b45a1dcce3d36d080f74d1aed37844b878.

CapabilityRequiredOptional
current_pricescoinssearch_width
historical_pricescoins, timestampsearch_width
price_chartcoinsstart or end, span, period, search_width
price_percentagecoinstimestamp, look_forward, period
first_pricescoins
blockchain, timestamp

Stablecoins

CapabilityRequiredOptional
list_stablecoinsquery, limit
get_stablecoinstablecoin_id (numeric id)
stablecoin_historychain, stablecoin_id, points
stablecoin_chains
stablecoin_pricespoints

Yields

CapabilityRequiredOptional
list_poolschain, project, symbol, limit
pool_historypool (UUID from list_pools)points

Volumes & fees

CapabilityRequiredOptional
dex_overviewchain, limit
dex_summaryprotocol
options_overviewchain, data_type, limit
options_summaryprotocoldata_type
open_interest_overviewlimit
fees_overviewchain, data_type, limit
fees_summaryprotocoldata_type

data_type: options → dailyPremiumVolume/dailyNotionalVolume; fees → dailyFees/dailyRevenue/dailyHoldersRevenue.

Examples

// Top 10 lending protocols on Ethereum
// Capability: defillama.list_protocols
{ "category": "Lending", "chain": "Ethereum", "limit": 10 }

// ETH price now, and 24h change
// Capability: defillama.current_prices
{ "coins": "coingecko:ethereum" }
// Capability: defillama.price_percentage
{ "coins": "coingecko:ethereum" }

// Best USDC pools on Arbitrum
// Capability: defillama.list_pools
{ "chain": "Arbitrum", "symbol": "USDC", "limit": 10 }

// Which DEX earned the most fees today?
// Capability: defillama.fees_overview
{ "data_type": "dailyRevenue", "limit": 10 }

// Solana TVL over time
// Capability: defillama.chain_tvl_history
{ "chain": "Solana", "points": 60 }

Large-response handling

Several DefiLlama endpoints return multi-megabyte payloads. The tool requests gzip, inflates the response incrementally, filters rows while scanning, keeps bounded top-N results, and downsamples time series before returning JSON to the agent. The full decompressed document is not retained in memory.

list_pools, list_protocols, and get_protocol perform the heaviest scans. IronClaw Reborn currently gives every WASM execution a fixed 500M fuel budget; these three capabilities may therefore return a fuel-limit error on large live datasets. Legacy WASM limit environment variables are not read by the Reborn production path, so there is currently no operator-side environment workaround. The host must add a supported configurable or per-capability fuel budget before these scans can reliably receive more fuel. Response and memory limits remain independent.

Endpoints used

  • https://api.llama.fi — protocols, chains, TVL, volumes, fees (free)
  • https://coins.llama.fi — token prices, blocks (free)
  • https://stablecoins.llama.fi — stablecoin circulation (free)
  • https://yields.llama.fi — yield pools (free)

API reference: https://api-docs.defillama.com/ (defillama-api.yaml in this folder is the OpenAPI spec snapshot).

Access & Credentials

Credential method

No credentials required

Network & Permissions

Network destinations
api.llama.ficoins.llama.fistablecoins.llama.fiyields.llama.fi
Effects
Uses network access
Default permissions
Allowed by default

Implementation

WIT Interface0.3.0
Source Pathtools/defillama
Technical tags
WASM toolHTTP allowlistNo required secrets

Resources

Review implementation and setup instructions before installing.