Application-facing task state for the io.modelcontextprotocol/tasks extension.
The struct contains a small amount of private bookkeeping (used_input_keys)
that never appears on the wire. State changes are explicit and terminal states
are immutable, which lets an atomic store resolve cancellation/completion races.
Summary
Functions
Returns the flat SEP-2663 creation result, without detailed payload fields.
Returns the flat status-specific tasks/get result.
Returns the complete status-specific payload for notifications/tasks.
Returns an RFC 3339/ISO 8601 UTC timestamp at millisecond precision.
Types
@type status() :: :working | :input_required | :completed | :failed | :cancelled
@type t() :: %Snodo.Extensions.Tasks.Task{ created_at: String.t(), error: map() | nil, id: String.t(), input_requests: map(), last_updated_at: String.t(), poll_interval_ms: pos_integer() | nil, result: map() | nil, status: status(), status_message: String.t() | nil, ttl_ms: pos_integer() | nil, used_input_keys: MapSet.t(String.t()) }
Functions
Returns the flat SEP-2663 creation result, without detailed payload fields.
Returns the flat status-specific tasks/get result.
Returns the complete status-specific payload for notifications/tasks.
@spec timestamp() :: String.t()
Returns an RFC 3339/ISO 8601 UTC timestamp at millisecond precision.