---
title: "Deletes a Task from the specified Job."
method: DELETE
path: "/jobs/{jobId}/tasks/{taskId}"
tags: ["Tasks"]
---

# Deletes a Task from the specified Job.

`DELETE /jobs/{jobId}/tasks/{taskId}`

When a Task is deleted, all of the files in its directory on the Compute Node
where it ran are also deleted (regardless of the retention time). For
multi-instance Tasks, the delete Task operation applies synchronously to the
primary task; subtasks and their files are then deleted asynchronously in the
background.

## Path parameters

- `jobId` string, required
- `taskId` string, required

## Query parameters

- `api-version` string, required
- `timeOut` integer

## Headers

- `client-request-id` string
- `return-client-request-id` boolean
- `ocp-date` string, date-time-rfc7231
- `If-Modified-Since` string, date-time-rfc7231
- `If-Unmodified-Since` string, date-time-rfc7231
- `If-Match` string
- `If-None-Match` string

## Response `200`

The request has succeeded.

## Other responses

- `default` — An unexpected error response.

## Changes

- **2026-07-13** `8427acd8fd77` — 1 warning, 2 info
  - deleted the `query` request parameter `timeout`
  - api operation id `Task_Delete` removed and replaced with `Tasks_DeleteTask`
  - added the new optional `query` request parameter `timeOut`

[Change history](https://skmtc.dev/azure/apis/batch-batch/changes/jobs/:jobId/tasks/:taskId/delete.md)

---

[API](https://skmtc.dev/azure/apis/batch-batch.md) · [All operations](https://skmtc.dev/azure/apis/batch-batch/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/azure/batch-batch/revisions/8427acd8fd77/schema)
