123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- [role="xpack"]
- [[security-api-disable-user-profile]]
- === Disable user profile API
- ++++
- <titleabbrev>Disable user profile</titleabbrev>
- ++++
- beta::[]
- Disables a user profile so it's not visible in
- <<security-api-suggest-user-profile,user profile searches>>.
- [[security-api-disable-user-profile-request]]
- ==== {api-request-title}
- `POST /_security/profile/<uid>/_disable`
- `PUT /_security/profile/<uid>/_disable`
- [[security-api-disable-user-profile-prereqs]]
- ==== {api-prereq-title}
- To use this API, you must have the `manage_user_profile` cluster privilege.
- [[security-api-disable-user-profile-desc]]
- ==== {api-description-title}
- When you <<security-api-activiate-user-profile,activate a user profile>>, it's
- automatically enabled and visible in user profile searches. You can use the
- disable user profile API to disable a user profile so it's not visible in
- these searches.
- To re-enable a disabled user profile, use the
- <<security-api-enable-user-profile,enable user profile API>> .
- [[security-api-disable-user-profile-path-params]]
- ==== {api-path-parms-title}
- `<uid>`::
- (Required, string) Unique identifier for the user profile.
- [[security-api-disable-user-profile-query-params]]
- ==== {api-query-parms-title}
- include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=refresh]
- [[security-api-disable-user-profile-example]]
- ==== {api-examples-title}
- The following request disables the user profile for a `uid` matching
- `u_kd2JMqwUQwSCCOxMv7M1vw`:
- [source,console]
- ----
- POST /_security/profile/u_kd2JMqwUQwSCCOxMv7M1vw/_disable
- ----
- // TEST[skip:uid is random and no way to ensure this uid exists]
|