diff options
Diffstat (limited to 'ickapi/version_view.py')
-rw-r--r-- | ickapi/version_view.py | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/ickapi/version_view.py b/ickapi/version_view.py new file mode 100644 index 0000000..23f723a --- /dev/null +++ b/ickapi/version_view.py @@ -0,0 +1,16 @@ +"""Version view module. + +Contains `/version` endpoint implementation. +""" + +from aiohttp import web + +import ickapi + + +class VersionView: + """Endpoint methods.""" + + async def get_version(self, request): + """Return component versions.""" + return web.json_response({'api': ickapi.__version__}) |