# Check a series

```http
POST https://trydimmi.com/api/v1/series/{series}/check
```

## Authorization

Send an API token as `Authorization: Bearer <token>`.
The token needs: `series:read`.

## Path parameters

- `series` (string, required): Id of the series, starting with srs_, such as srs_01jx2m8k4t. Find it with GET /series.

## Body

- `spec` (any): A definition to check instead of the saved working copy.

## Response 200 (OK)

- `data` (object, required)
  - `object` (string, required): The kind of record this is, the same for every record of its kind, such as article.
  - `problems` (object[] | null, required): What the series misses before it can go live, each with a code, a message and the step and field it is about; empty when it is ready.
    - `code` (string, required): Code of what the series is missing before it can go live, such as loop, entry_missing or step_unreachable.
    - `field` (string): The field of the step the problem is about. Left out when it is not about one field.
    - `message` (string, required): A sentence explaining the problem, to show beside the step.
    - `node_id` (string): Id of the step the problem is about. Left out when it concerns the whole series.

## Response default (Error)

- `code` (string, required): Stable code for programs to tell errors apart, such as validation_failed or internal_error.
- `errors` (object): Each rejected field mapped to its messages. Only present when the input was invalid.
- `message` (string, required): What went wrong, in words safe to show a person.

## Example request

```bash
curl --request POST \
  --url 'https://trydimmi.com/api/v1/series/{series}/check' \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "spec": null
}'
```

## Example response

```json
{
  "data": {
    "object": "<string>",
    "problems": [
      {
        "code": "<string>",
        "field": "<string>",
        "message": "<string>",
        "node_id": "<string>"
      }
    ]
  }
}
```

---

Index of all dimmi docs: https://trydimmi.com/llms.txt (full text: https://trydimmi.com/llms-full.txt)
