Skip to content
Docs

Chains

Include capabilities

Add include=capabilities to see which features each chain supports, including webhooks, before you call them.

Overview

GET/v1/chains?include=capabilities

The chain list tells you which chains you can use. Adding include=capabilities also tells you what works on each one, so you can show or hide features in your app, such as Send, NFTs, DeFi, Swap, or deposit alerts.

Query

FieldRequiredDescription
includeNocapabilities

Request

Request
curl -sS "https://blockchain.gray3.io/v1/chains?include=capabilities" \
  -H "X-Gray-Project-Id: proj_your_project_id" \
  -H "Authorization: Bearer gray_sk_your_secret"

Response

Each chain has the same fields as the plain list, plus a capabilities object.

HTTP 200 — success envelope wraps the payload in data.

json
{
  "data": {
    "items": [
      {
        "id": "ethereum",
        "name": "Ethereum",
        "family": "evm",
        "pathSlots": 2,
        "native": { "symbol": "ETH", "name": "Ether", "decimals": 18 },
        "explorer": { "url": "https://etherscan.io" },
        "capabilities": {
          "portfolio": { "status": "available", "code": 2 },
          "balance": { "status": "available", "code": 2 },
          "activity": { "status": "available", "code": 2 },
          "nfts": { "status": "available", "code": 2 },
          "defi": { "status": "available", "code": 2 },
          "swap": { "status": "available", "code": 2 },
          "transactions": { "status": "available", "code": 2 },
          "nativeTransfer": { "status": "available", "code": 2 },
          "tokenTransfer": { "status": "available", "code": 2 },
          "prices": { "status": "available", "code": 2 },
          "pricesMulti": { "status": "available", "code": 2 },
          "webhook": {
            "status": "available",
            "code": 2,
            "events": ["native_transfer", "token_transfer", "nft_transfer", "approval", "swap", "defi", "contract_interaction"],
            "confirmations": 6,
            "inPlan": true,
            "enabled": true
          }
        }
      }
    ]
  }
}

Status values

FieldRequiredDescription
unavailableNoRoute blocked for this chain on your plan or network type
partialNoSome operations work (e.g. portfolio without USD prices)
availableNoFeature is expected to work when other gates pass

Each capability also includes a numeric code for programmatic checks in SDKs.

Common capability keys

FieldRequiredDescription
portfolio / balanceNoBalances and token holdings
activityNoSingle-chain transaction history
nftsNoMainnet NFT list (see NFTs guide)
defiNoDeFi positions and action preparation (mainnet)
swapNoSwap and bridge quotes and route status (mainnet)
transactionsNoPrepare / simulate / broadcast / receipt
nativeTransfer / tokenTransferNoWhich send shapes prepare accepts
prices / pricesMultiNoUSD price quotes (mainnet)
transferMemoNoOptional memo/tag support and UI label for that chain
webhookNoAddress notifications: supported event types, confirmation depth, and whether they are on for this project

The webhook capability

webhook tells you whether Webhooks can watch addresses on the chain, which kinds of activity are reported, and whether your project will receive them right now.

FieldRequiredDescription
status / codeYesavailable (2) when Gray3 can watch this chain, otherwise unavailable (0).
eventsYesEvent types sent on this chain: native_transfer, token_transfer, nft_transfer, approval, swap, defi, contract_interaction. Empty when unavailable.
confirmationsNoBlocks before the confirmed message is sent. Only on available chains.
inPlanYesYour plan includes webhooks.
enabledYesMessages will be sent for this chain now: webhooks are in the plan, the chain is usable, the project's webhook is active, and the chain is one of its networks.

A chain can be available but not enabled, for example on a plan without webhooks or when the chain is not one of the webhook's networks. Use status to decide whether to offer the feature and enabled to show whether it is on.

Errors

Errors use HTTP { "error": { "code", "message", "retryable" } }. Branch on code, not the message text.

CodeHTTPWhen
unauthorized401Missing project credentials
revoked_secret401Secret revoked
json
{
  "error": {
    "code": "unauthorized",
    "message": "Human-readable detail (may be sanitized).",
    "retryable": false
  }
}