POST
/
feedback

Authorizations

api-key
string
headerrequired

Your Melodi API key

Body

application/json

Create feedback request object. Feedback is always associated with a message:

  • If only externalThreadId is provided, feedback will be attached to the last message in the thread
  • If both externalThreadId and externalMessageId are provided, feedback will be attached to the specified message Note: externalThreadId is only unique per project, so including projectId is recommended to ensure correct thread identification.
feedbackType
enum<string>
required

Type of feedback

Available options:
POSITIVE,
NEGATIVE
externalThreadId
string
required

External ID of the thread containing the target message

feedbackText
string

Text content of the feedback

externalMessageId
string

ID of the specific message for feedback. If not provided, feedback will be attached to the thread's last message

projectId
integer

Recommended - ID of the project this thread belongs to. Helps ensure correct thread identification

externalUser
object

External user information for associating feedback with a user

attributes
object

Key-value pairs where:

  • key: attribute name (must match an existing attribute in the project)
  • value: option name (must match an existing option for that attribute)

Response

200 - application/json
id
integer
required

Unique identifier for the feedback

attributeOptions
object[]
required

List of attribute options with their full attribute details

createdAt
string
required
updatedAt
string
required
feedbackType
string | null

Type of the feedback

Maximum length: 255
feedbackText
string | null

Text content of the feedback

externalUser
object

Information about the external user who provided the feedback