fix:增加接口调试信息

This commit is contained in:
ZhangYonghao
2026-03-21 21:39:25 +08:00
parent 3b660203dd
commit 7e563fae30
5 changed files with 51 additions and 1 deletions

View File

@@ -76,6 +76,8 @@ class Settings:
max_html_length = max(1024, _get_int_env("MAX_HTML_LENGTH", 200_000))
api_key = os.getenv("API_KEY", "").strip()
allow_unsafe_html = _get_bool_env("ALLOW_UNSAFE_HTML", False)
enable_request_debug_log = _get_bool_env("ENABLE_REQUEST_DEBUG_LOG", True)
request_log_max_chars = max(256, _get_int_env("REQUEST_LOG_MAX_CHARS", 10_000))
settings = Settings()