def METHOD_NAME(request,
            response,
            status_code = 200,
            content_type = b"text/html",
            payload_generator = __noop,
            cache_control = b"no-cache; must-revalidate",
            access_control_allow_origin = b"*",
            maybe_additional_headers = None):
    if preprocess_redirection(request, response):
        return
    if preprocess_stash_action(request, response):
        return
    response.add_required_headers = False
    response.writer.write_status(status_code)
    if access_control_allow_origin != None:
        response.writer.write_header(b"access-control-allow-origin",
                                     access_control_allow_origin)
    response.writer.write_header(b"content-type", content_type)
    response.writer.write_header(b"cache-control", cache_control)
    additional_headers = maybe_additional_headers or {}
    for header, value in additional_headers.items():
        response.writer.write_header(header, value)
    response.writer.end_headers()
    new_headers = {}
    new_val = []
    for key, val in request.headers.items():
        if len(val) == 1:
            new_val = isomorphic_decode(val[0])
        else:
            new_val = [isomorphic_decode(x) for x in val]
        new_headers[isomorphic_decode(key)] = new_val
    server_data = {u"headers": json.dumps(new_headers, indent = 4)}
    payload = payload_generator(server_data)
    response.writer.write(payload)