{"openapi":"3.1.0","info":{"title":"Market Data (BYOK) API","version":"0.1.0","description":"Market Data (BYOK) lets an AI assistant read your own Market Data data through the Market Data API with a key you supply (API token). Read-only: 11 tools (get_stock_quotes, get_stock_prices, get_stock_candles, get_stock_earnings, get_stock_news, get_market_status, get_option_expirations, get_option_chain, get_option_quote, lookup_option_symbol, get_fund_candles). The BYOK key travels with each...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-marketdata.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-marketdata/docs"},"termsOfService":"https://connectorbay.com/byok-marketdata/terms"},"servers":[{"url":"https://byok-marketdata.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-marketdata/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/get_stock_quotes":{"post":{"operationId":"get_stock_quotes","summary":"Get delayed quotes (bid, ask, last, change, volume) for one or more US stocks or ETFs. Answers are column arrays: elemen","description":"Get delayed quotes (bid, ask, last, change, volume) for one or more US stocks or ETFs. Answers are column arrays: element N of every array belongs to symbol N. 1 plan credit per symbol. Use for \"What are the latest quotes for AAPL, META and MSFT\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"symbols":{"description":"Comma-separated ticker symbols, for example 'AAPL,META,MSFT' (up to about 500 per request).","maxLength":2000,"title":"Symbols","type":"string"},"week52":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":false,"description":"True to also return 52-week high and low.","title":"Week52"},"extended":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"False to ignore extended-hours trades (default true).","title":"Extended"}},"required":["symbols"],"title":"get_stock_quotesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_stock_prices":{"post":{"operationId":"get_stock_prices","summary":"Get real-time midpoint prices (SmartMid model) with day change for one or more stocks. Column arrays, one element per sy","description":"Get real-time midpoint prices (SmartMid model) with day change for one or more stocks. Column arrays, one element per symbol. 1 plan credit per symbol. Use for \"What is the real-time mid price of MSFT and NVDA\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"symbols":{"description":"Comma-separated ticker symbols, for example 'MSFT,NVDA'.","maxLength":2000,"title":"Symbols","type":"string"},"extended":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"False to ignore extended-hours trades (default true).","title":"Extended"}},"required":["symbols"],"title":"get_stock_pricesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_stock_candles":{"post":{"operationId":"get_stock_candles","summary":"Get historical OHLCV candles for a stock or ETF at a chosen resolution (minutes, hours, days, weeks, months). Column arr","description":"Get historical OHLCV candles for a stock or ETF at a chosen resolution (minutes, hours, days, weeks, months). Column arrays: t (unix time), o, h, l, c, v. Intraday requests may span at most one year. Use for \"Show daily AAPL candles for January 2024\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"resolution":{"description":"Candle size: 'D' daily, 'W' weekly, 'M' monthly, 'Y' yearly, 'H' or '1H' hourly, or minutes such as '5' or '15'.","maxLength":20,"title":"Resolution","type":"string"},"symbol":{"description":"Ticker symbol of the US stock or ETF, for example 'AAPL'.","maxLength":200,"title":"Symbol","type":"string"},"from_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Earliest date, as ISO 8601 (2026-01-31), a unix timestamp or similar. Do not combine with countback.","title":"From Date"},"to_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Latest date, same formats as from_date.","title":"To Date"},"countback":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Return this many entries ending at to_date instead of using from_date (1 to 1000).","title":"Countback"},"adjustsplits":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"Adjust for splits (default true for daily, false for intraday).","title":"Adjustsplits"},"adjustdividends":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"Adjust for dividends, daily candles only. Set false together with adjustsplits for raw prices.","title":"Adjustdividends"},"extended":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"Include extended-hours trading in intraday candles.","title":"Extended"}},"required":["resolution","symbol"],"title":"get_stock_candlesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_stock_earnings":{"post":{"operationId":"get_stock_earnings","summary":"Get quarterly earnings history or upcoming report dates for a stock: fiscal period, report date, reported and estimated ","description":"Get quarterly earnings history or upcoming report dates for a stock: fiscal period, report date, reported and estimated EPS and surprise. Future report dates are estimates. Use for \"What were Apple's last earnings results versus estimates\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"symbol":{"description":"Ticker symbol of the US stock or ETF, for example 'AAPL'.","maxLength":200,"title":"Symbol","type":"string"},"from_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Earliest date, as ISO 8601 (2026-01-31), a unix timestamp or similar. Do not combine with countback.","title":"From Date"},"to_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Latest date, same formats as from_date.","title":"To Date"},"countback":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Return this many entries ending at to_date instead of using from_date (1 to 1000).","title":"Countback"},"date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Return only the report for this exact date.","title":"Date"}},"required":["symbol"],"title":"get_stock_earningsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_stock_news":{"post":{"operationId":"get_stock_news","summary":"Get recent news headlines for a stock with source URL and publication time (beta endpoint on the provider side). Column ","description":"Get recent news headlines for a stock with source URL and publication time (beta endpoint on the provider side). Column arrays, one element per article. Use for \"What is the latest news on AAPL\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"symbol":{"description":"Ticker symbol of the US stock or ETF, for example 'AAPL'.","maxLength":200,"title":"Symbol","type":"string"},"from_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Earliest date, as ISO 8601 (2026-01-31), a unix timestamp or similar. Do not combine with countback.","title":"From Date"},"to_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Latest date, same formats as from_date.","title":"To Date"},"countback":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Return this many entries ending at to_date instead of using from_date (1 to 1000).","title":"Countback"},"date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Return only news from this day.","title":"Date"}},"required":["symbol"],"title":"get_stock_newsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_market_status":{"post":{"operationId":"get_market_status","summary":"Check whether the US stock market is open or closed on a date or date range (holidays and weekends are closed; half days","description":"Check whether the US stock market is open or closed on a date or date range (holidays and weekends are closed; half days count as open). Use for \"Is the stock market open on 2026-11-26\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"country":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Two-letter ISO country code (only US is supported).","title":"Country"},"date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Single date to check, ISO 8601 or a relative string such as 'today'.","title":"Date"},"from_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Earliest date, as ISO 8601 (2026-01-31), a unix timestamp or similar. Do not combine with countback.","title":"From Date"},"to_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Latest date, same formats as from_date.","title":"To Date"},"countback":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Return this many entries ending at to_date instead of using from_date (1 to 1000).","title":"Countback"}},"title":"get_market_statusArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_option_expirations":{"post":{"operationId":"get_option_expirations","summary":"List option expiration dates available for an underlying stock, optionally only those that include a given strike, or as","description":"List option expiration dates available for an underlying stock, optionally only those that include a given strike, or as of a past trading day. Use for \"Which option expiration dates exist for AAPL\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"underlying_symbol":{"description":"Ticker symbol of the underlying, for example 'AAPL'.","maxLength":200,"title":"Underlying Symbol","type":"string"},"strike":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"Only expirations that list this strike price.","title":"Strike"},"date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Historical trading day to look up, ISO 8601.","title":"Date"}},"required":["underlying_symbol"],"title":"get_option_expirationsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_option_chain":{"post":{"operationId":"get_option_chain","summary":"Get the option chain of an underlying (current or end-of-day for a past date) with bid, ask, last, volume, open interest","description":"Get the option chain of an underlying (current or end-of-day for a past date) with bid, ask, last, volume, open interest, implied volatility and greeks. Column arrays, one element per contract. The provider counts 1 plan credit per contract returned, so keep strike_limit and filters small. Use for \"Show the ATM calls on AAPL expiring next month\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"underlying_symbol":{"description":"Ticker symbol of the underlying, for example 'AAPL'.","maxLength":200,"title":"Underlying Symbol","type":"string"},"expiration":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Expiration date (ISO 8601), or 'all' for every expiry. Defaults to the next monthly expiry.","title":"Expiration"},"dte":{"anyOf":[{"maximum":2000,"minimum":0,"type":"integer"},{"type":"null"}],"default":null,"description":"Pick the expiration closest to this many days to expiry.","title":"Dte"},"side":{"anyOf":[{"enum":["call","put"],"type":"string"},{"type":"null"}],"default":null,"description":"Only 'call' or 'put' contracts.","title":"Side"},"strike":{"anyOf":[{"maxLength":60,"type":"string"},{"type":"null"}],"default":null,"description":"Strike filter: 400, a list '400,405', a range '400-410' or an open range '>400'.","title":"Strike"},"range":{"anyOf":[{"enum":["itm","otm","all"],"type":"string"},{"type":"null"}],"default":null,"description":"Moneyness filter: itm, otm or all.","title":"Range"},"strike_limit":{"anyOf":[{"maximum":200,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"Keep only this many strikes closest to the money (1 to 200).","title":"Strike Limit"},"min_open_interest":{"anyOf":[{"minimum":0,"type":"integer"},{"type":"null"}],"default":null,"description":"Only contracts with at least this open interest.","title":"Min Open Interest"},"min_volume":{"anyOf":[{"minimum":0,"type":"integer"},{"type":"null"}],"default":null,"description":"Only contracts with at least this volume.","title":"Min Volume"},"date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Historical trading day for an end-of-day chain (greeks are null for past dates).","title":"Date"}},"required":["underlying_symbol"],"title":"get_option_chainArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_option_quote":{"post":{"operationId":"get_option_quote","summary":"Get the current or end-of-day quote of one option contract by OCC symbol: bid, ask, last, volume, open interest, implied","description":"Get the current or end-of-day quote of one option contract by OCC symbol: bid, ask, last, volume, open interest, implied volatility and greeks (greeks are null for past dates). Use for \"What is the quote on AAPL271217C00250000\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"option_symbol":{"description":"OCC option symbol, for example 'AAPL271217C00250000'.","maxLength":200,"title":"Option Symbol","type":"string"},"date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Historical trading day, ISO 8601.","title":"Date"},"from_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Earliest date, as ISO 8601 (2026-01-31), a unix timestamp or similar. Do not combine with countback.","title":"From Date"},"to_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Latest date, same formats as from_date.","title":"To Date"}},"required":["option_symbol"],"title":"get_option_quoteArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/lookup_option_symbol":{"post":{"operationId":"lookup_option_symbol","summary":"Convert a plain-text description such as 'AAPL 12/17/27 $250 Call' into an OCC option symbol. Errors when that contract ","description":"Convert a plain-text description such as 'AAPL 12/17/27 $250 Call' into an OCC option symbol. Errors when that contract does not exist. Use for \"What is the option symbol for AAPL 12/17/27 250 call\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"user_input":{"description":"Description with underlying, expiration date, strike and call or put, for example 'AAPL 12/17/27 $250 Call'.","maxLength":100,"title":"User Input","type":"string"}},"required":["user_input"],"title":"lookup_option_symbolArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_fund_candles":{"post":{"operationId":"get_fund_candles","summary":"Get historical daily, weekly, monthly or yearly price candles for a mutual fund. Column arrays: t, o, h, l, c. Use for \"","description":"Get historical daily, weekly, monthly or yearly price candles for a mutual fund. Column arrays: t, o, h, l, c. Use for \"Show monthly VFINX prices for 2024\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"resolution":{"description":"Candle size: 'D', 'W', 'M' or 'Y' (intraday is not supported for funds).","maxLength":20,"title":"Resolution","type":"string"},"symbol":{"description":"Mutual fund ticker symbol, for example 'VFINX'.","maxLength":200,"title":"Symbol","type":"string"},"from_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Earliest date, as ISO 8601 (2026-01-31), a unix timestamp or similar. Do not combine with countback.","title":"From Date"},"to_date":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Latest date, same formats as from_date.","title":"To Date"},"countback":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Return this many entries ending at to_date instead of using from_date (1 to 1000).","title":"Countback"}},"required":["resolution","symbol"],"title":"get_fund_candlesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}