qianwen-ops-auth
This skill walks you through QianWen API credential setup and validation. It handles both standard and Token Plan key types, manages environment variables and .env files, and provides verification steps to confirm your authentication is working correctly.
qianwen-ops-auth configures and verifies QianWen API credentials for secure authentication.
AI-generated summary based on this skill's SKILL.md
Install
QianWen-AI/qianwen-ai/qianwen-ops-auth · repository language: Python
git clone https://github.com/QianWen-AI/qianwen-ai
cp -r qianwen-ai/skills/ops/qianwen-ops-auth ~/.claude/skills/qianwen-ops-authnpx skillfed install QianWen-AI/qianwen-ai/qianwen-ops-authFrequently asked questions
AI-generated answers based on this skill's SKILL.md and metadata
How do I set up a QianWen API key?
qianwen-ops-auth guides you through obtaining and configuring your QianWen API credentials. First, generate an API key from the QianWen console, then store it securely—either as an environment variable (DASHSCOPE_API_KEY) or in a .env file. The skill walks you through both standard and Token Plan key types, ensuring your credentials are properly validated before use.
What should I do if I get a 401 unauthorized error with QianWen?
qianwen-ops-auth provides troubleshooting steps for 401 authentication errors. Common causes include an invalid or expired API key, incorrect environment variable naming, or misconfigured endpoint headers. Verify your DASHSCOPE_API_KEY is set correctly, check that you're using the right key type (standard vs. Token Plan), and confirm the key hasn't been revoked in your QianWen console.
How do I configure environment variables and .env files for QianWen API keys?
qianwen-ops-auth shows you how to set up both methods. For environment variables, export DASHSCOPE_API_KEY with your key value. For .env files, create a file in your project root with DASHSCOPE_API_KEY=your_key_here, then load it using your framework's dotenv library. The skill verifies your setup is correct and catches common configuration mistakes.
What's the difference between standard and Token Plan API key types?
qianwen-ops-auth explains that standard keys are general-purpose credentials for most QianWen API calls, while Token Plan keys (typically prefixed sk-sp) offer usage-based billing and different rate limits. The skill helps you identify which type you have and configure each correctly, since they may require different endpoint handling or validation steps.
How can I verify my QianWen API key is working correctly?
qianwen-ops-auth includes validation steps to confirm authentication success. Make a test API call to a QianWen endpoint using your configured credentials and check for a successful response. The skill guides you through interpreting error codes, confirming your key is active, and ensuring your environment setup is complete before deploying to production.
How do I set up custom OSS bucket credentials for QianWen file uploads?
qianwen-ops-auth covers configuring custom Object Storage Service (OSS) buckets for file uploads. You'll need to provide your OSS bucket name, access key ID, and secret access key. The skill shows you how to store these credentials securely alongside your QianWen API key and validate that your bucket permissions allow the upload operations you need.
SKILL.md
rendered from the published skill — quoted content, verbatim
> Agent setup: If your agent doesn't auto-load skills (e.g. Claude Code), see agent-compatibility.md once per session.
QianWen Authentication Setup
Configure and verify authentication for QianWen APIs. This skill is part of QianWen-AI/qianwen-ai.
Skill directory
Use this skill's internal files for learning. Load references only when the user needs console or documentation links.
| Location | Purpose |
|---|---|
references/tokenplan.md |
Token Plan 团队版 vs standard key: endpoint mapping, supported models (4 text + 4 image), Credits billing, error codes |
references/custom-oss.md |
Custom OSS bucket setup for |
(truncated - see the full file via the links below)
Read as markdown · JSON record · Browse the source repository
File tree — 5 files
skills/ops/qianwen-ops-auth/SKILL.md
skills/ops/qianwen-ops-auth/references/agent-compatibility.md
skills/ops/qianwen-ops-auth/references/custom-oss.md
skills/ops/qianwen-ops-auth/references/sources.md
skills/ops/qianwen-ops-auth/references/tokenplan.md