---
title: "Deletes multiple cases. It is required to supply exactly one of either caseIds or query in the request body. If caseIds are supplied, cases corresponding to those caseIds will be deleted. If query is supplied, all cases that match the query will be deleted."
method: DELETE
path: "/cases"
tags: ["Case"]
---

# Deletes multiple cases. It is required to supply exactly one of either caseIds or query in the request body. If caseIds are supplied, cases corresponding to those caseIds will be deleted. If query is supplied, all cases that match the query will be deleted.

`DELETE /cases`

## Request

- Base URL: `http://localhost:3001/api`
- URL: `http://localhost:3001/api/cases`
- Auth: none declared

## Request body

- union
  - object
    - `caseIds` string[], required: Cases corresponding to these ids will be deleted
    - `query` string: Cases matching this query will be deleted. Must contain non-whitespace characters.
  - object
    - `caseIds` string[]: Cases corresponding to these ids will be deleted
    - `query` string, required: Cases matching this query will be deleted. Must contain non-whitespace characters.

## Response `204`

Cases deleted

## Other responses

- `400`: Malformed request
- `403`: Forbidden
- `404`: Not found
- `422`: Unprocessable entity
- `500`: Internal server error

## Changes

- **2022-04-19** `7b73390be316`: 2 info
  - added the media type `application/json` for the response with the status `403`
  - added the media type `application/json` for the response with the status `404`

[Operation history](https://skmtc.dev/globaldothealth/apis/global-health-curator-service-api/changes/cases/delete.md)

---

[API](https://skmtc.dev/globaldothealth/apis/global-health-curator-service-api.md) - [All operations](https://skmtc.dev/globaldothealth/apis/global-health-curator-service-api/llms.txt) - [OpenAPI document](https://skmtc.dev/globaldothealth/apis/global-health-curator-service-api/revisions/5b1151265235?raw)
