머니페니 0b66eae847
All checks were successful
Deploy to Production / deploy (push) Successful in 3m5s
feat: improve KJB screening workflow
2026-05-14 07:52:28 +09:00

60 lines
1.3 KiB
Python

"""
Application configuration using Pydantic Settings.
"""
from pydantic_settings import BaseSettings
from functools import lru_cache
class Settings(BaseSettings):
# Application
app_name: str = "Galaxis-Po"
debug: bool = False
# Database
database_url: str
# JWT
jwt_secret: str
jwt_algorithm: str = "HS256"
access_token_expire_minutes: int = 60 * 24 # 24 hours
# CORS
cors_origins: str = "http://localhost:3000"
# Admin user (auto-created on startup if not exists)
admin_username: str = ""
admin_email: str = ""
admin_password: str = ""
# External APIs
kis_app_key: str = ""
kis_app_secret: str = ""
kis_account_no: str = ""
kis_paper_trade: bool = True
screening_auto_trade_enabled: bool = False
screening_risk_pct: float = 0.02
screening_max_order_amount: int = 5_000_000
dart_api_key: str = ""
krx_openapi_key: str = ""
# LLM Provider (optional)
anthropic_api_key: str = ""
openai_api_key: str = ""
llm_fast_model: str = ""
llm_strong_model: str = ""
# Notifications (optional)
discord_webhook_url: str = ""
telegram_bot_token: str = ""
telegram_chat_id: str = ""
class Config:
env_file = ".env"
case_sensitive = False
@lru_cache
def get_settings() -> Settings:
return Settings()