---
title: "Step and trigger types reference | Grafana Cloud documentation"
description: "Reference documentation for all available Grafana Workflows step types and trigger types, including inputs, outputs, and usage details."
---

# Step and trigger types reference

> Note
> 
> Grafana Workflows is currently in [private preview](/docs/release-life-cycle/). Grafana Labs offers support on a best-effort basis, and breaking changes might occur prior to the feature being made generally available.

## Step types

Steps are the individual actions in a workflow. They execute in order from first to last. Each step has a type, an ID, and a set of inputs. Every step produces outputs that later steps can reference through the workflow context using CEL expressions, for example, `${steps.my-step.outputs.responseBody}`.

For details on connecting steps with the workflow context, refer to [Use CEL expressions](/docs/grafana-cloud/alerting-and-irm/workflows/use-expressions).

### General

#### HTTP call (`http.call`)

Make an HTTP request to any URL with any method and body. Supports bearer token and basic authentication using secrets.

**Inputs:**

Expand table

| Name           | Type           | Required | Description                                                                                                                       |
|----------------|----------------|----------|-----------------------------------------------------------------------------------------------------------------------------------|
| `method`       | string         | Yes      | HTTP method, for example, `GET`, `POST`, `PUT`, `DELETE`.                                                                         |
| `url`          | string         | Yes      | The request URL.                                                                                                                  |
| `body`         | string         | No       | The request body.                                                                                                                 |
| `headers`      | array (string) | No       | Request headers.                                                                                                                  |
| `authMethod`   | string         | No       | Authentication method: `bearer` or `basic`.                                                                                       |
| `authSecret`   | secretString   | No       | Secret for bearer token authentication. Refer to [Manage secrets](/docs/grafana-cloud/alerting-and-irm/workflows/manage-secrets). |
| `authUsername` | string         | No       | Username for basic authentication.                                                                                                |
| `authPassword` | secretString   | No       | Password for basic authentication. Refer to [Manage secrets](/docs/grafana-cloud/alerting-and-irm/workflows/manage-secrets).      |

**Outputs:**

Expand table

| Name              | Type           | Description                    |
|-------------------|----------------|--------------------------------|
| `responseCode`    | int            | The HTTP response status code. |
| `responseBody`    | string         | The response body.             |
| `responseHeaders` | array (string) | The response headers.          |

#### No operation (`noop`)

Perform no action. Use this step as a placeholder during development or as a default branch target in switch steps.

This step has no inputs and produces no outputs.

### Flow control

#### Transform (`transform`)

Evaluate a template string with embedded CEL expressions to generate dynamic content. Use `${expression}` syntax to embed expressions that reference workflow inputs and previous step outputs.

**Inputs:**

Expand table

| Name       | Type   | Required | Description                                                   |
|------------|--------|----------|---------------------------------------------------------------|
| `template` | string | Yes      | A template string with embedded `${expression}` placeholders. |

**Outputs:**

Expand table

| Name     | Type   | Description                   |
|----------|--------|-------------------------------|
| `result` | string | The rendered template string. |

#### Filter (`filter`)

Gate workflow execution on a CEL condition. If the condition evaluates to `false`, the workflow stops and no further steps execute.

**Inputs:**

Expand table

| Name        | Type   | Required | Description                                   |
|-------------|--------|----------|-----------------------------------------------|
| `condition` | string | Yes      | A CEL expression that evaluates to a boolean. |

**Outputs:**

Expand table

| Name      | Type | Description                                         |
|-----------|------|-----------------------------------------------------|
| `matched` | bool | `true` if the condition matched, `false` otherwise. |

#### Switch (`switch`)

Conditionally execute different sets of steps based on CEL expressions. Each branch has a condition and its own list of steps. The first branch whose condition evaluates to `true` runs. Include a default branch with no condition as a fallback.

For details on how to define branches, refer to [Create workflows](/docs/grafana-cloud/alerting-and-irm/workflows/create-workflows).

**Outputs:**

Expand table

| Name                 | Type   | Description                                     |
|----------------------|--------|-------------------------------------------------|
| `matchedCase`        | string | The condition expression of the matched branch. |
| `matchedBranchIndex` | int    | The zero-based index of the matched branch.     |
| `error`              | string | An error message if evaluation failed.          |

#### Wait (`wait`)

Pause workflow execution for a specified number of seconds.

**Inputs:**

Expand table

| Name      | Type | Required | Description                    |
|-----------|------|----------|--------------------------------|
| `seconds` | int  | Yes      | The number of seconds to wait. |

**Outputs:**

Expand table

| Name            | Type | Description                            |
|-----------------|------|----------------------------------------|
| `waitedSeconds` | int  | The number of seconds the step waited. |

### Incident

Incident steps operate on Grafana Incidents. You can pass incident IDs directly or reference them from incident resources loaded into the workflow context. For details on loading incident data, refer to [Load incident data](/docs/grafana-cloud/alerting-and-irm/workflows/load-incident-data).

#### Add participant to incident (`incident.add-participant`)

Add a user to a Grafana Incident with a specific role.

**Inputs:**

Expand table

| Name         | Type   | Required | Description                                                                               |
|--------------|--------|----------|-------------------------------------------------------------------------------------------|
| `incidentID` | string | Yes      | The incident ID.                                                                          |
| `userID`     | string | Yes      | The user ID or email address of the participant.                                          |
| `role`       | string | No       | The participant role: `commander`, `investigator`, or `observer`. Defaults to `observer`. |

**Outputs:**

Expand table

| Name         | Type   | Description                                       |
|--------------|--------|---------------------------------------------------|
| `success`    | bool   | `true` if the participant was added successfully. |
| `didChange`  | bool   | `true` if the participant was newly added.        |
| `incidentID` | string | The incident ID.                                  |
| `error`      | string | An error message if the operation failed.         |

#### Set incident field (`incident.set-field`)

Update a field on a Grafana Incident, including title, status, severity, or role assignments.

**Inputs:**

Expand table

| Name         | Type   | Required | Description                                                              |
|--------------|--------|----------|--------------------------------------------------------------------------|
| `incidentID` | string | Yes      | The incident ID.                                                         |
| `field`      | string | Yes      | The field to update, for example, `title`, `status`, `severity`, `role`. |
| `value`      | string | Yes      | The new value for the field.                                             |
| `userID`     | string | No       | Required when `field` is `role`. The user ID to assign the role to.      |

**Outputs:**

Expand table

| Name         | Type   | Description                                   |
|--------------|--------|-----------------------------------------------|
| `success`    | bool   | `true` if the field was updated successfully. |
| `incidentID` | string | The incident ID.                              |
| `error`      | string | An error message if the operation failed.     |

### Slack

#### Create Slack channel (`slack.channel.create`)

Create a new public or private Slack channel.

**Inputs:**

Expand table

| Name          | Type   | Required | Description                                |
|---------------|--------|----------|--------------------------------------------|
| `channelName` | string | Yes      | The name for the new channel.              |
| `isPrivate`   | bool   | No       | Set to `true` to create a private channel. |

**Outputs:**

Expand table

| Name          | Type   | Description                               |
|---------------|--------|-------------------------------------------|
| `channelID`   | string | The Slack channel ID.                     |
| `channelName` | string | The final channel name assigned by Slack. |

#### Post message to Slack channel (`slack.message.post`)

Post a message to a Slack channel. Supports plain text, Block Kit blocks for rich formatting, attachments, and threaded replies.

**Inputs:**

Expand table

| Name             | Type   | Required | Description                                                  |
|------------------|--------|----------|--------------------------------------------------------------|
| `channelID`      | string | Yes      | The Slack channel ID to post to.                             |
| `messageText`    | string | No       | Plain text message content.                                  |
| `blocks`         | string | No       | A JSON string of Slack Block Kit blocks for rich formatting. |
| `threadTs`       | string | No       | The timestamp of a parent message to reply in a thread.      |
| `replyBroadcast` | bool   | No       | Set to `true` to also post the reply to the channel.         |
| `attachments`    | string | No       | A JSON array string of Slack message attachments.            |

**Outputs:**

Expand table

| Name        | Type   | Description            |
|-------------|--------|------------------------|
| `messageID` | string | The posted message ID. |

#### Archive Slack channel (`slack.channel.archive`)

Archive a Slack channel.

**Inputs:**

Expand table

| Name        | Type   | Required | Description                      |
|-------------|--------|----------|----------------------------------|
| `channelID` | string | Yes      | The Slack channel ID to archive. |

**Outputs:**

Expand table

| Name      | Type | Description                                      |
|-----------|------|--------------------------------------------------|
| `success` | bool | `true` if the channel was archived successfully. |

#### Add bookmark to Slack channel (`slack.channel.add-bookmark`)

Add a bookmark link to a Slack channel.

**Inputs:**

Expand table

| Name            | Type   | Required | Description                            |
|-----------------|--------|----------|----------------------------------------|
| `channelID`     | string | Yes      | The Slack channel ID.                  |
| `bookmarkTitle` | string | Yes      | The title for the bookmark.            |
| `bookmarkUrl`   | string | Yes      | The URL for the bookmark.              |
| `bookmarkEmoji` | string | No       | An emoji to display with the bookmark. |

**Outputs:**

Expand table

| Name         | Type   | Description                     |
|--------------|--------|---------------------------------|
| `bookmarkID` | string | The ID of the created bookmark. |

#### Add users to Slack channel (`slack.channel.add-users`)

Invite users to a Slack channel by their Slack user IDs.

**Inputs:**

Expand table

| Name        | Type           | Required | Description                         |
|-------------|----------------|----------|-------------------------------------|
| `channelID` | string         | Yes      | The Slack channel ID.               |
| `users`     | array (string) | Yes      | A list of Slack user IDs to invite. |

**Outputs:**

Expand table

| Name      | Type | Description                                  |
|-----------|------|----------------------------------------------|
| `success` | bool | `true` if the users were added successfully. |

### IRM

#### Page user via IRM (`irm.page-user`)

Create an IRM/OnCall escalation to page a user. Optionally associates the escalation with an incident and includes urgency and message context.

**Inputs:**

Expand table

| Name             | Type   | Required | Description                                                                                                          |
|------------------|--------|----------|----------------------------------------------------------------------------------------------------------------------|
| `userIdentifier` | string | Yes      | The user identifier value, interpreted according to `identifierType`.                                                |
| `identifierType` | string | No       | Identifier mode: `id` (default), `username`, or `email`. For `email`, the step resolves the user via the OnCall API. |
| `incidentID`     | string | No       | An incident ID to associate with the escalation.                                                                     |
| `important`      | bool   | No       | Set to `true` to mark the escalation as important. Defaults to `false`.                                              |
| `message`        | string | No       | A message to attach to the escalation.                                                                               |

**Outputs:**

Expand table

| Name            | Type   | Description                                                               |
|-----------------|--------|---------------------------------------------------------------------------|
| `oncallUserID`  | string | The resolved user identifier used in the escalation.                      |
| `escalationID`  | string | The created escalation ID.                                                |
| `state`         | string | The escalation state returned by OnCall, for example, `triggered`.        |
| `alertGroupURL` | string | A permalink to the related IRM alert group, if returned. Otherwise empty. |
| `error`         | string | An error message if the operation failed. Empty on success.               |

## Trigger types

Triggers define when a workflow starts. You configure triggers in the `startWhen` section of a workflow definition. For details on configuring triggers, refer to [Configure triggers](/docs/grafana-cloud/alerting-and-irm/workflows/configure-triggers).

### Event trigger

An event trigger starts a workflow when an incoming event matches a regular expression pattern. Events arrive on NATS subjects following the format `{app}.{instance-id}.{resource-type}.{event-type}`.

You define event triggers using matching rules. Each rule contains a regex pattern that the engine tests against incoming event subjects. If any rule matches, the workflow starts.

**Configuration:**

Expand table

| Field            | Type   | Required | Description                                                                                        |
|------------------|--------|----------|----------------------------------------------------------------------------------------------------|
| `eventNameRegex` | string | Yes      | A regular expression tested against the event subject. The workflow starts if the pattern matches. |

**Example:**

YAML ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy

```yaml
startWhen:
  matchingRules:
    - eventNameRegex: "grafana_irm_app\\.incident\\.created"
    - eventNameRegex: "grafana_irm_app\\.alert_groups\\.fired"
```

A workflow can have multiple matching rules. The workflow triggers if any rule matches.

#### Available event sources

The following table lists the event sources that can trigger workflows:

Expand table

| App               | Resource       | Event types                                   | Example event name                   |
|-------------------|----------------|-----------------------------------------------|--------------------------------------|
| `grafana_irm_app` | `incident`     | `created`, `updated`, and other state changes | `grafana_irm_app.incident.created`   |
| `grafana_irm_app` | `alert_groups` | `fired` and other alert group events          | `grafana_irm_app.alert_groups.fired` |

Event names follow the pattern `{app}.{resource-type}.{event-type}`.

### Schedule trigger

A schedule trigger starts a workflow at recurring times using a cron expression. Schedules use the standard five-field Unix cron format and run in UTC.

**Configuration:**

Expand table

| Field      | Type   | Required | Description                                                           |
|------------|--------|----------|-----------------------------------------------------------------------|
| (schedule) | string | Yes      | A five-field Unix cron expression in UTC, for example, `0 9 * * 1-5`. |

**Example:**

YAML ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy

```yaml
startWhen:
  schedules:
    - "0 9 * * 1-5"
    - "0 0 1 * *"
```

A workflow can have multiple schedules. Each schedule triggers the workflow independently.

**Cron field reference:**

Expand table

| Field        | Range                    | Special characters |
|--------------|--------------------------|--------------------|
| Minute       | 0-59                     | `*`, `,`, `-`, `/` |
| Hour         | 0-23                     | `*`, `,`, `-`, `/` |
| Day of month | 1-31                     | `*`, `,`, `-`, `/` |
| Month        | 1-12                     | `*`, `,`, `-`, `/` |
| Day of week  | 0-7 (0 and 7 are Sunday) | `*`, `,`, `-`, `/` |

### Manual trigger

A manual trigger starts a workflow only through the UI or API. Any workflow can be triggered manually regardless of whether it has event or schedule triggers configured.

To trigger a workflow manually in the editor, click **Test** and provide sample input data as a JSON object.

Manual-only workflows have an empty `startWhen` section:

YAML ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy

```yaml
startWhen:
  matchingRules: []
  schedules: []
```

### Combine triggers

A workflow can have both event and schedule triggers. The workflow starts when any matching rule matches an incoming event or when any schedule fires.

YAML ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy

```yaml
startWhen:
  matchingRules:
    - eventNameRegex: "grafana_irm_app\\.incident\\.created"
  schedules:
    - "0 9 * * 1-5"
```
