code: def get_rest_api_client(context: str | None = None) -> RestApiClient:
      cfg = CloudClientConfig.get_config()
      ctx = (
          cfg.get_context(context)
          if context
          else cfg.get_current_context()
      )
      return ctx.get_rest_api_client()
  
imports: from __future__ import annotations
  import logging
  import typing
  import attr
  import yaml
  from simple_di import Provide
  from simple_di import inject
  from ...exceptions import CloudRESTApiClientError
  from ..configuration.containers import BentoMLContainer
  from ..utils import bentoml_cattr
  from .client import RestApiClient
label_desc: Use image node_id 3 for calling a global function with example usage: get_rest_api_client(context) and returns: ctx