# Feedback

> Report harmful content, rate responses, and file bug reports.

Source: https://maincode.com/docs/python-client-sdk-feedback
Section: Client SDK · Matilda documentation

---

## `feedback.report(...)`

Reports a message for harmful, inaccurate, off-topic, or privacy-violating content.

```python
await client.feedback.report(
    message_id="msg-456",
    conversation_id="conv-123",
    reason="inaccurate",
    comment="The capital of Australia is Canberra, not Sydney.",
)
```

### Parameters

| Field | Type | Description |
| - | - | - |
| `message_id` | `str` | The message being reported. |
| `conversation_id` | `str` | The conversation containing the message. |
| `reason` | `'harmful' \| 'inaccurate' \| 'off_topic' \| 'privacy' \| 'other'` | Report reason. |
| `comment` | `str \| None` | Optional additional context. |

Returns a `dict` (e.g. `{"reportId": ..., "acknowledgedAt": ...}`).

## `feedback.response(...)`

Submits general response feedback (positive/negative sentiment with platform context).

```python
await client.feedback.response(
    message_id="msg-456",
    conversation_id="conv-123",
    comment="Great answer!",
    platform="web",
    app_version="1.0.0",
)
```

### Parameters

| Field | Type | Description |
| - | - | - |
| `message_id` | `str` | The message being rated. |
| `conversation_id` | `str` | The conversation containing the message. |
| `comment` | `str \| None` | Optional feedback text. |
| `platform` | `'web' \| 'ios' \| 'android' \| 'unknown' \| None` | Client platform. |
| `app_version` | `str \| None` | App version string. |
| `build_number` | `str \| None` | Build number. |

Returns a `dict` (e.g. `{"feedbackId": ..., "acknowledgedAt": ...}`).

## `feedback.report_bug(...)`

Files a bug report from your application. Reports land as GitHub issues in the internal feedback repository — titled `[SDK] <title>` and labelled `sdk-feedback` — so engineering can triage them directly.

The SDK automatically stamps the report with its package name (`matilda-client`), package version, and the Python runtime version, so you usually only need `title` and `description`. Pass the optional fields to override or supply anything else.

```python
await client.feedback.report_bug(
    title="stream() silently closes on 429",
    description="The stream closes without error when the API returns 429.",
    reproduction="Call chat.stream() in a loop until rate-limited; observe the close event.",
)
```

### Parameters

| Field | Type | Description |
| - | - | - |
| `title` | `str` | One-line summary of the bug (required, max 200 chars). |
| `description` | `str` | What went wrong (required, max 4000 chars). |
| `reproduction` | `str \| None` | Optional steps to reproduce (max 4000 chars). |
| `package` | `str \| None` | Reporting package name — defaults to this SDK's package name. |
| `package_version` | `str \| None` | Reporting package version — defaults to this SDK's version. |
| `platform` | `'web' \| 'ios' \| 'android' \| 'unknown' \| None` | Client platform. |
| `app_version` | `str \| None` | Your application's version string. |
| `idempotency_key` | `str \| None` | Optional key (max 128 chars) so retries don't create duplicate issues. |

Returns a `dict` (e.g. `{"feedbackId": ..., "acknowledgedAt": ...}`).
