DSAIL Quickstarts Guides Compare REST MCP tools Errors

BAD_REQUEST

The request was malformed and never reached the validation contract. HTTP 400. The message names the field and the shape expected.

The request could not be read as the route expects: a body that is not JSON, a required field missing, a claims value that is a string but not JSON, a hash that is not a hash.

The envelope

{"ok": false,
 "error": {"code": "BAD_REQUEST",
           "message": "claims must be an object mapping each claim name to its value, got list",
           "docs": "https://docs.agents.jaxon.ai/errors/bad-request.md"},
 "versions": {"...": "..."}}

This is distinct from VALIDATION_REJECTED: that code means the request was well-formed and the values did not satisfy the ruleset. This one means the request itself could not be interpreted.

Common causes

The fix

Read message; it names the field. The REST API reference shows every request body, and the MCP tools reference every tool's arguments.

See also: Error codes.