// This file is autogenerated, DO NOT EDIT
// ingest/processors/redact.asciidoc:107

[source, python]
----
resp = client.ingest.simulate(
    pipeline={
        "description": "Hide my IP",
        "processors": [
            {
                "redact": {
                    "field": "message",
                    "patterns": [
                        "%{IP:REDACTED}",
                        "%{EMAILADDRESS:REDACTED}"
                    ],
                    "prefix": "*",
                    "suffix": "*"
                }
            }
        ]
    },
    docs=[
        {
            "_source": {
                "message": "55.3.244.1 GET /index.html 15824 0.043 test@elastic.co"
            }
        }
    ],
)
print(resp)
----
