-
Notifications
You must be signed in to change notification settings - Fork 3
Suspend GrafanaAlert
Pause a Grafana Alert by Name, ID, or pause ALL alerts in Grafana
Suspend-GrafanaAlert [-AlertName <String>] [-WhatIf] [-Confirm] [<CommonParameters>]
Suspend-GrafanaAlert [-AlertId <Int32>] [-WhatIf] [-Confirm] [<CommonParameters>]
Suspend-GrafanaAlert [-All] [-Credential] <PSCredential> [-WhatIf] [-Confirm] [<CommonParameters>]
This cmdlet provides a way to pause Grafana alerts via the API
Suspend-GrafanaAlert -AlertId 12
Suspend-GrafanaAlert -AlertName WebResponseTime
Suspend-GrafanaAlert -All -Credential _username_
Suspend-GrafanaAlert -All -Credential (Get-Credential)
The ID of the Grafana Alert you wish to pause
Type: Int32
Parameter Sets: Id
Aliases:
Required: False
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False
The Name of the Grafana Alert you wish to pause
Type: String
Parameter Sets: Name
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Pause all Grafana Alerts
Type: SwitchParameter
Parameter Sets: All
Aliases:
Required: True
Position: 1
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
The credential to use to pause all Grafana alerts
Type: PSCredential
Parameter Sets: All
Aliases:
Required: True
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: wi
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
Prompts you for confirmation before running the cmdlet.
Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
The -Credential parameter is required when pausing all alerts. This is due to how the API handles the authentication header for that operation
-
Configuration
-
Admin
-
API Keys
-
Alerts
-
Dashboards
-
Folders
-
Snapshots
-
Other