Update Instance
Update an existing agent instance.
Only provided fields are updated. Returns the updated instance.
Returns: Updated agent instance.
Raises: NotFoundError: If instance not found or belongs to another organization.
Documentation Index
Fetch the complete documentation index at: https://docs.pragmatiks.io/llms.txt
Use this file to discover all available pages before exploring further.
Path Parameters
Body
Request body for updating an agent instance. All fields optional.
Status changes are not allowed here — use the transition endpoint instead.
Attributes: task_id: Task this instance is working on. 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.
Response
Successful Response
A running or completed agent session.
Agent instances live inside the tenant SurrealDB namespace — the
namespace is the organization boundary, so the record itself
carries no organization_id field.
Attributes: id: SurrealDB record ID (populated by database). 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