Transition an agent instance to a new status.
Validates the transition against allowed status transitions.
Returns: Updated agent instance with new status.
Raises: NotFoundError: If instance not found or belongs to another organization. InvalidLifecycleTransitionError: If the transition is not allowed.
Request body for transitioning an agent instance to a new status.
Attributes: status: Target status.
Lifecycle status of an agent instance.
starting, running, waiting, paused, completed, error, stopped Successful Response
A running or completed agent session.
Attributes: id: SurrealDB record ID (populated by database). organization_id: Owning organization. agent_type_id: Agent type this instance runs. task_id: Task this instance is working on. status: Current lifecycle status. started_at: When the instance began execution. ended_at: When the instance reached a terminal status. turn_count: Number of LLM turns completed. tokens_total: Total tokens consumed. needs_input: Whether the instance is blocked waiting for human input. current_step: Description of what the instance is currently doing. last_action_at: Timestamp of the most recent action. session_id: External session identifier for conversation continuity.
Lifecycle status of an agent instance.
starting, running, waiting, paused, completed, error, stopped