API Reference
All MisarCoder gateway endpoints — OpenAI-compatible chat, Anthropic messages, model discovery, the research agent, and A2A.
The MisarCoder gateway is served at https://api.misar.dev. Authenticate every request with Authorization: Bearer <API_KEY> (see Authentication).
Chat Completions
POST /v1/chat/completions — OpenAI-compatible, streaming or JSON
Models
GET /models and GET /models/catalog
Anthropic Messages
POST /v1/messages — Anthropic-compatible with claude-* passthrough
Research Agent
GET /api/v1/agent/stream — SSE research pipeline
A2A Protocol
Agent card discovery and task lifecycle
Endpoint summary
| Method | Path | Description |
|---|---|---|
POST | /v1/chat/completions | OpenAI-compatible chat completions (stream or JSON). |
POST | /v1/messages | Anthropic-compatible messages; claude-* models pass through to Anthropic. |
POST | /v1/messages/count_tokens | Count tokens for an Anthropic-format request. |
POST | /v1/embeddings | OpenAI-compatible embeddings proxy. |
POST | /v1/moderations | OpenAI-compatible moderation proxy. |
POST | /v1/responses | OpenAI Responses API (stateful). |
GET | /models | List available model ids. |
GET | /models/catalog | Full model catalog with metadata (incl. context_window). |
GET | /api/v1/agent/stream | Streaming research agent (SSE). |
GET | /.well-known/a2a-agent-card | A2A agent card discovery. |
GET | /agents, /agents/{id} | A2A agent listing / detail. |
POST | /agents/{id}/tasks | Submit an A2A task. |
GET | /health | Gateway health check. |
MCP management endpoints
The gateway also exposes /mcp/configure, /mcp/servers, /mcp/tools, /mcp/call, and /mcp/remove for managing MCP servers that MisarCoder itself connects to. These are distinct from the misarcoder_ask / misarcoder_complete client tools documented under MCP.