İlk commit: Stepstead backend (FastAPI)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
jts 2026-07-11 11:30:24 +03:00
commit ea049b8ccd
45 changed files with 6751 additions and 0 deletions

35
config.py Normal file
View file

@ -0,0 +1,35 @@
from pydantic_settings import BaseSettings, SettingsConfigDict
class Settings(BaseSettings):
model_config = SettingsConfigDict(env_file=".env", case_sensitive=True, extra="ignore")
DATABASE_URL: str
DATABASE_URL_SYNC: str
REDIS_URL: str
SECRET_KEY: str
ALGORITHM: str = "HS256"
ACCESS_TOKEN_EXPIRE_MINUTES: int = 1440 * 7 # 7 gün
APP_NAME: str = "Stepstead"
APP_URL: str = "https://stepstead.com"
API_URL: str = "https://api.stepstead.com"
DEBUG: bool = False
SMTP_HOST: str = "127.0.0.1"
SMTP_PORT: int = 587
SMTP_USER: str = ""
SMTP_PASSWORD: str = ""
SMTP_FROM: str = "Stepstead <noreply@stepstead.com>"
SMTP_TLS: bool = True
MAX_STEPS_PER_MINUTE: int = 200
STEP_SYNC_WINDOW_SECONDS: int = 60
SKILL_NAMES: list[str] = [
"mining", "fishing", "foraging", "woodcutting", "hunting",
"combat", "smithing", "alchemy", "cooking", "construction",
]
settings = Settings()