code: def log_event(
      self,
      end_user,
      response_obj,
      start_time,
      end_time,
      litellm_call_id,
      print_verbose,
      call_type,
      stream=False,
  ):
      print_verbose(
          f"LiteDebugger: Success/Failure Call Logging for call id {litellm_call_id}"
      )
      try:
          print_verbose(
              f"LiteLLMDebugger: Success/Failure Logging - Enters handler logging function for function {call_type} and stream set to {stream} with response object {response_obj}"
          )
          total_cost = 0  # [TODO] implement cost tracking
          response_time = (end_time - start_time).total_seconds()
          if call_type == "completion" and stream == False:
              litellm_data_obj = {
                  "response_time": response_time,
                  "total_cost": total_cost,
                  "response": response_obj["choices"][0]["message"][
                      "content"
                  ],
                  "litellm_call_id": litellm_call_id,
                  "status": "success",
              }
              print_verbose(
                  f"LiteDebugger: Logging - final data object: {litellm_data_obj}"
              )
              response = requests.post(
                  url=self.api_url,
                  headers={"content-type": "application/json"},
                  data=json.dumps(litellm_data_obj),
              )
          elif call_type == "embedding":
              litellm_data_obj = {
                  "response_time": response_time,
                  "total_cost": total_cost,
                  "response": str(
                      response_obj["data"][0]["embedding"][:5]
                  ),
                  "litellm_call_id": litellm_call_id,
                  "status": "success",
              }
              response = requests.post(
                  url=self.api_url,
                  headers={"content-type": "application/json"},
                  data=json.dumps(litellm_data_obj),
              )
          elif call_type == "completion" and stream == True:
              if (
                  len(response_obj["content"]) > 0
              ):  # don't log the empty strings
                  litellm_data_obj = {
                      "response_time": response_time,
                      "total_cost": total_cost,
                      "response": response_obj["content"],
                      "litellm_call_id": litellm_call_id,
                      "status": "success",
                  }
                  print_verbose(
                      f"LiteDebugger: Logging - final data object: {litellm_data_obj}"
                  )
                  response = requests.post(
                      url=self.api_url,
                      headers={"content-type": "application/json"},
                      data=json.dumps(litellm_data_obj),
                  )
          elif "error" in response_obj:
              if (
                  "Unable to map your input to a model."
                  in response_obj["error"]
              ):
                  total_cost = 0
              litellm_data_obj = {
                  "response_time": response_time,
                  "model": response_obj["model"],
                  "total_cost": total_cost,
                  "error": response_obj["error"],
                  "end_user": end_user,
                  "litellm_call_id": litellm_call_id,
                  "status": "failure",
                  "user_email": self.user_email,
              }
              print_verbose(
                  f"LiteDebugger: Logging - final data object: {litellm_data_obj}"
              )
              response = requests.post(
                  url=self.api_url,
                  headers={"content-type": "application/json"},
                  data=json.dumps(litellm_data_obj),
              )
              print_verbose(
                  f"LiteDebugger: api response - {response.text}"
              )
      except:
          print_verbose(
              f"[Non-Blocking Error] LiteDebugger: Logging Error - {traceback.format_exc()}"
          )
          pass
  
file_path: litellm/litellm/integrations/litedebugger.py
imports: import requests, traceback, json, os
  import types
label_desc: Use image node_id 5 for calling the LiteDebugger obj's underlying member method code with example usage: obj.log_event(end_user, response_obj, start_time, end_time, litellm_call_id, print_verbose, call_type, stream) without return types