27 lines
459 B
Python
27 lines
459 B
Python
|
|
from pydantic_settings import BaseSettings, SettingsConfigDict
|
||
|
|
|
||
|
|
|
||
|
|
class Settings(BaseSettings):
|
||
|
|
"""Настройки приложения"""
|
||
|
|
|
||
|
|
# Telegram
|
||
|
|
bot_token: str
|
||
|
|
|
||
|
|
# OpenAI
|
||
|
|
openai_api_key: str
|
||
|
|
|
||
|
|
# Database
|
||
|
|
database_url: str
|
||
|
|
|
||
|
|
# App settings
|
||
|
|
debug: bool = False
|
||
|
|
|
||
|
|
model_config = SettingsConfigDict(
|
||
|
|
env_file='.env',
|
||
|
|
env_file_encoding='utf-8',
|
||
|
|
case_sensitive=False
|
||
|
|
)
|
||
|
|
|
||
|
|
|
||
|
|
settings = Settings()
|