code: def _kill_actor_using_dashboard_gcs(
      webui_url: str, actor_id: str, force_kill=False
  ):
      resp = requests.get(
          webui_url + KILL_ACTOR_ENDPOINT,
          params={
              "actor_id": actor_id,
              "force_kill": force_kill,
          },
      )
      resp.raise_for_status()
      resp_json = resp.json()
      assert resp_json["result"] is True, "msg" in resp_json
      return resp_json
  
file_path: ray/python/ray/dashboard/modules/snapshot/tests/test_actors.py
imports: import logging
  import os
  import sys
  import time
  import pytest
  import requests
  import ray
  from ray._private.test_utils import format_web_url, wait_until_server_available
  from ray.dashboard.tests.conftest import *
label_desc: Use image node_id 3 for calling a global function with example usage: _kill_actor_using_dashboard_gcs(webui_url, actor_id, force_kill) and returns: resp_json