> ## Documentation Index
> Fetch the complete documentation index at: https://schedy.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Bulk delete

> DELETE /tasks - hard-delete tasks matching a filter across all statuses.

```
DELETE /tasks
```

Hard-deletes tasks matching a filter (across all statuses). At least one filter is required.

| Query param | Description                                                                                            |
| ----------- | ------------------------------------------------------------------------------------------------------ |
| `url`       | Delete tasks targeting this exact URL.                                                                 |
| `status`    | Delete only tasks in this lifecycle status (`pending`, `running`, `succeeded`, `failed`, `cancelled`). |
| `before`    | Delete tasks scheduled before this time (RFC3339).                                                     |
| `after`     | Delete tasks scheduled after this time (RFC3339).                                                      |

```bash theme={null}
# Everything for one URL
curl -X DELETE "http://localhost:8080/tasks?url=https://example.com/webhook" \
  -H "X-API-Key: your-secret"

# Combine filters
curl -X DELETE "http://localhost:8080/tasks?url=https://example.com/webhook&before=2025-05-26T15:00:00Z" \
  -H "X-API-Key: your-secret"

# Purge every failed task
curl -X DELETE "http://localhost:8080/tasks?status=failed" \
  -H "X-API-Key: your-secret"
```

Returns `{"deleted": N}`, or `400 Bad Request` if no filter is given or a timestamp is malformed.
