# Api python for update with ?pipeline=opennlp-pipeline parameter

**URL:** <https://discuss.elastic.co/t/api-python-for-update-with-pipeline-opennlp-pipeline-parameter/297228>\
**Category:** Elasticsearch\
**Tags:** language-clients\
**Created:** [February 15, 2022, 10:25am UTC](https://discuss.elastic.co/t/api-python-for-update-with-pipeline-opennlp-pipeline-parameter/297228 "2022-02-15T10:25:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![zabitelasticsearch](https://avatars.discourse-cdn.com/v4/letter/z/8dc957/32.png) [@zabitelasticsearch](https://discuss.elastic.co/u/zabitelasticsearch)\
**Post date:** [February 15, 2022, 10:25am UTC](https://discuss.elastic.co/t/api-python-for-update-with-pipeline-opennlp-pipeline-parameter/297228/1 "2022-02-15T10:25:29Z")

</div>

Hi,  
I use python library to query Elasticsearch.

```auto
from elasticsearch import Elasticsearch

 clearedText = "Kobe Bryant was one of the best basketball players of all times. Not even Michael Jordan has ever scored 81 points in one game. Munich is really an awesome city, but New York is as well. Yesterday has been the hottest day of the year."

 docId = "0mlxun4BYyp6RT6bXA1C"

 source_to_update = {
      "doc" : { "text": clearedText }
  }

  response = elasticClient.update(index='civile', doc_type="_doc", id=docId, body=source_to_update)
  print ('docId:',docId,"result:",response["result"],"response _shards:",response["_shards"]['successful'])

```

Specifically I want pass: ?pipeline=opennlp-pipeline parameter  
to update statement like this

```auto
PUT /civile/_doc/0mlxun4BYyp6RT6bXA1C?pipeline=opennlp-pipeline
{
  "text": "Kobe Bryant was one of the best basketball players of all times. Not even Michael Jordan has ever scored 81 points in one game. Munich is really an awesome city, but New York is as well. Yesterday has been the hottest day of the year."
}

```

how to achieve this but in python?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 15, 2022, 10:26am UTC](https://discuss.elastic.co/t/api-python-for-update-with-pipeline-opennlp-pipeline-parameter/297228/2 "2022-03-15T10:26:13Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
