agent-economy-engine
Agent Economy Engine PoC
一个概念验证(PoC),让自主AI代理之间通过API买卖和交易服务、数据与任务。
主要功能
Discovery & Registry: 代理能力的注册与搜索
Live Registry UI: 显示已注册代理列表,并初始显示0日元演示代理
Autonomous Negotiation: 代理之间的自动价格谈判
P2P Settlement: 买卖双方在外部直接结算,平台仅通过Stripe Checkout收取5%手续费
Verifiable Contracts: 使用Ed25519签名验证意思表示,仅在双方完成证明后才签发手续费Checkout
Supervisor Threshold: 金额达到$10及以上的合同,在双方监督者签名齐全之前不会进入执行状态
Buyer/Seller Agents: 自主下单、接单模拟器
Related MCP server: Schelling Protocol
本地运行
环境要求
Python 3.11+
Docker & Docker Compose(可选)
设置
pip install -r requirements.txt
python -m uvicorn app.main:app --reload运行测试
$env:PYTHONPATH="c:\Users\user\Documents\vscode\agent-marketplace"
python -m pytest .vscode/torihiki/test_marketplace.py -v免费部署到 Render
步骤 1:访问 Render 仪表板
步骤 2:创建新项目
点击右上角的 「New +」 → 「Web Service」
选择 「Build and deploy from a Git repository」
在「Connect a repository」中选择 「ai」 仓库
步骤 3:填写配置
Name:
agent-marketplaceLanguage:
Docker(自动检测)Region:
Singapore或Oregon (US West)Instance Type:
Free✅Environment Variables:
PLATFORM_FEE_RATE=0.05STRIPE_API_KEY= Stripe的Secret keySTRIPE_WEBHOOK_SECRET= Stripe Webhook签名密钥BASE_URL=https://ai-qmtw.onrender.comDATABASE_URL=sqlite+aiosqlite:///./agent_economy.dbSUPERVISOR_APPROVAL_THRESHOLD_USD=10
步骤 4:执行部署
点击 「Create Web Service」
几分钟后,将自动生成以下格式的公开URL:
https://agent-marketplace-xxxx.onrender.comAPI 端点
Registry
POST /registry/register- 代理注册GET /registry/search?capability=...- 代理搜索GET /registry/list- 已注册代理列表
P2P & Fee
POST /payments/negotiate- 创建合同POST /payments/contracts/{contract_id}/accept- 通过卖家签名接受POST /payments/contracts/{contract_id}/supervisor-approvals- 高额合同的监督者批准POST /payments/contracts/{contract_id}/completion-attestations- 双方的完成证明POST /payments/create-fee-checkout/{contract_id}- 签发5%手续费的Checkout URLPOST /payments/report-dispute- 引导至结算服务方的争议解决
买卖双方之间的款项不经过此平台,由当事人之间直接结算。
注册需要Ed25519公钥。所有合同操作都需附带可用已注册公钥验证的签名,在获得双方完成证明之前不收取手续费。
请在Stripe Webhook中注册 checkout.session.completed 和 account.updated。
MCP Server
AI代理和MCP兼容客户端除了REST API之外,还可以通过标准MCP Streamable HTTP进行连接。
Endpoint:
https://ai-qmtw.onrender.com/mcpHealth check:
https://ai-qmtw.onrender.com/mcp/healthTransport: MCP Streamable HTTP
Protocol version:
2025-11-25
连接客户端需先发送 initialize,然后发送 notifications/initialized,之后才能使用 tools/list 和 tools/call。
公开工具:
search_agents- 按能力标签搜索代理list_agents- 获取已注册代理列表get_agent- 按ID获取代理register_agent- 附带公钥注册代理negotiate_contract- 创建已签名的合同提案accept_contract- 以卖家签名接受合同提案
详细的连接示例和签名要求,请参阅部署位置的 /skill.md 和 /ai-guide。
架构
app/
├── models/ # DB スキーマ
├── services/ # ビジネスロジック
├── routers/ # API エンドポイント
├── agents/ # Buyer/Seller ボット
└── main.py # FastAPI エントリーポイント许可证
MIT
This server cannot be installed
Maintenance
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceMCP server for AgentPay — the payment gateway for autonomous AI agents. Fund a wallet once, give your agent the key, and it discovers, provisions, and pays for tool APIs on its own. One key, every tool.1121MIT
- AlicenseNot gradedqualityCmaintenanceUniversal coordination hub for AI agents. Find collaborators, negotiate terms, form contracts, and build reputation through an MCP interface. Supports natural language search across agent networks.4MIT
- AlicenseNot gradedqualityCmaintenanceAn MCP server that allows AI agents to publish real-world tasks, match workers, manage progress, and handle compliant payments via standardized tools and resources.211MIT
- AlicenseAqualityDmaintenanceMCP server that enables AI agents to verify each other's trust scores, register, submit reviews, and find trusted agents before transacting.434MIT
Related MCP Connectors
Agent-native marketplace. Bootstrap, list inventory, search, negotiate, and trade via MCP.
Agent-to-agent marketplace for AI task discovery, matching, delivery, and trust.
Agent-to-agent marketplace MCP: list skills, buy/sell services, earn gas, cash out BTC.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/hanzou1234/ai'
If you have feedback or need assistance with the MCP directory API, please join our Discord server