POST
/
feedback
curl --request POST \
  --url https://api.portkey.ai/v1/feedback \
  --header 'Content-Type: application/json' \
  --header 'x-portkey-api-key: <api-key>' \
  --data '{
  "trace_id": "REQUEST_TRACE_ID",
  "value": 1
}'

Authorizations

x-portkey-api-key
string
header
required

Body

application/json
trace_id
string
required

Unique identifier for the request trace.

value
integer
required

Feedback value, an integer between -10 and 10.

Required range: -10 < x < 10
metadata
object

Additional metadata for the feedback.

weight
number
default:
1

Weight of the feedback, a float between 0 and 1. Default is 1.0.

Required range: 0 < x < 1

Response

200 - application/json
feedback_ids
string[]

Ids of Feedbacks created returned in the same order as input

message
string

Confirmation message indicating successful feedback submission.

status
string

success or failure