# bad-request

<Badge variant="warning">400 Bad Request</Badge> <Badge variant="muted">bad-request</Badge>

| Field | Value |
|---|---|
| **Type URI** | `https://docs.kordiam.app/docs/errors/bad-request` |
| **HTTP Status** | `400 Bad Request` |

## Description

The server cannot process the request due to a client error that does not fall under a more
specific category. This typically indicates malformed JSON, a missing request body, or another
structural problem with the request.

## Response Example

```json
{
  "type": "https://docs.kordiam.app/docs/errors/bad-request",
  "title": "Bad Request",
  "status": 400,
  "detail": "Invalid JSON format in request body",
  "instance": "/api/v2/elements",
  "traceId": "abc-123-def"
}
```

## Common Causes

- Invalid JSON syntax (e.g., trailing commas, unquoted keys, unclosed braces)
- Empty request body when a body is required
- Request body shape that cannot be read as the endpoint's documented request model

## How to Fix

1. Verify that your request body contains well-formed JSON; use a JSON linter or validator before sending.
2. Ensure the body is not empty when the endpoint expects a payload.
3. Map client data to the endpoint's documented request schema before retrying.
