Alerting: Add message options for Telegram contact point (#74635)

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
pull/74752/head
Nutmos 2 years ago committed by GitHub
parent 3f3db49c4c
commit ad9f0b9e4e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      go.mod
  2. 2
      go.sum
  3. 12
      pkg/services/ngalert/notifier/channels_config/available_channels.go
  4. 34
      public/app/features/alerting/unified/mockGrafanaNotifiers.ts

@ -59,7 +59,7 @@ require (
github.com/google/uuid v1.3.0 // @grafana/backend-platform
github.com/google/wire v0.5.0 // @grafana/backend-platform
github.com/gorilla/websocket v1.5.0 // @grafana/grafana-app-platform-squad
github.com/grafana/alerting v0.0.0-20230831092459-f7dba8ede9b0 // @grafana/alerting-squad-backend
github.com/grafana/alerting v0.0.0-20230911211918-c939956dbb10 // @grafana/alerting-squad-backend
github.com/grafana/cuetsy v0.1.10 // @grafana/grafana-as-code
github.com/grafana/grafana-aws-sdk v0.19.1 // @grafana/aws-datasources
github.com/grafana/grafana-azure-sdk-go v1.8.1 // @grafana/backend-platform

@ -1790,6 +1790,8 @@ github.com/gotestyourself/gotestyourself v1.3.0/go.mod h1:zZKM6oeNM8k+FRljX1mnzV
github.com/gotestyourself/gotestyourself v2.2.0+incompatible/go.mod h1:zZKM6oeNM8k+FRljX1mnzVYeS8wiGgQyvST1/GafPbY=
github.com/grafana/alerting v0.0.0-20230831092459-f7dba8ede9b0 h1:iDCcF7YzzVWQDtgUp3pS5caAAfI3lk7RZ0BI5DMrero=
github.com/grafana/alerting v0.0.0-20230831092459-f7dba8ede9b0/go.mod h1:gyUqgDT+v6gARVCpbfi8bb/WiGNELNJiq6hGKadnIxc=
github.com/grafana/alerting v0.0.0-20230911211918-c939956dbb10 h1:GfTtChG09pAfCIQBjvM2e52WfIGrByBhxZ9VW/x1hXo=
github.com/grafana/alerting v0.0.0-20230911211918-c939956dbb10/go.mod h1:gyUqgDT+v6gARVCpbfi8bb/WiGNELNJiq6hGKadnIxc=
github.com/grafana/codejen v0.0.3 h1:tAWxoTUuhgmEqxJPOLtJoxlPBbMULFwKFOcRsPRPXDw=
github.com/grafana/codejen v0.0.3/go.mod h1:zmwwM/DRyQB7pfuBjTWII3CWtxcXh8LTwAYGfDfpR6s=
github.com/grafana/cuetsy v0.1.10 h1:+W9/7roI8LorL+D1RJhKGdhsTZ81adrK9dHS0r7qsXs=

@ -843,6 +843,18 @@ func GetAvailableNotifiers() []*NotifierPlugin {
Description: `Mode for parsing entities in the message text. Default is 'HTML'`,
PropertyName: "parse_mode",
},
{
Label: "Disable Web Page Preview",
Description: "Disables link previews for links in this message",
Element: ElementTypeCheckbox,
PropertyName: "disable_web_page_preview",
},
{
Label: "Protect Content",
Description: "Protects the contents of the sent message from forwarding and saving",
Element: ElementTypeCheckbox,
PropertyName: "protect_content",
},
{
Label: "Disable Notification",
Description: "Sends the message silently. Users will receive a notification with no sound.",

@ -1539,6 +1539,40 @@ export const grafanaAlertNotifiersMock: NotifierDTO[] = [
secure: false,
dependsOn: '',
},
{
element: 'checkbox',
inputType: '',
label: 'Disable Web Page Preview',
description: 'Disables link previews for links in this message',
placeholder: '',
propertyName: 'disable_web_page_preview',
selectOptions: null,
showWhen: {
field: '',
is: '',
},
required: false,
validationRule: '',
secure: false,
dependsOn: '',
},
{
element: 'checkbox',
inputType: '',
label: 'Protect Content',
description: 'Protects the contents of the sent message from forwarding and saving',
placeholder: '',
propertyName: 'protect_content',
selectOptions: null,
showWhen: {
field: '',
is: '',
},
required: false,
validationRule: '',
secure: false,
dependsOn: '',
},
{
element: 'checkbox',
inputType: '',

Loading…
Cancel
Save