RunEvent
One SSE frame's JSON payload, tagged by its `event` field (which also matches the SSE `event:` name). `finished` and `error` are stream-closing.
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://artifacts.apis.io/usewrit-app/json-schema/usewrit-app-run-event-schema.json",
"title": "RunEvent",
"description": "One SSE frame's JSON payload, tagged by its `event` field (which also matches the SSE `event:` name). `finished` and `error` are stream-closing.",
"x-generated": "2026-11-10",
"x-method": "derived",
"x-generator": "derive-json-schema.py",
"x-source": "openapi/usewrit-app-runs-api-openapi.yml#/components/schemas/RunEvent",
"oneOf": [
{
"$ref": "#/$defs/RunEventStarted"
},
{
"$ref": "#/$defs/RunEventStep"
},
{
"$ref": "#/$defs/RunEventProgress"
},
{
"$ref": "#/$defs/RunEventFinished"
},
{
"$ref": "#/$defs/RunEventError"
}
],
"$defs": {
"RunEventError": {
"type": "object",
"description": "TERMINAL: the run failed around the step loop. `message` is an operator-facing classification, never a raw secret/value. Stream-closing.",
"required": [
"event",
"run_id",
"message"
],
"properties": {
"event": {
"type": "string",
"const": "error"
},
"run_id": {
"type": "integer",
"format": "int64"
},
"message": {
"type": "string"
}
}
},
"RunEventFinished": {
"type": "object",
"description": "TERMINAL: the run reached a final status. Stream-closing.",
"required": [
"event",
"run_id",
"status"
],
"properties": {
"event": {
"type": "string",
"const": "finished"
},
"run_id": {
"type": "integer",
"format": "int64"
},
"status": {
"$ref": "#/$defs/RunStatus"
}
}
},
"RunEventProgress": {
"type": "object",
"description": "Coarse progress hint — `completed` of `total` steps done.",
"required": [
"event",
"run_id",
"completed",
"total"
],
"properties": {
"event": {
"type": "string",
"const": "progress"
},
"run_id": {
"type": "integer",
"format": "int64"
},
"completed": {
"type": "integer"
},
"total": {
"type": "integer"
}
}
},
"RunEventStarted": {
"type": "object",
"description": "The run is registered and about to drive its steps. `total_steps` counts the raw steps the engine will iterate (a synthetic subscription seed may report 0).",
"required": [
"event",
"run_id",
"total_steps"
],
"properties": {
"event": {
"type": "string",
"const": "started"
},
"run_id": {
"type": "integer",
"format": "int64"
},
"total_steps": {
"type": "integer"
}
}
},
"RunEventStep": {
"type": "object",
"description": "A step transitioned. `index` is 0-based into the raw step list; `step_type` is the recorded step kind — never a value.",
"required": [
"event",
"run_id",
"index",
"step_type",
"status"
],
"properties": {
"event": {
"type": "string",
"const": "step"
},
"run_id": {
"type": "integer",
"format": "int64"
},
"index": {
"type": "integer"
},
"step_type": {
"type": "string"
},
"status": {
"$ref": "#/$defs/StepStatus"
}
}
},
"RunStatus": {
"type": "string",
"description": "Terminal/in-flight run status (serde snake_case of `engine::RunStatus`). Treat as an open string enum in clients.",
"enum": [
"running",
"success",
"failed",
"cancelled",
"timeout",
"captcha_required",
"twofa_required"
]
},
"StepStatus": {
"type": "string",
"description": "Coarse per-step lifecycle marker.",
"enum": [
"running",
"succeeded",
"failed",
"skipped"
]
}
}
}
Work with this as data
Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for schemas
4 MCP tools reach this
find_json_schemasBrowse and filter every JSON Schema in the catalog.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.
Call it yourself
curl for this page
curl "https://apis.io/api/v1/json-schemas/usewrit-app-run-event"
curl "https://apis.io/api/v1/json-schemas?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.