# rainx/pytdx

Python tdx数据接口

Repository: https://github.com/rainx/pytdx
Canonical: https://ross.abutalabs.com/products/pytdx
Language: Python
License Family: other
Archived: true
Last push: 2020-04-15T13:02:24+00:00

## Health v2 (maintenance only)
Score: 10/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 3358, "days_push": 2331, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, archived, no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1553, forks 1045 (observed 2026-08-28T04:05:02.843131+00:00)

## What it is
pytdx is a Python library implementing the TongDaXin (TDX) network protocol to fetch Chinese stock market data such as quotes, K-line bars, and financial data from TDX servers. It was developed for personal learning purposes and has been officially archived by its author.

## Use cases
- fetch real-time stock quotes from TDX servers in Python
- download historical K-line candlestick data for Chinese A-shares
- pull financial statements and company info via the TDX protocol
- build a personal stock analysis or backtesting data pipeline
- scrape market data without a paid data vendor

## When to choose
- you need free access to Chinese stock market data via the TDX protocol in Python
- you are doing personal, non-commercial research or learning
- you are okay with unmaintained code and fixing issues yourself

## When to avoid
- you need a maintained library with bug fixes and support
- you intend any commercial use (explicitly prohibited by the author)
- you need reliable production-grade market data feeds
- you need markets outside China or non-TDX data sources

## Facets
- artifact type: library
- maturity: abandoned
- function: http-client, parser, sdk
- domain: fintech, apis
- platform: python, cross-platform
- tags: tdx, tongdaxin, stock-market-data, china-stock-market, quotes-api, archived, network-protocol, data-engineering

## Member repositories
- rainx/pytdx (main) score 10

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:02.843131+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:30:10.155709+00:00, confidence not recorded.
  - readme: https://github.com/rainx/pytdx (fetched 2026-08-28T04:05:02.843131+00:00, sha 58773ef7260b)
  - registry_pypi: https://pypi.org/pypi/pytdx/json (fetched 2026-08-29T11:30:30.720470+00:00, sha d71770637302)
- Data as of 2026-08-30T08:39:29.467469+00:00.
