---
title: "Execute a workflow"
method: POST
path: "/workflows/definitions/{id}/execute"
tags: ["Workflow executions"]
---

# Execute a workflow

`POST /workflows/definitions/{id}/execute`

## Request

- Base URL: `https://api.nullplatform.com`
- URL: `https://api.nullplatform.com/workflows/definitions/{id}/execute`
- Auth: HTTP bearer

Starts an execution of the revision resolved by `alias` (default `latest`) or `revision`. With an `idempotencyKey`, retries return the original execution with 200 and `deduplicated: true`.

## Path parameters

- `id` string, required

## Query parameters

- `alias` string
- `revision` integer

## Request body

- object
  - `inputs` object: Run inputs, matching the workflow's declared inputs.
  - `correlationKey` string: Key for targeting this execution with signals later.
  - `idempotencyKey` string: Unique per workflow. Retries with the same key return the original execution.

## Response `200`

An execution with this `idempotencyKey` already exists.

- object
  - `execution` Execution
    - `id` string, required
    - `workflowId` string, required
    - `revision` integer, required
    - `aliasName` string
    - `organizationId` string
    - `correlationKey` string: Client-chosen key used to target the execution with signals.
    - `idempotencyKey` string
    - `status` 'pending' | 'running' | 'completed' | 'failed' | 'cancelled' | 'timed_out', required
    - `inputs` object, required: Run inputs. Credential-named keys are masked on reads.
    - `outputs` object
    - `variables` object
    - `error` StepError
      - `code` string, required
      - `message` string, required
      - `details` object
      - `retryable` boolean
    - `parentExecutionId` string: Present on sub-workflow executions.
    - `parentStepId` string
    - `metadata` object
    - `startedAt` string, date-time, required
    - `updatedAt` string, date-time, required
    - `completedAt` string, date-time
  - `deduplicated` true

## Other responses

- `202`: The execution was accepted and started.
- `4XX`: Client error. The body says what went wrong: an error `type`, a human-readable `detail`, and, on validation failures, one entry per offending field.
- `5XX`: Unexpected server error.

## Changes

- **2026-09-17** `43b3c1ecdfd8`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/nullplatform/apis/nullplatform-api/changes/workflows/definitions/:id/execute/post.md)

---

[API](https://skmtc.dev/nullplatform/apis/nullplatform-api.md) - [All operations](https://skmtc.dev/nullplatform/apis/nullplatform-api/llms.txt) - [OpenAPI document](https://skmtc.dev/nullplatform/apis/nullplatform-api/revisions/d3f66bc633d4?raw)
