# Update comment settings

`PATCH https://api.cademi.com.br/api/v3/settings/support/comments`

Operation ID: `settings.support.comments.update` · API v3

Updates the lesson comment settings. Only the fields included in the request are changed; omitted fields are left unchanged.

Setting `moderation_enabled` to `false` publishes every comment in the account that is pending moderation. The number of comments published is returned in `effects.approved_pending_comments`.

To avoid overwriting a newer version, send the `ETag` returned by the retrieve operation in the `If-Match` header. The header is optional; when it is omitted, the update is applied to the current revision.

Required permissions: `settings.update_support`.

## Parameters

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `If-Match` | header | string | no |  |

## Request body

Content type: `application/json`.

Schema: object.

## Responses

### 200

Returns the updated lesson comment settings and, in effects, the number of pending comments published by the change.

Body: `data`: SettingsSupportComments.

Fields of SettingsSupportComments:

| Field | Type | Required | Description |
|---|---|---|---|
| `cooldown_minutes` | integer | yes |  |
| `defaults` | object | yes |  |
| `enabled` | boolean | yes |  |
| `min_length` | integer | yes |  |
| `moderation_enabled` | boolean | yes |  |
| `object` | string, one of `settings` | yes |  |
| `open_in_new_tab` | boolean | yes |  |
| `placeholder` | string | yes |  |
| `revision` | string | yes |  |
| `sort` | string, one of `newest`, `oldest` | yes |  |
| `tags_enabled` | boolean | yes |  |
| `title` | string | yes |  |

### 401

The credential is missing, malformed, expired, or revoked.

Body: Error.

### 403

The current credentials do not have the permission required by this operation.

Body: Error.

### 412

The comment settings have changed since the supplied revision was retrieved.

Body: Error.

### 422

The request body or query parameters failed validation.

Body: ValidationFailed.

Full schema: https://cademi.dev/openapi/v3.json
