Documentation Index
Fetch the complete documentation index at: https://docs.redpill.ai/llms.txt
Use this file to discover all available pages before exploring further.
Why Migrate?
- ✅ Same Multi-Provider - 50+ models
- ✅ TEE Protection - Hardware-enforced privacy
- ✅ OpenAI Compatible - Better SDK support
- ✅ Verifiable - Cryptographic attestation
- ✅ Confidential Models - Phala TEE models
Key Difference
| Feature | OpenRouter | RedPill |
|---|
| Multi-provider | ✅ Yes | ✅ Yes (50+ models) |
| TEE Protection | ❌ No | ✅ Full gateway in TEE |
| Attestation | ❌ No | ✅ Cryptographic proof |
| Privacy | ❌ None | ✅ Hardware-enforced |
Migration Steps
Update Endpoint
# Before (OpenRouter)
client = OpenAI(
base_url="https://openrouter.ai/api/v1",
api_key="YOUR_OPENROUTER_KEY"
)
# After (RedPill)
client = OpenAI(
base_url="https://api.redpill.ai/v1",
api_key="YOUR_REDPILL_KEY"
)
Update Model Names
Some model names may differ - check /v1/models
Model Name Changes
OpenRouter uses provider prefixes:
# OpenRouter naming
"openai/gpt-4"
"anthropic/claude-sonnet-4.5"
# RedPill naming (same format!)
"openai/gpt-5"
"anthropic/claude-sonnet-4.5"
RedPill uses the same provider/model format!
Code Changes
Before (OpenRouter)
from openai import OpenAI
client = OpenAI(
base_url="https://openrouter.ai/api/v1",
api_key=os.environ.get("OPENROUTER_API_KEY"),
)
response = client.chat.completions.create(
extra_headers={
"HTTP-Referer": "https://yourapp.com",
"X-Title": "Your App"
},
model="openai/gpt-4",
messages=[{"role": "user", "content": "Hello"}]
)
After (RedPill)
from openai import OpenAI
client = OpenAI(
base_url="https://api.redpill.ai/v1",
api_key=os.environ.get("REDPILL_API_KEY"),
)
response = client.chat.completions.create(
model="openai/gpt-5", # Simplified!
messages=[{"role": "user", "content": "Hello"}]
)
New TEE Features
After migration, you can:
1. Verify TEE Execution
# Get attestation
attestation = requests.get(
"https://api.redpill.ai/v1/attestation/report",
headers={"Authorization": f"Bearer {api_key}"}
)
2. Use Confidential Models
# Phala TEE models
response = client.chat.completions.create(
model="phala/glm-5",
messages=[...]
)
3. Get Signatures
# Cryptographic proof
signature = requests.get(
f"https://api.redpill.ai/v1/signature/{request_id}",
params={"model": "phala/qwen-2.5-7b-instruct"}
)
Pricing Comparison
Both use pay-as-you-go, but RedPill adds TEE protection at no extra cost.
Gradual Migration
Run both in parallel:
# Test with RedPill
redpill = OpenAI(
base_url="https://api.redpill.ai/v1",
api_key="REDPILL_KEY"
)
# Keep OpenRouter (temporarily)
openrouter = OpenAI(
base_url="https://openrouter.ai/api/v1",
api_key="OPENROUTER_KEY"
)
# Compare responses
redpill_resp = redpill.chat.completions.create(...)
openrouter_resp = openrouter.chat.completions.create(...)
Benefits After Migration
- ✅ Hardware-protected requests
- ✅ Cryptographic attestation
- ✅ Confidential AI models
- ✅ Better privacy compliance
- ✅ Verifiable execution
Get Started
Start using RedPill now →