{"uid":"cap_9rWhRDcz4sFtjFgrjxR_n","slug":"onesource-deepstate-order-book-api-3a771c23","name":"OneSource Deepstate Order Book API","description":"Two data families for AI agents: live Ethereum mainnet, Sepolia testnet, and Robinhood Chain RPC reads, plus Deepstate on-chain market data (order books, trades, candles, and analytics). Pay per call or use batch/session mode: USDC on Base via x402, or pathUSD/USDC.e on Tempo via MPP. No API key required to start; a flat-rate monthly subscription is also available.","url":"https://api.onesource.io/deepstate/v1/book/%7Bbook%7D","method":"GET","headers":{},"bodySchema":{"type":"object","properties":{"properties":{"type":"string"}}},"responseSchema":{"type":"json","example":{"asks":[{"side":"ask","size":32945.18,"maker":"0x7C3e9F1a5B2d4E68A091c3D5b7F20e846A1c9D3f","price":220.47924566,"order_id":"0x2ac5822b00000000000000000000000000000007abaf8d6000000000fffbb08b","size_raw":"32945180000","nonce_raw":4294684811,"price_raw":"220.47924566","rest_index":282484,"sequence_raw":"4294684811","is_bid_token0":true,"price_key_raw":"0x2ac5822b","queue_position":0,"rested_at_block":52685011}],"bids":[{"side":"bid","size":3263.516552,"maker":"0x884a1B2c3D4e5F60718293a4B5c6D7e8F90A1b2C","price":216.48219249,"order_id":"0x2ace848e00000000000000000000000000000000c2854f8800000000fffbb024","size_raw":"3263516552","nonce_raw":4294684708,"price_raw":"216.48219249","rest_index":282587,"sequence_raw":"4294684708","is_bid_token0":false,"price_key_raw":"0x2ace848e","queue_position":0,"rested_at_block":52685102}],"book_id":"0xdf941c235503a5d2e67aee5dea00f2965f99421c0d034bd77f924c05c66bf399","summary":{"book_id":"0xdf941c235503a5d2e67aee5dea00f2965f99421c0d034bd77f924c05c66bf399","mid_raw":"218.48071908","finality":"head","ask_count":208,"bid_count":45,"book_label":"NVDA/USDG","spread_bps":182.9476,"spread_raw":"3.99705317","order_count":253,"best_ask_raw":"220.47924566","best_bid_raw":"216.48219249","block_number":52685677,"top_ask_maker":"0x7C3e9F1a5B2d4E68A091c3D5b7F20e846A1c9D3f","top_bid_maker":"0x884a1B2c3D4e5F60718293a4B5c6D7e8F90A1b2C","market_session":"regular","top_ask_order_id":"0x2ac5822b00000000000000000000000000000007abaf8d6000000000fffbb08b","top_bid_order_id":"0x2ace848e00000000000000000000000000000000c2854f8800000000fffbb024","ask_depth_quote_raw":"6910233187","bid_depth_quote_raw":"1284770412","base_fee_per_gas_raw":"485000000","last_trade_price_raw":"216.48","ask_depth_1pct_quote_raw":"6910233187","bid_depth_1pct_quote_raw":"1284770412"},"finality":"head","book_slug":"NVDA-USDG","base_token":{"symbol":"NVDA","address":"0xd0601CE157Db5bdC3162BbaC2a2C8aF5320D9EEC","decimals":18},"block_hash":"0x9f2b1c0d4e7a5b83c61f0d2a4e8b7c95d3a1f6e08b2c4d7a9e5f31b0c8d2a4e6","book_label":"NVDA/USDG","quote_token":{"symbol":"USDG","address":"0x5fc5360D0400a0Fd4f2af552ADD042D716F1d168","decimals":6},"block_number":52685677,"market_session":"regular"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_POhEsY4UxT2m6yJohp3Nb","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Retrieves the full live on-chain order book (bids and asks) for a specified Deepstate market, including order details, depth summary, and market session info.","exampleAgentPrompt":"Pull the live Deepstate order book for NVDA/USDG — I want to see all current bids and asks, the spread, and the best bid and ask prices right now.","exampleUseCases":[{"title":"Live spread monitoring for arbitrage","prompt":"Check the current Deepstate order book for NVDA/USDG and tell me the best bid, best ask, and spread in basis points so I can evaluate an arbitrage opportunity."},{"title":"Order book depth for liquidity analysis","prompt":"Fetch the full Deepstate order book for the NVDA/USDG market and tell me how much liquidity is available within 1% of the mid price on both sides."},{"title":"Top-of-book price feed for AI trading agent","prompt":"What is the current mid price and top-of-book for the NVDA/USDG pair on Deepstate? I need the best bid and ask to calibrate my trading bot's limit orders."}],"resultDescription":"Returns a JSON object containing two arrays — bids and asks — each with individual order details (price, size, maker address, order ID, queue position, block rested), plus a summary object with best bid/ask, mid price, spread in bps, order count, market depth (quote value), last trade price, market session, block number, block hash, and base/quote token metadata.","failureModes":["Invalid or unknown book ID/slug returns a 404 or empty result","Stale data if queried at a block boundary — finality field indicates 'head' vs confirmed","Payment failure via x402 if USDC balance is insufficient — returns 402 Payment Required","Network or RPC lag may cause slightly outdated block data","Malformed book parameter returns a 400 Bad Request"],"whenToPreferThis":"Use this endpoint when you need real-time, full-depth on-chain order book data for a Deepstate market — including all resting bid and ask orders, spread, depth, and market session info. Prefer this over general blockchain RPC endpoints when the target is Deepstate market microstructure data rather than raw EVM state. Ideal for AI trading agents, arbitrage monitors, and DeFi analytics pipelines that need structured order book snapshots without parsing raw contract events.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T12:46:24.268Z","isFirstParty":false}