AISIX AI Gateway MCP server
2026년 11월 13일 커밋여러 LLM 제공업체와 MCP server 간의 트래픽을 라우팅, 관리, 보안 및 관찰할 수 있는 단일 OpenAI 호환 API를 제공합니다.
다른 이름 api7/aisix, aisix
- 스타
- 219
- Tools
- —
- 다운로드, 30일
- —
- 최신 버전
- 1.3.0
- 마지막 커밋
- 2026년 11월 13일
- 라이선스
- Apache-2.0
AISIX AI Gateway MCP란?
AISIX AI Gateway은(는) MCP server입니다. 여러 LLM 제공업체와 MCP server 간의 트래픽을 라우팅, 관리, 보안 및 관찰할 수 있는 단일 OpenAI 호환 API를 제공합니다.
프로젝트 README에서 생성된 요약
AISIX AI Gateway MCP server 정보
AISIX OSS는 플랫폼 팀이 단일 제어 지점을 통해 LLM 및 AI 에이전트 트래픽을 관리할 수 있도록 설계된 Rust 기반 AI 게이트웨이입니다. OpenAI, Anthropic, Google Gemini, AWS Bedrock, Azure OpenAI, DeepSeek를 포함한 다양한 제공업체를 위한 통합 인터페이스 역할을 하는 OpenAI 호환 API를 제공합니다. 이 단일 정적 바이너리를 자체 인프라에 배포하면 라이브 트래픽이 제3자 제어 평면을 거치지 않고도 요청을 라우팅, 보안 및 관찰할 수 있습니다.
게이트웨이는 시맨틱 라우팅, 앙상블 모델 실행, round robin 또는 최소 지연 시간(least latency) 전략을 사용한 자동 장애 조치와 같은 복잡한 운영 작업을 처리합니다. PII 탐지 및 콘텐츠 정책 준수를 위한 내장 가드레일을 포함하며, 메모리 또는 Redis 백엔드를 사용하는 캐싱 기능을 제공합니다. 사용자는 선언적인 resources.yaml 파일 또는 etcd 클러스터를 통해 시스템을 관리하며, 서비스를 재시작하지 않고도 SIGHUP을 통해 설정을 실시간으로 다시 로드할 수 있습니다.
활용 사례
- 1통합 모델 액세스개발자는 기존 OpenAI SDK 코드에서 모델 이름만 변경하여 서로 다른 LLM 제공업체 간을 간편하게 전환할 수 있습니다.
- 2안전한 MCP server 관리도구 네임스페이스와 호출자 자격 증명에 대한 엄격한 제어를 유지하면서 게이트웨이를 통해 여러 MCP server를 노출할 수 있습니다.
- 3지능형 요청 라우팅AI 클라이언트는 사용자 입력의 실제 의미를 기반으로 가장 적합한 모델에 프롬프트를 자동으로 전달할 수 있습니다.
- 4콘텐츠 안전 준수플랫폼 엔지니어는 다양한 모더레이션 도구를 사용하여 민감한 정보의 자동 비식별화를 구현하고 금지된 콘텐츠를 차단할 수 있습니다.
프로젝트의 README를 바탕으로 작성되었습니다. 모든 활용 사례는 해당 내용의 인용문과 대조하여 확인합니다.
AISIX AI Gateway MCP 설치 방법
형식 확인: 2026년 11월 10일Claude Code에 AISIX AI Gateway MCP 설치
$ claude mcp add aisix -- docker run -i --rm ghcr.io/api7/aisix:1.3.0Cursor에 AISIX AI Gateway MCP 설치
~/.cursor/mcp.json
{
"mcpServers": {
"aisix": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/api7/aisix:1.3.0"
]
}
}
}VS Code에 AISIX AI Gateway MCP 설치
.vscode/mcp.json
{
"servers": {
"aisix": {
"type": "stdio",
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/api7/aisix:1.3.0"
]
}
}
}Claude Desktop에 AISIX AI Gateway MCP 설치
claude_desktop_config.json
{
"mcpServers": {
"aisix": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/api7/aisix:1.3.0"
]
}
}
}Codex에 AISIX AI Gateway MCP 설치
~/.codex/config.toml
[mcp_servers.aisix] command = "docker" args = ["run", "-i", "--rm", "ghcr.io/api7/aisix:1.3.0"]
Gemini CLI에 AISIX AI Gateway MCP 설치
~/.gemini/settings.json
{
"mcpServers": {
"aisix": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/api7/aisix:1.3.0"
]
}
}
}구성
CALLER_API_KEYOPENAI_API_KEY
| 이름 | 설명 | 유형 |
|---|---|---|
| CALLER_API_KEY | — | |
| OPENAI_API_KEY | — |
자동 검사
2026년 11월 12일에 실행됨전체 보고서 →아직 인증되지 않았습니다. 서버는 80점 이상의 점수, 심각한 결함 없음, 그리고 검사에 충분한 데이터를 갖추어야 합니다. 검사 방식
- 소스 저장소 연결 및 접근 가능통과
- 오픈 소스 라이선스 (OSI)통과
- 최근 1년 내 커밋 또는 릴리스통과
- 패키지 이름이 인기 패키지와 유사하지 않음검사되지 않음
- 원격 엔드포인트가 HTTPS 사용검사되지 않음
- 파괴적인 도구에 라벨 표시됨검사되지 않음
- 모델에 대한 숨겨진 지침 없음통과
- 패키지와 의존성에 심각한 보안 권고 없음검사되지 않음
README
GitHub에서 보기AISIX OSS
The open-source, Rust-native AI gateway for LLMs and AI agents
One OpenAI-compatible API in front of every model. Route, govern, secure, cache, and observe all your LLM and AI-agent traffic from a single control point — shipped as one static binary with low per-request overhead. Run it in your infrastructure for free, forever.
Built by the original creators of Apache APISIX.
Start free · Documentation · Quickstart · AISIX Enterprise and AISIX Cloud · Roadmap
AISIX OSS is the open-source product built around the Rust-native AISIX gateway. The gateway puts a single, OpenAI-compatible API in front of every LLM provider — OpenAI, Anthropic, Google Gemini, AWS Bedrock, Azure OpenAI, DeepSeek, and any OpenAI-compatible endpoint. It gives platform teams one place to route, govern, secure, and observe LLM traffic, with first-class SSE streaming and low gateway overhead.
It runs as a single static binary — low cold-start, lock-free config reads, and hot
configuration reloads with no restarts: declare resources in one resources.yaml and
reload on SIGHUP, or point the gateway at etcd for a multi-replica cluster. Run the
gateway in your infrastructure, or connect it to AISIX Enterprise or
AISIX Cloud
for centralized management with team governance, budgets, audit, and a dashboard.
AISIX OSS (this repo) is the open-source product. It runs without a control plane using declarative configuration or etcd. The same gateway binary serves as the data plane in the commercial products: customers host the control plane with AISIX Enterprise, while API7 hosts it with AISIX Cloud. In all three products, the gateway runs in your environment and calls providers directly; live AI traffic does not pass through either control plane. The proxy API is identical throughout. Talk to us about AISIX Enterprise or AISIX Cloud →
⚡ Quickstart
One container. No control plane, no database, no configuration store — the gateway reads
every dynamic resource from one declarative resources.yaml.
# config.yaml
resources_file: /etc/aisix/resources.yaml
proxy:
addr: "0.0.0.0:3000"
admin:
enabled: false # a declarative gateway needs no admin listener
observability:
metrics:
prometheus:
enabled: true
addr: "0.0.0.0:9090"
# resources.yaml
_format_version: "1"
provider_keys:
- display_name: openai-main
provider: openai
api_key: ${OPENAI_API_KEY} # interpolated from the environment
models:
- display_name: my-model
provider: openai
model_name: gpt-4o-mini
provider_key: openai-main
api_keys:
- display_name: local-dev
key_env: CALLER_API_KEY # hashed at load; the plaintext is never stored
allowed_models: ["my-model"]
export OPENAI_API_KEY="YOUR_PROVIDER_KEY"
export CALLER_API_KEY="YOUR_CALLER_KEY"
docker run -d --name aisix \
-v "$(pwd)/config.yaml:/etc/aisix/config.yaml:ro" \
-v "$(pwd)/resources.yaml:/etc/aisix/resources.yaml:ro" \
-e OPENAI_API_KEY -e CALLER_API_KEY \
-p 3000:3000 -p 127.0.0.1:9090:9090 \
ghcr.io/api7/aisix:latest # proxy → :3000, metrics + status → :9090
# ^ the metrics/status listener is unauthenticated;
# keep it on loopback or a private network
Then call the gateway exactly like OpenAI:
curl http://localhost:3000/v1/chat/completions \
-H "Authorization: Bearer $CALLER_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"my-model","messages":[{"role":"user","content":"hello"}]}'
Edit resources.yaml and send SIGHUP (docker kill -s HUP aisix) to apply changes with
no restart — an invalid file is rejected whole and the last good configuration keeps
serving. Check a file before booting with aisix validate --resources resources.yaml.
Full walkthrough: the
Gateway Quickstart ·
every field: the resources file reference.
For a multi-replica cluster, point the gateway at etcd instead — resources_file and
etcd are mutually exclusive.
✨ Why AISIX
- One API, every model. Speak the OpenAI or Anthropic wire format in; the gateway
translates to whichever provider each model points at. Point an OpenAI or Claude SDK at
one
base_urland switch models without changing code. - A real gateway, in Rust. Single static binary, low cold-start, lock-free config reads on the hot path, native streaming.
- Open source, free forever. Apache-2.0 licensed and built to run in your infrastructure. Choose AISIX Enterprise or AISIX Cloud when you want centralized management through a control plane and dashboard.
- Production controls built in. Routing & failover, rate limits, guardrails, caching, and observability ship in the box. (Budgets and spend caps are AISIX Enterprise and AISIX Cloud features — the gateway enforces the control plane's decisions.)
🧩 Features — available today
Covered by 183 end-to-end scenario files (496 cases) that run against real gateway processes.
- OpenAI-compatible proxy (
:3000) —chat/completions,completions,responses,embeddings,rerank,images/{generations,edits},audio/{speech,transcriptions,translations},videos(submit → poll → fetch),files,batches,fine_tuning/jobs,realtime,GET /v1/models, plus a root-level/passthrough/:provider/*escape hatch. Native SSE streaming, tool/function calling, JSON mode, vision/multimodal input, and reasoning-content support. - Anthropic Messages API —
POST /v1/messagesas a first-class route, working against any configured upstream: requests and responses (including streaming) are translated both ways when a model points at a non-Anthropic provider. - Routing & failover — virtual/routing models with six strategies:
round_robin(smooth weighted round-robin),consistent_hash(session affinity keyed by header / cookie / API key / client IP),failover, plus metric-basedleast_cost,least_latency, andleast_busy. Per-targetprioritytiers (active/backup pools), retry budgets, cooldowns, tag-conditional targets, and per-attempt timeouts. - Ensemble models — fan one request out to a panel of models concurrently, then have a judge model synthesize a single answer, with a minimum-successful-responses threshold.
- Semantic routing — one virtual model that dispatches by the meaning of each request: it embeds the prompt, scores it against per-route example utterances, and routes to the best match (or a default). See the semantic routing docs.
- Rate limiting & concurrency — RPS/RPM/RPH/RPD + TPM/TPD + concurrency caps,
AND-combined across caller keys, models, and policy scopes (
api_key/model/team/member/team_member). Counters are per-process by default, or shared across replicas with the Redis backend. - Guardrails — content-policy enforcement on input and output, in-process or through a
provider: keyword/regex, built-in PII detection and redaction, Presidio, Lakera, OpenAI
Moderation, AWS Bedrock Guardrails, Azure AI Content Safety (Prompt Shield + text
moderation), and two Alibaba Cloud services. A block returns
422 content_filter; monitor mode records what would have happened without blocking. - Caching — exact-match response cache with per-policy TTL and model/key scope matchers; memory and Redis backends; cost-saved telemetry on every hit. Separately, automatic prompt caching can be enabled per direct Anthropic model to inject cache breakpoints, so callers get provider-side prompt discounts without changing their requests.
- MCP gateway — front registered upstream MCP servers at
/mcpwith gateway-held credentials, per-server tool namespaces, and per-caller access. It serves every Streamable HTTP revision from2025-03-26through stateless2026-07-28without downstream sessions. Upstreams useinitializeby default orserver/discoverwithprotocol_version: "2026-07-28". CI runs the official MCP suite's applicable tools-only protocol scenarios. Also exposes a REST API as MCP tools from its OpenAPI description. - A2A agent gateway — front A2A (Agent-to-Agent) agents at
/a2a/:agent, serving each agent's card with URLs rewritten to the gateway, over JSON-RPC 2.0. - Inbound authentication — caller API keys (SHA-256 hashed, model allowlists, expiry, rotation), or OIDC/JWT bearer tokens validated against registered providers (Entra ID, Okta, Google Workspace, or any OIDC issuer) with JWKS caching.
- Observability — Prometheus
/metrics, structured per-request access logs, usage events, OTLP/GenAI span export (Langfuse, Honeycomb, Grafana Cloud, or any OTLP receiver), plus dedicated Datadog and Aliyun SLS log exporters and object-storage (S3/GCS/Azure Blob) telemetry. - Declarative configuration — one
resources.yamlcarries all ten resource collections (provider keys, models, caller keys, guardrails, MCP servers, A2A agents, cache policies, observability exporters, rate-limit policies, OIDC providers), validated against the same JSON Schemas the gateway uses at runtime.aisix validatechecks a file offline;SIGHUPreloads it atomically. - Operational endpoints —
/livezand/readyzon the proxy listener;/status/config,/status/ready,/status/models, and Prometheus/metricson a dedicated metrics listener (:9090). The admin listener (:3001) additionally serves a read-only resource surface, OpenAPI 3 with a Scalar UI, and a playground. Resources are managed declaratively — through theresources_file(reloaded on SIGHUP) or direct etcd writes — not through the admin listener; its former write endpoints were removed.
🔌 Supported providers
AISIX dispatches through five native adapter families — distinct wire-protocol bridges, not one generic relabel. Whatever the upstream protocol, the client-facing API stays OpenAI-shaped.
| Adapter family | Reaches | Wire shape · auth |
|---|---|---|
openai |
OpenAI + any OpenAI-compatible vendor — DeepSeek, Groq, Mistral, Together, Fireworks, Perplexity, vLLM, Ollama, or self-hosted OpenAI-compatible endpoints | OpenAI chat completions · Bearer |
anthropic |
Anthropic Claude | Anthropic Messages · x-api-key |
bedrock |
AWS Bedrock — Anthropic, Meta Llama, Mistral, Cohere, Amazon Titan/Nova, AI21 | Bedrock Converse + /invoke · SigV4 |
vertex |
Google Vertex AI (Gemini) | Vertex :generateContent · OAuth2 |
azure-openai |
Azure OpenAI | Azure deployments · api-key / Entra ID |
Plus specialized handling for vendor quirks (e.g. DeepSeek reasoning content) and dedicated rerank / embeddings vendors (Cohere, Jina). Details in adapter protocol families.
☁️ Choose an AISIX Product
Same gateway binary, same proxy API — in every form the gateway runs in your environment. AISIX Enterprise adds a customer-hosted commercial control plane. AISIX Cloud adds an API7-hosted commercial control plane.
| AISIX OSS (this repo) | AISIX Enterprise | AISIX Cloud | |
|---|---|---|---|
| License | Apache-2.0 | Commercial | Commercial |
| Control plane | None | Customer-hosted | API7-hosted |
| Configuration | Declarative resources.yaml, or etcd for a cluster |
Dashboard + AISIX Cloud Admin API | Dashboard + AISIX Cloud Admin API |
| Tenancy | Single instance / namespace | Organization-scoped environments, teams, and members | Organization-scoped environments, teams, and members |
| Provider keys | ${VAR} references in resources.yaml; plaintext credentials in etcd |
Encrypted at rest; operator-triggered in-place rotation | Encrypted at rest; operator-triggered in-place rotation |
| Budgets | — (rate and token limits only) | Per key, provider, environment, organization, and team | Per key, provider, environment, organization, and team |
| RBAC and audit | Local admin key; no organization layer | Organization roles, invitations, and audit history | Organization roles, invitations, and audit history |
| Operations | You operate the gateway | You operate the control plane and gateways | API7 operates the control plane; you operate gateways |
→ Want centralized governance, budgets, and a dashboard? Talk to API7 about AISIX Enterprise or AISIX Cloud, or book a demo.
🏗️ Architecture
A single Cargo workspace; the aisix-server crate builds one binary named aisix that
wires the crates together.
crates/
├── aisix-core Config, snapshot, resource model, resources.yaml source, errors
├── aisix-etcd Config provider + watch supervisor
├── aisix-gateway Hub & bridge, SSE parser, provider trait
├── aisix-proxy /v1/*, /mcp, /a2a handlers, routing, middleware
├── aisix-admin Read-only resource surface + playground + OpenAPI
├── aisix-provider-* openai · anthropic · azure-openai · bedrock · vertex
├── aisix-mcp MCP gateway — server registry, tool ACL, transports
├── aisix-a2a A2A agent gateway — agent cards, JSON-RPC bridge
├── aisix-ratelimit fixed-window + token accounting + concurrency (local | redis)
├── aisix-cache memory + redis backends
├── aisix-redis shared Redis connection for cache + rate limits
├── aisix-guardrails pre/post content-policy hooks
├── aisix-obs tracing, metrics, access log, exporters
└── aisix-server the `aisix` binary — bootstrap + CLI
🗺️ Roadmap
Highlights on the roadmap; tracked live in issues:
- Semantic (embedding-similarity) response caching
- More observability sinks — Langsmith, Helicone, Slack alerts
- Prompt templates managed as gateway resources
- Llama-Guard as a guardrail provider
Shipped since this list was last written: the MCP gateway, the A2A agent gateway, OIDC/JWT inbound auth, Redis-backed distributed rate limiting, and the Lakera, Presidio, PII, and OpenAI Moderation guardrails — see Features above.
🛠️ Development
Prerequisites: the Rust toolchain pinned in rust-toolchain.toml. Docker is only needed
for the tests that exercise etcd, Redis, or provider emulators.
cargo check --workspace
cargo fmt --check
cargo clippy --workspace -- -D warnings
cargo test --workspace
# Coverage (matches the CI gate)
cargo llvm-cov --workspace --lcov --output-path lcov.info
# Run locally against a resources.yaml (no etcd needed). Copy the Quickstart's two files
# and change resources_file to the local path, e.g. resources_file: ./resources.yaml
cargo run -p aisix-server --bin aisix -- --config config.local.yaml
# Check a resources file without starting a listener
cargo run -p aisix-server --bin aisix -- validate --resources resources.yaml
💬 Community
- Discord — discord.gg/dUmRZ7Rvf
- Issues & discussions — github.com/api7/aisix/issues
- Contributing — CONTRIBUTING.md
- Website — api7.ai/ai-gateway
If AISIX is useful to you, a ⭐ helps other engineers find it.
📄 License
AISIX AI Gateway MCP 질문
AISIX AI Gateway MCP를 Claude Code에 추가하려면 어떻게 하나요?
터미널에서 claude mcp add aisix -- docker run -i --rm ghcr.io/api7/aisix:1.3.0를 실행합니다. 모든 프로젝트에서 사용할 수 있게 하려면 --scope user를 추가합니다.
AISIX AI Gateway MCP를 Cursor에 추가하려면 어떻게 하나요?
~/.cursor/mcp.json를 열고 mcpServers 아래에 서버를 추가합니다. 위 설치 섹션에 표시된 Cursor 구성을 사용합니다.
게이트웨이를 재시작하지 않고 설정 변경 사항을 적용하려면 어떻게 해야 하나요?
resources.yaml 파일을 편집한 후 프로세스에 SIGHUP 신호를 보내면 원자적으로 설정을 다시 로드할 수 있습니다.
AISIX는 MCP server를 지원하나요?
네, AISIX는 등록된 업스트림 MCP server를 대상으로 서버별 도구 네임스페이스와 호출자별 액세스를 제공하는 MCP 게이트웨이 역할을 수행합니다.
OpenAI 형식을 사용하여 Anthropic 모델과 함께 AISIX를 사용할 수 있나요?
네, 게이트웨이가 OpenAI 또는 Anthropic 와이어 형식을 변환하므로, OpenAI SDK를 게이트웨이로 지정하여 다양한 제공업체에 액세스할 수 있습니다.
어떤 종류의 보안 및 가드레일이 포함되어 있나요?
콘텐츠 정책 준수, PII 탐지 및 비식별화 기능이 포함되어 있으며, OpenAI Moderation 및 AWS Bedrock Guardrails와 같은 제공업체와 통합됩니다.