Quick Start
Follow the steps below to integrate within a few minutes.
Step 1: Get an API Key
Sign up and create an API Key in the console. Keep the key secure and never expose it in client-side or front-end code.
Step 2: Configure Base URL
Replace the official OpenAI endpoint with the Qiyiguo AI endpoint:
Python
from openai import OpenAI
client = OpenAI(
api_key="YOUR_API_KEY",
base_url="https://api.manysky.top/v1"
)
Node.js
import OpenAI from "openai";
const client = new OpenAI({
apiKey: process.env.MANYSKY_API_KEY,
baseURL: "https://api.manysky.top/v1"
});
Step 3: Call a Model
Use a single interface to call multiple models:
Chat Completions
resp = client.chat.completions.create(
model="gpt-4.1",
messages=[{"role": "user", "content": "Hello"}]
)
print(resp.choices[0].message.content)
Chat Completions
const resp = await client.chat.completions.create({
model: "claude-sonnet-4-20250514",
messages: [{ role: "user", content: "Hello" }]
});
console.log(resp.choices[0].message.content);
Recommended Practices
- Store and inject API keys securely on the server side
- Add retry and timeout mechanisms for critical requests
- Combine with Error Codes & Retry to improve robustness