Response Class

This describes a minimal http response interface used by this package.

Inheritance
builtins.object
Response

Constructor

Response()

Variables

status_code
int

The status code of this http response.

Our async code path would also accept an alias as "status".

text
string

The body of this http response.

Our async code path would also accept an awaitable with the same name.

Methods

raise_for_status

Raise an exception when http response status contains error

raise_for_status

Raise an exception when http response status contains error

raise_for_status()

Attributes

status_code

status_code = 200

text

text = 'body as a string'