The zaqar.api.handler
module¶
-
class
Handler
(storage, control, validate, defaults)¶ Bases:
object
Defines API handler
The handler validates and process the requests
-
clean_subscriptions
(subscriptions)¶
-
static
create_request
(payload=None, env=None)¶
-
create_response
(code, body, req=None)¶
-
get_defaults
()¶
-
process_request
(req, protocol)¶
-
set_subscription_factory
(factory)¶
-
static
validate_request
(payload, req)¶ Validate a request and its payload against a schema.
Returns: a Response object if validation failed, None otherwise.
-
verify_signature
(key, payload)¶
-