Files
connexion/examples/openapi3/helloworld_aiohttp/hello.py
2021-06-25 13:08:46 +02:00

15 lines
369 B
Python
Executable File

#!/usr/bin/env python3
from aiohttp import web
import connexion
async def post_greeting(name):
return web.Response(text='Hello {name}'.format(name=name))
if __name__ == '__main__':
app = connexion.AioHttpApp(__name__, port=9090, specification_dir='openapi/')
app.add_api('helloworld-api.yaml', arguments={'title': 'Hello World Example'})
app.run()