From 0bd9b2953adeaa69dbb181baabed44ebbcb2e69e Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Fri, 11 Apr 2025 19:19:36 -0700 Subject: [PATCH] fix(spend_tracking_utils.py): ensure each file create request is logged correctly --- litellm/proxy/spend_tracking/spend_tracking_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/litellm/proxy/spend_tracking/spend_tracking_utils.py b/litellm/proxy/spend_tracking/spend_tracking_utils.py index fc99d03d69..ecd3963a92 100644 --- a/litellm/proxy/spend_tracking/spend_tracking_utils.py +++ b/litellm/proxy/spend_tracking/spend_tracking_utils.py @@ -113,7 +113,7 @@ def generate_hash_from_response(response_obj: Any) -> str: def get_spend_logs_id( call_type: str, response_obj: dict, kwargs: dict ) -> Optional[str]: - if call_type == "aretrieve_batch": + if call_type == "aretrieve_batch" or call_type == "acreate_file": # Generate a hash from the response object id: Optional[str] = generate_hash_from_response(response_obj) else: