mirror of
https://github.com/koloideal/Argenta.git
synced 2026-06-10 18:15:28 +03:00
13 lines
392 B
Python
13 lines
392 B
Python
from argenta import Command, Response, Router
|
|
from argenta.response import ResponseStatus
|
|
|
|
router = Router(title="Example")
|
|
|
|
|
|
@router.command(Command("greet", description="Greet the user"))
|
|
def greet_handler(response: Response):
|
|
if response.status == ResponseStatus.ALL_FLAGS_VALID:
|
|
print("Hello! All flags are valid.")
|
|
else:
|
|
print("Warning: Some flags have issues.")
|