# aimock

> Mocks LLM APIs, MCP tools, A2A agents, AG-UI streams, and vector databases on one local port so AI app tests run offline and deterministically.

## Facts

- **Provider:** [CopilotKit](https://www.copilotkit.ai)
- **Homepage:** https://github.com/CopilotKit/aimock
- **Official:** No
- **Verified:** Verified: link and access path checked, Nov 2026
- **Last checked:** 2026-11-28
- **Endpoint health:** Live (`ok`) · checked 2026-11-28T20:19:19Z
- **Access methods:** cli, api
- **Auth:** None (`none`)
- **Categories:** Code & DevTools (`code-devtools`)
- **Tags:** llm-mocking, test-fixtures, record-replay, mcp-testing, ci-testing, deterministic-tests, open-source
- **Streaming:** No · **Push notifications:** No

## Use it now

### CLI
- **Install (npm):** `npm install @copilotkit/aimock`
- **Docs:** https://github.com/CopilotKit/aimock#quick-start

### API
- **Auth:** None needed
- **Docs:** https://github.com/CopilotKit/aimock#quick-start

## Try this first

Ask your coding agent:

- Use aimock to record real API traffic: ‹what you need›
- Use aimock to validate fixture files offline: ‹what you need›

## Limitations

- no MCP server

## Skills (5)

- **Mock LLM Providers** (`mock-llm-providers`): Mocks OpenAI, Claude, Gemini, Bedrock, Azure, Vertex AI, Ollama, and other provider APIs from fixtures, streaming included.
- **Record and Replay** (`record-and-replay`): Records real API traffic through a proxy, saves it as fixtures, and replays it deterministically with the recorded timing.
- **Mock MCP Servers** (`mock-mcp-servers`): Mocks MCP tools, resources, and prompts with session management so MCP clients can be tested without real servers.
- **Mock A2A and AG-UI** (`mock-a2a-and-ag-ui`): Mocks A2A agent-to-agent conversations with SSE streaming and AG-UI event streams for testing agent backends and frontends.
- **Validate Fixtures** (`validate-fixtures`): Validates fixture files offline without starting a server and reports errors and warnings, with JSON output for CI.

## Alternatives

- [Retrace](https://agentswitchboard.dev/agents/retrace.md) (`retrace`): Both offer CLI and API. In common: record replay, ci, testing.
- [AWS Emulator](https://agentswitchboard.dev/agents/aws-emulator.md) (`aws-emulator`): Both offer CLI and API. In common: ci testing, mock, test.
- [Vally](https://agentswitchboard.dev/agents/microsoft-vally.md) (`microsoft-vally`): Both offer CLI and API. In common: ci testing, llm.
- [Endform](https://agentswitchboard.dev/agents/endform.md) (`endform`): Both offer CLI. In common: replay, test, ci.
- [promptfoo](https://agentswitchboard.dev/agents/promptfoo.md) (`promptfoo`): Both offer CLI and API. In common: ci, testing, llm.

All 8 alternatives: https://agentswitchboard.dev/agents/aimock/alternatives · Compare side by side: https://agentswitchboard.dev/compare?a=aimock&b=retrace&c=aws-emulator

## For agents

- Listing JSON: https://agentswitchboard.dev/api/agents/aimock
- Alternatives JSON: https://agentswitchboard.dev/api/agents/aimock/alternatives
- MCP server (organic, no auth): https://agentswitchboard.dev/api/mcp
- Site guide: https://agentswitchboard.dev/llms.txt · Full index: https://agentswitchboard.dev/llms-full.txt
- Canonical HTML page: https://agentswitchboard.dev/agents/aimock
