Table of contents
Official Content
  • This documentation is valid for:

This API enables you to associate feedback from the Assistant answers.

Check the generic variables needed to use the API.

Endpoints

Feedback API provides the following endpoints:

Method Path Description
POST /feedback/request/{requestId} Add feedback to a request associated with a user's execution; note the requestId parameters are returned on every assistant reply.

POST/feedback/request/{requestId}

Updates an assistant feedback using the associated request identifier (requestId).

Parameter Type Description
origin string Origin for the feedback, use user-feedback
answerScore number Associated feedback: 1 good, 2 bad
comments string Associated feedback comment (optional)

Request body

{
    "origin": "user-feedback",
    "answerScore": 2,
    "comments": "this is a wrong anwer!!"
}

The expected response is a 200 statusCode and empty ({}) json

Samples

curl --location '$BASE_URL/v1/feedback/request/{requestId}' \
--header 'Content-Type: application/json' \
--header 'X-Saia-Cache-Enabled: false' \
--header 'Authorization: Bearer $SAIA_PROJECT_APITOKEN' \
--data '{
    "origin": "user-feedback",
    "answerScore": 2, 
    "comments": "bad answer!"
}'
import requests
import json

url = f"{BASE_URL}/v1/feedback/request/{requestId}"

payload = json.dumps({
  "origin": "user-feedback",
  "answerScore": 2,
  "comments": "bad answer!"
})
headers = {
  'Content-Type': 'application/json',
  'Authorization': f'Bearer {SAIA_PROJECT_APITOKEN}',
}

response = requests.request("POST", url, headers=headers, data=payload)

See Also

Organization API
API Reference

Last update: March 2025 | © GeneXus. All rights reserved. GeneXus Powered by Globant