check-in-connector-sync-job-api.asciidoc 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. [[check-in-connector-sync-job-api]]
  2. === Check in connector sync job API
  3. ++++
  4. <titleabbrev>Check in connector sync job</titleabbrev>
  5. ++++
  6. Checks in a connector sync job (updates `last_seen` to the current time).
  7. [[check-in-connector-sync-job-api-request]]
  8. ==== {api-request-title}
  9. `PUT _connector/_sync_job/<connector_sync_job_id>/_check_in/`
  10. [[check-in-connector-sync-job-api-prereqs]]
  11. ==== {api-prereq-title}
  12. * To sync data using connectors, it's essential to have the Elastic connectors service running.
  13. * The `connector_sync_job_id` parameter should reference an existing connector sync job.
  14. [[check-in-connector-sync-job-api-desc]]
  15. ==== {api-description-title}
  16. Checks in a connector sync job and sets `last_seen` to the time right before updating it in the internal index.
  17. [[check-in-connector-sync-job-path-params]]
  18. ==== {api-path-parms-title}
  19. `<connector_sync_job_id>`::
  20. (Required, string)
  21. [[check-in-connector-sync-job-api-response-codes]]
  22. ==== {api-response-codes-title}
  23. `200`::
  24. Connector sync job was successfully checked in.
  25. `404`::
  26. No connector sync job matching `connector_sync_job_id` could be found.
  27. [[check-in-connector-sync-job-api-example]]
  28. ==== {api-examples-title}
  29. The following example checks in the connector sync job `my-connector-sync-job`:
  30. [source,console]
  31. ----
  32. PUT _connector/_sync_job/my-connector-sync-job/_check_in
  33. ----
  34. // TEST[skip:there's no way to clean up after creating a connector sync job, as we don't know the id ahead of time. Therefore, skip this test.]