## Save the module configuration (tenant:settings:write)

`PUT /api/dms/v1/config`

Module: DMS · operationId: `setConfig` · Tag: Configuration · Auth: access token (`Authorization: Bearer <accessToken>`)

### Request body

`application/json` (required)

- `active` (boolean): The module is active for the tenant
- `classification` (object): Document classifier of incoming documents (Original-Eingangsbelege); omitted = defaults
  - `enabled` (boolean): The document classifier is on (default `true`)
  - `minConfidence` (number): Proposals from this confidence on are taken over; below it they wait for review (default `0.85`; max 1)
- `defaultRetentionDays` (integer): Default retention in days
- `defaultStorageClass` (string): Default storage class
- `extraction` (object): Text extraction settings; omitted = defaults
  - `enabled` (boolean): Text extraction is on (default `true`)
  - `layoutCategories` (array of string): Document types whose digital pages still go to AI OCR for layout
  - `maxPages` (integer): Page limit per document (default `200`; max 2000)
- `wormCompliance` (boolean): WORM compliance mode

Example:

```json
{
  "active": true,
  "classification": {
    "enabled": true,
    "minConfidence": 0.85
  },
  "defaultRetentionDays": 3650,
  "defaultStorageClass": "STANDARD",
  "extraction": {
    "enabled": true,
    "layoutCategories": [
      "delivery_note"
    ],
    "maxPages": 200
  },
  "wormCompliance": true
}
```

### Responses

- **200** Saved (`application/json`)
- **400** Error (`application/json`)

Fields of the 200 answer:

- `status` (string): Always saved

Example 200 answer:

```json
{
  "status": "saved"
}
```

### Example request

```bash
curl -X PUT 'https://api.mbcom.cloud/api/dms/v1/config' \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H 'Content-Type: application/json' \
  --data '{"active":true,"classification":{"enabled":true,"minConfidence":0.85},"defaultRetentionDays":3650,"defaultStorageClass":"STANDARD","extraction":{"enabled":true,"layoutCategories":["delivery_note"],"maxPages":200},"wormCompliance":true}'
```
