# Get a document version

`GET /v1/documents/{id}/versions/{versionId}`

Returns one saved version of a document's body as Markdown.

Scope: `docs:read`.

## Request

```bash
curl "https://api.lydie.co/v1/documents/01JCQ3V5MZ8G4ZK2X7T9R6N1PB/versions/01JCQ3V5MZ8G4ZK2X7T9R6N1PB" \
  -H "Authorization: Bearer $LYDIE_TOKEN"
```

## Path parameters

- `id` (ULID, required)
- `versionId` (string, required): (1–64 chars)

## Response

- `version` (DocumentVersion, required)
  - `id` (string, required)
  - `documentId` (ULID, required)
  - `kind` (string, required): auto: editing went idle. before_write: the state before an API write or restore. restore: the result of a restore. One of: `auto`, `before_write`, `restore`.
  - `authors` (string[], required): Actor refs of whoever changed the body since the previous version.
  - `restoredFrom` (string, required, nullable)
  - `sizeBytes` (integer, required)
  - `createdAt` (string, required)
- `markdown` (string, required)

```json
{
  "version": "3f9c2a71",
  "markdown": "# Meeting notes\n\n- Ship the developer docs"
}
```

Errors use the envelope described at https://developers.lydie.co/errors.md.
