Skip to main content
POST
https://api.u1.archetypeai.app/v0.5
/
lens
/
sessions
/
events
/
process
curl -X POST https://api.dev.u1.archetypeai.app/v0.5/lens/sessions/events/process \
  -H "Authorization: Bearer $ATAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "session_id": "lsn-250313c2177253cbaa7a73542edd90",
    "event": {
      "type": "image",
      "data": "base64_encoded_image_data"
    }
  }'
{
  "type": "success",
  "event_data": {
    "response": "Processing result..."
  }
}

Overview

This endpoint sends an event to an active session to process.

Request

Authorization
string
required
Bearer token for authentication. Format: Bearer $ATAI_API_KEY
session_id
string
required
The ID of the active session the event should be routed to.
event
object
required
The event to route to the session. Must contain a type field.

Response

type
string
Response type. “error” indicates a processing error occurred.
event_data
object
Event processing result or error details.
curl -X POST https://api.dev.u1.archetypeai.app/v0.5/lens/sessions/events/process \
  -H "Authorization: Bearer $ATAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "session_id": "lsn-250313c2177253cbaa7a73542edd90",
    "event": {
      "type": "image",
      "data": "base64_encoded_image_data"
    }
  }'
{
  "type": "success",
  "event_data": {
    "response": "Processing result..."
  }
}