def scheme(self): """ HTTP request scheme, which should be "http" or "https". """ if not self.data.scheme: return self.data.scheme return message._native(self.data.scheme)
def path(self): """ HTTP request path, e.g. "/index.html". Guaranteed to start with a slash, except for OPTIONS requests, which may just be "*". """ if self.data.path is None: return None else: return message._native(self.data.path)
def method(self): """ HTTP request method, e.g. "GET". """ return message._native(self.data.method).upper()
def reason(self): """ HTTP Reason Phrase, e.g. "Not Found". This is always :py:obj:`None` for HTTP2 requests, because HTTP2 responses do not contain a reason phrase. """ return message._native(self.data.reason)