{"openapi":"3.1.0","info":{"title":"StockKit API","version":"1.0.0","description":"Research, quotes, portfolios and unsigned swap transactions for tokenized US stocks on Robinhood Chain. Pay-per-call via x402 (USDG on Robinhood Chain or USDC on Base), or free during the beta.","x-guidance":"StockKit is a read and execution API for tokenized US stocks on Robinhood Chain (EVM chain id 4663). Every stock token is an ERC-20 traded against USDG (Global Dollar, 6 decimals) on Uniswap v3.\n\nHow to use it:\n- GET /v1/x402/research/{symbol} for fundamentals (SEC EDGAR) plus the live token price. Use the ticker, e.g. NVDA.\n- GET /v1/x402/quote?symbol=NVDA&side=buy&amount=100&denom=usd for the executable price of a swap. amount is a decimal string; denom is usd (USDG) or token.\n- GET /v1/x402/portfolio/{address} for a wallet's stock token holdings priced in USD.\n- GET /v1/x402/history/{symbol}?interval=1h&limit=100 for OHLC candles of the on-chain DEX price (5m to 1d intervals; history accrues from 2026-09-16).\n- POST /v1/x402/trade/build with JSON {symbol, side, amount, denom?, recipient, slippageBps?} to get unsigned transactions (optional approval, then the swap). Sign and broadcast them from the recipient wallet yourself; StockKit is non-custodial and never executes trades.\n\nPayment: the /v1/x402/* routes are pay-per-call via x402 v2. Call without payment to get a 402 whose PAYMENT-REQUIRED header (base64 JSON) lists two accepted rails: USDG on Robinhood Chain (eip155:4663, exact scheme via Permit2) and USDC on Base (eip155:8453, exact scheme via EIP-3009). Retry with a signed PAYMENT-SIGNATURE header; the settlement receipt comes back in PAYMENT-RESPONSE. Prices are $0.01 per call, $0.02 for trade/build.\n\nThe same handlers are also open for free during the beta at /v1/research/{symbol}, /v1/quote, /v1/portfolio/{address}, /v1/history/{symbol} and /v1/trade/build, with identical inputs and outputs. Additional free routes: GET /v1/assets (all tickers), GET /v1/assets/{symbol}, GET /v1/prices/{symbol}, GET /v1/stats/{symbol} (supply, per-pool liquidity, DEX premium vs the equity quote, 24h change), GET /v1/corporate-actions, GET /v1/markets?venue=pons, GET /v1/votes (shareholder vote events for Stock Tokens; live automatically once Robinhood ships voting upstream), GET /v1/votes/power/{address} (a wallet's vote weight: token balance x multiplier = underlying share equivalent). Price alerts with webhook delivery: POST /v1/alerts with JSON {symbol, condition: above|below, price, webhookUrl} (evaluated every 5 minutes against the on-chain DEX price, fires once; the response includes a secret that manages the alert via GET/DELETE /v1/alerts/{id}). An MCP server with the same tools runs at /mcp. Full docs: https://docs.stockkit.dev","contact":{"name":"StockKit","email":"hello@stockkit.dev","url":"https://stockkit.dev"},"termsOfService":"https://stockkit.dev/terms"},"servers":[{"url":"https://api.stockkit.dev"}],"externalDocs":{"description":"StockKit documentation","url":"https://docs.stockkit.dev"},"tags":[{"name":"Research","description":"Fundamentals and prices"},{"name":"Execution","description":"Quotes and unsigned swap transactions"},{"name":"Portfolio","description":"Wallet holdings"}],"paths":{"/v1/x402/research/{symbol}":{"get":{"operationId":"x402Research","summary":"Research - Fundamentals and live price for a tokenized stock","description":"Company fundamentals from SEC EDGAR (revenue, net income, shares outstanding, market cap, registrant details) merged with the live Robinhood Chain token record and price. Fundamentals are null for tickers with no SEC registrant (ETFs, trusts).","tags":["Research"],"parameters":[{"name":"symbol","in":"path","required":true,"description":"Stock token ticker on Robinhood Chain (case-insensitive), e.g. NVDA, AAPL, TSLA. List all tickers with GET /v1/assets.","schema":{"type":"string","minLength":1,"maxLength":16},"example":"NVDA"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Research"}}}},"402":{"description":"Payment Required","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 PaymentRequired object listing the accepted payment options.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","description":"The same x402 v2 PaymentRequired object, as JSON for humans.","properties":{"x402Version":{"type":"integer","const":2},"error":{"type":"string"},"accepts":{"type":"array","items":{"type":"object"}},"resource":{"type":"object"}}}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]}}},"/v1/research/{symbol}":{"get":{"operationId":"freeResearch","summary":"Research - Fundamentals and live price for a tokenized stock (free beta)","description":"Company fundamentals from SEC EDGAR (revenue, net income, shares outstanding, market cap, registrant details) merged with the live Robinhood Chain token record and price. Fundamentals are null for tickers with no SEC registrant (ETFs, trusts). Free, ungated twin of /v1/x402/research/{symbol}; same inputs and outputs.","tags":["Research"],"parameters":[{"name":"symbol","in":"path","required":true,"description":"Stock token ticker on Robinhood Chain (case-insensitive), e.g. NVDA, AAPL, TSLA. List all tickers with GET /v1/assets.","schema":{"type":"string","minLength":1,"maxLength":16},"example":"NVDA"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Research"}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[]}},"/v1/x402/quote":{"get":{"operationId":"x402Quote","summary":"Quote - Best executable price for a tokenized stock swap","description":"Simulates a swap against the deepest Uniswap v3 TOKEN/USDG pool on Robinhood Chain and returns the executable amount, effective price and gas estimate. Read-only; nothing is executed.","tags":["Execution"],"parameters":[{"name":"symbol","in":"query","required":true,"description":"Stock token ticker, e.g. NVDA.","schema":{"type":"string","minLength":1,"maxLength":16},"example":"NVDA"},{"name":"side","in":"query","required":true,"description":"buy = spend USDG to receive the token; sell = spend the token to receive USDG.","schema":{"type":"string","enum":["buy","sell"]},"example":"buy"},{"name":"amount","in":"query","required":true,"description":"Trade size as a positive decimal string, in the unit given by denom.","schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Positive decimal number encoded as a string."},"example":"100"},{"name":"denom","in":"query","required":false,"description":"Unit of amount: usd (USDG) or token (the stock token). Defaults to usd.","schema":{"type":"string","enum":["usd","token"],"default":"usd"},"example":"usd"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Quote"}}}},"400":{"description":"Invalid parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Payment Required","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 PaymentRequired object listing the accepted payment options.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","description":"The same x402 v2 PaymentRequired object, as JSON for humans.","properties":{"x402Version":{"type":"integer","const":2},"error":{"type":"string"},"accepts":{"type":"array","items":{"type":"object"}},"resource":{"type":"object"}}}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"No executable route","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]}}},"/v1/quote":{"get":{"operationId":"freeQuote","summary":"Quote - Best executable price for a tokenized stock swap (free beta)","description":"Simulates a swap against the deepest Uniswap v3 TOKEN/USDG pool on Robinhood Chain and returns the executable amount, effective price and gas estimate. Read-only; nothing is executed. Free, ungated twin of /v1/x402/quote; same inputs and outputs.","tags":["Execution"],"parameters":[{"name":"symbol","in":"query","required":true,"description":"Stock token ticker, e.g. NVDA.","schema":{"type":"string","minLength":1,"maxLength":16},"example":"NVDA"},{"name":"side","in":"query","required":true,"description":"buy = spend USDG to receive the token; sell = spend the token to receive USDG.","schema":{"type":"string","enum":["buy","sell"]},"example":"buy"},{"name":"amount","in":"query","required":true,"description":"Trade size as a positive decimal string, in the unit given by denom.","schema":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Positive decimal number encoded as a string."},"example":"100"},{"name":"denom","in":"query","required":false,"description":"Unit of amount: usd (USDG) or token (the stock token). Defaults to usd.","schema":{"type":"string","enum":["usd","token"],"default":"usd"},"example":"usd"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Quote"}}}},"400":{"description":"Invalid parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"No executable route","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[]}},"/v1/x402/portfolio/{address}":{"get":{"operationId":"x402Portfolio","summary":"Portfolio - Tokenized stock holdings of a wallet, priced in USD","description":"Scans every Robinhood Chain stock token for the wallet's balance and prices each position with the live multiplier-adjusted mid price.","tags":["Portfolio"],"parameters":[{"name":"address","in":"path","required":true,"description":"Wallet address on Robinhood Chain (chain id 4663).","schema":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},"example":"0x0E74F4793a144b0eB9c15CDB959B1D8bcAA5c9Cf"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Portfolio"}}}},"400":{"description":"Invalid address","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Payment Required","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 PaymentRequired object listing the accepted payment options.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","description":"The same x402 v2 PaymentRequired object, as JSON for humans.","properties":{"x402Version":{"type":"integer","const":2},"error":{"type":"string"},"accepts":{"type":"array","items":{"type":"object"}},"resource":{"type":"object"}}}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]}}},"/v1/portfolio/{address}":{"get":{"operationId":"freePortfolio","summary":"Portfolio - Tokenized stock holdings of a wallet, priced in USD (free beta)","description":"Scans every Robinhood Chain stock token for the wallet's balance and prices each position with the live multiplier-adjusted mid price. Free, ungated twin of /v1/x402/portfolio/{address}; same inputs and outputs.","tags":["Portfolio"],"parameters":[{"name":"address","in":"path","required":true,"description":"Wallet address on Robinhood Chain (chain id 4663).","schema":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},"example":"0x0E74F4793a144b0eB9c15CDB959B1D8bcAA5c9Cf"}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Portfolio"}}}},"400":{"description":"Invalid address","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[]}},"/v1/x402/history/{symbol}":{"get":{"operationId":"x402History","summary":"History - OHLC price candles for a tokenized stock","description":"OHLC candles built from the on-chain DEX price (deepest Uniswap v3 TOKEN/USDG pool on Robinhood Chain, sampled every 5 minutes). Intervals from 5m to 1d. History accrues from 2026-09-16; historySince in the response marks the first sample for the symbol.","tags":["Research"],"parameters":[{"name":"symbol","in":"path","required":true,"description":"Stock token ticker on Robinhood Chain (case-insensitive), e.g. NVDA, AAPL, TSLA. List all tickers with GET /v1/assets.","schema":{"type":"string","minLength":1,"maxLength":16},"example":"NVDA"},{"name":"interval","in":"query","required":false,"description":"Candle interval. Defaults to 1h.","schema":{"type":"string","enum":["5m","15m","1h","4h","1d"],"default":"1h"},"example":"1h"},{"name":"limit","in":"query","required":false,"description":"Max candles to return, newest window. Defaults to 100.","schema":{"type":"integer","minimum":1,"maximum":300,"default":100},"example":100}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/History"}}}},"400":{"description":"Invalid parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Payment Required","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 PaymentRequired object listing the accepted payment options.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","description":"The same x402 v2 PaymentRequired object, as JSON for humans.","properties":{"x402Version":{"type":"integer","const":2},"error":{"type":"string"},"accepts":{"type":"array","items":{"type":"object"}},"resource":{"type":"object"}}}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]}}},"/v1/history/{symbol}":{"get":{"operationId":"freeHistory","summary":"History - OHLC price candles for a tokenized stock (free beta)","description":"OHLC candles built from the on-chain DEX price (deepest Uniswap v3 TOKEN/USDG pool on Robinhood Chain, sampled every 5 minutes). Intervals from 5m to 1d. History accrues from 2026-09-16; historySince in the response marks the first sample for the symbol. Free, ungated twin of /v1/x402/history/{symbol}; same inputs and outputs.","tags":["Research"],"parameters":[{"name":"symbol","in":"path","required":true,"description":"Stock token ticker on Robinhood Chain (case-insensitive), e.g. NVDA, AAPL, TSLA. List all tickers with GET /v1/assets.","schema":{"type":"string","minLength":1,"maxLength":16},"example":"NVDA"},{"name":"interval","in":"query","required":false,"description":"Candle interval. Defaults to 1h.","schema":{"type":"string","enum":["5m","15m","1h","4h","1d"],"default":"1h"},"example":"1h"},{"name":"limit","in":"query","required":false,"description":"Max candles to return, newest window. Defaults to 100.","schema":{"type":"integer","minimum":1,"maximum":300,"default":100},"example":100}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/History"}}}},"400":{"description":"Invalid parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[]}},"/v1/x402/trade/build":{"post":{"operationId":"x402TradeBuild","summary":"Trade build - Unsigned swap transactions for a tokenized stock","description":"Quotes the swap and returns ready-to-sign transaction steps (an ERC-20 approval when the router allowance is short, then the Uniswap v3 SwapRouter02 call) for the recipient wallet to sign and broadcast itself. StockKit never holds keys or executes trades.","tags":["Execution"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeBuildRequest"},"example":{"symbol":"NVDA","side":"buy","amount":"100","denom":"usd","recipient":"0x0E74F4793a144b0eB9c15CDB959B1D8bcAA5c9Cf","slippageBps":50}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeBuild"}}}},"400":{"description":"Invalid body","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Payment Required","headers":{"PAYMENT-REQUIRED":{"description":"Base64-encoded x402 v2 PaymentRequired object listing the accepted payment options.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"type":"object","description":"The same x402 v2 PaymentRequired object, as JSON for humans.","properties":{"x402Version":{"type":"integer","const":2},"error":{"type":"string"},"accepts":{"type":"array","items":{"type":"object"}},"resource":{"type":"object"}}}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"No executable route","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.02"},"protocols":[{"x402":{}}]}}},"/v1/trade/build":{"post":{"operationId":"freeTradeBuild","summary":"Trade build - Unsigned swap transactions for a tokenized stock (free beta)","description":"Quotes the swap and returns ready-to-sign transaction steps (an ERC-20 approval when the router allowance is short, then the Uniswap v3 SwapRouter02 call) for the recipient wallet to sign and broadcast itself. StockKit never holds keys or executes trades. Free, ungated twin of /v1/x402/trade/build; same inputs and outputs.","tags":["Execution"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeBuildRequest"},"example":{"symbol":"NVDA","side":"buy","amount":"100","denom":"usd","recipient":"0x0E74F4793a144b0eB9c15CDB959B1D8bcAA5c9Cf","slippageBps":50}}}},"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeBuild"}}}},"400":{"description":"Invalid body","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Unknown asset","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"No executable route","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"502":{"description":"Upstream data source unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"security":[]}}},"components":{"schemas":{"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string","enum":["bad_request","not_found","no_liquidity","upstream_error","internal_error"]},"message":{"type":"string"}},"required":["code","message"]}},"required":["error"]},"Fact":{"type":"object","description":"Latest reported XBRL fact from SEC EDGAR company facts.","properties":{"value":{"type":"number"},"unit":{"type":"string","examples":["USD","shares"]},"periodStart":{"oneOf":[{"type":"string","format":"date"},{"type":"null"}]},"periodEnd":{"type":"string","format":"date"},"fiscalYear":{"oneOf":[{"type":"integer"},{"type":"null"}]},"form":{"oneOf":[{"type":"string","examples":["10-K","20-F","10-Q"]},{"type":"null"}]}},"required":["value","unit","periodStart","periodEnd","fiscalYear","form"]},"Token":{"type":"object","description":"Robinhood Chain stock token record.","properties":{"symbol":{"type":"string"},"name":{"type":"string"},"address":{"oneOf":[{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},{"type":"null"}]},"chainId":{"type":"integer","const":4663},"decimals":{"type":"integer"},"multiplier":{"type":"string","description":"Corporate-action multiplier: one token represents this many underlying shares."},"pendingMultiplier":{"oneOf":[{"type":"string"},{"type":"null"}]},"status":{"type":"string"},"logoUrl":{"type":"string"},"tradingCapabilities":{},"isin":{"type":"string"},"price":{"oneOf":[{"type":"object","properties":{"underlyingMid":{"type":"string","description":"Mid of the underlying equity quote, USD."},"tokenMid":{"type":"string","description":"underlyingMid x multiplier: USD value of one token."},"currency":{"type":"string"},"asOf":{"type":"string","format":"date-time"}},"required":["underlyingMid","tokenMid","currency","asOf"]},{"type":"null"}]}},"required":["symbol","name","address","chainId","decimals","multiplier","status","isin","price"]},"Research":{"type":"object","properties":{"symbol":{"type":"string"},"underlying":{"oneOf":[{"type":"object","description":"SEC registrant behind the token. Null when no registrant matches the ticker.","properties":{"ticker":{"type":"string"},"companyName":{"type":"string"},"cik":{"type":"string","description":"10-digit zero-padded SEC CIK."},"exchange":{"oneOf":[{"type":"string"},{"type":"null"}]},"industry":{"oneOf":[{"type":"string","description":"SIC description."},{"type":"null"}]},"sic":{"oneOf":[{"type":"string"},{"type":"null"}]},"stateOfIncorporation":{"oneOf":[{"type":"string"},{"type":"null"}]},"fiscalYearEnd":{"oneOf":[{"type":"string","description":"MMDD."},{"type":"null"}]},"isin":{"type":"string"}},"required":["ticker","companyName","cik","exchange","industry","sic","stateOfIncorporation","fiscalYearEnd","isin"]},{"type":"null"}]},"facts":{"type":"object","properties":{"revenue":{"oneOf":[{"$ref":"#/components/schemas/Fact"},{"type":"null"}]},"netIncome":{"oneOf":[{"$ref":"#/components/schemas/Fact"},{"type":"null"}]},"sharesOutstanding":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"},"unit":{"type":"string","const":"shares"},"asOf":{"type":"string","format":"date"}},"required":["value","unit","asOf"]},{"type":"null"}]},"marketCap":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"},"unit":{"type":"string","const":"USD"},"basis":{"type":"string"}},"required":["value","unit","basis"]},{"type":"null"}]}},"required":["revenue","netIncome","sharesOutstanding","marketCap"]},"token":{"$ref":"#/components/schemas/Token"},"sources":{"type":"array","items":{"type":"string"}},"note":{"oneOf":[{"type":"string"},{"type":"null"}]}},"required":["symbol","underlying","facts","token","sources","note"]},"QuoteDetails":{"type":"object","properties":{"side":{"type":"string","enum":["buy","sell"]},"mode":{"type":"string","enum":["exactIn","exactOut"],"description":"Which leg was fixed by the request (usd-denominated buys and token-denominated sells are exactIn)."},"feeTier":{"type":"integer","description":"Uniswap v3 pool fee in hundredths of a bip (500 = 0.05%)."},"usdAmount":{"type":"string","description":"USDG leg of the swap, 6 decimals."},"tokenAmount":{"type":"string","description":"Stock token leg of the swap, in whole tokens."},"effectivePricePerToken":{"oneOf":[{"type":"string","description":"usdAmount / tokenAmount."},{"type":"null"}]},"gasEstimate":{"type":"string","description":"Estimated gas units for the swap call."},"venue":{"type":"string","const":"uniswap-v3"},"pair":{"type":"string","const":"TOKEN/USDG"}},"required":["side","mode","feeTier","usdAmount","tokenAmount","effectivePricePerToken","gasEstimate","venue","pair"]},"Quote":{"allOf":[{"$ref":"#/components/schemas/QuoteDetails"},{"type":"object","properties":{"symbol":{"type":"string"},"tokenAddress":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},"asOf":{"type":"string","format":"date-time"}},"required":["symbol","tokenAddress","asOf"]}]},"Position":{"type":"object","properties":{"symbol":{"type":"string"},"name":{"type":"string"},"address":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},"balance":{"type":"string","description":"Token balance in whole tokens."},"decimals":{"type":"integer"},"usdPrice":{"oneOf":[{"type":"string","description":"Multiplier-adjusted USD mid price per token."},{"type":"null"}]},"usdValue":{"oneOf":[{"type":"string"},{"type":"null"}]}},"required":["symbol","name","address","balance","decimals","usdPrice","usdValue"]},"Portfolio":{"type":"object","properties":{"address":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},"chainId":{"type":"integer","const":4663},"positions":{"type":"array","description":"Non-zero holdings, largest USD value first.","items":{"$ref":"#/components/schemas/Position"}},"totalUsdValue":{"type":"string"},"asOf":{"type":"string","format":"date-time"}},"required":["address","chainId","positions","totalUsdValue","asOf"]},"Candle":{"type":"object","properties":{"t":{"type":"string","format":"date-time","description":"Bucket open time (UTC)."},"open":{"type":"number"},"high":{"type":"number"},"low":{"type":"number"},"close":{"type":"number"},"ticks":{"type":"integer","description":"5-minute samples aggregated into this candle."}},"required":["t","open","high","low","close","ticks"]},"History":{"type":"object","properties":{"symbol":{"type":"string"},"interval":{"type":"string","enum":["5m","15m","1h","4h","1d"]},"source":{"type":"string"},"historySince":{"oneOf":[{"type":"string","format":"date-time","description":"First recorded sample for this symbol."},{"type":"null"}]},"candles":{"type":"array","items":{"$ref":"#/components/schemas/Candle"}}},"required":["symbol","interval","source","historySince","candles"]},"TradeBuildRequest":{"type":"object","properties":{"symbol":{"type":"string","minLength":1,"maxLength":16,"description":"Stock token ticker, e.g. NVDA."},"side":{"type":"string","enum":["buy","sell"],"description":"buy = spend USDG to receive the token; sell = spend the token to receive USDG."},"amount":{"type":"string","pattern":"^\\d+(\\.\\d+)?$","description":"Trade size as a positive decimal string, in the unit given by denom."},"denom":{"type":"string","enum":["usd","token"],"default":"usd","description":"Unit of amount: usd (USDG) or token (the stock token)."},"recipient":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"Wallet that signs and sends the returned transactions and receives the swap output."},"slippageBps":{"type":"integer","minimum":1,"maximum":5000,"default":50,"description":"Max slippage in basis points (50 = 0.5%)."}},"required":["symbol","side","amount","recipient"],"additionalProperties":false},"TransactionStep":{"type":"object","properties":{"description":{"type":"string"},"to":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},"data":{"type":"string","pattern":"^0x[0-9a-fA-F]*$","description":"ABI-encoded calldata."},"value":{"type":"string","description":"Native value to send, in wei. Always \"0\"."}},"required":["description","to","data","value"]},"TradeBuild":{"type":"object","properties":{"symbol":{"type":"string"},"tokenAddress":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"EVM address, 0x-prefixed, 20 bytes."},"chainId":{"type":"integer","const":4663},"quote":{"$ref":"#/components/schemas/QuoteDetails"},"slippageBps":{"type":"integer"},"deadline":{"type":"integer","description":"Unix seconds after which the swap reverts."},"steps":{"type":"array","description":"Sign and send in order from the recipient wallet on Robinhood Chain.","items":{"$ref":"#/components/schemas/TransactionStep"}},"note":{"type":"string"}},"required":["symbol","tokenAddress","chainId","quote","slippageBps","deadline","steps","note"]}}}}