Skip to content

Record thumbs up/down on an assistant reply

POST
/api/v1/chat/feedback
curl --request POST \
--url http://localhost:11044/api/v1/chat/feedback \
--header 'Content-Type: application/json' \
--header 'X-Embabel-Api-Key: <X-Embabel-Api-Key>' \
--data '{ "text": "example", "verdict": "example" }'

Publishes a CHAT-sourced UserFeedbackEvent for the given message text and verdict. Doesn’t require an open stream — it’s a judgement on a reply already received, not a new turn.

The judgement on a reply already received: text is the reply being judged and must not be blank, and verdict is up or down, case-insensitive; anything else is refused with 400. It is recorded as chat feedback from the caller in their world, and needs no open session or stream

Media typeapplication/json

A thumbs up or down on an assistant reply already received; the body of POST /chat/feedback

object
text
required

Text of the assistant reply being judged; blank is a 400

string
verdict
required

Up or down, case-insensitive; anything else is a 400

string

Example generated

{
"text": "example",
"verdict": "example"
}

Feedback recorded

Media type*/*
object
key
additional properties
string

Missing text or an unrecognised verdict

Media type*/*

A refusal from the chat surface: the word error and the reason, written to be shown

object
message
required

What was refused and why, such as no open stream, no active session, or an unknown command

string
status
required

Always error. A client may branch on it rather than on the status code

string

Example

error