> ## Documentation Index
> Fetch the complete documentation index at: https://docs.thrad.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Feedback

> Send a user's thumbs up or thumbs down on an ad.

When a bid has `actions.feedback_url`, you can show thumbs up / thumbs down next to the ad. When the user taps one, `POST` it there.

Use `feedback_url` exactly as returned. It already carries the token that ties the feedback to this bid. No API key is needed, so you can call it from the browser or the app.

## Request

**feedback\_type** `string` *required*

`"positive"` or `"negative"`.

**feedback\_text** `string`

Optional. What the user wrote, up to 1,000 characters. Useful for "tell us why" after a thumbs down.

```json Thumbs up theme={null}
{
  "feedback_type": "positive"
}
```

```json Thumbs down with text theme={null}
{
  "feedback_type": "negative",
  "feedback_text": "Not relevant to my conversation"
}
```

## Response

```json 204 - Feedback recorded theme={null}
// No response body
```

Send one per ad. Sending again for the same ad is not an error: you get `204`, and the first one stands.

## Status codes

| status | meaning | what to do |
| - | - | - |
| `204` | feedback recorded, or already recorded | nothing |
| `404` | the link expired or isn't valid | drop it; don't retry |
| `422` | `feedback_type` is missing or not `positive` / `negative`, or `feedback_text` is too long | fix the request |
| `503` | we couldn't record it right now | drop it |

## Example

```javascript theme={null}
async function sendFeedback(bid, type, text) {
  const url = bid.actions?.feedback_url;
  if (!url) return; // no feedback for this ad
  await fetch(url, {
    method: "POST",
    headers: { "Content-Type": "application/json" },
    body: JSON.stringify({ feedback_type: type, ...(text ? { feedback_text: text } : {}) }),
  });
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.