XuanShu API

API key governance

Isolate keys by environment, team, and workload, and rotate them regularly.

Last verified:

Connection and authentication

Unified OpenAI-compatible Base URL: https://www.xuanshuapi.com/v1

OpenAI-compatible APIs use Authorization: Bearer <YOUR_API_KEY>; Claude Messages also accepts x-api-key: <YOUR_API_KEY>; Gemini v1beta uses x-goog-api-key: <YOUR_API_KEY>.

export OPENAI_API_KEY="<YOUR_API_KEY>"
export OPENAI_BASE_URL="https://www.xuanshuapi.com/v1"

API key governance

Use separate keys for development, testing, and production; minimize distribution, monitor usage, and revoke and rotate immediately after exposure.

Models, multipliers, quota, and usage depend on the current key and console data.

Next steps

Available models, multipliers, quotas, and some advanced capabilities depend on the current key and console configuration.