mirror of
https://github.com/LukeHagar/connexion.git
synced 2025-12-09 04:19:32 +00:00
13 lines
349 B
Python
Executable File
13 lines
349 B
Python
Executable File
#!/usr/bin/env python3
|
|
|
|
import connexion
|
|
|
|
|
|
def post_greeting(name: str) -> str:
|
|
return 'Hello {name}'.format(name=name)
|
|
|
|
if __name__ == '__main__':
|
|
app = connexion.FlaskApp(__name__, 9090, specification_dir='swagger/')
|
|
app.add_api('helloworld-api.yaml', connexion.apis.FlaskApi, arguments={'title': 'Hello World Example'})
|
|
app.run()
|