Delete all documents

DELETE /indexes/{indexUid}/documents

Delete all documents in the specified index.

Path parameters

  • indexUid string Required

    Index Unique Identifier

Responses

  • 202 application/json

    Accepted

  • 401 application/json

    Unauthorized

    Hide response attributes Show response attributes object
  • 404

    Not Found

DELETE /indexes/{indexUid}/documents
curl \
 -X DELETE https://example.meilisearch.com:7700/indexes/movies/documents \
 -H "Authorization: Bearer $ACCESS_TOKEN"
Response examples (202)
{
  "taskUid": 0,
  "indexUid": "movies",
  "status": "enqueued",
  "type": "documentDeletion",
  "enqueuedAt": "2021-01-01T09:39:00.000000Z"
}
Response examples (401)
{
  "message": "The Authorization header is missing. It must use the bearer authorization method.",
  "code": "missing_authorization_header",
  "type": "auth",
  "link": "https://docs.meilisearch.com/errors#missing_authorization_header"
}