python - How do i get the HTTP headers in a Google App Engine webapp2 requesthandler -
how access http headers of request calls method?
class getdbversion(webapp2.requesthandler): def get(self): # writes out db version
in main.py
app = webapp2.wsgiapplication([ ('/version', getdbversion # , more methods
do inside class webapp2.requesthandler.
self.request.headers
it give dict of headers.
Comments
Post a Comment