---
title: "Cancel a job"
method: POST
path: "/api/v1/jobs/{jobId}/cancel"
tags: ["Job Queue"]
---

# Cancel a job

`POST /api/v1/jobs/{jobId}/cancel`

## Request

- Base URL: `https://jostens.com`
- URL: `https://jostens.com/api/v1/jobs/{jobId}/cancel`
- Auth: none declared

Sends an asynchronous cancellation request for the specified job. The job may still complete if it has already finished or cannot be interrupted.

## Path parameters

- `jobId` string, uuid, required

## Response `200`

Cancellation request accepted.

- ResponseEntityStringView
  - `errors` ErrorEntity[]
    - `errorCode` string
    - `message` string
    - `fieldName` string
  - `entity` string
  - `messages` MessageEntity[]
    - `message` string
  - `i18nMessagesMap` object
  - `permissions` string[]
  - `pagination` Pagination
    - `currentPage` integer
    - `perPage` integer
    - `totalEntries` integer

## Other responses

- `401`: Unauthorized: Invalid or missing user authentication.
- `403`: Forbidden: User does not have permission to cancel this job.
- `404`: Not Found: Job with the specified ID does not exist or is already completed/cancelled.
- `500`: Internal Server Error: An unexpected error occurred while attempting to cancel the job.

---

[API](https://skmtc.dev/jostens/apis/dotcms-rest-api.md) - [All operations](https://skmtc.dev/jostens/apis/dotcms-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/jostens/apis/dotcms-rest-api/revisions/63810c01a4c9?raw)
