Docs/OSINT

Events

Poll the event log of a run.

GEThttps://api.vaelor.chat/v1/osint/cases/{id}/events

Returns the case's event log: what the agent planned, every tool it called, status changes and the final report. Poll with the after cursor to receive only new events.

Query parameters#

afterintegerDefault 0

Return only events with an id greater than this. Pass the last id you've seen.

Response#

eventsobject[]

Events, oldest first.

idinteger
Increasing event ID. Use it as your next after.
runIdstring
The run that emitted the event.
kindenum
status, plan, tool-start, tool-complete, tool-error, report or abort.
messagestring
A human-readable description.
createdAtstring
When it happened, in ISO 8601.

Polling#

Poll every 2–5 seconds while the run is active. Stop when you see a status event for a terminal state, or a report event.

let after = 0

while (true) {
  const { events } = await fetch(`https://api.vaelor.chat/v1/osint/cases/${caseId}/events?after=${after}`, {
    headers: { Authorization: `Bearer ${process.env.VAELOR_API_KEY}` }
  }).then((response) => response.json())

  for (const event of events) {
    console.log(`[${event.kind}] ${event.message}`)
    after = event.id
  }

  if (events.some((event) => event.kind === 'report' || event.kind === 'abort')) break

  await new Promise((resolve) => setTimeout(resolve, 3000))
}

Response200

JSON
{
  "events": [
    { "id": 41, "runId": "r_7c1e4b02", "kind": "status", "message": "Run started", "createdAt": "2026-10-20T08:03:04.000Z" },
    { "id": 42, "runId": "r_7c1e4b02", "kind": "plan", "message": "Resolve DNS and WHOIS, then search for staff pages", "createdAt": "2026-10-20T08:03:09.000Z" },
    { "id": 43, "runId": "r_7c1e4b02", "kind": "tool-start", "message": "Searching the web for \"northwind-trading.example\"", "createdAt": "2026-10-20T08:03:10.000Z" },
    { "id": 44, "runId": "r_7c1e4b02", "kind": "tool-complete", "message": "8 results", "createdAt": "2026-10-20T08:03:12.000Z" }
  ]
}

Was this page helpful?

Questions? Contact support

Last updated October 20, 2026