Skip to main content
All response models are defined using Pydantic and provide structured data from the API.

TriageResponse

Returned when triaging a support ticket to determine its category and priority.
category
string
required
The categorized type of the support ticket (e.g., “technical”, “billing”, “account”)
priority
string
required
The priority level of the ticket (e.g., “high”, “medium”, “low”)
confidence
object
required
Confidence scores for the triage classification

Example

{
  "category": "technical",
  "priority": "high",
  "confidence": {
    "category": 0.95,
    "priority": 0.87
  }
}

AnswerResponse

Comprehensive response containing triage, draft reply, next steps, and citations.
triage
object
required
Triage information for the support ticket
draft_reply
string
required
AI-generated draft response to the support ticket
internal_next_steps
array
required
List of recommended internal actions for support staff
citations
array
required
Supporting citations from the knowledge base
needs_human_review
boolean
required
Flag indicating whether this ticket requires human review before sending the draft reply

Example

{
  "triage": {
    "category": "technical",
    "priority": "high",
    "confidence": {
      "category": 0.95,
      "priority": 0.87
    }
  },
  "draft_reply": "Thank you for contacting support. To reset your password, please visit our password reset page at example.com/reset and follow the instructions...",
  "internal_next_steps": [
    "Verify user identity",
    "Check if email delivery is working",
    "Escalate to Tier 2 if issue persists"
  ],
  "citations": [
    {
      "document_name": "password-reset-guide.pdf",
      "chunk_id": "chunk_42",
      "snippet": "Users can reset their password by visiting the password reset page...",
      "full_content": "Users can reset their password by visiting the password reset page and entering their email address. A reset link will be sent within 5 minutes."
    }
  ],
  "needs_human_review": true
}

HealthResponse

Simple health check response to verify the API is running.
status
string
required
Health status of the API (default: “ok”)

Example

{
  "status": "ok"
}

Confidence

Standalone model for confidence scores used in triage operations.
category
float
required
Confidence score (0-1) for the category classification
priority
float
required
Confidence score (0-1) for the priority classification

Example

{
  "category": 0.95,
  "priority": 0.87
}

Citation

Standalone model representing a citation from the knowledge base.
document_name
string
required
Name of the source document
chunk_id
string
required
Unique identifier for the document chunk
snippet
string
required
Brief excerpt from the document
full_content
string
required
Complete content of the relevant document chunk

Example

{
  "document_name": "api-documentation.pdf",
  "chunk_id": "chunk_123",
  "snippet": "The API supports authentication via JWT tokens...",
  "full_content": "The API supports authentication via JWT tokens. Include the token in the Authorization header as 'Bearer <token>' for all authenticated requests."
}

Build docs developers (and LLMs) love