---
title: "Anomaly History"
method: GET
path: "/api/anomaly/history/{ticker}"
tags: ["Anomaly"]
---

# Anomaly History

`GET /api/anomaly/history/{ticker}`

## Request

- Base URL: `https://api.xfinlab.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.xfinlab.com/api/anomaly/history/{ticker}`
- Auth: none declared

Past 30 days of volume/price anomalies for a single ticker, with
related news attached to each flagged day -- powers the "過去30日
成交量異常" section on anomaly.html's single-ticker search result.

Single-ticker only, by explicit design choice: extending this to the
batch watchlist scan (GET /anomaly above) would multiply the yfinance
+ NewsAPI workload by the watchlist size, and was intentionally left
out of scope for this feature.

2026-09-14 fix (site-wide "hardcoded string ignores lang" audit): this
sibling of anomaly_search() above never accepted `lang` at all, even
though anomaly.html already sends I18N.currentLang to every OTHER
endpoint on this page. Reuses anomaly_search()'s already-all-47-
language `anom_ticker_format_error` key for the exact same message
(just phrased slightly differently in the original Chinese literal),
and threads `lang` into scan_last_30_days() for its own error/label
strings below.

## Path parameters

- `ticker` string, required

## Query parameters

- `lang` string

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/xfinlab/apis/xfinlab-api.md) · [All operations](https://skmtc.dev/xfinlab/apis/xfinlab-api/llms.txt) · [OpenAPI document](https://skmtc.dev/xfinlab/apis/xfinlab-api/revisions/205f85614bc6?raw)
