code: def cli(obj, ids, query, filters):
      
      client = obj['client']
      if ids:
          total = len(ids)
      else:
          if not (query or filters):
              click.confirm('Deleting all alerts. Do you want to continue?', abort=True)
          if query:
              query = [('q', query)]
          else:
              query = build_query(filters)
          total, _, _ = client.get_count(query)
          ids = [a.id for a in client.get_alerts(query)]
  
      with click.progressbar(ids, label='Deleting {} alerts'.format(total)) as bar:
          for id in bar:
              client.delete_alert(id)
docs: Delete alerts.