Skip to main content
POST
/
api
/
v2
/
sessions
/
{id}
/
feedback
Session feedback
curl --request POST \
  --url https://agp.eu.hcompany.ai/api/v2/sessions/{id}/feedback \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "success": true,
  "message": "<string>"
}
'
Submit feedback on a completed session. Use this to report whether the agent completed its task successfully. Returns 204 No Content.

Path parameters

id
string
required
The session ID.

Request body: Feedback

success
boolean
required
Whether the session completed its task successfully.
message
string
Optional feedback message with details.

Examples

Session feedback

curl -X POST https://agp.eu.hcompany.ai/api/v2/sessions/$SESSION_ID/feedback \
  -H "Authorization: Bearer $H_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "success": true,
    "message": "Task completed correctly"
  }'

Event feedback

You can also submit feedback on a specific event within the session:
PUT /api/v2/sessions/{id}/events/{event_index}/feedback
Same Feedback body. Returns 204 No Content.
curl -X PUT https://agp.eu.hcompany.ai/api/v2/sessions/$SESSION_ID/events/5/feedback \
  -H "Authorization: Bearer $H_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "success": false,
    "message": "Agent clicked the wrong button at this step"
  }'