# Send feedback

`POST https://api.paxalabs.com/v1/feedback`

POST /v1/feedback reports a wrong output, an API problem, or a platform issue to the Paxa team, tied to the requests it names.

Name the requests a report is about with their `x-request-id` values, or a live session's connection id. The ids let the team trace each request in the account's logs. For a wrong output, add an example with the exact input, the output you received, and the output you expected.

A rating on at least one request id is a complete report and the quickest signal after checking an output. Ratings feed the team's quality measures and stay open. A report with a message or an example is triaged, and [GET /v1/feedback](https://paxalabs.com/docs/api/feedback-list) returns its status and the team's note.

Feedback costs no credits and sits outside the rate limit. Each account can send 50 written reports and 1,000 rating-only reports in any 24 hours. Past either cap the report answers [429 feedback_limit](https://paxalabs.com/docs/errors#feedback_limit) and nothing is stored. Reports take no Idempotency-Key. Before sending one again, check [GET /v1/feedback](https://paxalabs.com/docs/api/feedback-list) with `request_id`.

## Headers

- `authorization` (Bearer pxa_..., required): Authorization: Bearer pxa_... (recommended).
- `x-api-key` (pxa_..., optional): Alternative to the Authorization header. Ignored when Authorization is present.

See authentication at https://paxalabs.com/docs/authentication.

## Body

- `kind` ("model" or "api" or "platform" or "other", required): What the report is about. Use model when an output was wrong or poor, api when the API misbehaved, platform for the dashboard, billing, or docs, and other for anything else.
- `rating` ("good" or "bad", optional): Your judgment of the output the request ids name. A rating alone is a complete report when request_ids names at least one request.
- `message` (string, optional, up to 10,000 characters): What happened and what you expected, in plain text or Markdown.
- `request_ids` (array of strings, optional): Up to 20 x-request-id values the report is about, or the connection id of a live session. They link the report to the requests in your logs.
- `example` (object, optional): A worked case as text, with the exact input, the output you received, and the output you expected.
  - `example.input` (string, optional, up to 10,000 characters): The input you sent.
  - `example.output` (string, optional, up to 10,000 characters): The output you received.
  - `example.expected` (string, optional, up to 10,000 characters): The output you expected instead.

## Response

- `id` (string, required): Report id. Pass it as before to list older reports.
- `kind` ("model" or "api" or "platform" or "other", required): What the report is about.
- `rating` ("good" or "bad" or null, required): The rating sent, or null.
- `message` (string or null, required): The message as stored, or null.
- `request_ids` (array of strings, required): The request ids sent, lowercased, deduplicated, and sorted.
- `example` (object, required): The example as stored; every field is null without one.
  - `example.input` (string or null, required): The example input, or null.
  - `example.output` (string or null, required): The example output, or null.
  - `example.expected` (string or null, required): The expected output, or null.
- `source` ("api" or "app", required): api: sent to this endpoint with a key. app: sent from the dashboard.
- `status` ("open" or "resolved", required): A report is open until the team has acted on it, and resolved from then on. A report that carries only a rating feeds quality measures and stays open.
- `resolution` (string or null, required): The team's note on the outcome; null when none was written.
- `created_at` (string, required): Creation time, ISO 8601.
- `resolved_at` (string or null, required): Resolution time, ISO 8601; null while open.

## Errors

- `validation` (400): The request body, query, or headers failed validation against the endpoint schema, or broke a rule the endpoint's reference states. A field the schema refused adds two fields to the problem body. path names the first failing field by location and name in dot form, such as body.voice or headers.idempotency-key. A body that could not be read gives the path body alone. reason is one stable code from the validation reasons list.
- `unauthorized` (401): The request carried no API key, or the key is invalid or disabled.
- `feedback_limit` (429): The account reached a daily feedback cap: 50 written reports, or 1,000 reports that carry only a rating, in the last 24 hours. Nothing was stored.

## Example

curl:

```bash
curl -X POST https://api.paxalabs.com/v1/feedback \
  -H "Authorization: Bearer $PAXA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "kind": "model",
    "rating": "bad",
    "message": "The reply to a customer dropped the polite register.",
    "request_ids": [
      "7d9c2b7e-4a41-4c8e-9a35-1f26d8c04b7a"
    ],
    "example": {
      "input": "Thank you for waiting. We will call you back today.",
      "output": "ขอบคุณที่รอ เดี๋ยวโทรกลับวันนี้",
      "expected": "ขอบคุณที่รอค่ะ ทางเราจะโทรกลับภายในวันนี้ค่ะ"
    }
  }'
```

Response:

```json
{
  "id": "3f1c9a52-8e4b-4d7a-b6c0-2e5f9d8a1b47",
  "kind": "model",
  "rating": "bad",
  "message": "The reply to a customer dropped the polite register.",
  "request_ids": [
    "7d9c2b7e-4a41-4c8e-9a35-1f26d8c04b7a"
  ],
  "example": {
    "input": "Thank you for waiting. We will call you back today.",
    "output": "ขอบคุณที่รอ เดี๋ยวโทรกลับวันนี้",
    "expected": "ขอบคุณที่รอค่ะ ทางเราจะโทรกลับภายในวันนี้ค่ะ"
  },
  "source": "api",
  "status": "open",
  "resolution": null,
  "created_at": "2026-09-28T06:12:44.301Z",
  "resolved_at": null
}
```
