feat: implement remaining repo methods for chatbot and quote
This commit is contained in:
parent
95101a6573
commit
4b7ffbc914
10 changed files with 352 additions and 177 deletions
|
|
@ -11,6 +11,7 @@ from apps.httpapi.litestar.dependencies import (
|
|||
authenticate,
|
||||
get_authenticate_action,
|
||||
get_authenticator,
|
||||
get_bot_manager,
|
||||
get_chatbot_repo,
|
||||
get_create_chatbot_svc,
|
||||
get_create_or_update_chatbot_action,
|
||||
|
|
@ -43,12 +44,11 @@ from apps.httpapi.litestar.routes.api import (
|
|||
save_bot_settings,
|
||||
)
|
||||
from apps.httpapi.litestar.routes.auth import get_code, login
|
||||
from huesoporro.bot import BotsManager
|
||||
from huesoporro.settings import Settings
|
||||
|
||||
|
||||
@get("/healthz")
|
||||
def get_health() -> dict:
|
||||
async def get_health() -> dict:
|
||||
return {"status": "ok"}
|
||||
|
||||
|
||||
|
|
@ -89,7 +89,7 @@ def create_app():
|
|||
"s": Provide(get_settings, use_cache=True),
|
||||
"a": Provide(get_authenticator, use_cache=True),
|
||||
"user": Provide(authenticate),
|
||||
"bm": Provide(BotsManager, use_cache=True),
|
||||
"bm": Provide(get_bot_manager, use_cache=True),
|
||||
"sss": Provide(get_sentences_storer_svc),
|
||||
"twitch_authenticator": Provide(get_authenticator),
|
||||
"authenticate_action": Provide(get_authenticate_action),
|
||||
|
|
@ -115,7 +115,6 @@ def create_app():
|
|||
|
||||
app = create_app()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
s = Settings.get()
|
||||
config = uvicorn.Config("main:app", host=s.port, port=s.port, log_level="info")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue