http-accept-header-checker.py (287B)
1 def main(request, response): 2 accept = request.headers.get(b"accept", b"") 3 response_headers = [(b"Content-Type", b"application/json"), 4 (b"Access-Control-Allow-Origin", b"*")] 5 return (200, response_headers, 6 b'{"accept": "' + accept + b'"}')