{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://velox.dev/schema/events/event.task.state.schema.json", "title": "event.task.state", "description": "A task changed lifecycle state. Carries the summary so the row can be repainted in full without a round trip, and error whenever the daemon has something to say about why: on every failed or retry_wait transition, and on a paused transition the daemon entered unilaterally rather than at a user's or scheduler's request.", "x-direction": "server-to-client", "type": "object", "properties": { "params": { "type": "object", "additionalProperties": false, "required": [ "taskId", "state" ], "properties": { "taskId": { "type": "string", "format": "uuid" }, "state": { "$ref": "https://velox.dev/schema/types/TaskState.schema.json" }, "previousState": { "oneOf": [ { "$ref": "https://velox.dev/schema/types/TaskState.schema.json" }, { "type": "null" } ] }, "summary": { "oneOf": [ { "$ref": "https://velox.dev/schema/types/TaskSummary.schema.json" }, { "type": "null" } ] }, "error": { "oneOf": [ { "$ref": "https://velox.dev/schema/types/TaskError.schema.json" }, { "type": "null" } ], "description": "Set when the new state is failed or retry_wait, and also when it is paused and the daemon entered that state on its own initiative \u2014 auth_required, server_file_changed, disk_full and the like \u2014 rather than because of a user action, a schedule window closing, or an admission-control decision. null on every other transition, including every deliberately-requested pause. A client must not assume a paused task has no error just because it usually doesn't; check this field rather than the state name alone." } } } } }