mitmproxy/examples/simple/add_header.py

6 lines
119 B
Python

from mitmproxy import http
def response(flow: http.HTTPFlow) -> None:
flow.response.headers["newheader"] = "foo"