|
|
|
@ -31,8 +31,10 @@ def create_flask_app_with_configs() -> DifyApp:
|
|
|
|
request_id = get_request_id()
|
|
|
|
request_id = get_request_id()
|
|
|
|
|
|
|
|
|
|
|
|
try:
|
|
|
|
try:
|
|
|
|
if request.method.lower() == "post" and "application/json" in request.headers.get("content-type",
|
|
|
|
if (
|
|
|
|
"").lower():
|
|
|
|
request.method.lower() == "post"
|
|
|
|
|
|
|
|
and "application/json" in request.headers.get("content-type", "").lower()
|
|
|
|
|
|
|
|
):
|
|
|
|
logging.info(
|
|
|
|
logging.info(
|
|
|
|
f"[before request]|request_id: {request_id},"
|
|
|
|
f"[before request]|request_id: {request_id},"
|
|
|
|
f" method: {request.method}, url: {request.url}, request_data: {request.get_json()}"
|
|
|
|
f" method: {request.method}, url: {request.url}, request_data: {request.get_json()}"
|
|
|
|
|