code: def init(self, app_id=None):
          
          self.set_app_id(app_id)
  
          err_msg = (
              'Unable to initialize. Check Steam client is running '
              'and Steam application ID is defined in steam_appid.txt or passed to Api.'
          )
  
          if self._lib.steam_init():
  
              try:
                  _set_client(self._lib.Client())
  
                  self.utils = Utils()
                  self.current_user = CurrentUser()
                  self.friends = Friends()
                  self.groups = Groups()
                  self.apps = Applications()
                  self.overlay = Overlay()
                  self.screenshots = Screenshots()
  
              except Exception as e:
                  raise SteamApiStartupError('%s:\n%s' % (err_msg, e))
  
          else:
              raise SteamApiStartupError(err_msg)
docs: Initializes Steam API library.
  
          :param str|int app_id: Application ID.
          :raises: SteamApiStartupError