Arb Capital API

REST API for the multi-vault DeFi yield aggregator.

Auth: If API_KEY is configured, include Authorization: Bearer <key> on all requests.
Rate limits: 60 req/min for D1 reads, 30 req/min for on-chain routes. Per-IP, per-route.
BigInt: Large numbers (TVL, balances, amounts) are serialized as strings to preserve precision.
Addresses: All on-chain addresses are stored and returned lowercase.

Vaults

GET/api/vaults30/min

On-chain data for all vaults on a given chain.

ParamTypeRequiredDescription
chainId1 | 8453YesEthereum (1) or Base (8453)

Response

{
  "0x5c1E...64bc": {
    "vaultId": "arbcap-usdt-core",
    "totalAssets": "1234567890",
    "totalSupply": "1234567890",
    "assetAddress": "0x...",
    "vaultDecimals": 6
  }
}
GET/api/vaults/metadata60/min

APY, utilization, and trend data for vaults.

Cache: 60s

ParamTypeRequiredDescription
vault_idstringNoFilter to a single vault

Response

[{
  "vault_id": "arbcap-usdt-core",
  "apy": 4.52,
  "apy_trend": "up",
  "utilization": 0.85,
  "updated_at": "2026-02-25T12:00:00"
}]
GET/api/vaults/allocations30/min

Per-strategy/market allocations for a vault with APYs.

MetaMorpho: APYs from Morpho GraphQL with on-chain IRM fallback. Euler: APYs from D1.

ParamTypeRequiredDescription
vault_idstringYesVault identifier

Response

{
  "allocations": [{
    "strategy": "0xabc...def",
    "name": "WBTC / USDT",
    "allocated": "500000000",
    "percentage": 45.23,
    "cap": "1000000000",
    "apy": 4.54
  }]
}
GET/api/vaults/snapshots60/min

Historical TVL snapshots for a vault.

Cache: 300s

ParamTypeRequiredDescription
vault_idstringYesVault identifier
daysnumberNoLookback period (default 30, 1–365)

Response

{
  "snapshots": [{
    "timestamp": "2026-02-20T00:00:00",
    "total_assets": "1234567890",
    "total_supply": "1234567890"
  }]
}
GET/api/vaults/apy-history60/min

Historical APY snapshots for a vault.

Cache: 300s

ParamTypeRequiredDescription
vault_idstringYesVault identifier
daysnumberNoLookback period (default 7, 1–90)

Response

{
  "snapshots": [{
    "timestamp": "2026-02-20T00:00:00",
    "apy": 4.52
  }]
}
GET/api/vaults/performance60/min

Aggregated performance stats over a time window.

Cache: 300s

ParamTypeRequiredDescription
vault_idstringYesVault identifier
daysnumberNoLookback period (default 30, 1–365)

Response

{
  "avg_apy": 7.83,
  "min_apy": 5.12,
  "max_apy": 11.04,
  "tvl_start": "1000000000",
  "tvl_end": "1125000000",
  "tvl_change_pct": 12.5
}
GET/api/vaults/strategy-history60/min

Historical TVL snapshots for a strategy.

Cache: 300s

ParamTypeRequiredDescription
strategystringYesStrategy contract address
daysnumberNoLookback period (default 30, 1–365)

Response

{
  "snapshots": [{
    "timestamp": "2026-02-20T00:00:00",
    "strategy_address": "0xabc...def",
    "total_assets": "1234567890",
    "total_supply": "1234567890"
  }]
}

User Positions

GET/api/vaults/position30/min

On-chain position data for a user in a vault.

ParamTypeRequiredDescription
chainId1 | 8453YesChain ID
vaultaddressYesVault contract address
assetaddressYesUnderlying asset address
useraddressYesUser wallet address

Response

{
  "assetBalance": "1000000",
  "allowance": "500000",
  "shareBalance": "980000",
  "maxWithdraw": "990000"
}
GET/api/vaults/preview-withdraw30/min

Preview shares required to withdraw a given asset amount.

ParamTypeRequiredDescription
chainId1 | 8453YesChain ID
vaultaddressYesVault contract address
amountstringYesAsset amount (BigInt as string)

Response

{
  "sharesRequired": "980000"
}
GET/api/vaults/position-snapshots60/min

Historical position value snapshots for a user.

ParamTypeRequiredDescription
userstringYesUser wallet address
vault_idstringYesVault identifier
daysnumberNoLookback period (default 30, 1–365)

Response

{
  "snapshots": [{
    "timestamp": "2026-02-20T00:00:00",
    "asset_value": "1050000"
  }]
}

Portfolio

GET/api/portfolio60/min

User portfolio summary across all vaults.

ParamTypeRequiredDescription
userstringYesUser wallet address

Response

{
  "total_value": "125000000",
  "vaults": [{
    "vault_id": "arbcap-usdt-core",
    "asset_value": "100000000",
    "share_balance": "98000000",
    "timestamp": "2026-02-25T12:00:00",
    "deposit_count": 3,
    "withdraw_count": 1
  }]
}

Transactions

GET/api/transactions60/min

Recent transactions for a user (max 100, newest first).

ParamTypeRequiredDescription
userstringYesUser wallet address
vault_idstringNoFilter to a specific vault

Response

[{
  "id": 1,
  "user_address": "0xabc...def",
  "vault_id": "arbcap-usdt-core",
  "chain_id": 1,
  "tx_hash": "0x123...789",
  "action": "deposit",
  "amount": "1000000",
  "shares": "980000",
  "timestamp": "2026-02-25T10:30:00"
}]
GET/api/transactions/summary60/min

Aggregated transaction volume stats.

Cache: 120s

ParamTypeRequiredDescription
vault_idstringNoFilter to a specific vault
daysnumberNoLookback period (default 30, 1–365)

Response

{
  "deposit_count": 47,
  "withdraw_count": 12,
  "total_deposited": "1250000000",
  "total_withdrawn": "320000000",
  "unique_users": 18
}

Strategies

GET/api/strategies60/min

All strategy APYs, ordered by APY descending.

Cache: 120s

Response

[{
  "strategy_address": "0xabc...def",
  "name": "WBTC / USDT",
  "apy": 4.54,
  "updated_at": "2026-02-25T12:00:00"
}]

Overview

GET/api/overview60/min

Protocol-wide aggregate stats.

Cache: 120s

Response

{
  "total_tvl": "5250000000",
  "vault_count": 3,
  "avg_apy": 7.2,
  "total_users": 42
}

RPC Proxy

POST/api/rpc30/min

Proxies JSON-RPC requests to Alchemy. Only whitelisted methods allowed.

Auth: Required — Bearer <WORKER_SECRET | API_KEY>

Allowed methods: eth_chainId, eth_call, eth_estimateGas, eth_getTransactionReceipt. Max body: 8KB. No batch requests.

ParamTypeRequiredDescription
chainId"1" | "8453"NoChain ID (default "1")

Response

Upstream Alchemy JSON-RPC response