Detect Issues
Run issue detection on a conversation provided in the request body.
Send an array of messages in OpenAI chat format. By default, the endpoint
evaluates the last message. Set message_indexes_to_evaluate to evaluate
a different message or multiple messages.
Set store_conversation to true to persist the conversation, messages,
and evaluation in the database so they appear in the dashboard.
You can override the active workspace evaluator by providing either
evaluator_id or a config object with custom labels and domain
context.
Header Parameters
Workspace UUID for session-authenticated calls.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Request body for issue detection.
Attributes:
messages: Array of messages in OpenAI chat format.
By default, the last message is evaluated.
store_conversation: If true, persist the conversation, messages, and
evaluation in the database. Defaults to true.
generation_info: Optional metadata about the LLM call that produced the
target assistant message. Persisted only when the target message is
from the assistant and store_conversation is true.
config: Optional issue config override. When provided, these
labels and domain context are used instead of the workspace config.
evaluator_id: Optional workspace evaluator ID. When provided, that
evaluator's labels and domain context are used.
message_indexes_to_evaluate: Optional zero-based message indexes that
may receive annotations. Defaults to the last message.
Response Body
application/json
application/json
curl -X POST "https://example.com/v1/evaluate" \ -H "Content-Type: application/json" \ -d '{ "messages": [ { "content": "string", "role": "developer" } ] }'{ "annotations": [ { "message_index": 0, "text": "string", "label": "string", "explanation": "string", "message_part_index": 0, "start_offset": 0, "end_offset": 0, "tool_name": "string", "parameter_name": "string" } ], "usage": { "input_tokens": 0, "cost_cents": 0 }, "evaluation_id": "4108ec8e-6efd-4b9b-bace-0bb4c296c324", "conversation_id": "cc71b11a-25cd-4c2d-9950-df2cc38e3407"}