Skip to content

Repository files navigation

anything2api

OpenAI/Anthropic-compatible reverse proxy. Forked from tiantianGPU/replit2api2, extended with additional OpenAI/Codex/Gemini models and a Gemini routing path that prefers same-host /integrations/google-gemini-* (Anything-platform style) and falls back to the OpenAI client (Replit / Vertex OpenAI compat) on 404.

Supported models

  • Anthropic (via AI_INTEGRATIONS_ANTHROPIC_*): claude-opus-4-7, claude-opus-4-6, claude-sonnet-4-6, claude-haiku-4-5
  • OpenAI (via AI_INTEGRATIONS_OPENAI_*): gpt-5.5, gpt-5.4, gpt-5.2, gpt-5-mini, gpt-5-nano, gpt-5-codex, codex-mini-latest, o4-mini, o3
  • Gemini (same-host /integrations/google-gemini-{ver} first, fallback to OpenAI client): gemini-3.1-pro-preview, gemini-2.5-pro, gemini-2.5-flash

Endpoints

  • GET /v1/models
  • POST /v1/chat/completions (OpenAI-compatible, supports tool calls + streaming)
  • POST /v1/messages (Anthropic native, byte-preserving transparent proxy)
  • GET / Portal UI

Bearer token via PROXY_API_KEY env, or auto-generated and stored in .proxy-key at build time (also baked into the Portal as VITE_PROXY_API_KEY).

Deploy

  1. Fork / import this repo into a Replit workspace
  2. Enable Anthropic + OpenAI AI Integrations so Replit injects the AI_INTEGRATIONS_* env vars
  3. Run — root package.json build + start

For Anything-style platforms, the same code works as long as the host serves /integrations/google-gemini-{ver} paths (Gemini routing) and the OpenAI/Anthropic integrations inject the same env names.

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages