githubEdit

circle-playWorkflowExecutions

Query workflow executions with pagination and filtering

Audience: Programmer

Returns a paginated list of Temporal workflow executions with optional filtering and ordering. This query provides lightweight execution metadata without history for efficient retrieval of workflow execution status.

For workflow history events, use the separate workflowHistory query.

Arguments

Name
Type
Description

where

WorkflowExecutionsWhereInput

Filter criteria for workflow executions

first

Int

Maximum number of executions to return. Defaults to 100

after

String

Pagination cursor from previous response (NextPageToken from Temporal)

orderBy

WorkflowExecutionOrder

Ordering options for the returned list

Return Type

WorkflowExecutionInfoConnection! - A connection containing workflow execution information with pagination support.

Connection Fields

Field
Type
Description

edges

[WorkflowExecutionInfoEdge!]!

List of workflow execution edges

pageInfo

WorkflowExecutionPageInfo!

Pagination information

totalCount

Int!

Total count of matching executions

Edge Fields

Field
Type
Description

node

WorkflowExecutionInfo!

The workflow execution information

cursor

String!

Cursor for pagination

Filter Options (WorkflowExecutionsWhereInput)

Workflow Identification

Filter
Type
Description

workflowID

String

Exact workflow ID match

workflowIDNeq

String

Not equal to workflow ID

workflowIDIn

[String!]

Match any of the provided workflow IDs

workflowIDNotIn

[String!]

Exclude specific workflow IDs

workflowIDHasPrefix

String

Workflow ID starts with

workflowIDHasSuffix

String

Workflow ID ends with

workflowIDContains

String

Workflow ID contains substring (case-sensitive)

workflowIDEqualFold

String

Case-insensitive equality match

workflowIDContainsFold

String

Case-insensitive substring match

runID

String

Exact run ID match

runIDNeq

String

Not equal to run ID

runIDIn

[String!]

Match any of the provided run IDs

runIDNotIn

[String!]

Exclude specific run IDs

runIDHasPrefix

String

Run ID starts with

runIDHasSuffix

String

Run ID ends with

runIDContains

String

Run ID contains substring (case-sensitive)

runIDEqualFold

String

Case-insensitive equality match

runIDContainsFold

String

Case-insensitive substring match

Workflow Type

Filter
Type
Description

typeName

String

Exact workflow type name

typeNameNeq

String

Not equal to type name

typeNameIn

[String!]

Match any of the provided type names

typeNameNotIn

[String!]

Exclude specific type names

typeNameHasPrefix

String

Type name starts with

typeNameHasSuffix

String

Type name ends with

typeNameContains

String

Type name contains substring (case-sensitive)

typeNameEqualFold

String

Case-insensitive equality match

typeNameContainsFold

String

Case-insensitive substring match

Workflow Name

Filter
Type
Description

workflowName

String

Exact workflow name match (custom search attribute)

workflowNameNeq

String

Not equal to workflow name

workflowNameIn

[String!]

Match any of the provided workflow names

workflowNameNotIn

[String!]

Exclude specific workflow names

workflowNameHasPrefix

String

Workflow name starts with

workflowNameHasSuffix

String

Workflow name ends with

workflowNameContains

String

Workflow name contains substring (case-sensitive)

workflowNameEqualFold

String

Case-insensitive equality match

workflowNameContainsFold

String

Case-insensitive substring match

Status

Filter
Type
Description

status

String

Exact status match (RUNNING, COMPLETED, FAILED, etc.)

statusNeq

String

Not equal to status

statusIn

[String!]

Match any of the provided statuses

statusNotIn

[String!]

Exclude specific statuses

statusHasPrefix

String

Status starts with

statusHasSuffix

String

Status ends with

statusContains

String

Status contains substring (case-sensitive)

statusEqualFold

String

Case-insensitive equality match

statusContainsFold

String

Case-insensitive substring match

Time Filters

Filter
Type
Description

startTime

String

Exact start time (ISO 8601)

startTimeGT

String

Started after

startTimeGTE

String

Started at or after

startTimeLT

String

Started before

startTimeLTE

String

Started at or before

closeTime

String

Exact close time

closeTimeGT

String

Closed after

closeTimeGTE

String

Closed at or after

closeTimeIsNil

Boolean

Still running (no close time)

closeTimeNotNil

Boolean

Has completed (has close time)

Search Attributes

Filter
Type
Description

service

String

Exact service name match

serviceNeq

String

Not equal to service

serviceIn

[String!]

Match any of the services

serviceNotIn

[String!]

Exclude specific services

serviceHasPrefix

String

Service starts with

serviceHasSuffix

String

Service ends with

serviceContains

String

Service contains substring (case-sensitive)

serviceEqualFold

String

Case-insensitive equality match

serviceContainsFold

String

Case-insensitive substring match

serviceIsNil

Boolean

Service is not set

serviceNotNil

Boolean

Service is set

dataType

String

Exact data type match

dataTypeNeq

String

Not equal to data type

dataTypeIn

[String!]

Match any data types

dataTypeNotIn

[String!]

Exclude specific data types

dataTypeHasPrefix

String

Data type starts with

dataTypeHasSuffix

String

Data type ends with

dataTypeContains

String

Data type contains substring (case-sensitive)

dataTypeEqualFold

String

Case-insensitive equality match

dataTypeContainsFold

String

Case-insensitive substring match

dataTypeIsNil

Boolean

Data type is not set

dataTypeNotNil

Boolean

Data type is set

dataId

String

Exact data ID match

dataIdNeq

String

Not equal to data ID

dataIdIn

[String!]

Match any data IDs

dataIdNotIn

[String!]

Exclude specific data IDs

dataIdHasPrefix

String

Data ID starts with

dataIdHasSuffix

String

Data ID ends with

dataIdContains

String

Data ID contains substring

dataIdIsNil

Boolean

Data ID is not set

dataIdNotNil

Boolean

Data ID is set

Assignment

Filter
Type
Description

assignee

String

Exact assignee match

assigneeNeq

String

Not equal to assignee

assigneeIn

[String!]

Match any assignees

assigneeNotIn

[String!]

Exclude specific assignees

assigneeHasPrefix

String

Assignee starts with

assigneeHasSuffix

String

Assignee ends with

assigneeContains

String

Assignee contains substring (case-sensitive)

assigneeEqualFold

String

Case-insensitive equality match

assigneeContainsFold

String

Case-insensitive substring match

assigneeIsNil

Boolean

Unassigned workflows

assigneeNotNil

Boolean

Assigned workflows

groupBy

String

Exact group by value

groupByNeq

String

Not equal to group by value

groupByIn

[String!]

Match any group by values

groupByNotIn

[String!]

Exclude specific group by values

groupByHasPrefix

String

Group by starts with

groupByHasSuffix

String

Group by ends with

groupByContains

String

Group by contains substring (case-sensitive)

groupByEqualFold

String

Case-insensitive equality match

groupByContainsFold

String

Case-insensitive substring match

groupByIsNil

Boolean

Group by is not set

groupByNotNil

Boolean

Group by is set

Logical Operators

Filter
Type
Description

and

[WorkflowExecutionsWhereInput!]

All conditions must match

or

[WorkflowExecutionsWhereInput!]

Any condition matches

not

WorkflowExecutionsWhereInput

Negate condition

Ordering Options (WorkflowExecutionOrder)

Field
Values
Description

direction

ASC, DESC

Sort direction

field

START_TIME, CLOSE_TIME, WORKFLOW_ID, STATUS

Field to sort by

Usage Examples

Basic Query with Pagination

Filter by Status and Type

Complex Filtering with AND

Using OR Operator

Find workflows that are either unassigned or not assigned to a specific user:

Find workflows in multiple statuses from different services:

Using NOT Operator

Exclude specific workflow types:

Combining OR, AND, and NOT

Find active workflows that are either high priority or assigned to a specific team:

Using String Predicates

Case-insensitive search with suffix matching:

Search workflows with case-insensitive substring matching:

Paginating Through Results

Find Specific Workflow

Filter by Data Type and Service

Example Response

Breaking Changes

This query has undergone significant changes:

  1. Return type changed from [WorkflowExecutionInfo!]! to WorkflowExecutionInfoConnection!

  2. Pagination support added via first and after parameters

  3. Ordering support added via orderBy parameter

  4. History not included - use workflowHistory query for history events

See WorkflowExecutionInfo for migration examples.

Notes

  • Returns lightweight execution metadata WITHOUT history for performance

  • Use workflowHistory query to fetch history for specific executions

  • Pagination uses Temporal's NextPageToken directly

  • Default page size is 100 if first is not specified

  • Results can be ordered by start time, close time, workflow ID, or status

  • Logical operators (or, and, not) are fully supported for building complex queries

  • String predicates include case-sensitive (hasPrefix, hasSuffix, contains) and case-insensitive (equalFold, containsFold) variants

  • Case-insensitive predicates (equalFold, containsFold) map to the same Temporal operators as their case-sensitive counterparts since Temporal doesn't have native case-insensitive operators

Last updated

Was this helpful?