# Stock price history API for your agent

Stock price history API for an agent: it sends a ticker symbol and a date range to a catalog endpoint and reads open, high and low back. Several providers sell the call, so the agent tries the cheapest first. You pay per call, and a failed call costs nothing.

## What this does

Daily history is the base of every chart and backtest. Your agent sends a ticker and a date range and reads back one row per trading day: open, high, low, close and volume. From there it can compute returns, find the best and worst days or draw the curve.

Three endpoints return it. One returns end-of-day data for a ticker with filters for period and date range. One returns end-of-day data for a single symbol between two dates, with a limit, an offset and a sort. One takes several comma-separated symbols in one call and covers a very large list of tickers.

You give: a ticker symbol and a date range. Example: AAPL.US from 2026-01-01 to 2026-03-31.

## What differs between providers

- EODHD Financial Data API (eodhd-eod): returns end-of-day history for a ticker, with a period, a date range and a field filter.
- Marketstack (marketstack-tickers-eod): returns end-of-day data for one symbol between two dates, with a limit, an offset and a sort.
- Marketstack (marketstack-eod): takes several comma-separated symbols in one call and an optional exchange.

## Before you start

- Set both dates. An open range returns the most recent rows only, and a long one returns a lot of rows.
- Mind adjustments. Splits and dividends change old prices, and an adjusted close keeps the series comparable. Your agent should say which one it used.
- Batch tickers on the endpoint that takes several. One call for ten symbols is cheaper than ten calls.

## Prompt

Use looot to get the daily prices of AAPL.US from 2026-01-01 to 2026-03-31 and return date, open, high, low, close and volume, plus the best and the worst day. 1. Set up https://looot.ai/skill.md. 2. Search the catalog for each step and check its price before you call. 3. Run the cheapest endpoint that fits. 4. Show the results as a table and the total cost.

## Steps and providers

- Fetch the daily prices: eodhd, marketstack. 1 call per ticker.

## What comes back

- Open, high, low and close
- Volume
- Date
- One row per trading day

## The request and what comes back

Each run is one POST to /v1/runs with an endpoint id and an input. These are illustrative calls with generic values. The run's result holds the provider's own fields.

- EODHD Financial Data API: {"endpointId":"eodhd-eod","input":{"ticker":"AAPL.US","from":"2026-01-01","to":"2026-03-31"},"wait":30}
- Marketstack: {"endpointId":"marketstack-tickers-eod","input":{"symbol":"AAPL","date_from":"2026-01-01","date_to":"2026-03-31"},"wait":30}

## What can I compute from the rows?

Daily returns, the best and worst day, a moving average and the largest drop from a peak. Your agent computes them from the rows with its own tools, and looot returns the data and bills the calls.

## What is the ticker format?

One provider uses a ticker with an exchange suffix such as AAPL.US, and the other takes the bare symbol. Your agent reads the endpoint page to use the right one.

## How do I get daily stock prices through an API?

Send the ticker and a date range to an end-of-day endpoint. Your agent reads back one row per trading day with open, high, low, close and volume.

## Can I get several tickers in one call?

Yes, on the endpoint that takes comma-separated symbols. The others take one ticker per call.

## Does it include dividends and splits?

The catalog has split and dividend endpoints from these providers. The end-of-day calls return the price rows.

## How far back does the history go?

That depends on the provider and the ticker. State the date range you need, and read the endpoint page for limits.

## How much does one ticker cost?

You pay per call, and the price depends on the provider your agent picks. This page reads the cheapest live price from the catalog and shows no number when the catalog is unreachable.

## Do I pay when a stock price history call fails?

No. A call that fails at the provider costs nothing, and your agent can retry it or send it to another provider.

## Do I need an account with each stock price history provider?

No. One looot key reaches every provider in the catalog. You top up once, and each call is billed at the price shown before it runs.

## How do I call stock price history from code?

Send a POST to /v1/runs with the endpoint id, the input and a new idempotency key, and your looot token in the Authorization header. With wait set to 30, the answer comes back in the response when the run ends within 30 seconds. Otherwise poll GET /v1/runs/<runId>.

## Can I run stock price history on a schedule?

That needs scheduled runs, not available yet. Run it by hand whenever you want fresh results.

## Do I pay while my agent is idle?

No. looot bills per call, and nothing runs while your agent is idle.

## Related pages

- /use-cases/stock-quote-api
- /use-cases/stock-news-api
- /use-cases/crypto-price-api

## Last reviewed

2026-10-04. The cost per 1,000 ticker runs is read live from the catalog on the web page.
