slm-get-status.asciidoc 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. [[slm-api-get-status]]
  2. === Get {slm} status API
  3. [subs="attributes"]
  4. ++++
  5. <titleabbrev>Get {slm} status</titleabbrev>
  6. ++++
  7. Retrieves the status of {slm} ({slm-init}).
  8. [[slm-api-get-status-request]]
  9. ==== {api-request-title}
  10. `GET /_slm/status`
  11. [[slm-api-get-status-desc]]
  12. ==== {api-description-title}
  13. Returns the status of the {slm-init} plugin.
  14. The `operation_mode` field in the response shows one of three states:
  15. `STARTED`, `STOPPING`, or `STOPPED`.
  16. You halt and restart the {slm-init} plugin with the
  17. <<slm-api-stop, stop>> and <<slm-api-start, start>> APIs.
  18. ==== {api-query-parms-title}
  19. include::{docdir}/rest-api/common-parms.asciidoc[tag=timeoutparms]
  20. [[slm-api-get-status-prereqs]]
  21. ==== {api-prereq-title}
  22. If the {es} {security-features} are enabled, you must have the
  23. `manage_slm` or `read_slm` cluster privileges to use this API.
  24. For more information, see <<security-privileges>>.
  25. [[slm-api-get-status-example]]
  26. ==== {api-examples-title}
  27. [source,console]
  28. --------------------------------------------------
  29. GET _slm/status
  30. --------------------------------------------------
  31. The API returns the following result:
  32. [source,console-result]
  33. --------------------------------------------------
  34. {
  35. "operation_mode": "RUNNING"
  36. }
  37. --------------------------------------------------
  38. // TESTRESPONSE[s/"operation_mode": "RUNNING"/"operation_mode": $body.operation_mode/]