@the-next-ai/ai-gateway
v1.0.10
Published
TypeScript Fastify AI protocol gateway for OpenAI, Anthropic, Gemini, MCP and agent workflows.
Maintainers
Readme
Next AI Gateway
基于 TypeScript + Fastify 的 AI 协议网关,支持 OpenAI、Anthropic、Gemini、MCP Gateway 与事件驱动 Agent。
快速开始
npm install
npm run dev生产运行:
npm run build
npm startDocker Compose:
export AUTH_STATIC_API_KEYS='replace-with-gateway-client-key'
export MANAGER_API_KEY='replace-with-manager-admin-key'
export OPENAI_API_KEY='sk-...'
export MCP_REMOTE_KEY='replace-with-strong-mcp-key'
export TOOLHUB_MANAGEMENT_TOKEN='replace-with-toolhub-admin-key'
export MINIMAX_API_KEY='replace-with-minimax-api-key'
export ANTHROPIC_API_KEY='replace-with-tool-search-provider-key'
docker compose up --build主要能力
- OpenAI
chat/completions、responses、embeddings、moderations、images/generations - Anthropic
messages - Gemini
generateContent/streamGenerateContent - 跨协议转换、供应商 fallback、provider plugin、健康检查、指标、幂等、并发隔离、熔断与重试
- MCP Gateway、MCP WebSocket RPC、事件驱动 Agent
- HTTP / WebSocket / gRPC / stdio 外部配置源与事件投递
文档
npm 发布
本仓库包含 .npmignore、prepack 构建、GitHub Actions CI/CD,以及可指定版本发布的 release 命令:
npm run release -- 1.2.3更多选项见 发布与 CI/CD。
