# Errors and limits

> What assistants see when something goes wrong, and how request limits work.

The MCP server uses the same API keys, sign-in rules and limits as the [REST API](https://tirver.com/help/api.md), so the same ideas apply.

## How the server answers

The server speaks Streamable HTTP in stateless JSON-RPC. Each `POST` carries one JSON-RPC message, or a batch of up to 20, and gets a JSON reply. Notifications get `202` with no body. There is no session and no event stream, so `GET` and `DELETE` answer `405`.

## Errors

Problems before the request reaches the MCP protocol use the HTTP status and the same JSON error body as the REST API, with a `request_id`.

| Status | Code | What to do |
|---|---|---|
| 401 | `missing_api_key` or `invalid_api_key` | Create a new key and update the client. |
| 413 | `payload_too_large` | Send a smaller request. The limit is 256 KB. |
| 429 | `rate_limited` | Wait for `Retry-After` seconds. |
| 500 | `internal_error` | Try again in a moment. |

Protocol mistakes are JSON-RPC errors: `-32700` for a body that is not JSON, `-32600` for an invalid request, `-32601` for an unknown method, `-32602` for invalid parameters or an unknown tool, and `-32002` for a resource that is not found.

When a tool itself fails, because an argument is wrong, the record does not exist, the key lacks the scope, the module is switched off or a limit was hit, the assistant gets a normal result marked `isError` with a plain message it can read to you. Ask it to try again, or to explain what it needs.

## Limits

- 120 requests a minute per key. REST and MCP requests made with the same key share this.
- `ask` is limited to 10 a minute per key, on top of the 120.

Limits are counted per server instance, so they are best effort. Long searches across many conversations are best done in several short steps. See [rate limits](https://tirver.com/help/api/rate-limits.md) for the headers and the full explanation.

## Logs

Tirver records every request, including rejected ones, with the key prefix, the tool name and the status, so problems can be investigated. It does not record arguments, results or the key itself.

Source: https://tirver.com/help/mcp/limits
