1. Packages
  2. Cloudflare Provider
  3. API Docs
  4. getMagicNetworkMonitoringRule
Cloudflare v6.1.2 published on Monday, Apr 28, 2025 by Pulumi

cloudflare.getMagicNetworkMonitoringRule

Explore with Pulumi AI

cloudflare logo
Cloudflare v6.1.2 published on Monday, Apr 28, 2025 by Pulumi

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as cloudflare from "@pulumi/cloudflare";
    
    const exampleMagicNetworkMonitoringRule = cloudflare.getMagicNetworkMonitoringRule({
        accountId: "6f91088a406011ed95aed352566e8d4c",
        ruleId: "2890e6fa406311ed9b5a23f70f6fb8cf",
    });
    
    import pulumi
    import pulumi_cloudflare as cloudflare
    
    example_magic_network_monitoring_rule = cloudflare.get_magic_network_monitoring_rule(account_id="6f91088a406011ed95aed352566e8d4c",
        rule_id="2890e6fa406311ed9b5a23f70f6fb8cf")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-cloudflare/sdk/v6/go/cloudflare"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cloudflare.LookupMagicNetworkMonitoringRule(ctx, &cloudflare.LookupMagicNetworkMonitoringRuleArgs{
    			AccountId: "6f91088a406011ed95aed352566e8d4c",
    			RuleId:    pulumi.StringRef("2890e6fa406311ed9b5a23f70f6fb8cf"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Cloudflare = Pulumi.Cloudflare;
    
    return await Deployment.RunAsync(() => 
    {
        var exampleMagicNetworkMonitoringRule = Cloudflare.GetMagicNetworkMonitoringRule.Invoke(new()
        {
            AccountId = "6f91088a406011ed95aed352566e8d4c",
            RuleId = "2890e6fa406311ed9b5a23f70f6fb8cf",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.cloudflare.CloudflareFunctions;
    import com.pulumi.cloudflare.inputs.GetMagicNetworkMonitoringRuleArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var exampleMagicNetworkMonitoringRule = CloudflareFunctions.getMagicNetworkMonitoringRule(GetMagicNetworkMonitoringRuleArgs.builder()
                .accountId("6f91088a406011ed95aed352566e8d4c")
                .ruleId("2890e6fa406311ed9b5a23f70f6fb8cf")
                .build());
    
        }
    }
    
    variables:
      exampleMagicNetworkMonitoringRule:
        fn::invoke:
          function: cloudflare:getMagicNetworkMonitoringRule
          arguments:
            accountId: 6f91088a406011ed95aed352566e8d4c
            ruleId: 2890e6fa406311ed9b5a23f70f6fb8cf
    

    Using getMagicNetworkMonitoringRule

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getMagicNetworkMonitoringRule(args: GetMagicNetworkMonitoringRuleArgs, opts?: InvokeOptions): Promise<GetMagicNetworkMonitoringRuleResult>
    function getMagicNetworkMonitoringRuleOutput(args: GetMagicNetworkMonitoringRuleOutputArgs, opts?: InvokeOptions): Output<GetMagicNetworkMonitoringRuleResult>
    def get_magic_network_monitoring_rule(account_id: Optional[str] = None,
                                          rule_id: Optional[str] = None,
                                          opts: Optional[InvokeOptions] = None) -> GetMagicNetworkMonitoringRuleResult
    def get_magic_network_monitoring_rule_output(account_id: Optional[pulumi.Input[str]] = None,
                                          rule_id: Optional[pulumi.Input[str]] = None,
                                          opts: Optional[InvokeOptions] = None) -> Output[GetMagicNetworkMonitoringRuleResult]
    func LookupMagicNetworkMonitoringRule(ctx *Context, args *LookupMagicNetworkMonitoringRuleArgs, opts ...InvokeOption) (*LookupMagicNetworkMonitoringRuleResult, error)
    func LookupMagicNetworkMonitoringRuleOutput(ctx *Context, args *LookupMagicNetworkMonitoringRuleOutputArgs, opts ...InvokeOption) LookupMagicNetworkMonitoringRuleResultOutput

    > Note: This function is named LookupMagicNetworkMonitoringRule in the Go SDK.

    public static class GetMagicNetworkMonitoringRule 
    {
        public static Task<GetMagicNetworkMonitoringRuleResult> InvokeAsync(GetMagicNetworkMonitoringRuleArgs args, InvokeOptions? opts = null)
        public static Output<GetMagicNetworkMonitoringRuleResult> Invoke(GetMagicNetworkMonitoringRuleInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetMagicNetworkMonitoringRuleResult> getMagicNetworkMonitoringRule(GetMagicNetworkMonitoringRuleArgs args, InvokeOptions options)
    public static Output<GetMagicNetworkMonitoringRuleResult> getMagicNetworkMonitoringRule(GetMagicNetworkMonitoringRuleArgs args, InvokeOptions options)
    
    fn::invoke:
      function: cloudflare:index/getMagicNetworkMonitoringRule:getMagicNetworkMonitoringRule
      arguments:
        # arguments dictionary

    The following arguments are supported:

    AccountId string
    RuleId string
    The id of the rule. Must be unique.
    AccountId string
    RuleId string
    The id of the rule. Must be unique.
    accountId String
    ruleId String
    The id of the rule. Must be unique.
    accountId string
    ruleId string
    The id of the rule. Must be unique.
    account_id str
    rule_id str
    The id of the rule. Must be unique.
    accountId String
    ruleId String
    The id of the rule. Must be unique.

    getMagicNetworkMonitoringRule Result

    The following output properties are available:

    AccountId string
    AutomaticAdvertisement bool
    Toggle on if you would like Cloudflare to automatically advertise the IP Prefixes within the rule via Magic Transit when the rule is triggered. Only available for users of Magic Transit.
    BandwidthThreshold double
    The number of bits per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    Duration string
    The amount of time that the rule threshold must be exceeded to send an alert notification. The final value must be equivalent to one of the following 8 values ["1m","5m","10m","15m","20m","30m","45m","60m"]. Available values: "1m", "5m", "10m", "15m", "20m", "30m", "45m", "60m".
    Id string
    The id of the rule. Must be unique.
    Name string
    The name of the rule. Must be unique. Supports characters A-Z, a-z, 0-9, underscore (_), dash (-), period (.), and tilde (~). You can’t have a space in the rule name. Max 256 characters.
    PacketThreshold double
    The number of packets per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    PrefixMatch string
    Prefix match type to be applied for a prefix auto advertisement when using an advanced_ddos rule. Available values: "exact", "subnet", "supernet".
    Prefixes List<string>
    Type string
    MNM rule type. Available values: "threshold", "zscore", "advanced_ddos".
    ZscoreSensitivity string
    Level of sensitivity set for zscore rules. Available values: "low", "medium", "high".
    ZscoreTarget string
    Target of the zscore rule analysis. Available values: "bits", "packets".
    RuleId string
    The id of the rule. Must be unique.
    AccountId string
    AutomaticAdvertisement bool
    Toggle on if you would like Cloudflare to automatically advertise the IP Prefixes within the rule via Magic Transit when the rule is triggered. Only available for users of Magic Transit.
    BandwidthThreshold float64
    The number of bits per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    Duration string
    The amount of time that the rule threshold must be exceeded to send an alert notification. The final value must be equivalent to one of the following 8 values ["1m","5m","10m","15m","20m","30m","45m","60m"]. Available values: "1m", "5m", "10m", "15m", "20m", "30m", "45m", "60m".
    Id string
    The id of the rule. Must be unique.
    Name string
    The name of the rule. Must be unique. Supports characters A-Z, a-z, 0-9, underscore (_), dash (-), period (.), and tilde (~). You can’t have a space in the rule name. Max 256 characters.
    PacketThreshold float64
    The number of packets per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    PrefixMatch string
    Prefix match type to be applied for a prefix auto advertisement when using an advanced_ddos rule. Available values: "exact", "subnet", "supernet".
    Prefixes []string
    Type string
    MNM rule type. Available values: "threshold", "zscore", "advanced_ddos".
    ZscoreSensitivity string
    Level of sensitivity set for zscore rules. Available values: "low", "medium", "high".
    ZscoreTarget string
    Target of the zscore rule analysis. Available values: "bits", "packets".
    RuleId string
    The id of the rule. Must be unique.
    accountId String
    automaticAdvertisement Boolean
    Toggle on if you would like Cloudflare to automatically advertise the IP Prefixes within the rule via Magic Transit when the rule is triggered. Only available for users of Magic Transit.
    bandwidthThreshold Double
    The number of bits per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    duration String
    The amount of time that the rule threshold must be exceeded to send an alert notification. The final value must be equivalent to one of the following 8 values ["1m","5m","10m","15m","20m","30m","45m","60m"]. Available values: "1m", "5m", "10m", "15m", "20m", "30m", "45m", "60m".
    id String
    The id of the rule. Must be unique.
    name String
    The name of the rule. Must be unique. Supports characters A-Z, a-z, 0-9, underscore (_), dash (-), period (.), and tilde (~). You can’t have a space in the rule name. Max 256 characters.
    packetThreshold Double
    The number of packets per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    prefixMatch String
    Prefix match type to be applied for a prefix auto advertisement when using an advanced_ddos rule. Available values: "exact", "subnet", "supernet".
    prefixes List<String>
    type String
    MNM rule type. Available values: "threshold", "zscore", "advanced_ddos".
    zscoreSensitivity String
    Level of sensitivity set for zscore rules. Available values: "low", "medium", "high".
    zscoreTarget String
    Target of the zscore rule analysis. Available values: "bits", "packets".
    ruleId String
    The id of the rule. Must be unique.
    accountId string
    automaticAdvertisement boolean
    Toggle on if you would like Cloudflare to automatically advertise the IP Prefixes within the rule via Magic Transit when the rule is triggered. Only available for users of Magic Transit.
    bandwidthThreshold number
    The number of bits per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    duration string
    The amount of time that the rule threshold must be exceeded to send an alert notification. The final value must be equivalent to one of the following 8 values ["1m","5m","10m","15m","20m","30m","45m","60m"]. Available values: "1m", "5m", "10m", "15m", "20m", "30m", "45m", "60m".
    id string
    The id of the rule. Must be unique.
    name string
    The name of the rule. Must be unique. Supports characters A-Z, a-z, 0-9, underscore (_), dash (-), period (.), and tilde (~). You can’t have a space in the rule name. Max 256 characters.
    packetThreshold number
    The number of packets per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    prefixMatch string
    Prefix match type to be applied for a prefix auto advertisement when using an advanced_ddos rule. Available values: "exact", "subnet", "supernet".
    prefixes string[]
    type string
    MNM rule type. Available values: "threshold", "zscore", "advanced_ddos".
    zscoreSensitivity string
    Level of sensitivity set for zscore rules. Available values: "low", "medium", "high".
    zscoreTarget string
    Target of the zscore rule analysis. Available values: "bits", "packets".
    ruleId string
    The id of the rule. Must be unique.
    account_id str
    automatic_advertisement bool
    Toggle on if you would like Cloudflare to automatically advertise the IP Prefixes within the rule via Magic Transit when the rule is triggered. Only available for users of Magic Transit.
    bandwidth_threshold float
    The number of bits per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    duration str
    The amount of time that the rule threshold must be exceeded to send an alert notification. The final value must be equivalent to one of the following 8 values ["1m","5m","10m","15m","20m","30m","45m","60m"]. Available values: "1m", "5m", "10m", "15m", "20m", "30m", "45m", "60m".
    id str
    The id of the rule. Must be unique.
    name str
    The name of the rule. Must be unique. Supports characters A-Z, a-z, 0-9, underscore (_), dash (-), period (.), and tilde (~). You can’t have a space in the rule name. Max 256 characters.
    packet_threshold float
    The number of packets per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    prefix_match str
    Prefix match type to be applied for a prefix auto advertisement when using an advanced_ddos rule. Available values: "exact", "subnet", "supernet".
    prefixes Sequence[str]
    type str
    MNM rule type. Available values: "threshold", "zscore", "advanced_ddos".
    zscore_sensitivity str
    Level of sensitivity set for zscore rules. Available values: "low", "medium", "high".
    zscore_target str
    Target of the zscore rule analysis. Available values: "bits", "packets".
    rule_id str
    The id of the rule. Must be unique.
    accountId String
    automaticAdvertisement Boolean
    Toggle on if you would like Cloudflare to automatically advertise the IP Prefixes within the rule via Magic Transit when the rule is triggered. Only available for users of Magic Transit.
    bandwidthThreshold Number
    The number of bits per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    duration String
    The amount of time that the rule threshold must be exceeded to send an alert notification. The final value must be equivalent to one of the following 8 values ["1m","5m","10m","15m","20m","30m","45m","60m"]. Available values: "1m", "5m", "10m", "15m", "20m", "30m", "45m", "60m".
    id String
    The id of the rule. Must be unique.
    name String
    The name of the rule. Must be unique. Supports characters A-Z, a-z, 0-9, underscore (_), dash (-), period (.), and tilde (~). You can’t have a space in the rule name. Max 256 characters.
    packetThreshold Number
    The number of packets per second for the rule. When this value is exceeded for the set duration, an alert notification is sent. Minimum of 1 and no maximum.
    prefixMatch String
    Prefix match type to be applied for a prefix auto advertisement when using an advanced_ddos rule. Available values: "exact", "subnet", "supernet".
    prefixes List<String>
    type String
    MNM rule type. Available values: "threshold", "zscore", "advanced_ddos".
    zscoreSensitivity String
    Level of sensitivity set for zscore rules. Available values: "low", "medium", "high".
    zscoreTarget String
    Target of the zscore rule analysis. Available values: "bits", "packets".
    ruleId String
    The id of the rule. Must be unique.

    Package Details

    Repository
    Cloudflare pulumi/pulumi-cloudflare
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the cloudflare Terraform Provider.
    cloudflare logo
    Cloudflare v6.1.2 published on Monday, Apr 28, 2025 by Pulumi