from pydantic_settings import BaseSettings, SettingsConfigDict class Settings(BaseSettings): model_config = SettingsConfigDict(env_file=".env", env_file_encoding="utf-8") database_url: str = "postgres://spliteasy:spliteasy@localhost:5432/spliteasy" oidc_issuer: str = "https://keycloak.example.com/realms/myrealm" oidc_client_id: str = "spliteasy" oidc_client_secret: str = "" allowed_audiences: str = "account,spliteasy" @property def audiences(self) -> list[str]: return [a.strip() for a in self.allowed_audiences.split(",") if a.strip()] settings = Settings()