code: def set_policy_threshold(zap_helper, policy_ids, threshold):
      
      if not policy_ids:
          policy_ids = _get_all_policy_ids(zap_helper)
  
      with zap_error_handler():
          zap_helper.set_policy_alert_threshold(policy_ids, threshold)
  
      console.info('Set alert threshold to {0}.'.format(threshold))
docs: Set the alert threshold for policies.