---
type: api
title: Update the connector pipeline
description: When you create a new connector, the configuration of an ingest pipeline is populated with default settings.
url: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/elasticsearch-serverless/operation/operation-connector-update-pipeline
resource: https://www.elastic.co/elastic/docs-builder/docs/4371/api/doc/elasticsearch-serverless/operation/operation-connector-update-pipeline
products:
  - Elasticsearch Serverless
---

# Update the connector pipeline

Availability:

## Paths

- `PUT` `/_connector/{connector_id}/_pipeline`

- [Api key auth](/elastic/docs-builder/docs/4371/api/doc/elasticsearch-serverless/authentication#apikeyauth)

#### Path Parameters

- `connector_id` (string Id)
  The unique identifier of the connector to be updated

## Description

When you create a new connector, the configuration of an ingest pipeline is populated with default settings.

## Request Body

`application/json`

- `pipeline` ({} IngestPipelineParams) — required
  - `extract_binary_content` (boolean) — required
  - `name` (string) — required
  - `reduce_whitespace` (boolean) — required
  - `run_ml_inference` (boolean) — required

## Response

`application/json`

- `result` (enum Result)
  Values: `created`, `updated`, `deleted`, `not_found`, `noop`
## Code Examples

#### Console

```console
PUT _connector/my-connector/_pipeline
{
    "pipeline": {
        "extract_binary_content": true,
        "name": "my-connector-pipeline",
        "reduce_whitespace": true,
        "run_ml_inference": true
    }
}
```

#### JavaScript

```javascript
const response = await client.connector.updatePipeline({
  connector_id: "my-connector",
  pipeline: {
    extract_binary_content: true,
    name: "my-connector-pipeline",
    reduce_whitespace: true,
    run_ml_inference: true,
  },
});
```

#### Python

```python
resp = client.connector.update_pipeline(
    connector_id="my-connector",
    pipeline={
        "extract_binary_content": True,
        "name": "my-connector-pipeline",
        "reduce_whitespace": True,
        "run_ml_inference": True
    },
)
```

#### curl

```curl
curl -X PUT "$ELASTICSEARCH_URL/_connector/my-connector/_pipeline" \
  -H "Authorization: ApiKey $ELASTIC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "pipeline": {
      "extract_binary_content": true,
      "name": "my-connector-pipeline",
      "reduce_whitespace": true,
      "run_ml_inference": true
    }
  }'
```

#### Java

```java
client.connector().updatePipeline(u -> u
    .connectorId("my-connector")
    .pipeline(p -> p
        .extractBinaryContent(true)
        .name("my-connector-pipeline")
        .reduceWhitespace(true)
        .runMlInference(true)
    )
);
```

#### PHP

```php
$resp = $client->connector()->updatePipeline([
    "connector_id" => "my-connector",
    "body" => [
        "pipeline" => [
            "extract_binary_content" => true,
            "name" => "my-connector-pipeline",
            "reduce_whitespace" => true,
            "run_ml_inference" => true,
        ],
    ],
]);
```

#### Ruby

```ruby
response = client.connector.update_pipeline(
  connector_id: "my-connector",
  body: {
    "pipeline": {
      "extract_binary_content": true,
      "name": "my-connector-pipeline",
      "reduce_whitespace": true,
      "run_ml_inference": true
    }
  }
)
```

## Response Examples

#### Connector update pipeline response example1

```json
{
  "result": "updated"
}
```

