Alerting: edit cloud receivers (#33570)

This commit is contained in:
Domas
2021-05-06 12:32:45 +03:00
committed by GitHub
parent e642506dcb
commit 10a4606315
42 changed files with 2906 additions and 196 deletions

View File

@@ -36,7 +36,7 @@ export interface AlertRule {
evalData?: { noData?: boolean; evalMatches?: any };
}
export type NotifierType =
export type GrafanaNotifierType =
| 'discord'
| 'hipchat'
| 'email'
@@ -57,6 +57,17 @@ export type NotifierType =
| 'LINE'
| 'kafka';
export type CloudNotifierType =
| 'email'
| 'pagerduty'
| 'pushover'
| 'slack'
| 'opsgenie'
| 'victorops'
| 'webhook'
| 'wechat';
export type NotifierType = GrafanaNotifierType | CloudNotifierType;
export interface NotifierDTO {
name: string;
description: string;
@@ -103,7 +114,15 @@ export interface ChannelTypeSettings {
}
export interface NotificationChannelOption {
element: 'input' | 'select' | 'checkbox' | 'textarea';
element:
| 'input'
| 'select'
| 'checkbox'
| 'textarea'
| 'subform'
| 'subform_array'
| 'key_value_map'
| 'string_array';
inputType: string;
label: string;
description: string;
@@ -111,9 +130,10 @@ export interface NotificationChannelOption {
propertyName: string;
required: boolean;
secure: boolean;
selectOptions?: Array<SelectableValue<string>>;
selectOptions?: Array<SelectableValue<string>> | null;
showWhen: { field: string; is: string };
validationRule: string;
subformOptions?: NotificationChannelOption[];
}
export interface NotificationChannelState {