Calculator
Migration guides

The Switchboard

Turn price savings into action. Step-by-step guides with code snippets, compatibility scores and gotchas.

Prices checked 13 Nov 2026

Guides

OpenAI to Anthropic

Compatibility
85%
Difficulty
Easy
Time
1-2 hours
Cheapest output price
Same priceGPT-6 Luna $0.50 vs Claude Haiku 5.5 $0.50 per million output tokens

Migration steps

  1. Install the Anthropic SDK: npm install @anthropic-ai/sdk
  2. Replace API key environment variable: OPENAI_API_KEY → ANTHROPIC_API_KEY
  3. Update the client initialization code
  4. Modify message format (role/content structure is similar)
  5. Update function calling to use Claude's tool_use format
  6. Test with a subset of your prompts to verify output quality
Before (OpenAI)
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: process.env.OPENAI_API_KEY,
});

const response = await client.chat.completions.create({
  model: "gpt-5.4",
  messages: [
    { role: "system", content: "You are helpful." },
    { role: "user", content: "Hello!" }
  ],
});

console.log(response.choices[0].message.content);
After (Anthropic)
import Anthropic from '@anthropic-ai/sdk';

const client = new Anthropic({
  apiKey: process.env.ANTHROPIC_API_KEY,
});

const response = await client.messages.create({
  model: "claude-sonnet-5-5",
  max_tokens: 1024,
  system: "You are helpful.",
  messages: [
    { role: "user", content: "Hello!" }
  ],
});

// Thinking is on by default, so content can start with a thinking block
for (const block of response.content) {
  if (block.type === "text") console.log(block.text);
}

Watch out for

  • System prompts work differently -- Claude uses a dedicated system parameter
  • Function calling syntax differs -- Claude uses tool_use blocks
  • Token counting methods are different
  • Max context window varies by model

OpenAI to Google

Compatibility
75%
Difficulty
Medium
Time
2-4 hours
Cheapest output price
▼ 20% lowerGPT-6 Luna $0.50 vs Gemini 2.5 Flash-Lite $0.40 per million output tokens

Migration steps

  1. Install Google AI SDK: npm install @google/generative-ai
  2. Replace API key: OPENAI_API_KEY → GOOGLE_API_KEY
  3. Update client initialization with GoogleGenerativeAI
  4. Convert messages to Gemini's parts-based format
  5. Update streaming handlers if using SSE
  6. Configure safety settings as needed
Before (OpenAI)
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: process.env.OPENAI_API_KEY,
});

const response = await client.chat.completions.create({
  model: "gpt-5.4",
  messages: [
    { role: "user", content: "Hello!" }
  ],
});
After (Google)
import { GoogleGenerativeAI } from '@google/generative-ai';

const genAI = new GoogleGenerativeAI(
  process.env.GOOGLE_API_KEY
);

const model = genAI.getGenerativeModel({
  model: "gemini-3.8-flash"
});

const result = await model.generateContent("Hello!");
console.log(result.response.text());

Watch out for

  • Gemini uses a different message format (parts-based)
  • Safety settings are more granular in Gemini
  • Streaming API differs significantly
  • Function calling uses a different schema format

OpenAI to DeepSeek

Compatibility
95%
Difficulty
Easy
Time
30 minutes
Cheapest output price
▲ 140% higherGPT-6 Luna $0.50 vs DeepSeek V4.1 Flash $1.20 per million output tokens

Migration steps

  1. Update the base URL to DeepSeek's endpoint
  2. Replace API key: OPENAI_API_KEY → DEEPSEEK_API_KEY
  3. Change model name to deepseek-flash (or deepseek-v4-pro)
  4. Test -- most code works without changes
Before (OpenAI)
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: process.env.OPENAI_API_KEY,
});

const response = await client.chat.completions.create({
  model: "gpt-5.4",
  messages: [
    { role: "user", content: "Hello!" }
  ],
});
After (DeepSeek)
import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: process.env.DEEPSEEK_API_KEY,
  baseURL: "https://api.deepseek.com",
});

const response = await client.chat.completions.create({
  model: "deepseek-flash",
  messages: [
    { role: "user", content: "Hello!" }
  ],
});
// Same response format -- it just works!

Watch out for

  • DeepSeek uses OpenAI-compatible API -- minimal changes needed
  • Vision works on deepseek-flash but not on deepseek-v4-pro
  • Weekday peak hours (01:00-04:00 and 06:00-10:00 UTC) bill at double the off-peak rate
  • Rate limits and quotas differ
  • Response format may have subtle differences

Anthropic to OpenAI

Compatibility
85%
Difficulty
Easy
Time
1-2 hours
Cheapest output price
Same priceClaude Haiku 5.5 $0.50 vs GPT-6 Luna $0.50 per million output tokens

Migration steps

  1. Install OpenAI SDK: npm install openai
  2. Replace API key: ANTHROPIC_API_KEY → OPENAI_API_KEY
  3. Move system prompt into messages array
  4. Update response parsing from text blocks in content to choices[0].message.content
  5. Update tool calling format if used
Before (Anthropic)
import Anthropic from '@anthropic-ai/sdk';

const client = new Anthropic();

const response = await client.messages.create({
  model: "claude-sonnet-5-5",
  max_tokens: 1024,
  system: "You are helpful.",
  messages: [
    { role: "user", content: "Hello!" }
  ],
});
After (OpenAI)
import OpenAI from 'openai';

const client = new OpenAI();

const response = await client.chat.completions.create({
  model: "gpt-5.4",
  messages: [
    { role: "system", content: "You are helpful." },
    { role: "user", content: "Hello!" }
  ],
});

Watch out for

  • OpenAI uses system messages in the messages array, not a separate parameter
  • Function calling syntax is different (tools vs tool_use)
  • Response structure differs (choices[] vs content[])

Next steps