Response object¶
- code:
HTTP status code,
- data:
data part of HTTP response,
- headers:
HTTP headers,
- cookies:
cookies,
- callback:
function that builds completely custom request
- sleep:
amount of time to wait before send response data
Response object is a dict with keys:
response :: code¶
- type:
intHTTP status code
response :: data¶
- type:
bytesbody of HTTP response
response :: headers¶
- type:
listHTTP headers
response :: path¶
- type:
strThe path fragment of the requested URL
response :: callback¶
- type:
function
The function that builds custom response
response :: sleep¶
- type:
intTime to wait before send data to HTTP client