home / skills / openclaw / skills / yahoo-data-fetcher

yahoo-data-fetcher skill

/skills/noypearl/yahoo-data-fetcher

This skill fetches real-time stock quotes from Yahoo Finance and returns structured data for multiple symbols, enabling quick financial insights.

npx playbooks add skill openclaw/skills --skill yahoo-data-fetcher

Review the files below or copy the command above to add this skill to your agents.

Files (4)
SKILL.md
1.1 KB
---
name: yahoo-data-fetcher
description: Fetch real-time stock quotes from Yahoo Finance.
user-invocable: true
metadata:
  moltbot:
    emoji: "📈"
    requires:
      bins: ["node"]
    homepage: https://query1.finance.yahoo.com/v7/finance/quote
---

# Yahoo Data Fetcher – Stock Quote

Get current stock price data from Yahoo Finance.

This skill fetches the latest market quote for one or more stock symbols and returns normalized JSON output.

---

## Command

### `/stock quote`

Fetch the latest quote for one or more stock symbols.

---

## Input

- `symbols` (string or array of strings)

Examples:
- `"AAPL"`
- `"AAPL MSFT TSLA"`
- `"AAPL,MSFT,TSLA"`
- `["AAPL", "MSFT"]`
- `{ "symbols": ["AAPL", "MSFT"] }`

---

## Output

For each symbol:

- `symbol` – stock ticker
- `price` – latest market price
- `change` – absolute price change
- `changePercent` – percentage change
- `currency` – trading currency
- `marketState` – market status (e.g. `REGULAR`, `CLOSED`)

Example output:

```json
[
  {
    "symbol": "AAPL",
    "price": 189.12,
    "change": 1.23,
    "changePercent": 0.65,
    "currency": "USD",
    "marketState": "REGULAR"
  }
]

Overview

This skill fetches real-time stock quotes from Yahoo Finance and returns normalized JSON for one or more tickers. It focuses on delivering the latest price, absolute and percentage change, currency, and market state. The output is compact and suitable for embedding in dashboards, bots, or automation workflows.

How this skill works

You provide one or multiple symbols as a string or array (e.g., "AAPL", "AAPL MSFT", or ["AAPL","MSFT"]). The skill queries Yahoo Finance for current market data, normalizes the result, and returns a JSON array with fields like symbol, price, change, changePercent, currency, and marketState. It handles common input formats and aggregates results into a consistent structure for easy consumption.

When to use it

  • Display up-to-the-minute prices in a trading dashboard or chat bot.
  • Power alerts and monitoring for specific tickers or portfolios.
  • Enrich financial reports or automation pipelines with current market values.
  • Quickly validate market moves during trading hours.
  • Integrate into customer-facing tools that need live quote snapshots.

Best practices

  • Supply symbols as an array or a space/comma-separated string to avoid parsing ambiguity.
  • Verify currency and marketState when combining symbols from different exchanges.
  • Cache results for short intervals if calling frequently to avoid rate limits.
  • Validate symbol existence and handle missing or delisted tickers gracefully.
  • Use changePercent together with absolute change to convey movement magnitude and context.

Example use cases

  • Fetch a single quote: input "AAPL" returns price, change, changePercent, currency, marketState.
  • Fetch multiple quotes for a portfolio: input ["AAPL","MSFT","TSLA"] to get a normalized array for each ticker.
  • Embed in a Slack bot: user types "/stock quote AAPL,MSFT" and receives JSON or formatted summary.
  • Automate end-of-day summaries by polling marketState and recording the final price if marketState is CLOSED.
  • Trigger alerts when changePercent exceeds a configured threshold for monitored symbols.

FAQ

What input formats are accepted?

Accepts a single symbol string, space- or comma-separated strings, or an array of strings.

What does marketState represent?

marketState indicates trading status such as REGULAR or CLOSED to show whether the price is live or final.