Repository navigation
v4.0
AIProxyOauth 4.0
Connect Claude Code and other Anthropic Messages clients to eligible Copilot
models using explicit copilot/ names.
Changes:
- Route POST /v1/messages to Copilot only when the account model catalog
explicitly advertises that endpoint. Works on Copilot-only servers. - Preserve native request fields, tools, JSON responses, SSE events, and usage.
Forward validated version/beta headers using the proxy's Copilot credential. - Keep unqualified and anthropic/ Messages requests on Anthropic.
Unsupported models are rejected without provider or protocol failover. - Share bounded native response delivery, with disconnect and size-limit tests.
- Add Claude Code setup instructions, including effort=auto for Haiku.
Validation:
- 611 Java tests and 23 offline Python tests pass.
- Live Copilot Haiku tests passed for JSON, streaming, tool calls, and tool results.
- User confirmed Claude Code Sonnet and Haiku operation, including Haiku tools.
Limits:
- Native Copilot model-picker discovery and token counting are not included.
- Claude Code may show unrecognized-model and classifier billing notices.
- Copilot's upstream SSE terminator is preserved; the proxy adds no sentinel.
- Enterprise Cloud and other Claude Code features remain live-unverified.
Requires Java 21 and an account with access to the selected provider/model.
Download AIProxyOauth-4.0.jar and run:
java -jar AIProxyOauth-4.0.jar --help
Full Changelog: v3.1.1...v4.0