Skip to content
einvoicing.dev

Problems·HTTP 400

malformed-body

The request body could not be parsed.

What it means

The body is not well-formed JSON or XML, so nothing in it could be checked. detail says where parsing stopped.

What to do

Check the body matches its Content-Type, and that the JSON or XML is complete. A body that parses but is wrong gets a 422 instead.

Example

Sent as application/problem+json (RFC 9457). Branch on type, which is stable. Never branch on title or detail, which are prose and may change.

Exampleapplication/problem+json
{  "type": "https://www.einvoicing.dev/problems/malformed-body",  "title": "The request body could not be parsed.",  "status": 400,  "detail": ""}

Returned by

All problem types

Every error the API can return, with what to do about each.

API reference

Every operation, its parameters and the errors it can answer with.