put-calendar-job.asciidoc 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. --
  2. :api: put-calendar-job
  3. :request: PutCalendarJobRequest
  4. :response: PutCalendarResponse
  5. --
  6. [role="xpack"]
  7. [id="{upid}-{api}"]
  8. === Put {anomaly-jobs} in calendar API
  9. Adds {anomaly-jobs} jobs to an existing {ml} calendar.
  10. The API accepts a +{request}+ and responds
  11. with a +{response}+ object.
  12. [id="{upid}-{api}-request"]
  13. ==== Put {anomaly-jobs} in calendar request
  14. A +{request}+ is constructed referencing a non-null
  15. calendar ID, and JobIDs to which to add to the calendar
  16. ["source","java",subs="attributes,callouts,macros"]
  17. --------------------------------------------------
  18. include-tagged::{doc-tests-file}[{api}-request]
  19. --------------------------------------------------
  20. <1> The ID of the calendar to which to add the jobs
  21. <2> The JobIds to add to the calendar
  22. [id="{upid}-{api}-response"]
  23. ==== Put {anomaly-jobs} in calendar response
  24. The returned +{response}+ contains the updated calendar:
  25. ["source","java",subs="attributes,callouts,macros"]
  26. --------------------------------------------------
  27. include-tagged::{doc-tests-file}[{api}-response]
  28. --------------------------------------------------
  29. <1> The updated calendar
  30. include::../execution.asciidoc[]