Delete users API

Deletes users from the native realm.

Request

DELETE /_security/user/<username>

Prerequisites

  • To use this API, you must have at least the manage_security cluster privilege.

Description

For more information about the native realm, see Realms and Native user authentication.

Path parameters

username

(Required, string) An identifier for the user.

Examples

The following example deletes the user jacknich:

  1. DELETE /_security/user/jacknich

If the user is successfully deleted, the request returns {"found": true}. Otherwise, found is set to false.

  1. {
  2. "found" : true
  3. }