by AlephantAI
Alephant is an open-source AI Agent Gateway for routing, tracking, and controlling LLM usage across AI agents, members, and workflows, and for publishing agent capabilities as paid endpoints with x402 and MPP payment rails.
# Add to your Claude Code skills
git clone https://github.com/AlephantAI/AIephant-AI-Agent-GatewayGuides for using ai agents skills like AIephant-AI-Agent-Gateway.
Last scanned: 6/29/2026
{
"issues": [],
"status": "PASSED",
"scannedAt": "2026-06-29T08:59:11.064Z",
"npmAuditRan": true,
"pipAuditRan": true,
"promptInjectionRan": true
}Alephant AI Gateway is an OpenAI-compatible control layer for production AI applications, available as hosted SaaS or as a self-hosted gateway. It gives developers one stable API surface while the gateway handles provider-specific adaptation, model routing, policy enforcement, layered caching, retries, fallback, usage metadata, request logging, and audit trails.
Instead of wiring every application directly to every provider, teams connect once and route across 50+ providers, 320+ models, and custom model backends. Start with Alephant Cloud for a managed workspace, or self-host the gateway when you need private infrastructure, BYO keys, and direct operational control.
import OpenAI from "openai"
const openai = new OpenAI({
baseURL: "https://ai.alephant.io/v1",
defaultHeaders: {
Authorization: `Bearer ${process.env.ALEPHANT_API_KEY}`,
"Alephant-Session-Id": "session-xxx", // optional
}
})
Alephant AI Gateway is currently in beta (0.2.0-beta.30). Alephant Cloud is the hosted SaaS path, and this repository provides the gateway runtime for self-hosted and platform-connected deployments. Public APIs, configuration fields, and internal build modes may evolve before a stable 1.0 release.
AI applications are moving from single-model prototypes to production systems that call many providers, agents, tools, and custom model backends. Without a gateway, every team ends up rebuilding the same operational layer: provider adapters, routing rules, key management, usage metadata, retries, caching, and request logs.
Alephant AI Gateway centralizes that layer behind one OpenAI-compatible API. It gives developers a stable integration surface while platform teams get policy before provider access, cache before repeated calls, fallback before outages, and audit trails before production incidents.
The goal is simple: make AI traffic observable, governable, and reliable without slowing developers down. Learn more ->
| Capability | What Alephant AI Gateway provides |
|---|---|
| One API surface | OpenAI-compatible /v1/* and /ai/* routes for chat, responses, embeddings, images, and provider-style model names |
| Provider and model coverage | 50+ providers, 320+ models, local runtimes, OpenRouter-style catalogs, and custom/private backends |
| Provider adaptation | Request, tool, streaming, error, usage, finish-reason, and response normalization across provider APIs |
| Routing and resilience | Direct provider paths, policy routers, retries, fallback, health checks, provider 429 handling, and fail-open cache paths |
| Agent client compatibility | OpenAI-compatible formats for Cursor, Codex, opencode, and Antigravity workflows |
| IDE integration | Cursor-ready with architecture rules, workflow guides, implementation skills, and task management; opencode, Codex, and Claude Code adapters in progress |
| Policy and key control | Virtual keys, master key resolution, model policy, workspace provider allowlists, and concurrency controls |
| Caching | Gateway-side LLM KV cache and semantic cache to avoid repeated upstream calls |
| Observability | Request logs, traces, metrics, usage metadata, optional body archival, and downstream log delivery |
| Live operations | Route, virtual key, and provider key refresh from database changes without restarting the gateway |
| Deployment | Hosted SaaS through Alephant Cloud, or self-hosted Rust gateway with PostgreSQL, Redis, Qdrant, and S3-compatible integrations |
| Surface | Purpose |
|---|---|
/v1/* |
Drop-in OpenAI-compatible API for existing SDKs and agent clients |
/router/{id}/* |
Policy-driven routing through a configured router |
/{provider}/* |
Direct provider passthrough when you want explicit upstream control |
model=provider/model_id |
Select a provider and model without changing application code |
| Custom backends | Put private models or self-hosted runtimes behind the same gateway contract |
Every request passes through the same gateway lifecycle: global middleware, routing, provider mapping, dispatch, cache, fallback, and async logging. The entry path depends on how much control you want:
| Path | Use it for |
|---|---|
/v1/* |
Unified OpenAI-style access with model=provider/model_id |
/router/{id}/* |
Policy-driven routing through a configured router |
/{provider}/* |
Direct provider passthrough when you want an explicit upstream |
Use one OpenAI-style request shape across 50+ providers and 320+ models, including OpenAI-compatible APIs, Anthropic Messages, Gemini, Bedrock, Ollama, OpenRouter-style catalogs, and custom backends. The client selects a runtime with model=provider/model_id; Alephant resolves the provider, applies the right adapter, maps provider-specific fields, and returns a normalized OpenAI-style response.
Instead of listing every model in the README, this section focuses on the contract: one request format in, one consistent response out. The provider and model catalog can evolve independently without forcing application code changes.
Alephant AI Gateway ships repository-level tooling for AI-assisted development inside supported IDEs.
| IDE / Agent Client | Status | What's included |
|---|---|---|
| Cursor | Ready | Project architecture & code-convention rules, development & API workflow guides, gated-module-implementation skill (Skill), file-based task management (Task Magic) — see the .cursor directory; also configure the gateway in Agent Settings → Models |
| opencode | In progress | Adapter and configuration under development |
| Codex | In progress | Adapter and configuration under development |
| Claude Code | In progress | Adapter and configuration under development |
Keep your existing OpenAI SDK and change
AIephant-AI-Agent-Gateway is an open-source ai agents skill for AI coding assistants such as Claude Code, Codex CLI, and ChatGPT, built by AlephantAI. Alephant is an open-source AI Agent Gateway for routing, tracking, and controlling LLM usage across AI agents, members, and workflows, and for publishing agent capabilities as paid endpoints with x402 and MPP payment rails. It has 100 GitHub stars.
Yes. AIephant-AI-Agent-Gateway passed SkillsLLM's automated security scan — a dependency vulnerability audit plus prompt-injection heuristics — with no high-severity issues. You can read the full report in the Security Report section on this page.
Clone the repository with "git clone https://github.com/AlephantAI/AIephant-AI-Agent-Gateway" and add it to your Claude Code skills directory (see the Installation section above).
AIephant-AI-Agent-Gateway is primarily written in Rust. It is open-source under AlephantAI on GitHub, so you can review or fork the full source.
Yes. SkillsLLM lists many other AI Agents skills you can browse and compare side by side. Open the AI Agents category from the badge at the top of this page, or use the Related Skills and comparison links further down to weigh AIephant-AI-Agent-Gateway against similar tools.
No comments yet. Be the first to share your thoughts!