Integration
Get Started in Minutes
The WorkChi API is fully compatible with OpenAI. Just change the base URL and you're done.
Quick Start
1
Get your API key
Sign up at workchi.ai to get your API key.
2
Change the base URL
Update your code to use the WorkChi endpoint:
# OpenAI (before)
https://api.openai.com/v1
# WorkChi (after)
https://api.workchi.ai/v1
https://api.openai.com/v1
# WorkChi (after)
https://api.workchi.ai/v1
3
Use "auto" for intelligent routing
Set model: "auto" to let the router select the optimal model, or specify a specific model.
Code Examples
const WorkChi = require('workchi-sdk');
// Initialize with your API key
const client = new WorkChi('wk_your_api_key');
// Basic chat completion with auto-routing
async function chat() {
const response = await client.chat.completions.create({
model: 'auto', // Router selects optimal model
messages: [
{ role: 'system', content: 'You are a helpful assistant.' },
{ role: 'user', content: 'Explain quantum computing in simple terms.' }
],
max_tokens: 1000
});
console.log(response.choices[0].message.content);
}
chat();Framework Support
๐
LangChain
Native Python and JS support
๐
LlamaIndex
RAG and indexing support
๐ค
AutoGPT
Autonomous agent support
๐ช
Semantic Kernel
Microsoft ecosystem
Advanced Options
Custom Routing Rules
Define your own routing logic based on task type, language, or user tier.
{
"model": {
"task": "code",
"language": "de",
"tier": "premium"
}
}EU Data Residency
Route all requests to EU-hosted models for compliance.
{
"model": "auto",
"region": "eu" // Forces EU providers
}Ready to integrate?
Get your API key and start using the WorkChi Router today.