yangmao.ai · Python setup money page
Tiangong AI Python API Setup
Use this page when you need a working Python starting point for Tiangong AI, then validate quota and model names in the official console before production.
Quick verdict
- Free API: Free tier
- Rate limits: Varies
- Best model starting point: 天工大模型
- China access: direct or relatively friendly
Provider fit matrix
Production readiness checklist
Python setup snapshot
Start with the smallest possible chat completion, then move the key to your server-side secret manager before production.
# 天工 API 需要申请开发者权限
# 详见 docs.tiangong.cn Free API and pricing notes
Free tier
SkyWork API has free tier
Access and production risk
China-friendly / direct path likely
By Kunlun Tech, direct access in China.
How to set it up
Create or locate your provider API key in the official dashboard.
Install the provider SDK or requests dependency shown in the example.
Set the API key in an environment variable instead of hard-coding secrets.
Run a small Tiangong AI chat completion with 天工大模型.
Watch free credits, RPM/TPM limits, response shape, and error messages before scaling.
Fallback CTA with tracked UTM
If you do not want to juggle provider keys, rate limits, and regional access, use openllmapi.com as a unified API fallback.
Try openllmapi with one key →UTM: utm_source=yangmao.ai · utm_medium=seo · utm_campaign=provider · utm_content=tiangong-setup-python
Related internal links
Source snapshot
Data source: yangmao.ai provider YAML tracker plus provider docs reviewed by the daily crawler. Official dashboards can change quota and pricing without notice; verify before production.
- yangmao.ai provider id
- tiangong
- Official source
- https://www.tiangong.cn
- Last updated
- 2026-05-16
- Free tier
- No explicit limit
- API credits
- Free tier
- Rate limit
- Varies
- Access note
- By Kunlun Tech, direct access in China.
FAQ
Does Tiangong AI have a free API?
Yes. Current yangmao.ai record: Free tier. Rate limit note: Varies.
Is Tiangong AI OpenAI-compatible?
This snapshot uses a provider-specific OpenAI SDK example. If your app requires one stable OpenAI-compatible endpoint, use an aggregator or relay after checking Tiangong AI docs.
Can I use Tiangong AI from China?
Tiangong AI is marked as relatively direct or China-friendly in the current tracker.
What should I do when Tiangong AI credits run out?
Compare the alternatives below, check /en/free-ai-api/, or use the openllmapi CTA on this page as a one-key fallback with tracked UTM: campaign=provider, content=tiangong-setup-python.