# Update a question

`PATCH https://api.cademi.com.br/api/v3/products/{product_id}/questions/{question_id}`

Operation ID: `questions.update` · API v3

Reopens a question or changes whether it is pinned. The question text belongs to the user and cannot be changed.

Setting `status` to `open` returns the question to the queue of questions awaiting a reply and requires the `questions.reopen` permission. Any published reply remains visible. Changing `pinned` requires the `questions.pin` permission.

Send the `ETag` returned by the retrieve operation in the `If-Match` header to avoid overwriting a newer version.

Required permissions: `questions.update`, `questions.reopen`, `questions.pin`.

## Parameters

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `product_id` | path | string | yes |  |
| `question_id` | path | string | yes |  |
| `If-Match` | header | string | no |  |

## Request body

Content type: `application/json`.

| Field | Type | Required | Description |
|---|---|---|---|
| `pinned` | boolean | no |  |
| `status` | string, one of `open` | no |  |

## Responses

### 200

Returns the updated question.

### 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.

### 404

The question was not found in the specified product or is not accessible with the current credentials.

Body: Error.

### 412

The question has 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
