---
title: "Delete task"
method: DELETE
path: "/contracts/{contract_id}/tasks/{task_id}"
tags: ["Tasks"]
---

# Delete task

`DELETE /contracts/{contract_id}/tasks/{task_id}`

## Request

- Base URL: `https://api.letsdeel.com/rest`
- URL: `https://api.letsdeel.com/rest/contracts/{contract_id}/tasks/{task_id}`
- Auth: HTTP bearer

Removes a task from a contract when it should be dropped altogether rather than edited, and records an optional explanation with the removal. This removal cannot be undone through the API, so use it only when the task is not needed any more.

 **Token scopes**: `contracts:write`

## Path parameters

- `contract_id` string, required
- `task_id` string, required

## Query parameters

- `reason` string

## Response `200`

The task was successfully deleted.

- TasksDeleteContractTaskResponse200
  - `data` ContractsContractIdTasksTaskIdDeleteResponsesContentApplicationJsonSchemaData, required
    - `deleted` boolean, required: Indicates whether the task was successfully deleted.

## Other responses

- `400`: Invalid request. For example, missing required parameters or invalid format.
- `401`: Operation failed.
- `403`: Permission denied. The user does not have the required access to delete the task.
- `404`: The specified task or contract was not found.
- `500`: Operation failed.

---

[API](https://skmtc.dev/deel/apis/endpoints-2.md) - [All operations](https://skmtc.dev/deel/apis/endpoints-2/llms.txt) - [OpenAPI document](https://skmtc.dev/deel/apis/endpoints-2/revisions/b48979ae8a04?raw)
