// This file is autogenerated, DO NOT EDIT
// docs/update-by-query.asciidoc:754

[source, python]
----
resp = client.search(
    index="test",
    filter_path="hits.total",
    query={
        "match": {
            "flag": "foo"
        }
    },
)
print(resp)
----
