Skip to content
Ona Docs

CancelWorkflowExecution

client.automations.cancelExecution(AutomationCancelExecutionParams { workflowExecutionId } body, RequestOptionsoptions?): AutomationCancelExecutionResponse
POST/gitpod.v1.WorkflowService/CancelWorkflowExecution

Cancels a running workflow execution.

Use this method to:

  • Stop long-running executions
  • Cancel failed executions
  • Manage resource usage

Examples

  • Cancel execution:

    Stops a running workflow execution.

    workflowExecutionId: "d2c94c27-3b76-4a42-b88c-95a85e392c68"
ParametersExpand Collapse
body: AutomationCancelExecutionParams { workflowExecutionId }
workflowExecutionId?: string
formatuuid
ReturnsExpand Collapse
AutomationCancelExecutionResponse = unknown

CancelWorkflowExecution

import Gitpod from '@gitpod/sdk';

const client = new Gitpod({
  bearerToken: process.env['GITPOD_API_KEY'], // This is the default and can be omitted
});

const response = await client.automations.cancelExecution({
  workflowExecutionId: 'd2c94c27-3b76-4a42-b88c-95a85e392c68',
});

console.log(response);
{}
Returns Examples
{}