openapi: 3.1.0
info:
title: Sb0 Agent APIKeys Events API
version: 0.1.0
tags:
- name: Events
paths:
/events:
get:
description: 'List events for a specific task and agent.
Optionally filter for events after a specific sequence ID.
Results are ordered by sequence_id.'
operationId: events_list
parameters:
- description: Optional event ID to get events after this ID
in: query
name: last_processed_event_id
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: Optional event ID to get events after this ID
title: Last Processed Event Id
- description: Optional limit on number of results
in: query
name: limit
required: false
schema:
anyOf:
- maximum: 1000
minimum: 1
type: integer
- type: 'null'
description: Optional limit on number of results
title: Limit
- description: The task ID
in: query
name: task_id
required: true
schema:
description: The task ID
title: Task Id
type: string
- description: The agent ID
in: query
name: agent_id
required: true
schema:
description: The agent ID
title: Agent Id
type: string
responses:
'200':
content:
application/json:
schema:
items:
$ref: '#/components/schemas/Event'
title: Response Events List
type: array
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
summary: List Events
tags:
- Events
/events/{event_id}:
get:
operationId: events_retrieve
parameters:
- in: path
name: event_id
required: true
schema:
title: Event Id
type: string
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/Event'
description: Successful Response
'422':
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
description: Validation Error
summary: Get Event
tags:
- Events
components:
schemas:
DataPart:
description: Generic data part for unknown/passthrough content.
properties:
data:
description: Arbitrary data content
title: Data
type:
const: data
default: data
description: Part type discriminator
title: Type
type: string
required:
- data
title: DataPart
type: object
TextPart:
description: Text content part.
properties:
text:
description: The text content
title: Text
type: string
type:
const: text
default: text
description: Part type discriminator
title: Type
type: string
required:
- text
title: TextPart
type: object
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
title: Detail
type: array
title: HTTPValidationError
type: object
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
title: Location
type: array
msg:
title: Message
type: string
type:
title: Error Type
type: string
required:
- loc
- msg
- type
title: ValidationError
type: object
Event:
description: 'Event returned from the events API.
Content is TextPart or DataPart (human-readable content only).'
properties:
agent_id:
description: The UUID of the agent that the event belongs to
title: Agent Id
type: string
content:
anyOf:
- $ref: '#/components/schemas/TextPart'
- $ref: '#/components/schemas/DataPart'
- type: 'null'
description: The content of the event (TextPart or DataPart)
title: Content
created_at:
anyOf:
- format: date-time
type: string
- type: 'null'
description: The timestamp of the event
title: Created At
id:
description: The UUID of the event
title: Id
type: string
sequence_id:
description: The sequence ID of the event
title: Sequence Id
type: integer
streamCapabilities:
anyOf:
- items:
type: string
type: array
- type: 'null'
description: Server-advertised stream lifecycle capabilities for this event
title: Streamcapabilities
task_id:
description: The UUID of the task that the event belongs to
title: Task Id
type: string
required:
- id
- sequence_id
- task_id
- agent_id
title: Event
type: object
x-fern-idempotency-headers:
- header: Idempotency-Key
name: idempotency_key