Skip to main content
skill CX Codex

price-history — Claude Code skill: what it does, how to install

The price-history Claude Code skill fetches historical OHLCV data for a stock. It activates for requests about past prices or data for chart analysis.

MIT 102 installs ★ 417 updated 2026-10-21

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add staskh/trading_skills --skill price-history -a claude-code
Open on GitHub

What price-history does

The skill retrieves historical OHLCV records from Yahoo Finance for a ticker symbol. Its scripts/history.py script returns JSON with dates, opening and closing prices, highs, lows, and volume. The requested period and data interval can be set as arguments.

The trading-skills dependency and the yfinance library are required. The command runs through uv run python; use python instead if uv is missing or the project has no pyproject.toml. Time-based calculations and timestamps use America/New_York. The JSON output also carries generated_at and data_delay fields.

What it helps with

  • fetch historical quotes for a stock ticker
  • compare a stock’s highs and lows over a period
  • get OHLCV records for chart analysis

Example prompts for the agent

  • Fetch a month of historical prices for AAPL.
  • Get MSFT price data for 1y with a 1wk interval.
  • Retrieve historical TSLA data for chart analysis.

How to install price-history

1Skills CLI (Vercel)

npx skills add staskh/trading_skills --skill price-history -a claude-code

2Manually: put the files in place

~/.claude/skills/price-history/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/price-history/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about price-history

How do I install price-history in Claude Code?

Run npx skills add staskh/trading_skills --skill price-history -a claude-code. The skill file is at ~/.claude/skills/price-history/SKILL.md.

What does price-history do?

It fetches historical OHLCV data for a stock from Yahoo Finance and returns it as JSON. The period and interval are configurable.

What does price-history need to run?

It requires the trading-skills dependency and the yfinance library. The script uses uv run python; switch to python if uv is unavailable or pyproject.toml is missing.

Source text

SKILL.md · MIT
---
name: price-history
description: Get historical price data (OHLCV) for a stock. Use when user asks about price history, historical data, past performance, price over time, or needs data for chart analysis.
dependencies: ["trading-skills"]
---

# Price History

Fetch historical OHLCV data from Yahoo Finance.

## Instructions

> **Note:** If `uv` is not installed or `pyproject.toml` is not found, replace `uv run python` with `python` in all commands below.

```bash
uv run python scripts/history.py SYMBOL [--period PERIOD] [--interval INTERVAL]
```

## Arguments

- `SYMBOL` - Ticker symbol
- `--period` - Time period: 1d, 5d, 1mo, 3mo, 6mo, 1y, 2y, 5y, 10y, ytd, max (default: 1mo)
- `--interval` - Data interval: 1m, 2m, 5m, 15m, 30m, 60m, 90m, 1h, 1d, 5d, 1wk, 1mo (default: 1d)

## Output

Returns JSON with:
- `symbol` - Ticker
- `period` - Requested period
- `interval` - Data interval
- `data` - Array of {date, open, high, low, close, volume}

Summarize key price movements, highs/lows, and trends.

## Dependencies

- `yfinance`


## Timezone

All timestamps and time-based calculations must use the `America/New_York` timezone. All JSON output must include `generated_at` (NY time string) and `data_delay` fields.

© staskh · MIT · staskh/trading_skills

Similar skills

All skills for Finance and business →

From the same set12

The whole set →
stock-quote stock-quote is a Claude Code skill that fetches current price, volume, change, and 52-week range for any ticker. CX Codex +1 138installs greeks Skill computes option Greeks (delta, gamma, theta, vega) and implied volatility using the Black-Scholes model. Use it to understand how your position reacts to price changes, time decay, and shifts in volatility. CX Codex +1 137installs report-stock report-stock builds stock research reports in Markdown or PDF covering market trends, PMCC viability, and company fundamentals. CX Codex +1 123installs option-chain Skill pulls option chain data from Yahoo Finance: calls and puts with strike prices, bids, asks, volumes, and implied volatility. Use it to check option quotes for a specific expiration date. CX Codex +1 117installs risk-assessment risk-assessment calculates risk metrics for stocks and positions: volatility, beta, Value at Risk, and maximum drawdown. Use it to assess position risk and determine sizing. CX Codex +1 113installs ib-portfolio ib-portfolio — a skill for Claude Code fetches open positions and holdings from Interactive Brokers. The agent invokes it when asked about current stocks, portfolio value, or account assets. CX Codex +1 107installs spread-analysis The spread-analysis skill performs quantitative analysis of multi-leg option strategies for Claude Code. It triggers on requests concerning vertical spreads, iron condors, straddles, or strangle strategies. CX Codex +1 105installs ib-account The ib-account Claude Code skill fetches an Interactive Brokers account summary. It activates for questions about balances, buying power, or available cash. CX Codex +1 103installs

Project sponsors

Companies that keep this analytics open