using System;
using System.Collections.Generic;
using System.Threading;
using System.Threading.Tasks;
using InfluxDB.Client.Api.Domain;
using InfluxDB.Client.Api.Service;
using InfluxDB.Client.Core;
using InfluxDB.Client.Domain;
namespace InfluxDB.Client
{
public interface INotificationRulesApi
{
///
/// Add a Slack notification rule.
///
/// Human-readable name describing the notification rule.
/// The notification repetition interval.
/// The template used to generate notification.
/// Status rule the notification rule attempts to match.
/// The endpoint to use for notification.
/// The ID of the organization that owns this notification rule.
/// Cancellation token
/// Notification rule created
Task CreateSlackRuleAsync(string name, string every, string messageTemplate,
RuleStatusLevel status, SlackNotificationEndpoint endpoint, string orgId,
CancellationToken cancellationToken = default);
///
/// Add a Slack notification rule.
///
/// Human-readable name describing the notification rule.
/// The notification repetition interval.
/// The template used to generate notification.
/// Status rule the notification rule attempts to match.
/// List of tag rules the notification rule attempts to match.
/// The endpoint to use for notification.
/// The ID of the organization that owns this notification rule.
/// Cancellation token
/// Notification rule created
Task CreateSlackRuleAsync(string name, string every, string messageTemplate,
RuleStatusLevel status, List tagRules, SlackNotificationEndpoint endpoint, string orgId,
CancellationToken cancellationToken = default);
///
/// Add a PagerDuty notification rule.
///
/// Human-readable name describing the notification rule.
/// The notification repetition interval.
/// The template used to generate notification.
/// Status rule the notification rule attempts to match.
/// List of tag rules the notification rule attempts to match.
/// The endpoint to use for notification.
/// The ID of the organization that owns this notification rule
/// Cancellation token
/// Notification rule created
Task CreatePagerDutyRuleAsync(string name, string every,
string messageTemplate, RuleStatusLevel status, List tagRules,
PagerDutyNotificationEndpoint endpoint, string orgId, CancellationToken cancellationToken = default);
///
/// Add a HTTP notification rule.
///
/// Human-readable name describing the notification rule.
/// The notification repetition interval.
/// Status rule the notification rule attempts to match.
/// List of tag rules the notification rule attempts to match.
/// The endpoint to use for notification.
/// The ID of the organization that owns this notification rule.
/// Cancellation token
/// Notification rule created
Task CreateHttpRuleAsync(string name, string every, RuleStatusLevel status,
List tagRules, HTTPNotificationEndpoint endpoint, string orgId,
CancellationToken cancellationToken = default);
///
/// Add a notification rule.
///
/// Notification rule to create
/// Cancellation token
/// Notification rule created
Task CreateRuleAsync(NotificationRule rule,
CancellationToken cancellationToken = default);
///
/// Update a notification rule.
///
/// Notification rule update to apply
/// Cancellation token
/// An updated notification rule
Task UpdateNotificationRuleAsync(NotificationRule rule,
CancellationToken cancellationToken = default);
///
/// Update a notification rule.
///
/// The notification rule ID.
/// Notification rule update to apply
/// Cancellation token
/// An updated notification rule
Task UpdateNotificationRuleAsync(string ruleId, NotificationRuleUpdate update,
CancellationToken cancellationToken = default);
///
/// Delete a notification rule.
///
/// The notification rule
/// Cancellation token
///
Task DeleteNotificationRuleAsync(NotificationRule rule, CancellationToken cancellationToken = default);
///
/// Delete a notification rule.
///
/// The notification rule ID
/// Cancellation token
///
Task DeleteNotificationRuleAsync(string ruleId, CancellationToken cancellationToken = default);
///
/// Get a notification rule.
///
/// The notification rule ID
/// Cancellation token
/// The notification rule requested
Task FindNotificationRuleByIdAsync(string ruleId,
CancellationToken cancellationToken = default);
///
/// Get notification rules.
///
/// Only show notification rules that belong to a specific organization ID.
/// Cancellation token
/// A list of notification rules
Task> FindNotificationRulesAsync(string orgId,
CancellationToken cancellationToken = default);
///
/// Get all notification rules.
///
/// Only show notification rules that belong to a specific organization ID.
/// find options
/// Cancellation token
///
Task FindNotificationRulesAsync(string orgId, FindOptions findOptions,
CancellationToken cancellationToken = default);
///
/// List all labels for a notification rule.
///
/// The notification rule.
/// Cancellation token
/// A list of all labels for a notification rule
Task> GetLabelsAsync(NotificationRule rule, CancellationToken cancellationToken = default);
///
/// List all labels for a notification rule
///
/// The notification rule ID.
/// Cancellation token
/// A list of all labels for a notification rule
Task> GetLabelsAsync(string ruleId, CancellationToken cancellationToken = default);
///
/// Add a label to a notification rule.
///
/// Label to add
/// The notification rule.
/// Cancellation token
/// The label was added to the notification rule
Task