Limits and errors
Error codes What they mean
Xale's MCP server answers in two layers: protocol errors (HTTP status and a JSON-RPC error) and tool errors (a normal result with isError: true). The OAuth endpoints answer with standard OAuth error codes. Look up the message you got below.
Two layers
- Protocol errors come back as a JSON-RPC
errorobject,{ "code": …, "message": "…" }, often with an HTTP status other than 200. - Tool errors come back as a normal
tools/callresultwithisError: trueand one plain sentence incontent[0].. See Tool errors · shared shapes.text
HTTP and JSON-RPC errors
| HTTP | Code | Message | What to do |
|---|---|---|---|
401 | -32001 | "Sign in to Xale to use this connector." | Start OAuth from the WWW-Authenticate header. With a token that's expired, revoked or wrong, the header adds error="invalid_ and "Connect the app to Xale again." |
403 | -32600 | "This origin may not call Xale's MCP server." | A browser call from an origin Xale doesn't accept. Call from your server, or from loopback. |
400 | -32600 | "Unsupported MCP-Protocol-Version. Supported: 2025-11-25, 2025-06-18." | Send a supported version. |
400 | -32600 | "Batches are not supported; send one message per POST." | One message per POST. |
400 | -32600 | "Not a valid JSON-RPC 2.0 message." | Check jsonrpc, method, params and id. |
400 | -32600 | "{method} is a request and needs an id." | Only notifications/… may leave out id. |
400 | -32700 | "Parse error." or "The request body couldn't be read." | Send valid JSON. |
413 | -32600 | "This request is over Xale's 256 KB limit. …" | Split it: see Size limits. |
429 | -32000 | "Too many requests on this connection. Try again in a minute." | Wait 60 seconds (Retry-After: 60). |
429 | -32000 | "Too many requests. Try again in a minute." | Wait 60 seconds. |
503 | -32000 | "Xale is temporarily unavailable. Try again shortly." | Retry shortly. |
405 | No body, Allow: POST, OPTIONS | Use POST only: the server is stateless. |
A notification is accepted with 202 and no body.
Errors inside a 200
| Code | Message |
|---|---|
-32601 | "Method not found: {method}" |
-32602 | "Unknown tool: {name}" |
-32602 | "Unknown prompt." |
-32002 | "Resource not found." |
Tool error texts to recognise
| Starts with | Means |
|---|---|
| "This connection wasn't given permission to …" | The scope is missing. The person reconnects and leaves that permission ticked. |
| "Xale's AI connector needs Xale Pro." | See Pro required. |
| "Invalid arguments for {tool}: check …" | Up to five fields, each with its rule; your values are never repeated. |
| "Invalid arguments for {tool}: … must be a single id from another Xale tool." | An id field holds something other than one id. |
| "Nothing with that id is available in this Xale." | Missing, in Trash or kept away. See Hidden items. |
| "This call is still being made." / "Xale can't tell whether an earlier call…" / "This requestId was already used for different content…" | requestId states. See Request ids. |
| "… (ref 1a2b3c4d)" | An internal failure, with a reference. For a read: "Xale couldn't complete that. Try again shortly (ref …)." For a write: see Partial saves. |
OAuth errors
The registration, token and revocation endpoints answer { "error": "…", "error_, usually with HTTP 400.
error | Example error_ |
|---|---|
invalid_ | "The parameter … appears more than once." |
invalid_ | "Unknown client." |
invalid_ | "The authorization code expired. Connect again." · "The refresh token was already used." · "This connection was removed. Connect the app to Xale again." · "This Xale account can't be used right now." |
invalid_ | On refresh: "Not supported: …" or "The requested scope was not granted." |
invalid_ | "Wrong resource." |
unsupported_ | "Use authorization_code or refresh_token." |
invalid_ | A return address that isn't an accepted app callback or loopback |
invalid_ | A registration Xale can't accept |
slow_ (429) | "Too many requests. Try again in a minute." |
temporarily_ (503) | "Xale couldn't complete that. Try again shortly." |
Token lifetimes and refresh: Tokens · expiry and refresh.
- Checked against main
8aef9b15