enable-user-profile.asciidoc 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. [role="xpack"]
  2. [[security-api-enable-user-profile]]
  3. === Enable user profile API
  4. ++++
  5. <titleabbrev>Enable user profile</titleabbrev>
  6. ++++
  7. beta::[]
  8. Enables a user profile so it's visible in
  9. <<security-api-suggest-user-profile,user profile searches>>.
  10. [[security-api-enable-user-profile-request]]
  11. ==== {api-request-title}
  12. `POST /_security/profile/<uid>/_enable`
  13. `PUT /_security/profile/<uid>/_enable`
  14. [[security-api-enable-user-profile-prereqs]]
  15. ==== {api-prereq-title}
  16. To use this API, you must have the `manage_user_profile` cluster privilege.
  17. [[security-api-enable-user-profile-desc]]
  18. ==== {api-description-title}
  19. When you <<security-api-activiate-user-profile,activate a user profile>>, it's
  20. automatically enabled and visible in user profile searches. If you later
  21. <<security-api-disable-user-profile,disable the user profile>>, you can use the
  22. enable user profile API to make the profile visible in these searches again.
  23. [[security-api-enable-user-profile-path-params]]
  24. ==== {api-path-parms-title}
  25. `<uid>`::
  26. (Required, string) Unique identifier for the user profile.
  27. [[security-api-enable-user-profile-query-params]]
  28. ==== {api-query-parms-title}
  29. include::{es-repo-dir}/rest-api/common-parms.asciidoc[tag=refresh]
  30. [[security-api-enable-user-profile-example]]
  31. ==== {api-examples-title}
  32. The following request enables the user profile for a `uid` matching
  33. `u_kd2JMqwUQwSCCOxMv7M1vw`:
  34. [source,console]
  35. ----
  36. POST /_security/profile/u_kd2JMqwUQwSCCOxMv7M1vw/_enable
  37. ----
  38. // TEST[skip:uid is random and no way to ensure this uid exists]