Skip to main content
RedPill’s OpenAI-compatible API works seamlessly with popular AI frameworks and SDKs.

OpenAI SDK

Official OpenAI Python and TypeScript SDKs

LangChain

Build complex AI applications with LangChain

Vercel AI SDK

Build streaming AI UIs with React and Next.js

Langfuse

LLM observability and analytics

Quick Start

All integrations follow the same pattern:
1

Install the SDK

Install your preferred framework or SDK
2

Configure Base URL

Point to RedPill’s API endpoint: https://api.redpill.ai/v1
3

Add API Key

Use your RedPill API key for authentication
4

Choose Models

Select from 60+ models (66+ provider integrations available) with provider prefix (e.g., openai/gpt-5)

Why Use RedPill?

All requests flow through hardware-protected secure enclaves, regardless of which framework you use.
Access models from OpenAI, Anthropic, Google, DeepSeek, and more through a single API.
Works with any tool that supports OpenAI’s API format - just change the base URL.
Use Phala’s confidential models for end-to-end private AI processing.

Integration Comparison

FrameworkBest ForLanguageDifficulty
OpenAI SDKSimple integrationsPython, TypeScriptEasy
LangChainComplex AI apps, RAGPython, TypeScriptMedium
Vercel AI SDKReact/Next.js UIsTypeScriptEasy
LangfuseObservabilityPython, TypeScriptEasy

Example: Switch to RedPill

Before (Direct OpenAI)

from openai import OpenAI

client = OpenAI(api_key="sk-openai-key")

response = client.chat.completions.create(
    model="gpt-4",
    messages=[{"role": "user", "content": "Hello"}]
)

After (RedPill with Privacy Protection)

from openai import OpenAI

client = OpenAI(
    api_key="sk-redpill-key",
    base_url="https://api.redpill.ai/v1"  # Only 1 line change!
)

response = client.chat.completions.create(
    model="openai/gpt-5",  # Add provider prefix
    messages=[{"role": "user", "content": "Hello"}]
)
That’s it! Just 2 small changes and you get hardware-enforced privacy protection + access to 60+ models (66+ provider integrations available).

Community Integrations

These tools also work with RedPill’s OpenAI-compatible API:
  • Continue - AI code assistant for VS Code
  • Cursor - AI-powered code editor
  • LibreChat - ChatGPT-like interface
  • BetterChatGPT - Web UI for OpenAI API
  • ChatGPT Next Web - Self-hosted ChatGPT web UI

Need Help?

Discord Community

Get help from the community

GitHub Examples

Browse code examples