All notable changes to tikhub will be documented in this file. The format is based on Keep a Changelog and the project follows Semantic Versioning.
- mkdocs-material site at
mkdocs.yml+docs/. Hand-written guides for authentication, async, errors, pagination, retries, logging, CLI, naming rules, and a migration guide fromtikhub_sdk_v2. - Auto-generated API reference (
docs/reference.md, 1540 lines) listing all 1010 methods with their endpoint paths and signatures. Regenerated byscripts/generate_docs.py. - CLI (
pip install "tikhub[cli]"->tikhubconsole script):tikhub healthtikhub fetch <url>tikhub user infotikhub user usagetikhub --versionImplemented insrc/tikhub/cli/.
- GitHub Actions docs workflow (
.github/workflows/docs.yml) builds the mkdocs site and deploys to GitHub Pages on every push to main. - GitHub Actions release workflow (
.github/workflows/release.yml) triggered by version tags (v3.x.y); builds sdist + wheel and publishes to PyPI via OIDC trusted publishing after running the full lint / typecheck / test / coverage gate. Self-typed lifecycle methods onBaseClient/AsyncBaseClientsowith TikHub() as client:correctly narrows toTikHub(not the parent base class) under mypy strict.- 8 new CLI tests - 110 total now passing.
- Codegen pipeline under
scripts/:refresh_spec.py— pulls latestopenapi.json, prints diff vs cached snapshot.generate_resources.py— regenerates all resource modules +client.py+async_client.pyfromspec/openapi.json.verify_coverage.py— CI gate that asserts every spec endpoint has a matching SDK method (and vice versa).
- All 52 resources for TikHub OpenAPI V5.3.2 wired up — 1010 / 1010 endpoints.
- Multipart support in
_base_client._request(the one Sora2 image-upload endpoint). - GitHub Actions CI (
.github/workflows/ci.yml): lint, mypy, pytest matrix on Python 3.9–3.13, plus the coverage gate. docs/quickstart.md— runnable 5-minute tour.- 61 new tests (
tests/unit/test_generated_resources.py) covering resource attribute presence, query/JSON/array body dispatch, async ↔ sync parity, and total endpoint count.
Complete rewrite of the TikHub Python SDK.
- New
tikhubpackage built from scratch against TikHub OpenAPI spec V5.3.2. TikHub(sync) andAsyncTikHub(async) clients backed byhttpx.- Bearer-token authentication via constructor or
$TIKHUB_API_KEY. - Exception hierarchy rooted at
TikHubErrorwith clear HTTP status mapping. - Automatic retry for transient failures (5xx, 429, network errors) with exponential backoff and
Retry-Afterhonouring. - Rate-limit-aware sleeping based on
X-RateLimit-Resetheaders. - Cursor / page / offset paginator scaffolding.
- Pydantic v2 model layer (
extra="allow"so the SDK survives upstream additions). health_checkresource demonstrating the foundation end-to-end.
- Legacy auto-generated code (
setup.py,tox.ini, old docs, old tests) replaced by the new hand-architected SDK.