Skip to main content
Glama

AgentForge

一个 API 密钥。300+ AI 智能体。零配置。

AgentForge 是一个统一的 AI 智能体 API 网关和市场。使用单个 API 密钥即可访问数百个 AI 智能体——无需为每个智能体管理单独的 API 密钥、身份验证或计费。

在线演示 | API 文档 | 浏览智能体

为什么选择 AgentForge?

大多数 AI 智能体平台要求你为使用的每个智能体管理单独的 API 密钥、身份验证流程和计费。AgentForge 为你提供一个密钥,掌控一切

  • 统一 API — 通过单个 REST 端点调用任何智能体

    • 300+ 智能体 — 预装了来自 GitHub 和 HuggingFace 的热门智能体

      • 创作者经济 — 发布你自己的智能体并赚取收入(创作者分成 90%)

        • 为开发者打造 — RESTful API、流式传输支持、API 密钥认证、速率限制

          • MCP 支持 — 将 AgentForge 用作模型上下文协议 (MCP) 服务器,从 Claude、Cursor 和其他 MCP 客户端访问所有智能体

          • 快速入门

          • 使用 API(无需安装)

          • # 1. Get your API key at https://patreon.zeabur.app/#/settings/api-keys
            # 2. Call any agent:
            curl -X POST https://patreon.zeabur.app/api/agents/AGENT_ID/invoke \
              -H "Authorization: Bearer af_k_your_key_here" \
              -H "Content-Type: application/json" \
              -d '{"messages": [{"role": "user", "content": "Hello!"}]}'

            Python

            import requests
            response = requests.post(
                "https://patreon.zeabur.app/api/agents/AGENT_ID/invoke",
                headers={"Authorization": "Bearer af_k_your_key_here"},
                json={"messages": [{"role": "user", "content": "Hello!"}]}
            )
            print(response.json())

            JavaScript

            const response = await fetch(
              "https://patreon.zeabur.app/api/agents/AGENT_ID/invoke",
              {
                method: "POST",
                headers: {
                  "Authorization": "Bearer af_k_your_key_here",
                  "Content-Type": "application/json",
                },
                body: JSON.stringify({
                  messages: [{ role: "user", content: "Hello!" }],
                }),
              }
            );
            const data = await response.json();

            MCP 服务器(模型上下文协议)

            AgentForge 内置了一个 MCP 服务器 (mcp/server.ts),将所有 300 多个智能体作为 MCP 工具公开。这使得任何兼容 MCP 的客户端(Claude Desktop、Cursor、Continue 等)无需额外配置即可发现并调用智能体。

            公开的 MCP 工具

            | 工具 | 描述 | | -------------------- | ----------------------- | | list_agents | 列出市场上的所有智能体(可选分类/限制过滤器) | | get_agent | 通过 ID 获取特定智能体的详细信息 | | invoke_agent | 使用聊天补全风格的消息数组调用任何智能体 | | check_agent_health | 检查特定智能体的健康状况/可用性 | | get_platform_stats | 检索平台汇总统计信息 |

            在本地运行 MCP 服务器

            git clone https://github.com/doggychip/agentforge.git
            cd agentforge
            npm install
            
            # Set your AgentForge API key (get one at https://patreon.zeabur.app/#/settings/api-keys)
            export AGENTFORGE_API_KEY=af_k_your_key_here
            
            # Start the MCP server (communicates over stdio)
            npm run mcp:start

            连接到 Claude Desktop

            将以下内容添加到你的 claude_desktop_config.json 中 (macOS 上位于 ~/Library/Application Support/Claude/claude_desktop_config.json):

            {
              "mcpServers": {
                "agentforge": {
                  "command": "npx",
                  "args": ["tsx", "/path/to/agentforge/mcp/server.ts"],
                  "env": {
                    "AGENTFORGE_API_KEY": "af_k_your_key_here"
                  }
                }
              }
            }

            重启 Claude Desktop。你现在将在 MCP 连接器面板中看到可用的 AgentForge 工具。

            连接到其他 MCP 客户端

            任何支持 stdio 传输的 MCP 客户端都可以连接到 AgentForge:

            # Generic stdio invocation
            AGENTFORGE_API_KEY=af_k_your_key_here npx tsx /path/to/agentforge/mcp/server.ts

            MCP 服务器的环境变量

            | 变量 | 必需 | 描述 | | --------------------- | ------------------- | ----------------------------------------- | | AGENTFORGE_API_KEY | 是(用于 invoke_agent) | 你的 AgentForge API 密钥 | | AGENTFORGE_BASE_URL | 否 | 覆盖基础 URL(默认:https://patreon.zeabur.app) |

            功能

            面向用户

            • 浏览并发现 300 多个 AI 智能体、工具和 API

              • 一个 API 密钥即可访问所有智能体

                • 免费和付费智能体,定价透明

                  • 支持实时响应的流式传输

                    • 使用情况跟踪和计费历史记录

                    • 面向创作者

                      • 发布无限数量的智能体并设置你自己的定价

                        • 90% 收入分成(10% 平台费用)

                          • 通过 Stripe Connect 支付到你的银行账户

                            • 包含订阅者指标的分析仪表板

                              • API 代理 — 我们处理身份验证、速率限制和计费

                              • 平台

                                • Google OAuth + 电子邮件/密码身份验证

                                  • 双重身份验证 (TOTP)

                                    • 速率限制(每密钥每小时 1000 次请求,每天 10000 次请求)

                                      • 智能体健康监控

                                        • 从 GitHub 热门和 HuggingFace 自动导入

                                        • API 端点

                                        • | 方法 | 端点 | 描述 |

                                        • |--------|----------|-------------|

                                        • | POST | /api/agents/:id/invoke | 调用智能体 |

                                        • | GET | /api/agents | 列出所有智能体 |

                                        • | GET | /api/agents/:id | 获取智能体详情 |

                                        • | GET | /api/agents/:id/health | 检查智能体健康状况 |

                                        • | GET | /api/stats | 平台统计信息 |

                                        • 完整 API 文档:patreon.zeabur.app/#/docs

                                        • 自托管

                                        • 先决条件

                                          • Node.js 20+

                                            • PostgreSQL

                                            • 设置

                                            • git clone https://github.com/doggychip/agentforge.git
                                              cd agentforge
                                              npm install
                                              
                                              # Set environment variables
                                              export DATABASE_URL=postgresql://user:password@host:5432/agentforge
                                              
                                              # Start development server (auto-migrates and seeds)
                                              npm run dev

                                              环境变量

                                              | 变量 | 必需 | 描述 | | ----------------------- | -- | ------------------- | | DATABASE_URL | 是 | PostgreSQL 连接字符串 | | STRIPE_SECRET_KEY | 否 | 用于支付的 Stripe API 密钥 | | STRIPE_WEBHOOK_SECRET | 否 | Stripe Webhook 签名密钥 | | GOOGLE_CLIENT_ID | 否 | Google OAuth 客户端 ID | | GOOGLE_CLIENT_SECRET | 否 | Google OAuth 客户端密钥 | | SMTP_HOST | 否 | 用于电子邮件的 SMTP 服务器 | | SMTP_USER | 否 | SMTP 用户名 | | SMTP_PASS | 否 | SMTP 密码 |

                                              部署到 Zeabur

                                              1. 推送到 GitHub

                                                1. Zeabur 中创建项目

                                                  1. 导入仓库 + 添加 PostgreSQL 服务

                                                    1. Zeabur 会自动注入 DATABASE_URL

                                                    2. 技术栈

                                                      • 前端:React 18, Tailwind CSS, shadcn/ui, TanStack Query, wouter

                                                        • 后端:Express 5, Drizzle ORM, Passport

                                                          • 数据库:PostgreSQL

                                                            • 支付:Stripe Connect

                                                              • 认证:bcrypt, Google OAuth, TOTP 2FA

                                                                • 部署:Docker / Zeabur

                                                                  • MCP:@modelcontextprotocol/sdk (TypeScript)

                                                                  • 项目结构

                                                                  • agentforge/
                                                                    ├── client/src/          # React frontend
                                                                    │   ├── pages/           # Route pages
                                                                    │   ├── components/      # Shared components
                                                                    │   └── hooks/           # Auth, query hooks
                                                                    ├── mcp/
                                                                    │   └── server.ts        # MCP server (5 tools over stdio)
                                                                    ├── server/
                                                                    │   ├── routes.ts        # API endpoints
                                                                    │   ├── storage.ts       # Database layer
                                                                    │   └── db.ts            # Connection + migrations
                                                                    ├── shared/
                                                                    │   └── schema.ts        # Drizzle schema + types
                                                                    └── Dockerfile

                                                                    贡献

                                                                    欢迎提交 Pull Request。对于重大更改,请先开启一个 Issue。

                                                                    许可证

                                                                    MIT

Install Server
A
security – no known vulnerabilities
F
license - not found
A
quality - A tier

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/doggychip/agentforge'

If you have feedback or need assistance with the MCP directory API, please join our Discord server