🌐
Claude
docs.claude.com › en › api › openai-sdk
OpenAI SDK compatibility - Claude Docs
For the best experience and access to Claude API full feature set (PDF processing, citations, extended thinking, and prompt caching), we recommend using the native Claude API. To use the OpenAI SDK compatibility feature, you’ll need to:
🌐
Microsoft Learn
learn.microsoft.com › en-us › samples › azure-samples › claude-with-openai-responses › claude-with-openai-responses
Claude Models with OpenAI Responses API - Code Samples | Microsoft Learn
Multi-language code samples demonstrating how to use the OpenAI Responses API to interact with Claude models (Sonnet 4.5, Haiku 4.5, Opus 4.5) hosted in Microsoft Foundry with EntraID (keyless) authentication.
🌐
GitHub
github.com › fuergaosi233 › claude-code-proxy
GitHub - fuergaosi233/claude-code-proxy: Claude Code to OpenAI API Proxy
Convert Claude API requests to OpenAI API calls, allowing you to use various LLM providers through the Claude Code CLI.
Starred by 1.8K users
Forked by 241 users
Languages   Python 99.7% | Dockerfile 0.3%
🌐
GitHub
github.com › jtsang4 › claude-to-chatgpt
GitHub - jtsang4/claude-to-chatgpt: This project converts the API of Anthropic's Claude model to the OpenAI Chat API format.
This project converts the API of Anthropic's Claude model to the OpenAI Chat API format. - jtsang4/claude-to-chatgpt
Starred by 1.3K users
Forked by 148 users
Languages   Python 54.9% | JavaScript 43.3% | Dockerfile 1.8%
🌐
Reddit
reddit.com › r/chatgptpro › api - open ai v claude
r/ChatGPTPro on Reddit: API - Open AI v Claude
July 6, 2024 -

Has anyone been using either or both on a high level? Which of the two provides the most cost efficient, consistent and non robotic answers/outputs? I’m currently using 4o and even then, still outputs inconsistently for workflows like data extraction.

🌐
GitHub
github.com › missuo › claude2openai
GitHub - missuo/claude2openai: Convert the Claude API to OpenAI compatible API.
Convert the Claude API to OpenAI compatible API. Contribute to missuo/claude2openai development by creating an account on GitHub.
Starred by 114 users
Forked by 19 users
Languages   Go 98.1% | Dockerfile 1.9%
🌐
Lunar
lunar.dev › flows › switching-requests-from-the-openai-api-to-anthropics-claude-apis
Switching requests from the OpenAI API to Anthropic’s Claude APIs
Notably, Claude 3 Opus has demonstrated superior performance over OpenAI's GPT-4 in various benchmarks, including graduate-level expert reasoning. While GPT-4 offers broad capabilities, Claude's design prioritizes producing reliable and trustworthy outputs, with recent iterations like Claude 3 Opus surpassing GPT-4 in certain performance metrics. Prompting: Both APIs allow users to provide natural language prompts to the models, which then generate relevant text responses.
🌐
Claude
claude.com › platform › api
Claude Developer Platform | Claude
Use our API to create new user experiences, products, and ways to work with the most advanced AI models on the market.
🌐
Pipedream
pipedream.com › apps › openai › integrations › anthropic
Integrate the OpenAI (ChatGPT) API with the Anthropic (Claude) API - Pipedream
Setup the OpenAI (ChatGPT) API trigger to run a workflow which integrates with the Anthropic (Claude) API. Pipedream's integration platform allows you to integrate OpenAI (ChatGPT) and Anthropic (Claude) remarkably fast. Free for developers.
Find elsewhere
🌐
GitHub
github.com › easychen › aiapi
GitHub - easychen/aiapi: A Claude-driven, OpenAI specification-compliant API, free
AiAPI is a cross-platform client that converts the Claude website into an OpenAI-compatible API, allowing you to use Claude's 100k context capability in any OpenAI-compatible software. What's even better is that it's free.
Starred by 138 users
Forked by 8 users
🌐
Reddit
reddit.com › r/claudeai › claude code api wrapper
r/ClaudeAI on Reddit: Claude Code API Wrapper
July 3, 2025 -

edit Thanks to all the early users. There are a couple of inherent limitations with the CLI/SDK that make using it with Roocode difficult. I think this will work best in chat like applications - if you want to code and have a Claude Code subscription then just use Claude Code 😅

/edit

In an effort to get EVEN more out of the Claude Max Plan - I present the Claude Code API Wrapper/Server.

The tool transforms your Claude Code instance into a API server that can be used (locally) in place of an OpenAI chat completion key. Literally just substitute in your localhost address and you are off to the races.

As ever, starts, issues and PRs are welcome!

https://github.com/RichardAtCT/claude-code-openai-wrapper

🌐
GitHub
github.com › cabinlab › claude-code-api
GitHub - cabinlab/claude-code-api: API to use Claude Code wherever OpenAI keys are expected
An OpenAI-compatible API gateway for Claude Code with simple auth and web-based key management & revocation
Author   cabinlab
🌐
BetterTouchTool Community
community.folivora.ai › feature requests
Add Claude API (just like the openAI one) - Feature Requests - BetterTouchTool Community
July 13, 2024 - The Open AI API feature is great, wonder if you can add one to allow me to use Claudes API. Thanks
🌐
GitHub
github.com › ruvnet › claude-flow › wiki › Using-Claude-Code-with-Open-Models
Using Claude Code with Open Models
Select the Text Generation Inference (TGI) template ≥ v1.4.0. TGI now ships an OpenAI-compatible Messages API—tick "Enable OpenAI compatibility" or add --enable-openai in advanced settings.
Author   ruvnet
🌐
GitHub
github.com › 1rgs › claude-code-proxy
GitHub - 1rgs/claude-code-proxy: Run Claude Code on OpenAI models
The proxy automatically maps Claude models to either OpenAI or Gemini models based on the configured model: ... The BIG_MODEL and SMALL_MODEL will get the appropriate prefix based on whether they're in the OpenAI or Gemini model lists ... OPENAI_API_KEY="your-openai-key" GEMINI_API_KEY="your-google-key" # Needed if PREFERRED_PROVIDER=google # PREFERRED_PROVIDER="openai" # Optional, it's the default # BIG_MODEL="gpt-4.1" # Optional, it's the default # SMALL_MODEL="gpt-4.1-mini" # Optional, it's the default
Starred by 2.7K users
Forked by 367 users
Languages   Python 99.7% | Dockerfile 0.3%
🌐
WIRED
wired.com › business › artificial intelligence › anthropic revokes openai's access to claude
Anthropic Revokes OpenAI's Access to Claude | WIRED
August 1, 2025 - Anthropic revoked OpenAI’s API access to its models on Tuesday, multiple sources familiar with the matter tell WIRED. OpenAI was informed that its access was cut off due to violating the terms of service. “Claude Code has become the go-to choice for coders everywhere, and so it was no surprise to learn OpenAI's own technical staff were also using our coding tools ahead of the launch of GPT-5,” Anthropic spokesperson Christopher Nulty said in a statement to WIRED.
🌐
Medium
medium.com › @AI_prompt_design › should-you-use-your-own-claude-openai-api-key-037ac420b649
Should you use your own Claude/OpenAI API key? | by The AI Prompt Design Journal | Medium
October 19, 2024 - Or OpenAI API key? It’s fairly simple. you go to the Claude or OpenAI website, sign up for an account, enter a credit card, and then generate a unique API key.
🌐
Zapier
zapier.com › productivity › app tips
Claude API: How to get a key and use the API
July 8, 2024 - This guide includes a step-by-step tutorial on how to get a Claude API key, how to call the Claude API, and how to get the responses where you want them.
🌐
Reddit
reddit.com › r/localllama › gateway/proxy for claude-code to openai api compatible.
r/LocalLLaMA on Reddit: Gateway/Proxy for Claude-Code to OpenAI API compatible.
August 2, 2025 -

Sharing an OpenAI proxy solution for Claude-Code

https://github.com/ziozzang/claude2openai-proxy

Advantages:

  1. In theory, as long as an OpenAI-compatible API supports tool usage, you can smoothly test any model with Claude Code.

  2. You can start using Claude Code with any specified model, whether it’s internal or external.

  3. You can also debug if needed.

  4. Anyway, at least from my tests, it works very well. The only issue is the model itself.

----

While using Claude Code, I wanted to connect to a local model. There were tools like claude-code-router and other systems, but I couldn’t find a solid solution that worked well for multiple users. So, based on https://github.com/1rgs/claude-code-proxy , I built a proxy tailored for my use. Since it converts between different protocols, “gateway” might actually be a more fitting term.

Anyway, here are the features:

Full support for Claude Code.

  • On the server side, you can configure which model to proxy. For example, when a request comes in for opus or sonnet, you can route it to a predefined model.

  • Alternatively, you can force the model selection at Claude Code startup by letting the user set it via environment variables.

  • Authentication is done via the ANTHROPIC_API_KEY environment variable. The provided token is then forwarded to the backend as a Bearer token for the OpenAI API.

Below is an example of setting up the server and actually using it from a client:

ANTHROPIC_BASE_URL=http://localhost:8082 \
ANTHROPIC_API_KEY=sk-openapi-auth-token \
ANTHROPIC_MODEL="openrouter/horizon-beta" \
ANTHROPIC_SMALL_FAST_MODEL="openrouter/horizon-beta" \
claude  

To be honest, I made this to test the openrouter/horizon-beta model. :)

The pipeline works great: Claude Code -(Claude API)-> my modified proxy server -(OpenAI API)-> openrouter/horizon-beta.

By the way, you can find what I built at https://github.com/ziozzang/claude2openai-proxy . I use it by building it into a container.

To be honest,

  • horizon-alpha doesn’t seem to handle Claude Code’s prompts very well. Qwen3-Coder flash (30B A3B) either. (tool calling issue.)

  • horizon-beta handles them quite well.

  • However, both models ask the user to make choices too often to be suitable for full automation. Compared to Sonnet, they don’t feel ideal for automated workflows.

PS.

The whole reason this started was because of Claude Code’s usage limits. LoL...