Skip to content
Ona Docs

UpdateWorkflow

client.Automations.Update(ctx, body) (*AutomationUpdateResponse, error)
POST/gitpod.v1.WorkflowService/UpdateWorkflow

Updates a workflow’s configuration using full replacement semantics.

Update Behavior:

  • All provided fields completely replace existing values
  • Optional fields that are not provided remain unchanged
  • Complex fields (triggers, action) are replaced entirely, not merged
  • To remove optional fields, explicitly set them to empty/default values

Use this method to:

  • Modify workflow settings
  • Update triggers and actions
  • Change execution limits
  • Update workflow steps

Examples

  • Update workflow name:

    Changes the workflow’s display name.

    workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047"
    name: "Updated Workflow Name"
  • Replace all triggers:

    Completely replaces the workflow’s trigger configuration.

    workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047"
    triggers:
      - manual: {}
        context:
          projects:
            projectIds: ["new-project-id"]
  • Update execution limits:

    Completely replaces the workflow’s action configuration.

    workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047"
    action:
      limits:
        maxParallel: 10
        maxTotal: 100
      steps:
        - task:
            command: "npm test"
ParametersExpand Collapse
body AutomationUpdateParams
Action param.Field[WorkflowAction]Optional

WorkflowAction defines the actions to be executed in a workflow.

Description param.Field[string]Optional

Description must be at most 500 characters:

size(this) <= 500
Disabled param.Field[bool]Optional

When set, enables or disables the workflow. A disabled workflow will not be triggered by any automatic trigger and manual starts are rejected.

Executor param.Field[Subject]Optional
Name param.Field[string]Optional

Name must be between 1 and 80 characters:

size(this) >= 1 && size(this) <= 80
Report param.Field[WorkflowAction]Optional

WorkflowAction defines the actions to be executed in a workflow.

Triggers param.Field[[]WorkflowTrigger]Optional

Automation can have at most 10 triggers:

size(this) <= 10

WorkflowTriggerContext defines the context in which a workflow should run.

Context determines where and how the workflow executes:

  • Projects: Execute in specific project environments
  • Repositories: Execute in environments created from repository URLs
  • Agent: Execute in agent-managed environments with custom prompts
  • FromTrigger: Use context derived from the trigger event (PR-specific)

Context Usage by Trigger Type:

  • Manual: Can use any context type
  • Time: Typically uses Projects or Repositories context
  • PullRequest: Can use any context, FromTrigger uses PR repository context
Agent WorkflowTriggerContextAgentOptional

Execute workflow in agent-managed environments. Agent receives the specified prompt and manages execution context.

Prompt stringOptional

Agent prompt must be between 1 and 20,000 characters:

size(this) >= 1 && size(this) <= 20000
FromTrigger unknownOptional

Use context derived from the trigger event. Currently only supported for PullRequest triggers - uses PR repository context.

Projects WorkflowTriggerContextProjectsOptional

Execute workflow in specific project environments. Creates environments for each specified project.

ProjectIDs []stringOptional
Repositories WorkflowTriggerContextRepositoriesOptional

Execute workflow in environments created from repository URLs. Supports both explicit repository URLs and search patterns.

EnvironmentClassID stringOptional
formatuuid
RepoSelector WorkflowTriggerContextRepositoriesRepoSelectorOptional

RepositorySelector defines how to select repositories for workflow execution. Combines a search string with an SCM host to identify repositories.

RepoSearchString stringOptional

Search string to match repositories using SCM-specific search patterns. For GitHub: supports GitHub search syntax (e.g., “org:gitpod-io language:go”, “user:octocat stars:>100”) For GitLab: supports GitLab search syntax See SCM provider documentation for supported search patterns.

minLength1
ScmHost stringOptional

SCM host where the search should be performed (e.g., “github.com”, “gitlab.com”)

minLength1
RepositoryURLs WorkflowTriggerContextRepositoriesRepositoryURLsOptional

RepositoryURLs contains a list of explicit repository URLs. Creates one action per repository URL.

RepoURLs []stringOptional
Manual unknownOptional

Manual trigger - executed when StartWorkflow RPC is called. No additional configuration needed.

PullRequest WorkflowTriggerPullRequestOptional

Pull request trigger - executed when specified PR events occur. Only triggers for PRs in repositories matching the trigger context.

Events []WorkflowTriggerPullRequestEventOptional
One of the following:
const WorkflowTriggerPullRequestEventPullRequestEventUnspecified WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_UNSPECIFIED"
const WorkflowTriggerPullRequestEventPullRequestEventOpened WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_OPENED"
const WorkflowTriggerPullRequestEventPullRequestEventUpdated WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_UPDATED"
const WorkflowTriggerPullRequestEventPullRequestEventApproved WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_APPROVED"
const WorkflowTriggerPullRequestEventPullRequestEventMerged WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_MERGED"
const WorkflowTriggerPullRequestEventPullRequestEventClosed WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_CLOSED"
const WorkflowTriggerPullRequestEventPullRequestEventReadyForReview WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_READY_FOR_REVIEW"
IntegrationID stringOptional

integration_id is the optional ID of an integration that acts as the source of webhook events. When set, the trigger will be activated when the webhook receives events.

formatuuid
WebhookID stringOptional

webhook_id is the optional ID of a webhook that this trigger is bound to. When set, the trigger will be activated when the webhook receives events. This allows multiple workflows to share a single webhook endpoint.

formatuuid
Time WorkflowTriggerTimeOptional

Time-based trigger - executed automatically based on cron schedule. Uses standard cron expression format (minute hour day month weekday).

CronExpression stringOptional

Cron expression must be between 1 and 100 characters:

size(this) >= 1 && size(this) <= 100
WorkflowID param.Field[string]Optional
formatuuid
ReturnsExpand Collapse
type AutomationUpdateResponse struct{…}
Workflow WorkflowOptional

Workflow represents a workflow configuration.

ID stringOptional
formatuuid
Metadata WorkflowMetadataOptional

WorkflowMetadata contains workflow metadata.

CreatedAt TimeOptional

A Timestamp represents a point in time independent of any time zone or local calendar, encoded as a count of seconds and fractions of seconds at nanosecond resolution. The count is relative to an epoch at UTC midnight on January 1, 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar backwards to year one.

All minutes are 60 seconds long. Leap seconds are “smeared” so that no leap second table is needed for interpretation, using a 24-hour linear smear.

The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By restricting to that range, we ensure that we can convert to and from RFC 3339 date strings.

Examples

Example 1: Compute Timestamp from POSIX time().

 Timestamp timestamp;
 timestamp.set_seconds(time(NULL));
 timestamp.set_nanos(0);

Example 2: Compute Timestamp from POSIX gettimeofday().

 struct timeval tv;
 gettimeofday(&tv, NULL);

 Timestamp timestamp;
 timestamp.set_seconds(tv.tv_sec);
 timestamp.set_nanos(tv.tv_usec * 1000);

Example 3: Compute Timestamp from Win32 GetSystemTimeAsFileTime().

 FILETIME ft;
 GetSystemTimeAsFileTime(&ft);
 UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime;

 // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z
 // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z.
 Timestamp timestamp;
 timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL));
 timestamp.set_nanos((INT32) ((ticks % 10000000) * 100));

Example 4: Compute Timestamp from Java System.currentTimeMillis().

 long millis = System.currentTimeMillis();

 Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000)
     .setNanos((int) ((millis % 1000) * 1000000)).build();

Example 5: Compute Timestamp from Java Instant.now().

 Instant now = Instant.now();

 Timestamp timestamp =
     Timestamp.newBuilder().setSeconds(now.getEpochSecond())
         .setNanos(now.getNano()).build();

Example 6: Compute Timestamp from current time in Python.

 timestamp = Timestamp()
 timestamp.GetCurrentTime()

JSON Mapping

In JSON format, the Timestamp type is encoded as a string in the RFC 3339 format. That is, the format is “{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z” where {year} is always expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution), are optional. The “Z” suffix indicates the timezone (“UTC”); the timezone is required. A proto3 JSON serializer should always use UTC (as indicated by “Z”) when printing the Timestamp type and a proto3 JSON parser should be able to accept both UTC and other timezones (as indicated by an offset).

For example, “2017-01-15T01:30:15.01Z” encodes 15.01 seconds past 01:30 UTC on January 15, 2017.

In JavaScript, one can convert a Date object to this format using the standard toISOString() method. In Python, a standard datetime.datetime object can be converted to this format using strftime with the time format spec ‘%Y-%m-%dT%H:%M:%S.%fZ’. Likewise, in Java, one can use the Joda Time’s ISODateTimeFormat.dateTime() to obtain a formatter capable of generating timestamps in this format.

formatdate-time
Creator SubjectOptional
ID stringOptional

id is the UUID of the subject

formatuuid
Principal PrincipalOptional

Principal is the principal of the subject

One of the following:
const PrincipalUnspecified Principal = "PRINCIPAL_UNSPECIFIED"
const PrincipalAccount Principal = "PRINCIPAL_ACCOUNT"
const PrincipalUser Principal = "PRINCIPAL_USER"
const PrincipalRunner Principal = "PRINCIPAL_RUNNER"
const PrincipalEnvironment Principal = "PRINCIPAL_ENVIRONMENT"
const PrincipalServiceAccount Principal = "PRINCIPAL_SERVICE_ACCOUNT"
const PrincipalRunnerManager Principal = "PRINCIPAL_RUNNER_MANAGER"
Description stringOptional
maxLength500
Executor SubjectOptional
ID stringOptional

id is the UUID of the subject

formatuuid
Principal PrincipalOptional

Principal is the principal of the subject

One of the following:
const PrincipalUnspecified Principal = "PRINCIPAL_UNSPECIFIED"
const PrincipalAccount Principal = "PRINCIPAL_ACCOUNT"
const PrincipalUser Principal = "PRINCIPAL_USER"
const PrincipalRunner Principal = "PRINCIPAL_RUNNER"
const PrincipalEnvironment Principal = "PRINCIPAL_ENVIRONMENT"
const PrincipalServiceAccount Principal = "PRINCIPAL_SERVICE_ACCOUNT"
const PrincipalRunnerManager Principal = "PRINCIPAL_RUNNER_MANAGER"
Name stringOptional
maxLength80
minLength1
UpdatedAt TimeOptional

A Timestamp represents a point in time independent of any time zone or local calendar, encoded as a count of seconds and fractions of seconds at nanosecond resolution. The count is relative to an epoch at UTC midnight on January 1, 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar backwards to year one.

All minutes are 60 seconds long. Leap seconds are “smeared” so that no leap second table is needed for interpretation, using a 24-hour linear smear.

The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By restricting to that range, we ensure that we can convert to and from RFC 3339 date strings.

Examples

Example 1: Compute Timestamp from POSIX time().

 Timestamp timestamp;
 timestamp.set_seconds(time(NULL));
 timestamp.set_nanos(0);

Example 2: Compute Timestamp from POSIX gettimeofday().

 struct timeval tv;
 gettimeofday(&tv, NULL);

 Timestamp timestamp;
 timestamp.set_seconds(tv.tv_sec);
 timestamp.set_nanos(tv.tv_usec * 1000);

Example 3: Compute Timestamp from Win32 GetSystemTimeAsFileTime().

 FILETIME ft;
 GetSystemTimeAsFileTime(&ft);
 UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime;

 // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z
 // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z.
 Timestamp timestamp;
 timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL));
 timestamp.set_nanos((INT32) ((ticks % 10000000) * 100));

Example 4: Compute Timestamp from Java System.currentTimeMillis().

 long millis = System.currentTimeMillis();

 Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000)
     .setNanos((int) ((millis % 1000) * 1000000)).build();

Example 5: Compute Timestamp from Java Instant.now().

 Instant now = Instant.now();

 Timestamp timestamp =
     Timestamp.newBuilder().setSeconds(now.getEpochSecond())
         .setNanos(now.getNano()).build();

Example 6: Compute Timestamp from current time in Python.

 timestamp = Timestamp()
 timestamp.GetCurrentTime()

JSON Mapping

In JSON format, the Timestamp type is encoded as a string in the RFC 3339 format. That is, the format is “{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z” where {year} is always expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution), are optional. The “Z” suffix indicates the timezone (“UTC”); the timezone is required. A proto3 JSON serializer should always use UTC (as indicated by “Z”) when printing the Timestamp type and a proto3 JSON parser should be able to accept both UTC and other timezones (as indicated by an offset).

For example, “2017-01-15T01:30:15.01Z” encodes 15.01 seconds past 01:30 UTC on January 15, 2017.

In JavaScript, one can convert a Date object to this format using the standard toISOString() method. In Python, a standard datetime.datetime object can be converted to this format using strftime with the time format spec ‘%Y-%m-%dT%H:%M:%S.%fZ’. Likewise, in Java, one can use the Joda Time’s ISODateTimeFormat.dateTime() to obtain a formatter capable of generating timestamps in this format.

formatdate-time
Spec WorkflowSpecOptional
Action WorkflowActionOptional

WorkflowAction defines the actions to be executed in a workflow.

Limits WorkflowActionLimits

Limits defines execution limits for workflow actions. Concurrent actions limit cannot exceed total actions limit:

this.max_parallel <= this.max_total
MaxParallel int64Optional

Maximum parallel actions must be between 1 and 25:

this >= 1 && this <= 25
formatint32
MaxTotal int64Optional

Maximum total actions must be between 1 and 100:

this >= 1 && this <= 100
formatint32
PerExecution WorkflowActionLimitsPerExecutionOptional

PerExecution defines limits per execution action.

MaxTime stringOptional

Maximum time allowed for a single execution action. Use standard duration format (e.g., “30m” for 30 minutes, “2h” for 2 hours).

formatregex
Steps []WorkflowStepOptional

Automation must have between 1 and 50 steps:

size(this) >= 1 && size(this) <= 50
Agent WorkflowStepAgentOptional

WorkflowAgentStep represents an agent step that executes with a prompt.

Prompt stringOptional

Prompt must be between 1 and 20,000 characters:

size(this) >= 1 && size(this) <= 20000
PullRequest WorkflowStepPullRequestOptional

WorkflowPullRequestStep represents a pull request creation step.

Branch stringOptional

Branch name must be between 1 and 255 characters:

size(this) >= 1 && size(this) <= 255
Description stringOptional

Description must be at most 20,000 characters:

size(this) <= 20000
Draft boolOptional
Title stringOptional

Title must be between 1 and 500 characters:

size(this) >= 1 && size(this) <= 500
Task WorkflowStepTaskOptional

WorkflowTaskStep represents a task step that executes a command.

Command stringOptional

Command must be between 1 and 20,000 characters:

size(this) >= 1 && size(this) <= 20000
Report WorkflowActionOptional

WorkflowAction defines the actions to be executed in a workflow.

Limits WorkflowActionLimits

Limits defines execution limits for workflow actions. Concurrent actions limit cannot exceed total actions limit:

this.max_parallel <= this.max_total
MaxParallel int64Optional

Maximum parallel actions must be between 1 and 25:

this >= 1 && this <= 25
formatint32
MaxTotal int64Optional

Maximum total actions must be between 1 and 100:

this >= 1 && this <= 100
formatint32
PerExecution WorkflowActionLimitsPerExecutionOptional

PerExecution defines limits per execution action.

MaxTime stringOptional

Maximum time allowed for a single execution action. Use standard duration format (e.g., “30m” for 30 minutes, “2h” for 2 hours).

formatregex
Steps []WorkflowStepOptional

Automation must have between 1 and 50 steps:

size(this) >= 1 && size(this) <= 50
Agent WorkflowStepAgentOptional

WorkflowAgentStep represents an agent step that executes with a prompt.

Prompt stringOptional

Prompt must be between 1 and 20,000 characters:

size(this) >= 1 && size(this) <= 20000
PullRequest WorkflowStepPullRequestOptional

WorkflowPullRequestStep represents a pull request creation step.

Branch stringOptional

Branch name must be between 1 and 255 characters:

size(this) >= 1 && size(this) <= 255
Description stringOptional

Description must be at most 20,000 characters:

size(this) <= 20000
Draft boolOptional
Title stringOptional

Title must be between 1 and 500 characters:

size(this) >= 1 && size(this) <= 500
Task WorkflowStepTaskOptional

WorkflowTaskStep represents a task step that executes a command.

Command stringOptional

Command must be between 1 and 20,000 characters:

size(this) >= 1 && size(this) <= 20000
Triggers []WorkflowTriggerOptional

WorkflowTriggerContext defines the context in which a workflow should run.

Context determines where and how the workflow executes:

  • Projects: Execute in specific project environments
  • Repositories: Execute in environments created from repository URLs
  • Agent: Execute in agent-managed environments with custom prompts
  • FromTrigger: Use context derived from the trigger event (PR-specific)

Context Usage by Trigger Type:

  • Manual: Can use any context type
  • Time: Typically uses Projects or Repositories context
  • PullRequest: Can use any context, FromTrigger uses PR repository context
Agent WorkflowTriggerContextAgentOptional

Execute workflow in agent-managed environments. Agent receives the specified prompt and manages execution context.

Prompt stringOptional

Agent prompt must be between 1 and 20,000 characters:

size(this) >= 1 && size(this) <= 20000
FromTrigger unknownOptional

Use context derived from the trigger event. Currently only supported for PullRequest triggers - uses PR repository context.

Projects WorkflowTriggerContextProjectsOptional

Execute workflow in specific project environments. Creates environments for each specified project.

ProjectIDs []stringOptional
Repositories WorkflowTriggerContextRepositoriesOptional

Execute workflow in environments created from repository URLs. Supports both explicit repository URLs and search patterns.

EnvironmentClassID stringOptional
formatuuid
RepoSelector WorkflowTriggerContextRepositoriesRepoSelectorOptional

RepositorySelector defines how to select repositories for workflow execution. Combines a search string with an SCM host to identify repositories.

RepoSearchString stringOptional

Search string to match repositories using SCM-specific search patterns. For GitHub: supports GitHub search syntax (e.g., “org:gitpod-io language:go”, “user:octocat stars:>100”) For GitLab: supports GitLab search syntax See SCM provider documentation for supported search patterns.

minLength1
ScmHost stringOptional

SCM host where the search should be performed (e.g., “github.com”, “gitlab.com”)

minLength1
RepositoryURLs WorkflowTriggerContextRepositoriesRepositoryURLsOptional

RepositoryURLs contains a list of explicit repository URLs. Creates one action per repository URL.

RepoURLs []stringOptional
Manual unknownOptional

Manual trigger - executed when StartWorkflow RPC is called. No additional configuration needed.

PullRequest WorkflowTriggerPullRequestOptional

Pull request trigger - executed when specified PR events occur. Only triggers for PRs in repositories matching the trigger context.

Events []WorkflowTriggerPullRequestEventOptional
One of the following:
const WorkflowTriggerPullRequestEventPullRequestEventUnspecified WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_UNSPECIFIED"
const WorkflowTriggerPullRequestEventPullRequestEventOpened WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_OPENED"
const WorkflowTriggerPullRequestEventPullRequestEventUpdated WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_UPDATED"
const WorkflowTriggerPullRequestEventPullRequestEventApproved WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_APPROVED"
const WorkflowTriggerPullRequestEventPullRequestEventMerged WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_MERGED"
const WorkflowTriggerPullRequestEventPullRequestEventClosed WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_CLOSED"
const WorkflowTriggerPullRequestEventPullRequestEventReadyForReview WorkflowTriggerPullRequestEvent = "PULL_REQUEST_EVENT_READY_FOR_REVIEW"
IntegrationID stringOptional

integration_id is the optional ID of an integration that acts as the source of webhook events. When set, the trigger will be activated when the webhook receives events.

formatuuid
WebhookID stringOptional

webhook_id is the optional ID of a webhook that this trigger is bound to. When set, the trigger will be activated when the webhook receives events. This allows multiple workflows to share a single webhook endpoint.

formatuuid
Time WorkflowTriggerTimeOptional

Time-based trigger - executed automatically based on cron schedule. Uses standard cron expression format (minute hour day month weekday).

CronExpression stringOptional

Cron expression must be between 1 and 100 characters:

size(this) >= 1 && size(this) <= 100
WebhookURL stringOptional

Webhook URL for triggering this workflow via HTTP POST Format: {base_url}/workflows/{workflow_id}/webhooks

UpdateWorkflow

package main

import (
  "context"
  "fmt"

  "github.com/gitpod-io/gitpod-sdk-go"
  "github.com/gitpod-io/gitpod-sdk-go/option"
)

func main() {
  client := gitpod.NewClient(
    option.WithBearerToken("My Bearer Token"),
  )
  automation, err := client.Automations.Update(context.TODO(), gitpod.AutomationUpdateParams{
    Triggers: gitpod.F([]gitpod.WorkflowTriggerParam{gitpod.WorkflowTriggerParam{
      Context: gitpod.F(gitpod.WorkflowTriggerContextParam{
        Projects: gitpod.F(gitpod.WorkflowTriggerContextProjectsParam{
          ProjectIDs: gitpod.F([]string{"new-project-id"}),
        }),
      }),
      Manual: gitpod.F[any](map[string]interface{}{
      }),
    }}),
    WorkflowID: gitpod.F("b0e12f6c-4c67-429d-a4a6-d9838b5da047"),
  })
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", automation.Workflow)
}
{
  "workflow": {
    "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "metadata": {
      "createdAt": "2019-12-27T18:11:19.117Z",
      "creator": {
        "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
        "principal": "PRINCIPAL_UNSPECIFIED"
      },
      "description": "description",
      "executor": {
        "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
        "principal": "PRINCIPAL_UNSPECIFIED"
      },
      "name": "x",
      "updatedAt": "2019-12-27T18:11:19.117Z"
    },
    "spec": {
      "action": {
        "limits": {
          "maxParallel": 0,
          "maxTotal": 0,
          "perExecution": {
            "maxTime": "+9125115.360s"
          }
        },
        "steps": [
          {
            "agent": {
              "prompt": "prompt"
            },
            "pullRequest": {
              "branch": "branch",
              "description": "description",
              "draft": true,
              "title": "title"
            },
            "report": {
              "outputs": [
                {
                  "acceptanceCriteria": "acceptanceCriteria",
                  "boolean": {},
                  "command": "command",
                  "float": {
                    "max": 0,
                    "min": 0
                  },
                  "integer": {
                    "max": 0,
                    "min": 0
                  },
                  "key": "key",
                  "prompt": "prompt",
                  "string": {
                    "pattern": "pattern"
                  },
                  "title": "title"
                }
              ]
            },
            "task": {
              "command": "command"
            }
          }
        ]
      },
      "deleting": true,
      "disabled": true,
      "report": {
        "limits": {
          "maxParallel": 0,
          "maxTotal": 0,
          "perExecution": {
            "maxTime": "+9125115.360s"
          }
        },
        "steps": [
          {
            "agent": {
              "prompt": "prompt"
            },
            "pullRequest": {
              "branch": "branch",
              "description": "description",
              "draft": true,
              "title": "title"
            },
            "report": {
              "outputs": [
                {
                  "acceptanceCriteria": "acceptanceCriteria",
                  "boolean": {},
                  "command": "command",
                  "float": {
                    "max": 0,
                    "min": 0
                  },
                  "integer": {
                    "max": 0,
                    "min": 0
                  },
                  "key": "key",
                  "prompt": "prompt",
                  "string": {
                    "pattern": "pattern"
                  },
                  "title": "title"
                }
              ]
            },
            "task": {
              "command": "command"
            }
          }
        ]
      },
      "triggers": [
        {
          "context": {
            "agent": {
              "prompt": "prompt"
            },
            "fromTrigger": {},
            "projects": {
              "projectIds": [
                "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"
              ]
            },
            "repositories": {
              "environmentClassId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
              "repoSelector": {
                "repoSearchString": "x",
                "scmHost": "x"
              },
              "repositoryUrls": {
                "repoUrls": [
                  "x"
                ]
              }
            }
          },
          "manual": {},
          "pullRequest": {
            "events": [
              "PULL_REQUEST_EVENT_UNSPECIFIED"
            ],
            "integrationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
            "webhookId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"
          },
          "time": {
            "cronExpression": "cronExpression"
          }
        }
      ]
    },
    "webhookUrl": "webhookUrl"
  }
}
Returns Examples
{
  "workflow": {
    "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
    "metadata": {
      "createdAt": "2019-12-27T18:11:19.117Z",
      "creator": {
        "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
        "principal": "PRINCIPAL_UNSPECIFIED"
      },
      "description": "description",
      "executor": {
        "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
        "principal": "PRINCIPAL_UNSPECIFIED"
      },
      "name": "x",
      "updatedAt": "2019-12-27T18:11:19.117Z"
    },
    "spec": {
      "action": {
        "limits": {
          "maxParallel": 0,
          "maxTotal": 0,
          "perExecution": {
            "maxTime": "+9125115.360s"
          }
        },
        "steps": [
          {
            "agent": {
              "prompt": "prompt"
            },
            "pullRequest": {
              "branch": "branch",
              "description": "description",
              "draft": true,
              "title": "title"
            },
            "report": {
              "outputs": [
                {
                  "acceptanceCriteria": "acceptanceCriteria",
                  "boolean": {},
                  "command": "command",
                  "float": {
                    "max": 0,
                    "min": 0
                  },
                  "integer": {
                    "max": 0,
                    "min": 0
                  },
                  "key": "key",
                  "prompt": "prompt",
                  "string": {
                    "pattern": "pattern"
                  },
                  "title": "title"
                }
              ]
            },
            "task": {
              "command": "command"
            }
          }
        ]
      },
      "deleting": true,
      "disabled": true,
      "report": {
        "limits": {
          "maxParallel": 0,
          "maxTotal": 0,
          "perExecution": {
            "maxTime": "+9125115.360s"
          }
        },
        "steps": [
          {
            "agent": {
              "prompt": "prompt"
            },
            "pullRequest": {
              "branch": "branch",
              "description": "description",
              "draft": true,
              "title": "title"
            },
            "report": {
              "outputs": [
                {
                  "acceptanceCriteria": "acceptanceCriteria",
                  "boolean": {},
                  "command": "command",
                  "float": {
                    "max": 0,
                    "min": 0
                  },
                  "integer": {
                    "max": 0,
                    "min": 0
                  },
                  "key": "key",
                  "prompt": "prompt",
                  "string": {
                    "pattern": "pattern"
                  },
                  "title": "title"
                }
              ]
            },
            "task": {
              "command": "command"
            }
          }
        ]
      },
      "triggers": [
        {
          "context": {
            "agent": {
              "prompt": "prompt"
            },
            "fromTrigger": {},
            "projects": {
              "projectIds": [
                "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"
              ]
            },
            "repositories": {
              "environmentClassId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
              "repoSelector": {
                "repoSearchString": "x",
                "scmHost": "x"
              },
              "repositoryUrls": {
                "repoUrls": [
                  "x"
                ]
              }
            }
          },
          "manual": {},
          "pullRequest": {
            "events": [
              "PULL_REQUEST_EVENT_UNSPECIFIED"
            ],
            "integrationId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
            "webhookId": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"
          },
          "time": {
            "cronExpression": "cronExpression"
          }
        }
      ]
    },
    "webhookUrl": "webhookUrl"
  }
}