ArchAstro.V1.Agents.WorkItems (archastro v0.2.0)

Copy Markdown

AgentWorkItem API resource.

Summary

Functions

Claim or resume workflow work for an agent

Functions

claim(client, agent, input)

Claim or resume workflow work for an agent

Atomically claims the oldest queued or lease-expired item. To resume after a harness restart, pass both the saved work_item and the same lease_owner; the server refreshes that active lease without incrementing its attempt. Returns data: null when no eligible item exists, including when another lease owns the explicitly requested item.

Successful response

list(client, agent, params \\ %ArchAstro.Types.Operations.GetApiV1AgentsAgentWorkItems.Params{})

List active workflow work available to the viewer

Lists queued, claimed, and running external work yielded by durable workflows. The top-level collection includes work for every agent the viewer can execute; the agent-nested collection limits results to that agent. This discovery response never includes lease tokens. Use the agent claim endpoint to acquire new work or resume a saved lease.

Successful response