http.HttpResponse.__getitem__()

HttpResponse.__getitem__(header) Returns the value for the given header name. Case-insensitive.

http.HttpResponse.__delitem__()

HttpResponse.__delitem__(header) Deletes the header with the given name. Fails silently if the header doesn’t exist. Case-insensitive.

http.HttpResponse.writelines()

HttpResponse.writelines(lines) [source] Writes a list of lines to the response. Line separators are not added. This method makes an HttpResponse instance a stream-like object.

http.HttpResponse.write()

HttpResponse.write(content) [source] This method makes an HttpResponse instance a file-like object.

http.HttpResponse.writable()

HttpResponse.writable() [source] Always True. This method makes an HttpResponse instance a stream-like object.

http.HttpResponse.tell()

HttpResponse.tell() [source] This method makes an HttpResponse instance a file-like object.

http.HttpResponse.streaming

HttpResponse.streaming This is always False. This attribute exists so middleware can treat streaming responses differently from regular responses.

http.HttpResponse.status_code

HttpResponse.status_code The HTTP status code for the response. Changed in Django 1.9: Unless reason_phrase is explicitly set, modifying the value of status_code outside the constructor will also modify the value of reason_phrase.

http.HttpResponse.set_signed_cookie()

HttpResponse.set_signed_cookie(key, value, salt='', max_age=None, expires=None, path='/', domain=None, secure=None, httponly=True) Like set_cookie(), but cryptographic signing the cookie before setting it. Use in conjunction with HttpRequest.get_signed_cookie(). You can use the optional salt argument for added key strength, but you will need to remember to pass it to the corresponding HttpRequest.get_signed_cookie() call.

http.HttpResponse.set_cookie()

HttpResponse.set_cookie(key, value='', max_age=None, expires=None, path='/', domain=None, secure=None, httponly=False) Sets a cookie. The parameters are the same as in the Morsel cookie object in the Python standard library. max_age should be a number of seconds, or None (default) if the cookie should last only as long as the client’s browser session. If expires is not specified, it will be calculated. expires should either be a string in the format "Wdy, DD-Mon-YY HH:MM:SS GMT" or a date