{
  "openapi": "3.1.0",
  "info": {
    "title": "RagRadar \u2014 Multi-Chain Intelligence",
    "version": "10.4.0",
    "description": "AI-powered on-chain analytics across Base, Arbitrum, Solana, Ethereum, Optimism, Polygon. 66 REST endpoints covering wallet analytics, Portfolio P&L tracker, DeFi yields, token safety, smart money tracking, whale alerts, sniper detection, GMX perps, Solana degen tools, protocol stats, gas tracking, token approvals, multi-chain balance, DEX aggregator quotes, arbitrage scanning, NFT analytics (powered by Alchemy), and Solana NFT analytics (powered by Magic Eden).",
    "x-guidance": "RagRadar: 66 paid REST endpoints across Base, Arbitrum, Solana, Ethereum, Optimism, Polygon. Covers wallet analytics, Portfolio P&L tracker (realized + unrealized, cost basis, win/loss), DeFi yields, token safety, sniper tracking, smart money, whale alerts, protocol stats, intelligence, GMX perps, Solana degen tools, social signals, gas tracker, approvals scanner, multi-chain balance, DEX aggregator quotes, arbitrage scanning, NFT analytics (floor price, collections, sales, ownership), and Solana NFT analytics (Magic Eden data). Pay USDC via x402 protocol on Base or Solana.",
    "contact": {
      "name": "RagRadar",
      "url": "https://ragradar.vercel.app",
      "email": "ragradar@gmail.com",
      "x-twitter": "@0xragna"
    }
  },
  "servers": [
    {
      "url": "https://ragradar.vercel.app",
      "description": "Production (Vercel)"
    }
  ],
  "paths": {
    "/api/portfolio/{chain}/{address}": {
      "get": {
        "operationId": "getPortfolio",
        "summary": "Wallet Portfolio \u2014 token balances on any chain",
        "description": "Get native + ERC-20 token balances for any wallet. Supports: base, arbitrum, polygon, avalanche, celo.",
        "tags": [
          "Wallet Analytics"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.005000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "base",
                "arbitrum",
                "polygon",
                "avalanche",
                "celo"
              ]
            },
            "description": "Chain identifier"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "EVM wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Wallet portfolio with token balances",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/history/{chain}/{address}": {
      "get": {
        "operationId": "getTxHistory",
        "summary": "Transaction History \u2014 recent wallet activity",
        "description": "Get recent transaction history for a wallet. Supports Blockscout chains: base, arbitrum, celo.",
        "tags": [
          "Wallet Analytics"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "base",
                "arbitrum",
                "celo"
              ]
            },
            "description": "Chain identifier (must have Blockscout)"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "EVM wallet address (0x...)"
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "default": 20,
              "maximum": 100
            },
            "description": "Number of transactions to return"
          }
        ],
        "responses": {
          "200": {
            "description": "Transaction history",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/summary/{chain}/{address}": {
      "get": {
        "operationId": "getWalletSummary",
        "summary": "Wallet Summary \u2014 full analytics package",
        "description": "Complete wallet analytics: portfolio, history, activity stats. Supports Blockscout chains: base, arbitrum, celo.",
        "tags": [
          "Wallet Analytics"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "base",
                "arbitrum",
                "celo"
              ]
            },
            "description": "Chain identifier"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "EVM wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Full wallet summary",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/token-safety/{chain}/{address}": {
      "get": {
        "operationId": "checkTokenSafety",
        "summary": "Token Safety \u2014 rug risk analysis",
        "description": "Token safety analysis using GoPlus Security data. Honeypot check, holder analysis, tax info. Supports all chains: base, arbitrum, polygon, avalanche, celo.",
        "tags": [
          "Safety"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "base",
                "arbitrum",
                "polygon",
                "avalanche",
                "celo"
              ]
            },
            "description": "Chain identifier"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Token contract address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Token safety analysis",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/yields": {
      "get": {
        "operationId": "getDefiYields",
        "summary": "DeFi Yields \u2014 all Base yield opportunities",
        "description": "Real-time DeFi yields from DeFiLlama (1,700+ pools on Base). Sorted by APY.",
        "tags": [
          "DeFi Yields"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "DeFi yield data",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/yields/best/{asset}": {
      "get": {
        "operationId": "getBestYield",
        "summary": "Best Yield \u2014 top yield for a specific asset",
        "description": "Find the best yield for USDC, ETH, or other assets across all Base DeFi protocols.",
        "tags": [
          "DeFi Yields"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "asset",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Asset symbol (e.g. USDC, ETH)"
          }
        ],
        "responses": {
          "200": {
            "description": "Best yield for asset",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/yields/risk": {
      "get": {
        "operationId": "getYieldsByRisk",
        "summary": "Yields by Risk \u2014 yields categorized by risk level",
        "description": "DeFi yields categorized by risk level (low/medium/high).",
        "tags": [
          "DeFi Yields"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Yields by risk category",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/yields/rebalance": {
      "get": {
        "operationId": "getRebalanceRecommendation",
        "summary": "Rebalance Recommendation \u2014 compare current vs best yield",
        "description": "Compare your current yield vs best available. Suggests rebalancing options.",
        "tags": [
          "DeFi Yields"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.050000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "protocol",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Current protocol name"
          },
          {
            "name": "apy",
            "in": "query",
            "required": true,
            "schema": {
              "type": "number"
            },
            "description": "Current APY (e.g. 3.5)"
          }
        ],
        "responses": {
          "200": {
            "description": "Rebalance recommendation",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/wallet-risk/{address}": {
      "get": {
        "operationId": "checkWalletRisk",
        "summary": "Wallet Risk \u2014 age, activity, scam detection",
        "description": "Wallet risk scoring \u2014 age, activity patterns, scam interaction, bot detection.",
        "tags": [
          "Safety"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.030000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Wallet risk analysis",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/sniper/token/{address}": {
      "get": {
        "operationId": "findTokenSnipers",
        "summary": "Token Snipers \u2014 early buyers of a token",
        "description": "Find wallets that bought early on a token. Shows position, ROI, still-holding status.",
        "tags": [
          "Sniper Tracker"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Token contract address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Token snipers data",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/sniper/wallet/{address}": {
      "get": {
        "operationId": "getWalletSniperRecord",
        "summary": "Wallet Sniper Record \u2014 track record for a wallet",
        "description": "Sniper track record for a wallet \u2014 score, success rate, tokens traded.",
        "tags": [
          "Sniper Tracker"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Wallet sniper record",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/sniper/trending": {
      "get": {
        "operationId": "getTrendingSnipers",
        "summary": "Trending Snipers \u2014 top snipers from trending tokens",
        "description": "Top snipers from trending tokens on Base \u2014 wallets that buy early on multiple tokens.",
        "tags": [
          "Sniper Tracker"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Trending snipers",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/smart-money/wallet/{address}": {
      "get": {
        "operationId": "analyzeSmartMoneyWallet",
        "summary": "Smart Money Wallet \u2014 analysis for a wallet",
        "description": "Smart money analysis for a wallet \u2014 score, classification, trading patterns.",
        "tags": [
          "Smart Money"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Smart money analysis",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/smart-money/token/{address}": {
      "get": {
        "operationId": "findSmartMoneyBuyers",
        "summary": "Smart Money Token \u2014 find smart money buyers",
        "description": "Find smart money buyers of a token \u2014 who's buying, are they still holding.",
        "tags": [
          "Smart Money"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Token contract address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Smart money buyers",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/smart-money/activity": {
      "get": {
        "operationId": "getSmartMoneyActivity",
        "summary": "Smart Money Activity \u2014 what smart money is buying",
        "description": "What smart money wallets are buying right now on Base.",
        "tags": [
          "Smart Money"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Smart money activity",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/whale/alerts": {
      "get": {
        "operationId": "getWhaleAlerts",
        "summary": "Whale Alerts \u2014 large transfers",
        "description": "Recent whale alerts \u2014 large transfers from known whale wallets.",
        "tags": [
          "Whale Alerts"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Whale alerts",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/whale/alerts/{token}": {
      "get": {
        "operationId": "getTokenWhaleActivity",
        "summary": "Token Whale Activity \u2014 holder concentration",
        "description": "Token whale activity \u2014 holder concentration, risk score.",
        "tags": [
          "Whale Alerts"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "token",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Token contract address"
          }
        ],
        "responses": {
          "200": {
            "description": "Token whale activity",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/whale/movements": {
      "get": {
        "operationId": "getWhaleMovements",
        "summary": "Whale Movements \u2014 cross-token activity",
        "description": "Cross-token whale activity \u2014 volume, buy/sell ratio.",
        "tags": [
          "Whale Alerts"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Whale movements",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/whale/heatmap": {
      "get": {
        "operationId": "getWhaleHeatmap",
        "summary": "Whale Heatmap \u2014 tokens ranked by whale activity",
        "description": "Whale heatmap \u2014 tokens ranked by whale activity score.",
        "tags": [
          "Whale Alerts"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Whale heatmap",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/whale/accumulation": {
      "get": {
        "operationId": "getAccumulationSignals",
        "summary": "Accumulation Signals \u2014 tokens being accumulated",
        "description": "Accumulation signals \u2014 tokens being accumulated by large buyers.",
        "tags": [
          "Whale Alerts"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Accumulation signals",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/intelligence/token/{address}": {
      "get": {
        "operationId": "getTokenIntelligence",
        "summary": "Token Intelligence \u2014 complete token analysis",
        "description": "Complete token intelligence \u2014 safety + whale + smart money + snipers combined.",
        "tags": [
          "Intelligence"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.050000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Token contract address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Token intelligence",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/intelligence/wallet/{address}": {
      "get": {
        "operationId": "getWalletIntelligence",
        "summary": "Wallet Intelligence \u2014 complete wallet analysis",
        "description": "Complete wallet intelligence \u2014 portfolio + smart money + sniper + risk combined.",
        "tags": [
          "Intelligence"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.050000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Wallet intelligence",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/market/pulse": {
      "get": {
        "operationId": "getMarketPulse",
        "summary": "Market Pulse \u2014 real-time market overview",
        "description": "Real-time market pulse \u2014 whale picks + smart money activity + top movers + yields.",
        "tags": [
          "Intelligence"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.050000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Market pulse",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/defi/dashboard": {
      "get": {
        "operationId": "getDefiDashboard",
        "summary": "DeFi Dashboard \u2014 yields + protocols + TVL",
        "description": "DeFi dashboard \u2014 yields + protocols + TVL + movers combined.",
        "tags": [
          "Intelligence"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.030000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "DeFi dashboard",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/risk/{address}": {
      "get": {
        "operationId": "getRiskAssessment",
        "summary": "Risk Assessment \u2014 token safety + whale + signals",
        "description": "Risk assessment \u2014 token safety + whale concentration + smart money signal.",
        "tags": [
          "Intelligence"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.030000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "Token contract address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Risk assessment",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/arbitrum/gmx/stats": {
      "get": {
        "operationId": "getGmxStats",
        "summary": "GMX Stats \u2014 TVL, volume, fees on Arbitrum",
        "description": "GMX V2 stats \u2014 TVL $152M+, 127 tokens, protocol data. Arbitrum-specific.",
        "tags": [
          "GMX Perps"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "GMX stats",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/arbitrum/gmx/funding": {
      "get": {
        "operationId": "getGmxFundingRates",
        "summary": "GMX Funding Rates \u2014 yield pools",
        "description": "GMX yield pools \u2014 20+ pools with APY, TVL data. Arbitrum-specific.",
        "tags": [
          "GMX Perps"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "GMX funding rates",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/arbitrum/gmx/glp": {
      "get": {
        "operationId": "getGlpYield",
        "summary": "GLP Yield \u2014 GMX/GLP staking yields",
        "description": "GLP and GMX staking yield data. Arbitrum-specific.",
        "tags": [
          "GMX Perps"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "GLP yield data",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/arbitrum/gmx/liquidations": {
      "get": {
        "operationId": "getGmxLiquidations",
        "summary": "GMX Liquidations \u2014 liquidation feed",
        "description": "Recent GMX liquidations feed. Arbitrum-specific.",
        "tags": [
          "GMX Perps"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "GMX liquidations",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/solana/token-safety/{mint}": {
      "get": {
        "operationId": "checkSolanaTokenSafety",
        "summary": "Solana Token Safety \u2014 rug check",
        "description": "Solana token safety analysis using GoPlus Security data. Honeypot, mint authority, freeze, holder analysis.",
        "tags": [
          "Solana"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "mint",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Solana token mint address"
          }
        ],
        "responses": {
          "200": {
            "description": "Token safety analysis",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/solana/snipers/{mint}": {
      "get": {
        "operationId": "findSolanaSnipers",
        "summary": "Solana Snipers \u2014 early buyers detection",
        "description": "Find early buyers (snipers) for a Solana token. Shows who bought in first 5 minutes.",
        "tags": [
          "Solana"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "mint",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Solana token mint address"
          }
        ],
        "responses": {
          "200": {
            "description": "Sniper data",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/solana/snipers/{mint}/score": {
      "get": {
        "operationId": "getSolanaSniperScore",
        "summary": "Solana Sniper Score \u2014 sniping activity",
        "description": "Sniper score for a Solana token (0-100). Higher = more sniping activity.",
        "tags": [
          "Solana"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "mint",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Solana token mint address"
          }
        ],
        "responses": {
          "200": {
            "description": "Sniper score",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/solana/trending": {
      "get": {
        "operationId": "getSolanaTrending",
        "summary": "Solana Trending \u2014 top tokens by activity",
        "description": "Trending Solana pools \u2014 top tokens by activity on Solana DEXes.",
        "tags": [
          "Solana"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Trending pools",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/solana/new-tokens": {
      "get": {
        "operationId": "getSolanaNewTokens",
        "summary": "Solana New Tokens \u2014 degen alpha signal",
        "description": "New Solana tokens \u2014 recently created pools (degen alpha signal).",
        "tags": [
          "Solana"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "New tokens",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/solana/top-volume": {
      "get": {
        "operationId": "getSolanaTopVolume",
        "summary": "Solana Top Volume \u2014 highest volume pools",
        "description": "Top Solana pools by 24h volume.",
        "tags": [
          "Solana"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Top volume pools",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/social/token/{chain}/{address}": {
      "get": {
        "operationId": "getTokenSocial",
        "summary": "Token social presence \u2014 aggregated from DexScreener + GeckoTerminal",
        "tags": [
          "Social Signals"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.030000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Blockchain (base, arbitrum, solana)"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Token contract address"
          }
        ],
        "responses": {
          "200": {
            "description": "Social data with links, trust score, market data"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/social/trending": {
      "get": {
        "operationId": "getSocialTrending",
        "summary": "Trending tokens with social data \u2014 volume, links, trust score",
        "tags": [
          "Social Signals"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "query",
            "schema": {
              "type": "string",
              "default": "base"
            },
            "description": "Chain name"
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "default": 20
            },
            "description": "Max results (1-50)"
          }
        ],
        "responses": {
          "200": {
            "description": "Trending pools with social enrichment"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/social/farcaster/crypto": {
      "get": {
        "operationId": "getFarcasterCrypto",
        "summary": "Farcaster crypto signals \u2014 top casts, channels, engagement",
        "tags": [
          "Social Signals"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "default": 20
            },
            "description": "Max casts to return"
          }
        ],
        "responses": {
          "200": {
            "description": "Crypto Farcaster data with engagement metrics"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/social/kol/activity": {
      "get": {
        "operationId": "getKolActivity",
        "summary": "KOL activity \u2014 what influencers are buying, cluster signals",
        "tags": [
          "Social Signals"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.030000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "query",
            "schema": {
              "type": "string",
              "default": "sol"
            },
            "description": "Chain (sol, base, eth, bsc)"
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "default": 20
            },
            "description": "Max trades"
          }
        ],
        "responses": {
          "200": {
            "description": "KOL trades with cluster detection"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/social/sentiment/{keyword}": {
      "get": {
        "operationId": "getSocialSentiment",
        "summary": "Multi-source social sentiment \u2014 Farcaster, GeckoTerminal, DexScreener",
        "tags": [
          "Social Signals"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.030000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "keyword",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Search keyword (token name, ticker, or topic)"
          }
        ],
        "responses": {
          "200": {
            "description": "Sentiment score with multi-platform signals"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/protocols/base": {
      "get": {
        "operationId": "getBaseProtocols",
        "summary": "Base protocol stats \u2014 TVL, categories, top protocols",
        "tags": [
          "Protocol Stats"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [],
        "responses": {
          "200": {
            "description": "Protocol data from DeFiLlama"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/protocols/base/tvl": {
      "get": {
        "operationId": "getBaseTvl",
        "summary": "Base chain TVL history \u2014 30 day trend",
        "tags": [
          "Protocol Stats"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [],
        "responses": {
          "200": {
            "description": "TVL history data"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/protocols/base/movers": {
      "get": {
        "operationId": "getBaseMovers",
        "summary": "Top gainers and losers on Base by TVL change",
        "tags": [
          "Protocol Stats"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [],
        "responses": {
          "200": {
            "description": "Top movers data"
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/gas": {
      "get": {
        "operationId": "getGasPrices",
        "summary": "Gas Tracker \u2014 real-time gas prices across all chains",
        "description": "Get current gas prices on Base, Ethereum, Arbitrum, Optimism, Polygon, and Solana. Returns gasPrice, maxFeePerGas, maxPriorityFeePerGas in gwei (EVM) or microLamports (Solana).",
        "tags": [
          "Gas Tracker"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.001000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [],
        "responses": {
          "200": {
            "description": "Gas prices for all supported chains",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/gas/{chain}": {
      "get": {
        "operationId": "getGasForChain",
        "summary": "Gas Price \u2014 single chain",
        "description": "Get gas price for a specific chain. Supported: base, ethereum, arbitrum, optimism, polygon, solana.",
        "tags": [
          "Gas Tracker"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.001000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "base",
                "ethereum",
                "arbitrum",
                "optimism",
                "polygon",
                "solana"
              ]
            },
            "description": "Chain name"
          }
        ],
        "responses": {
          "200": {
            "description": "Gas price for specified chain",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/approvals/{chain}/{address}": {
      "get": {
        "operationId": "scanApprovals",
        "summary": "Token Approvals Scanner \u2014 detect unlimited approvals",
        "description": "Scan a wallet's token approvals. Detects unlimited approvals, maps known spenders (Uniswap, 1inch, Aerodrome, Morpho), and provides revoke recommendations via revoke.cash. Supports: base, ethereum, arbitrum.",
        "tags": [
          "Security"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "base",
                "ethereum",
                "arbitrum"
              ]
            },
            "description": "Chain identifier"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "EVM wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Token approvals scan results with risk assessment",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/balance/{address}": {
      "get": {
        "operationId": "getMultichainBalance",
        "summary": "Multi-chain Balance \u2014 all chains in one call",
        "description": "Get native + stablecoin (USDC, USDT, DAI) balance across 5 chains (Ethereum, Base, Arbitrum, Optimism, Polygon) in a single call. Returns total stablecoin value.",
        "tags": [
          "Wallet Analytics"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.010000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "EVM wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "Multi-chain balance with native + stablecoins",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/pnl/{chain}/{address}": {
      "get": {
        "operationId": "getPortfolioPnL",
        "summary": "Portfolio P&L Tracker — realized + unrealized profit/loss",
        "description": "Full portfolio P&L analysis for any wallet. Tracks cost basis (average cost method), realized P&L from closed positions, unrealized P&L from open positions using real-time GeckoTerminal prices. Includes win/loss ratio, best/worst trades, and per-token breakdown. Supports Base, Arbitrum, Celo (Blockscout chains).",
        "tags": [
          "P&L Tracker"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.050000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": ["base", "arbitrum", "celo"]
            },
            "description": "Chain identifier (must have Blockscout)"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "EVM wallet address (0x...)"
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "default": 100,
              "maximum": 200
            },
            "description": "Max token transfers to analyze"
          },
          {
            "name": "realized_only",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            },
            "description": "If true, skip unrealized P&L calculation (faster)"
          }
        ],
        "responses": {
          "200": {
            "description": "Full P&L breakdown with summary + per-token positions",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/pnl/{chain}/{address}/summary": {
      "get": {
        "operationId": "getPnLSummary",
        "summary": "P&L Summary — lightweight total P&L stats",
        "description": "Quick P&L summary for a wallet: total realized/unrealized P&L, win rate, best/worst trades. Faster than full P&L endpoint.",
        "tags": [
          "P&L Tracker"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.020000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": ["base", "arbitrum", "celo"]
            },
            "description": "Chain identifier"
          },
          {
            "name": "address",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^0x[a-fA-F0-9]{40}$"
            },
            "description": "EVM wallet address (0x...)"
          }
        ],
        "responses": {
          "200": {
            "description": "P&L summary",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required"
          }
        }
      }
    },
    "/api/quote/{chain}/{from}/{to}": {
      "get": {
        "operationId": "getDexQuote",
        "summary": "DEX Aggregator Quote — best swap route across DEXes",
        "description": "Compare swap quotes across Aerodrome, Uniswap V3/V4, SushiSwap, PancakeSwap, BaseSwap, Hydrex. Returns best route with alternatives, price impact, and pool liquidity. Uses real pool data from GeckoTerminal.",
        "tags": [
          "DEX Aggregator"
        ],
        "x-payment-info": {
          "price": {
            "mode": "fixed",
            "currency": "USD",
            "amount": "0.005000"
          },
          "protocols": [
            {
              "x402": {}
            }
          ]
        },
        "parameters": [
          {
            "name": "chain",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": ["base", "arbitrum", "ethereum", "polygon", "optimism", "avalanche", "bsc", "celo"]
            },
            "description": "Chain identifier"
          },
          {
            "name": "from",
            "in": "path",
            "required": true,
            "schema": { "type": "string" },
            "description": "Source token address (0x...) or 'native' for wrapped native token"
          },
          {
            "name": "to",
            "in": "path",
            "required": true,
            "schema": { "type": "string" },
            "description": "Destination token address (0x...)"
          },
          {
            "name": "amount",
            "in": "query",
            "schema": { "type": "number", "default": 1 },
            "description": "Amount of source token to swap"
          }
        ],
        "responses": {
          "200": {
            "description": "Best swap quote with alternatives",
            "content": {
              "application/json": {
                "schema": { "type": "object" }
              }
            }
          },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/quote/pools/{chain}/{from}/{to}": {
      "get": {
        "operationId": "getQuotePools",
        "summary": "Pool Discovery — all pools for a token pair",
        "description": "List all liquidity pools for a token pair across DEXes. Shows liquidity, 24h volume, fees, price changes.",
        "tags": ["DEX Aggregator"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.003000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "chain", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Chain identifier" },
          { "name": "from", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Token A address" },
          { "name": "to", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Token B address" }
        ],
        "responses": {
          "200": { "description": "Pool list with liquidity and volume data", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/quote/dexes/{chain}": {
      "get": {
        "operationId": "getSupportedDexes",
        "summary": "Supported DEXes — list of DEXes for a chain",
        "description": "Returns supported DEXes, their types, fee tiers, and native token address.",
        "tags": ["DEX Aggregator"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.001000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "chain", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Chain identifier" }
        ],
        "responses": {
          "200": { "description": "Supported DEXes list", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/arb/scan": {
      "get": {
        "operationId": "scanArbitrage",
        "summary": "Arbitrage Scanner — cross-DEX price differences",
        "description": "Scan all token pairs for arbitrage opportunities across DEXes on Base.",
        "tags": ["Arbitrage"],
        "security": [],
        "parameters": [
          { "name": "amount", "in": "query", "schema": { "type": "integer", "default": 1000 }, "description": "Trade amount in USD" }
        ],
        "responses": {
          "200": { "description": "Arbitrage opportunities", "content": { "application/json": { "schema": { "type": "object" } } } }
        }
      }
    },
    "/api/arb/pair/{from}/{to}": {
      "get": {
        "operationId": "scanArbitragePair",
        "summary": "Arbitrage Pair — price diff for specific pair",
        "description": "Check arbitrage opportunity between two specific tokens.",
        "tags": ["Arbitrage"],
        "security": [],
        "parameters": [
          { "name": "from", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Source token symbol" },
          { "name": "to", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Target token symbol" },
          { "name": "amount", "in": "query", "schema": { "type": "integer", "default": 1000 }, "description": "Trade amount in USD" }
        ],
        "responses": {
          "200": { "description": "Arbitrage result", "content": { "application/json": { "schema": { "type": "object" } } } }
        }
      }
    },
    "/api/arb/tokens": {
      "get": {
        "operationId": "getArbTokens",
        "summary": "Supported Arb Tokens — tokens and DEXes for arbitrage",
        "description": "List supported tokens and DEXes for arbitrage scanning.",
        "tags": ["Arbitrage"],
        "security": [],
        "responses": {
          "200": { "description": "Supported tokens and DEXes", "content": { "application/json": { "schema": { "type": "object" } } } }
        }
      }
    },
    "/api/nft/portfolio/{address}": {
      "get": {
        "operationId": "getNFTPortfolio",
        "summary": "NFT Portfolio — all NFTs owned by a wallet",
        "description": "Get all NFTs owned by a wallet address with metadata, images, collection info. Supports Base + Ethereum chains.",
        "tags": ["NFT Analytics"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.500000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "address", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Wallet address" },
          { "name": "chain", "in": "query", "schema": { "type": "string", "enum": ["base", "eth"], "default": "base" }, "description": "Blockchain network" },
          { "name": "limit", "in": "query", "schema": { "type": "integer", "default": 50 }, "description": "Max NFTs to return (1-100)" },
          { "name": "pageKey", "in": "query", "schema": { "type": "string" }, "description": "Pagination cursor" }
        ],
        "responses": {
          "200": { "description": "NFT portfolio with metadata", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/collection/{chain}/{contract}": {
      "get": {
        "operationId": "getCollectionInfo",
        "summary": "Collection Info — metadata + floor price",
        "description": "Get collection metadata including name, symbol, total supply, OpenSea data, social links, and floor price.",
        "tags": ["NFT Analytics"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.250000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "chain", "in": "path", "required": true, "schema": { "type": "string", "enum": ["base", "eth"] }, "description": "Blockchain network" },
          { "name": "contract", "in": "path", "required": true, "schema": { "type": "string" }, "description": "NFT contract address" }
        ],
        "responses": {
          "200": { "description": "Collection metadata", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/floor/{chain}/{contract}": {
      "get": {
        "operationId": "getFloorPrice",
        "summary": "Floor Price — OpenSea + LooksRare",
        "description": "Get floor price for a collection from OpenSea and LooksRare marketplaces.",
        "tags": ["NFT Analytics"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.200000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "chain", "in": "path", "required": true, "schema": { "type": "string", "enum": ["base", "eth"] }, "description": "Blockchain network" },
          { "name": "contract", "in": "path", "required": true, "schema": { "type": "string" }, "description": "NFT contract address" }
        ],
        "responses": {
          "200": { "description": "Floor price data", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/sales/{chain}/{contract}": {
      "get": {
        "operationId": "getNFTSales",
        "summary": "NFT Sales — recent transactions",
        "description": "Get recent NFT sales for a collection including marketplace, tokenId, buyer, seller, price, and tx hash.",
        "tags": ["NFT Analytics"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.500000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "chain", "in": "path", "required": true, "schema": { "type": "string", "enum": ["base", "eth"] }, "description": "Blockchain network" },
          { "name": "contract", "in": "path", "required": true, "schema": { "type": "string" }, "description": "NFT contract address" },
          { "name": "limit", "in": "query", "schema": { "type": "integer", "default": 20 }, "description": "Max sales to return (1-100)" },
          { "name": "fromBlock", "in": "query", "schema": { "type": "string" }, "description": "Start block number" },
          { "name": "toBlock", "in": "query", "schema": { "type": "string" }, "description": "End block number" }
        ],
        "responses": {
          "200": { "description": "Recent NFT sales", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/owners/{chain}/{contract}/{tokenId}": {
      "get": {
        "operationId": "getNFTOwners",
        "summary": "NFT Owners — wallets holding a specific NFT",
        "description": "Get list of wallets that own a specific NFT token.",
        "tags": ["NFT Analytics"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.250000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "chain", "in": "path", "required": true, "schema": { "type": "string", "enum": ["base", "eth"] }, "description": "Blockchain network" },
          { "name": "contract", "in": "path", "required": true, "schema": { "type": "string" }, "description": "NFT contract address" },
          { "name": "tokenId", "in": "path", "required": true, "schema": { "type": "string" }, "description": "NFT token ID" }
        ],
        "responses": {
          "200": { "description": "NFT owners list", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/solana/collection/{symbol}": {
      "get": {
        "operationId": "getSolanaCollectionStats",
        "summary": "Solana Collection Stats — floor price + volume",
        "description": "Get Solana collection stats from Magic Eden including floor price, volume, listed count.",
        "tags": ["Solana NFT"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.250000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "symbol", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Collection symbol (e.g. degods, okaybears)" }
        ],
        "responses": {
          "200": { "description": "Collection stats", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/solana/portfolio/{wallet}": {
      "get": {
        "operationId": "getSolanaNFTPortfolio",
        "summary": "Solana NFT Portfolio — wallet holdings",
        "description": "Get all Solana NFTs owned by a wallet address with metadata, images, collection info.",
        "tags": ["Solana NFT"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.500000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "wallet", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Solana wallet address" },
          { "name": "limit", "in": "query", "schema": { "type": "integer", "default": 20 }, "description": "Max NFTs to return (1-100)" },
          { "name": "offset", "in": "query", "schema": { "type": "integer", "default": 0 }, "description": "Pagination offset" }
        ],
        "responses": {
          "200": { "description": "Solana NFT portfolio", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/solana/token/{mint}": {
      "get": {
        "operationId": "getSolanaTokenMetadata",
        "summary": "Solana Token Metadata — full NFT info",
        "description": "Get Solana NFT token metadata including name, image, attributes, price, collection info.",
        "tags": ["Solana NFT"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.200000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "mint", "in": "path", "required": true, "schema": { "type": "string" }, "description": "NFT mint address" }
        ],
        "responses": {
          "200": { "description": "Token metadata", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/nft/solana/activities/{collection}": {
      "get": {
        "operationId": "getSolanaCollectionActivities",
        "summary": "Solana Collection Activities — sales/bids/listings",
        "description": "Get recent Solana collection activities from Magic Eden including sales, bids, and listings.",
        "tags": ["Solana NFT"],
        "x-payment-info": {
          "price": { "mode": "fixed", "currency": "USD", "amount": "0.500000" },
          "protocols": [{ "x402": {} }]
        },
        "parameters": [
          { "name": "collection", "in": "path", "required": true, "schema": { "type": "string" }, "description": "Collection symbol" },
          { "name": "limit", "in": "query", "schema": { "type": "integer", "default": 20 }, "description": "Max activities to return (1-100)" },
          { "name": "offset", "in": "query", "schema": { "type": "integer", "default": 0 }, "description": "Pagination offset" }
        ],
        "responses": {
          "200": { "description": "Collection activities", "content": { "application/json": { "schema": { "type": "object" } } } },
          "402": { "description": "Payment Required" }
        }
      }
    },
    "/api/protocols": {
      "get": {
        "operationId": "listProtocols",
        "summary": "API Index — all available endpoints",
        "description": "Free endpoint listing all available API routes organized by category.",
        "tags": ["Meta"],
        "security": [],
        "responses": {
          "200": { "description": "API endpoint listing", "content": { "application/json": { "schema": { "type": "object" } } } }
        }
      }
    },
    "/health": {
      "get": {
        "operationId": "healthCheck",
        "summary": "Health Check — server status",
        "description": "Free endpoint returning server status, version, supported networks.",
        "tags": ["Meta"],
        "security": [],
        "responses": {
          "200": { "description": "Health status", "content": { "application/json": { "schema": { "type": "object" } } } }
        }
      }
    }
  }
}