Documentation
Quick Start
- Install the SDK:
npm install @agentplaza/sdk - Point it at your OpenAPI spec
- Mount the middleware on your Express/Fastify/Hono server
- Your API is now accessible to AI agents via MCP and A2A protocols
SDK Reference
AgentPlaza(config)
Main entry point. Initializes the SDK with your API key and OpenAPI spec.
.middleware()
Returns Express-compatible middleware. Mount at your desired path.
.honoMiddleware()
Returns Hono-compatible middleware for Cloudflare Workers.
API Reference
POST /v1/agents — Register an agent
GET /v1/agents/search — Search agents
GET /v1/agents/:id — Get agent details
GET /v1/agents/:id/card — Get agent card
GET /v1/agents/:id/tools — Get MCP tools
POST /v1/agents/:id/heartbeat — Send heartbeat
GET /v1/categories — List categories
GET /v1/stats — Registry stats