ClawSkills logoClawSkills

Quodd Stock Quotes

通过 Quodd API 获取实时股票报价。获取美国股票的当前价格、日内最高/最低价和盘后数据。当用户询问股价、时使用

介绍

# Quodd Stock Quotes

通过 Quodd API 获取美股实时行情。

更多信息,请访问:https://www.quodd.com/stock-and-etf-data

## 快速开始

```bash # Get a quote for Apple python scripts/quote.py AAPL

# Get quotes for multiple tickers python scripts/quote.py AAPL MSFT META ```

## 前置条件

设置以下环境变量:

```bash export QUODD_USERNAME="your_username" export QUODD_PASSWORD="your_password" ```

## 使用方法

### 单个代码

```bash python scripts/quote.py AAPL ```

### 多个代码

```bash python scripts/quote.py AAPL MSFT META GOOGL ```

### JSON 输出

```bash python scripts/quote.py AAPL --format json ```

### 强制刷新令牌

```bash python scripts/quote.py AAPL --no-cache ```

## 输出格式

### 文本(默认)

``` Quodd Stock Quotes Symbol Date Time High Low Close AH Time AH Price ------------------------------------------------------------------------------- AAPL 01/29/26 14:30 185.50 180.25 182.63 17:45:30 182.80 ```

### JSON

```json { "quotes": [ { "symbol": "AAPL", "date": "01/29/26", "time": "14:30", "high": 185.50, "low": 180.25, "close": 182.63, "after_hours_time": "17:45:30", "after_hours_price": 182.80 } ] } ```

## 输出字段

- **Symbol** - 股票代码 - **Date** - 行情日期 - **Time** - 行情时间 - **High** - 当日最高价 - **Low** - 当日最低价 - **Close** - 最后成交价 - **AH Time** - 盘后交易时间 - **AH Price** - 盘后价格

## 注意事项

- 身份验证令牌缓存在 `~/.openclaw/credentials/quodd-token.json` 中,有效期为 20 小时 - 如果在凭证更改后遇到身份验证错误,请使用 `--no-cache`

更多产品