From 3c2ba96e052264d8f5e277b487b753965de6d7b6 Mon Sep 17 00:00:00 2001 From: Stefan Haun Date: Mon, 28 Sep 2020 00:07:00 +0200 Subject: [PATCH] Add routing for entities handlers --- app.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app.py b/app.py index 2507d97..5c880cf 100644 --- a/app.py +++ b/app.py @@ -89,11 +89,13 @@ class Oas3Handler(tornado.web.RequestHandler, metaclass=ABCMeta): self.finish() -def make_app(_auth_provider=None): +def make_app(auth_provider=None): version_path = r"/v[0-9]" return tornado.web.Application([ (version_path + r"/health", HealthHandler), (version_path + r"/oas3", Oas3Handler), + (version_path + r"/entities", AllEntitiesHandler, {"auth_provider": auth_provider}), + (version_path + r"/entity/{.*}", SingleEntityHandler, {"auth_provider": auth_provider}), ])