Top module doc string

Module Contents



A helper class that make request handling easier

class Aeros.Request.EasyRequest[source]

A helper class that make request handling easier

All attributes are assessable via the same syntax, while with Flask.request or quart.request, you will have slightly different syntax when retrieving different request attributes.


You only need to await attributes that need calculation, for example evaluating the request body, like .json or .form.

headers = EasyRequest.headers
params = EasyRequest.params
form = await EasyRequest.form # requires time for calculation
json = await EasyRequest.json # requires time for calculation
params :dict

The URL parameters like Flask.request.params.

headers :dict

The request headers like Flask.request.headers.

__quart_request :request

The Flask.request. instance that is used in the current scope.


loads the content of Flask.request into this instance and returns it.

__call__(self, f)[source]

Decorates an endpoint function to use the EasyRequest with.

async property form(self)

The request form data like Flask.request.form.

async property json(self)

The request body data (as JSON) like Flask.request.form.

Be aware that in order for Flask.request.get_json() to return a JSON dictionary, the Content-Type header must be set to application/json.