1. Packages
  2. Cisco Meraki
  3. API Docs
  4. networks
  5. TrafficAnalysis
Cisco Meraki v0.2.4 published on Friday, Jun 14, 2024 by Pulumi

meraki.networks.TrafficAnalysis

Explore with Pulumi AI

meraki logo
Cisco Meraki v0.2.4 published on Friday, Jun 14, 2024 by Pulumi

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as meraki from "@pulumi/meraki";
    
    const example = new meraki.networks.TrafficAnalysis("example", {
        customPieChartItems: [{
            name: "Item from hostname",
            type: "host",
            value: "example.com",
        }],
        mode: "disabled",
        networkId: "string",
    });
    export const merakiNetworksTrafficAnalysisExample = example;
    
    import pulumi
    import pulumi_meraki as meraki
    
    example = meraki.networks.TrafficAnalysis("example",
        custom_pie_chart_items=[meraki.networks.TrafficAnalysisCustomPieChartItemArgs(
            name="Item from hostname",
            type="host",
            value="example.com",
        )],
        mode="disabled",
        network_id="string")
    pulumi.export("merakiNetworksTrafficAnalysisExample", example)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-meraki/sdk/go/meraki/networks"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := networks.NewTrafficAnalysis(ctx, "example", &networks.TrafficAnalysisArgs{
    			CustomPieChartItems: networks.TrafficAnalysisCustomPieChartItemArray{
    				&networks.TrafficAnalysisCustomPieChartItemArgs{
    					Name:  pulumi.String("Item from hostname"),
    					Type:  pulumi.String("host"),
    					Value: pulumi.String("example.com"),
    				},
    			},
    			Mode:      pulumi.String("disabled"),
    			NetworkId: pulumi.String("string"),
    		})
    		if err != nil {
    			return err
    		}
    		ctx.Export("merakiNetworksTrafficAnalysisExample", example)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Meraki = Pulumi.Meraki;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Meraki.Networks.TrafficAnalysis("example", new()
        {
            CustomPieChartItems = new[]
            {
                new Meraki.Networks.Inputs.TrafficAnalysisCustomPieChartItemArgs
                {
                    Name = "Item from hostname",
                    Type = "host",
                    Value = "example.com",
                },
            },
            Mode = "disabled",
            NetworkId = "string",
        });
    
        return new Dictionary<string, object?>
        {
            ["merakiNetworksTrafficAnalysisExample"] = example,
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.meraki.networks.TrafficAnalysis;
    import com.pulumi.meraki.networks.TrafficAnalysisArgs;
    import com.pulumi.meraki.networks.inputs.TrafficAnalysisCustomPieChartItemArgs;
    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) {
            var example = new TrafficAnalysis("example", TrafficAnalysisArgs.builder()
                .customPieChartItems(TrafficAnalysisCustomPieChartItemArgs.builder()
                    .name("Item from hostname")
                    .type("host")
                    .value("example.com")
                    .build())
                .mode("disabled")
                .networkId("string")
                .build());
    
            ctx.export("merakiNetworksTrafficAnalysisExample", example);
        }
    }
    
    resources:
      example:
        type: meraki:networks:TrafficAnalysis
        properties:
          customPieChartItems:
            - name: Item from hostname
              type: host
              value: example.com
          mode: disabled
          networkId: string
    outputs:
      merakiNetworksTrafficAnalysisExample: ${example}
    

    Create TrafficAnalysis Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new TrafficAnalysis(name: string, args: TrafficAnalysisArgs, opts?: CustomResourceOptions);
    @overload
    def TrafficAnalysis(resource_name: str,
                        args: TrafficAnalysisArgs,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def TrafficAnalysis(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        network_id: Optional[str] = None,
                        custom_pie_chart_items: Optional[Sequence[TrafficAnalysisCustomPieChartItemArgs]] = None,
                        mode: Optional[str] = None)
    func NewTrafficAnalysis(ctx *Context, name string, args TrafficAnalysisArgs, opts ...ResourceOption) (*TrafficAnalysis, error)
    public TrafficAnalysis(string name, TrafficAnalysisArgs args, CustomResourceOptions? opts = null)
    public TrafficAnalysis(String name, TrafficAnalysisArgs args)
    public TrafficAnalysis(String name, TrafficAnalysisArgs args, CustomResourceOptions options)
    
    type: meraki:networks:TrafficAnalysis
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args TrafficAnalysisArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args TrafficAnalysisArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args TrafficAnalysisArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args TrafficAnalysisArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args TrafficAnalysisArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var trafficAnalysisResource = new Meraki.Networks.TrafficAnalysis("trafficAnalysisResource", new()
    {
        NetworkId = "string",
        CustomPieChartItems = new[]
        {
            new Meraki.Networks.Inputs.TrafficAnalysisCustomPieChartItemArgs
            {
                Name = "string",
                Type = "string",
                Value = "string",
            },
        },
        Mode = "string",
    });
    
    example, err := networks.NewTrafficAnalysis(ctx, "trafficAnalysisResource", &networks.TrafficAnalysisArgs{
    	NetworkId: pulumi.String("string"),
    	CustomPieChartItems: networks.TrafficAnalysisCustomPieChartItemArray{
    		&networks.TrafficAnalysisCustomPieChartItemArgs{
    			Name:  pulumi.String("string"),
    			Type:  pulumi.String("string"),
    			Value: pulumi.String("string"),
    		},
    	},
    	Mode: pulumi.String("string"),
    })
    
    var trafficAnalysisResource = new TrafficAnalysis("trafficAnalysisResource", TrafficAnalysisArgs.builder()
        .networkId("string")
        .customPieChartItems(TrafficAnalysisCustomPieChartItemArgs.builder()
            .name("string")
            .type("string")
            .value("string")
            .build())
        .mode("string")
        .build());
    
    traffic_analysis_resource = meraki.networks.TrafficAnalysis("trafficAnalysisResource",
        network_id="string",
        custom_pie_chart_items=[meraki.networks.TrafficAnalysisCustomPieChartItemArgs(
            name="string",
            type="string",
            value="string",
        )],
        mode="string")
    
    const trafficAnalysisResource = new meraki.networks.TrafficAnalysis("trafficAnalysisResource", {
        networkId: "string",
        customPieChartItems: [{
            name: "string",
            type: "string",
            value: "string",
        }],
        mode: "string",
    });
    
    type: meraki:networks:TrafficAnalysis
    properties:
        customPieChartItems:
            - name: string
              type: string
              value: string
        mode: string
        networkId: string
    

    TrafficAnalysis Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The TrafficAnalysis resource accepts the following input properties:

    NetworkId string
    networkId path parameter. Network ID
    CustomPieChartItems List<TrafficAnalysisCustomPieChartItem>
    The list of items that make up the custom pie chart for traffic reporting.
    Mode string
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    NetworkId string
    networkId path parameter. Network ID
    CustomPieChartItems []TrafficAnalysisCustomPieChartItemArgs
    The list of items that make up the custom pie chart for traffic reporting.
    Mode string
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    networkId String
    networkId path parameter. Network ID
    customPieChartItems List<TrafficAnalysisCustomPieChartItem>
    The list of items that make up the custom pie chart for traffic reporting.
    mode String
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    networkId string
    networkId path parameter. Network ID
    customPieChartItems TrafficAnalysisCustomPieChartItem[]
    The list of items that make up the custom pie chart for traffic reporting.
    mode string
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    network_id str
    networkId path parameter. Network ID
    custom_pie_chart_items Sequence[TrafficAnalysisCustomPieChartItemArgs]
    The list of items that make up the custom pie chart for traffic reporting.
    mode str
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    networkId String
    networkId path parameter. Network ID
    customPieChartItems List<Property Map>
    The list of items that make up the custom pie chart for traffic reporting.
    mode String
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).

    Outputs

    All input properties are implicitly available as output properties. Additionally, the TrafficAnalysis resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing TrafficAnalysis Resource

    Get an existing TrafficAnalysis resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: TrafficAnalysisState, opts?: CustomResourceOptions): TrafficAnalysis
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            custom_pie_chart_items: Optional[Sequence[TrafficAnalysisCustomPieChartItemArgs]] = None,
            mode: Optional[str] = None,
            network_id: Optional[str] = None) -> TrafficAnalysis
    func GetTrafficAnalysis(ctx *Context, name string, id IDInput, state *TrafficAnalysisState, opts ...ResourceOption) (*TrafficAnalysis, error)
    public static TrafficAnalysis Get(string name, Input<string> id, TrafficAnalysisState? state, CustomResourceOptions? opts = null)
    public static TrafficAnalysis get(String name, Output<String> id, TrafficAnalysisState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    CustomPieChartItems List<TrafficAnalysisCustomPieChartItem>
    The list of items that make up the custom pie chart for traffic reporting.
    Mode string
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    NetworkId string
    networkId path parameter. Network ID
    CustomPieChartItems []TrafficAnalysisCustomPieChartItemArgs
    The list of items that make up the custom pie chart for traffic reporting.
    Mode string
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    NetworkId string
    networkId path parameter. Network ID
    customPieChartItems List<TrafficAnalysisCustomPieChartItem>
    The list of items that make up the custom pie chart for traffic reporting.
    mode String
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    networkId String
    networkId path parameter. Network ID
    customPieChartItems TrafficAnalysisCustomPieChartItem[]
    The list of items that make up the custom pie chart for traffic reporting.
    mode string
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    networkId string
    networkId path parameter. Network ID
    custom_pie_chart_items Sequence[TrafficAnalysisCustomPieChartItemArgs]
    The list of items that make up the custom pie chart for traffic reporting.
    mode str
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    network_id str
    networkId path parameter. Network ID
    customPieChartItems List<Property Map>
    The list of items that make up the custom pie chart for traffic reporting.
    mode String
    The traffic analysis mode for the network. Can be one of 'disabled' (do not collect traffic types), 'basic' (collect generic traffic categories), or 'detailed' (collect destination hostnames).
    networkId String
    networkId path parameter. Network ID

    Supporting Types

    TrafficAnalysisCustomPieChartItem, TrafficAnalysisCustomPieChartItemArgs

    Name string
    The name of the custom pie chart item.
    Type string
    The signature type for the custom pie chart item. Can be one of 'host', 'port' or 'ipRange'.
    Value string
    The value of the custom pie chart item. Valid syntax depends on the signature type of the chart item (see sample request/response for more details).
    Name string
    The name of the custom pie chart item.
    Type string
    The signature type for the custom pie chart item. Can be one of 'host', 'port' or 'ipRange'.
    Value string
    The value of the custom pie chart item. Valid syntax depends on the signature type of the chart item (see sample request/response for more details).
    name String
    The name of the custom pie chart item.
    type String
    The signature type for the custom pie chart item. Can be one of 'host', 'port' or 'ipRange'.
    value String
    The value of the custom pie chart item. Valid syntax depends on the signature type of the chart item (see sample request/response for more details).
    name string
    The name of the custom pie chart item.
    type string
    The signature type for the custom pie chart item. Can be one of 'host', 'port' or 'ipRange'.
    value string
    The value of the custom pie chart item. Valid syntax depends on the signature type of the chart item (see sample request/response for more details).
    name str
    The name of the custom pie chart item.
    type str
    The signature type for the custom pie chart item. Can be one of 'host', 'port' or 'ipRange'.
    value str
    The value of the custom pie chart item. Valid syntax depends on the signature type of the chart item (see sample request/response for more details).
    name String
    The name of the custom pie chart item.
    type String
    The signature type for the custom pie chart item. Can be one of 'host', 'port' or 'ipRange'.
    value String
    The value of the custom pie chart item. Valid syntax depends on the signature type of the chart item (see sample request/response for more details).

    Import

    $ pulumi import meraki:networks/trafficAnalysis:TrafficAnalysis example "network_id"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    meraki pulumi/pulumi-meraki
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the meraki Terraform Provider.
    meraki logo
    Cisco Meraki v0.2.4 published on Friday, Jun 14, 2024 by Pulumi