← All types
Ob Object

TaskState

A task requiring human action

Fields

id

TaskID!Non-null

Unique identifier

type

TaskType!Non-null

Task type (manual or approval)

Possible values (3)
MANUAL

A manual task with custom outcomes

APPROVAL

An approval task from a workflow

AGENT_AUTOMATED

A task automatically resolved by an AI agent

Current status

Possible values (7)
CREATED

Task has been created

ALLOCATED

Task allocated to a specific user

WORKING

Task is being worked on

PAUSED

Task is paused

COMPLETED

Task has been completed

CANCELLED

Task has been cancelled

REJECTED

Task has been rejected

title

String!Non-null

Task title

Optional description

Associated task definition (for manual tasks)

Linked resource type (e.g., job, component)

Linked resource ID

Directly assigned user

Assigned team

User who claimed this team task

User who created this task

priority

Int!Non-null

Priority (higher = more urgent)

dueAt

ISO8601Nullable

Due date (ISO8601)

Selected outcome value

Additional outcome data (JSON)

Workflow execution (for approval tasks)

Workflow node ID (for approval tasks)

Completion timestamp (ISO8601)

Creation timestamp (ISO8601)

Last update timestamp (ISO8601)

subjectId

IDNullable

TypeID of the record this task is about. Derived from resourceType/resourceId for older tasks; null when unknown.

A personal to-do the person created for themself. Visible to task readers like any task; its owner can always read it.

For a task from a JOURNEY template: the journey's launch inputs the workflow seeded from its data, keyed by input key (a resource input is { id, label }). Null for other tasks.

The task's template: its name, its description (the instructions) and its outcome options. Readable by anyone who can read the task; null when the task has no template or it was deleted.

Name of the assigned team; null when the task has no team or it was deleted.

Name of the workflow whose execution created this task; null for tasks created outside a workflow.

The record this task is about (see subjectId), with its label and status when the caller may read that record. Meant for a single task view, not long lists: it queries the record per task.

Time people logged on this task, newest first, voided entries included. Anyone who can read the task reads all its entries.

Arguments (2)

first

IntOptional

Number of entries from the newest

after

StringOptional

Cursor to start after

Total seconds of finished, non-void time logged on this task; a running timer is not counted until it stops.

The caller's running timer on this task, or null.

Referenced by (4)
Exact type SDL
"""A task requiring human action"""
type TaskState {
  """Unique identifier"""
  id: TaskID!
  """Task type (manual or approval)"""
  type: TaskType!
  """Current status"""
  status: TaskStatus!
  """Task title"""
  title: String!
  """Optional description"""
  description: String
  """Associated task definition (for manual tasks)"""
  taskDefinitionId: TaskDefinitionID
  """Linked resource type (e.g., job, component)"""
  resourceType: String
  """Linked resource ID"""
  resourceId: String
  """Directly assigned user"""
  assignedUserId: UserID
  """Assigned team"""
  assignedTeamId: TeamID
  """User who claimed this team task"""
  claimedByUserId: UserID
  """User who created this task"""
  createdByUserId: UserID!
  """Priority (higher = more urgent)"""
  priority: Int!
  """Due date (ISO8601)"""
  dueAt: ISO8601
  """Selected outcome value"""
  outcome: String
  """Additional outcome data (JSON)"""
  outcomeData: String
  """Workflow execution (for approval tasks)"""
  workflowExecutionId: WorkflowExecutionID
  """Workflow node ID (for approval tasks)"""
  workflowNodeId: String
  """Completion timestamp (ISO8601)"""
  completedAt: ISO8601
  """Creation timestamp (ISO8601)"""
  createdAt: String!
  """Last update timestamp (ISO8601)"""
  updatedAt: String!
  """
  TypeID of the record this task is about. Derived from resourceType/resourceId for older tasks; null when unknown.
  """
  subjectId: ID
  """
  A personal to-do the person created for themself. Visible to task readers like any task; its owner can always read it.
  """
  personal: Boolean!
  """
  For a task from a JOURNEY template: the journey's launch inputs the workflow seeded from its data, keyed by input key (a resource input is { id, label }). Null for other tasks.
  """
  journeySeed: JSON
  """
  The task's template: its name, its description (the instructions) and its outcome options. Readable by anyone who can read the task; null when the task has no template or it was deleted.
  """
  taskDefinition: TaskDefinitionState
  """
  Name of the assigned team; null when the task has no team or it was deleted.
  """
  assignedTeamName: String
  """
  Name of the workflow whose execution created this task; null for tasks created outside a workflow.
  """
  workflowName: String
  """
  The record this task is about (see subjectId), with its label and status when the caller may read that record. Meant for a single task view, not long lists: it queries the record per task.
  """
  subject: TaskSubject
  """
  Time people logged on this task, newest first, voided entries included. Anyone who can read the task reads all its entries.
  """
  timeEntries(
    """Number of entries from the newest"""
    first: Int
    """Cursor to start after"""
    after: String
  ): TaskTimeEntryConnection!
  """
  Total seconds of finished, non-void time logged on this task; a running timer is not counted until it stops.
  """
  timeSpentSeconds: Int!
  """The caller's running timer on this task, or null."""
  myRunningTimer: TaskTimeEntry
}