Endpoint

POST https://api.histeeria.com/v1/ingest
Authorization: Bearer hst_live_xxxx
Content-Type: application/json
Returns 202 Accepted with:
{
  "decision_id": "550e8400-e29b-41d4-a716-446655440000",
  "queued": true
}

Request body

FieldTypeRequiredDescription
inputanyYesPrompt, messages, or structured input
outputstringYesAgent response
agent_idstringNoAgent identifier (max 255)
session_idstringNoSession / conversation ID
domainstringNoEvaluation context (max 100)
metadataobjectNoCustom key-value data
input_tokensintegerNoInput token count
output_tokensintegerNoOutput token count
sdk_versionstringNoSet by SDK automatically

Example

curl -X POST https://api.histeeria.com/v1/ingest \
  -H "Authorization: Bearer $HISTEERIA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "agent_id": "support-v2",
    "session_id": "sess_abc123",
    "domain": "customer_support",
    "input": {
      "messages": [
        {"role": "user", "content": "I need a refund for order #9912"}
      ]
    },
    "output": "I will check order #9912 against the refund policy before proceeding.",
    "metadata": {"channel": "web", "escalated": false},
    "input_tokens": 42,
    "output_tokens": 18
  }'

Prefer the SDK

The SDK handles batching, retries, and silent failure. Use raw HTTP only when the SDK isn’t available in your runtime.