---
title: "CancelJob"
method: POST
path: "/depot.ci.v1.CIService/CancelJob"
tags: ["CIService"]
---

# CancelJob

`POST /depot.ci.v1.CIService/CancelJob`

## Request

- Base URL: `https://api.depot.dev`
- URL: `https://api.depot.dev/depot.ci.v1.CIService/CancelJob`
- Auth: HTTP bearer

Cancels a queued, waiting, or running job and its active attempt.

## Headers

- `Connect-Protocol-Version` 1, required: Define the version of the Connect protocol
- `Connect-Timeout-Ms` number: Define the timeout, in ms

## Request body

- DepotCiV1CancelJobRequest
  - `workflowId` string, required: Unique identifier for the workflow containing the job. Returned by `GetRunStatus` and `ListWorkflows`.
  - `jobId` string, required: Unique identifier for the job to cancel. Returned by `GetRunStatus` and `GetWorkflow`.

## Response `200`

Success

- DepotCiV1CancelJobResponse
  - `jobId` string: Unique identifier for the job. Matches the request `jobId`.
  - `status` string: Updated job status. Should be "cancelled".

## Other responses

- `default`: Error

---

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