Create connector sync job API
This functionality is in beta and is subject to change. The design and code is less mature than official GA features and is being provided as-is with no warranties. Beta features are not subject to the support SLA of official GA features.
Creates a connector sync job.
To get started with Connector APIs, check out our tutorial.
resp = client.perform_request(
"POST",
"/_connector/_sync_job",
headers={"Content-Type": "application/json"},
body={
"id": "connector-id",
"job_type": "full",
"trigger_method": "on_demand"
},
)
print(resp) response = client.connector.sync_job_post(
body: {
id: 'connector-id',
job_type: 'full',
trigger_method: 'on_demand'
}
)
puts response const response = await client.transport.request({
method: "POST",
path: "/_connector/_sync_job",
body: {
id: "connector-id",
job_type: "full",
trigger_method: "on_demand",
},
});
console.log(response); POST _connector/_sync_job
{
"id": "connector-id",
"job_type": "full",
"trigger_method": "on_demand"
} Request
POST _connector/_sync_job
Prerequisites
- To sync data using self-managed connectors, you need to deploy the Elastic connector service. on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors.
- The
idparameter should reference an existing connector.
Description
Creates a connector sync job document in the internal index and initializes its counters and timestamps with default values. Certain values can be updated via the API.
Request body
-
id - (Required, string) The id of the connector to create the sync job for.
-
job_type - (Optional, string) The job type of the created sync job. Defaults to
full. -
trigger_method - (Optional, string) The trigger method of the created sync job. Defaults to
on_demand.
Response body
-
id - (string) The ID associated with the connector sync job document.
Response codes
-
201 - Indicates that the connector sync job was created successfully.
-
400 - Indicates that the request was malformed.
-
404 - Indicates that either the index or the referenced connector is missing.
© 2023-2025 Elasticsearch
As of September 2024, Elasticsearch is available under a choice of three licenses: the Server Side Public License (SSPL), the Elastic License, or the AGPLv3 (OSI approved).
Elasticsearch and the Elasticsearch logo are trademarks of Elasticsearch B.V., registered in the U.S. and in other countries.
https://www.elastic.co/guide/en/elasticsearch/reference/8.17/create-connector-sync-job-api.html