1. Packages
  2. Cisco Meraki Provider
  3. API Docs
  4. networks
  5. SwitchAccessControlLists
Cisco Meraki v0.4.1 published on Saturday, Mar 15, 2025 by Pulumi

meraki.networks.SwitchAccessControlLists

Explore with Pulumi AI

Example Usage

Coming soon!
Coming soon!
Coming soon!
Coming soon!
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.meraki.networks.SwitchAccessControlLists;
import com.pulumi.meraki.networks.SwitchAccessControlListsArgs;
import com.pulumi.meraki.networks.inputs.SwitchAccessControlListsRuleArgs;
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 SwitchAccessControlLists("example", SwitchAccessControlListsArgs.builder()
            .networkId("string")
            .rules(SwitchAccessControlListsRuleArgs.builder()
                .comment("Deny SSH")
                .dst_cidr("172.16.30/24")
                .dst_port("22")
                .ip_version("ipv4")
                .policy("deny")
                .protocol("tcp")
                .src_cidr("10.1.10.0/24")
                .src_port("any")
                .vlan("10")
                .build())
            .build());

        ctx.export("merakiNetworksSwitchAccessControlListsExample", example);
    }
}
Copy
resources:
  example:
    type: meraki:networks:SwitchAccessControlLists
    properties:
      networkId: string
      rules:
        - comment: Deny SSH
          dst_cidr: 172.16.30/24
          dst_port: '22'
          ip_version: ipv4
          policy: deny
          protocol: tcp
          src_cidr: 10.1.10.0/24
          src_port: any
          vlan: '10'
outputs:
  merakiNetworksSwitchAccessControlListsExample: ${example}
Copy

Create SwitchAccessControlLists Resource

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

Constructor syntax

new SwitchAccessControlLists(name: string, args: SwitchAccessControlListsArgs, opts?: CustomResourceOptions);
@overload
def SwitchAccessControlLists(resource_name: str,
                             args: SwitchAccessControlListsArgs,
                             opts: Optional[ResourceOptions] = None)

@overload
def SwitchAccessControlLists(resource_name: str,
                             opts: Optional[ResourceOptions] = None,
                             network_id: Optional[str] = None,
                             rules: Optional[Sequence[SwitchAccessControlListsRuleArgs]] = None,
                             rules_responses: Optional[Sequence[SwitchAccessControlListsRulesResponseArgs]] = None)
func NewSwitchAccessControlLists(ctx *Context, name string, args SwitchAccessControlListsArgs, opts ...ResourceOption) (*SwitchAccessControlLists, error)
public SwitchAccessControlLists(string name, SwitchAccessControlListsArgs args, CustomResourceOptions? opts = null)
public SwitchAccessControlLists(String name, SwitchAccessControlListsArgs args)
public SwitchAccessControlLists(String name, SwitchAccessControlListsArgs args, CustomResourceOptions options)
type: meraki:networks:SwitchAccessControlLists
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. SwitchAccessControlListsArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. SwitchAccessControlListsArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. SwitchAccessControlListsArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. SwitchAccessControlListsArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. SwitchAccessControlListsArgs
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 switchAccessControlListsResource = new Meraki.Networks.SwitchAccessControlLists("switchAccessControlListsResource", new()
{
    NetworkId = "string",
    Rules = new[]
    {
        new Meraki.Networks.Inputs.SwitchAccessControlListsRuleArgs
        {
            Comment = "string",
            DstCidr = "string",
            DstPort = "string",
            IpVersion = "string",
            Policy = "string",
            Protocol = "string",
            SrcCidr = "string",
            SrcPort = "string",
            Vlan = "string",
        },
    },
    RulesResponses = new[]
    {
        new Meraki.Networks.Inputs.SwitchAccessControlListsRulesResponseArgs
        {
            Comment = "string",
            DstCidr = "string",
            DstPort = "string",
            IpVersion = "string",
            Policy = "string",
            Protocol = "string",
            SrcCidr = "string",
            SrcPort = "string",
            Vlan = "string",
        },
    },
});
Copy
example, err := networks.NewSwitchAccessControlLists(ctx, "switchAccessControlListsResource", &networks.SwitchAccessControlListsArgs{
	NetworkId: pulumi.String("string"),
	Rules: networks.SwitchAccessControlListsRuleArray{
		&networks.SwitchAccessControlListsRuleArgs{
			Comment:   pulumi.String("string"),
			DstCidr:   pulumi.String("string"),
			DstPort:   pulumi.String("string"),
			IpVersion: pulumi.String("string"),
			Policy:    pulumi.String("string"),
			Protocol:  pulumi.String("string"),
			SrcCidr:   pulumi.String("string"),
			SrcPort:   pulumi.String("string"),
			Vlan:      pulumi.String("string"),
		},
	},
	RulesResponses: networks.SwitchAccessControlListsRulesResponseArray{
		&networks.SwitchAccessControlListsRulesResponseArgs{
			Comment:   pulumi.String("string"),
			DstCidr:   pulumi.String("string"),
			DstPort:   pulumi.String("string"),
			IpVersion: pulumi.String("string"),
			Policy:    pulumi.String("string"),
			Protocol:  pulumi.String("string"),
			SrcCidr:   pulumi.String("string"),
			SrcPort:   pulumi.String("string"),
			Vlan:      pulumi.String("string"),
		},
	},
})
Copy
var switchAccessControlListsResource = new SwitchAccessControlLists("switchAccessControlListsResource", SwitchAccessControlListsArgs.builder()
    .networkId("string")
    .rules(SwitchAccessControlListsRuleArgs.builder()
        .comment("string")
        .dstCidr("string")
        .dstPort("string")
        .ipVersion("string")
        .policy("string")
        .protocol("string")
        .srcCidr("string")
        .srcPort("string")
        .vlan("string")
        .build())
    .rulesResponses(SwitchAccessControlListsRulesResponseArgs.builder()
        .comment("string")
        .dstCidr("string")
        .dstPort("string")
        .ipVersion("string")
        .policy("string")
        .protocol("string")
        .srcCidr("string")
        .srcPort("string")
        .vlan("string")
        .build())
    .build());
Copy
switch_access_control_lists_resource = meraki.networks.SwitchAccessControlLists("switchAccessControlListsResource",
    network_id="string",
    rules=[{
        "comment": "string",
        "dst_cidr": "string",
        "dst_port": "string",
        "ip_version": "string",
        "policy": "string",
        "protocol": "string",
        "src_cidr": "string",
        "src_port": "string",
        "vlan": "string",
    }],
    rules_responses=[{
        "comment": "string",
        "dst_cidr": "string",
        "dst_port": "string",
        "ip_version": "string",
        "policy": "string",
        "protocol": "string",
        "src_cidr": "string",
        "src_port": "string",
        "vlan": "string",
    }])
Copy
const switchAccessControlListsResource = new meraki.networks.SwitchAccessControlLists("switchAccessControlListsResource", {
    networkId: "string",
    rules: [{
        comment: "string",
        dstCidr: "string",
        dstPort: "string",
        ipVersion: "string",
        policy: "string",
        protocol: "string",
        srcCidr: "string",
        srcPort: "string",
        vlan: "string",
    }],
    rulesResponses: [{
        comment: "string",
        dstCidr: "string",
        dstPort: "string",
        ipVersion: "string",
        policy: "string",
        protocol: "string",
        srcCidr: "string",
        srcPort: "string",
        vlan: "string",
    }],
});
Copy
type: meraki:networks:SwitchAccessControlLists
properties:
    networkId: string
    rules:
        - comment: string
          dstCidr: string
          dstPort: string
          ipVersion: string
          policy: string
          protocol: string
          srcCidr: string
          srcPort: string
          vlan: string
    rulesResponses:
        - comment: string
          dstCidr: string
          dstPort: string
          ipVersion: string
          policy: string
          protocol: string
          srcCidr: string
          srcPort: string
          vlan: string
Copy

SwitchAccessControlLists Resource Properties

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

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The SwitchAccessControlLists resource accepts the following input properties:

NetworkId This property is required. string
networkId path parameter. Network ID
Rules List<SwitchAccessControlListsRule>
An ordered array of the access control list rules
RulesResponses List<SwitchAccessControlListsRulesResponse>
An ordered array of the access control list rules
NetworkId This property is required. string
networkId path parameter. Network ID
Rules []SwitchAccessControlListsRuleArgs
An ordered array of the access control list rules
RulesResponses []SwitchAccessControlListsRulesResponseArgs
An ordered array of the access control list rules
networkId This property is required. String
networkId path parameter. Network ID
rules List<SwitchAccessControlListsRule>
An ordered array of the access control list rules
rulesResponses List<SwitchAccessControlListsRulesResponse>
An ordered array of the access control list rules
networkId This property is required. string
networkId path parameter. Network ID
rules SwitchAccessControlListsRule[]
An ordered array of the access control list rules
rulesResponses SwitchAccessControlListsRulesResponse[]
An ordered array of the access control list rules
network_id This property is required. str
networkId path parameter. Network ID
rules Sequence[SwitchAccessControlListsRuleArgs]
An ordered array of the access control list rules
rules_responses Sequence[SwitchAccessControlListsRulesResponseArgs]
An ordered array of the access control list rules
networkId This property is required. String
networkId path parameter. Network ID
rules List<Property Map>
An ordered array of the access control list rules
rulesResponses List<Property Map>
An ordered array of the access control list rules

Outputs

All input properties are implicitly available as output properties. Additionally, the SwitchAccessControlLists 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 SwitchAccessControlLists Resource

Get an existing SwitchAccessControlLists 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?: SwitchAccessControlListsState, opts?: CustomResourceOptions): SwitchAccessControlLists
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        network_id: Optional[str] = None,
        rules: Optional[Sequence[SwitchAccessControlListsRuleArgs]] = None,
        rules_responses: Optional[Sequence[SwitchAccessControlListsRulesResponseArgs]] = None) -> SwitchAccessControlLists
func GetSwitchAccessControlLists(ctx *Context, name string, id IDInput, state *SwitchAccessControlListsState, opts ...ResourceOption) (*SwitchAccessControlLists, error)
public static SwitchAccessControlLists Get(string name, Input<string> id, SwitchAccessControlListsState? state, CustomResourceOptions? opts = null)
public static SwitchAccessControlLists get(String name, Output<String> id, SwitchAccessControlListsState state, CustomResourceOptions options)
resources:  _:    type: meraki:networks:SwitchAccessControlLists    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
NetworkId string
networkId path parameter. Network ID
Rules List<SwitchAccessControlListsRule>
An ordered array of the access control list rules
RulesResponses List<SwitchAccessControlListsRulesResponse>
An ordered array of the access control list rules
NetworkId string
networkId path parameter. Network ID
Rules []SwitchAccessControlListsRuleArgs
An ordered array of the access control list rules
RulesResponses []SwitchAccessControlListsRulesResponseArgs
An ordered array of the access control list rules
networkId String
networkId path parameter. Network ID
rules List<SwitchAccessControlListsRule>
An ordered array of the access control list rules
rulesResponses List<SwitchAccessControlListsRulesResponse>
An ordered array of the access control list rules
networkId string
networkId path parameter. Network ID
rules SwitchAccessControlListsRule[]
An ordered array of the access control list rules
rulesResponses SwitchAccessControlListsRulesResponse[]
An ordered array of the access control list rules
network_id str
networkId path parameter. Network ID
rules Sequence[SwitchAccessControlListsRuleArgs]
An ordered array of the access control list rules
rules_responses Sequence[SwitchAccessControlListsRulesResponseArgs]
An ordered array of the access control list rules
networkId String
networkId path parameter. Network ID
rules List<Property Map>
An ordered array of the access control list rules
rulesResponses List<Property Map>
An ordered array of the access control list rules

Supporting Types

SwitchAccessControlListsRule
, SwitchAccessControlListsRuleArgs

Comment string
Description of the rule (optional)
DstCidr string
Destination IP address (in IP or CIDR notation)
DstPort string
Destination port
IpVersion string
IP address version
Policy string
'allow' or 'deny' traffic specified by this rule
Protocol string
The type of protocol
SrcCidr string
Source IP address (in IP or CIDR notation)
SrcPort string
Source port
Vlan string
ncoming traffic VLAN
Comment string
Description of the rule (optional)
DstCidr string
Destination IP address (in IP or CIDR notation)
DstPort string
Destination port
IpVersion string
IP address version
Policy string
'allow' or 'deny' traffic specified by this rule
Protocol string
The type of protocol
SrcCidr string
Source IP address (in IP or CIDR notation)
SrcPort string
Source port
Vlan string
ncoming traffic VLAN
comment String
Description of the rule (optional)
dstCidr String
Destination IP address (in IP or CIDR notation)
dstPort String
Destination port
ipVersion String
IP address version
policy String
'allow' or 'deny' traffic specified by this rule
protocol String
The type of protocol
srcCidr String
Source IP address (in IP or CIDR notation)
srcPort String
Source port
vlan String
ncoming traffic VLAN
comment string
Description of the rule (optional)
dstCidr string
Destination IP address (in IP or CIDR notation)
dstPort string
Destination port
ipVersion string
IP address version
policy string
'allow' or 'deny' traffic specified by this rule
protocol string
The type of protocol
srcCidr string
Source IP address (in IP or CIDR notation)
srcPort string
Source port
vlan string
ncoming traffic VLAN
comment str
Description of the rule (optional)
dst_cidr str
Destination IP address (in IP or CIDR notation)
dst_port str
Destination port
ip_version str
IP address version
policy str
'allow' or 'deny' traffic specified by this rule
protocol str
The type of protocol
src_cidr str
Source IP address (in IP or CIDR notation)
src_port str
Source port
vlan str
ncoming traffic VLAN
comment String
Description of the rule (optional)
dstCidr String
Destination IP address (in IP or CIDR notation)
dstPort String
Destination port
ipVersion String
IP address version
policy String
'allow' or 'deny' traffic specified by this rule
protocol String
The type of protocol
srcCidr String
Source IP address (in IP or CIDR notation)
srcPort String
Source port
vlan String
ncoming traffic VLAN

SwitchAccessControlListsRulesResponse
, SwitchAccessControlListsRulesResponseArgs

Comment string
Description of the rule (optional)
DstCidr string
Destination IP address (in IP or CIDR notation)
DstPort string
Destination port
IpVersion string
IP address version
Policy string
'allow' or 'deny' traffic specified by this rule
Protocol string
The type of protocol
SrcCidr string
Source IP address (in IP or CIDR notation)
SrcPort string
Source port
Vlan string
ncoming traffic VLAN
Comment string
Description of the rule (optional)
DstCidr string
Destination IP address (in IP or CIDR notation)
DstPort string
Destination port
IpVersion string
IP address version
Policy string
'allow' or 'deny' traffic specified by this rule
Protocol string
The type of protocol
SrcCidr string
Source IP address (in IP or CIDR notation)
SrcPort string
Source port
Vlan string
ncoming traffic VLAN
comment String
Description of the rule (optional)
dstCidr String
Destination IP address (in IP or CIDR notation)
dstPort String
Destination port
ipVersion String
IP address version
policy String
'allow' or 'deny' traffic specified by this rule
protocol String
The type of protocol
srcCidr String
Source IP address (in IP or CIDR notation)
srcPort String
Source port
vlan String
ncoming traffic VLAN
comment string
Description of the rule (optional)
dstCidr string
Destination IP address (in IP or CIDR notation)
dstPort string
Destination port
ipVersion string
IP address version
policy string
'allow' or 'deny' traffic specified by this rule
protocol string
The type of protocol
srcCidr string
Source IP address (in IP or CIDR notation)
srcPort string
Source port
vlan string
ncoming traffic VLAN
comment str
Description of the rule (optional)
dst_cidr str
Destination IP address (in IP or CIDR notation)
dst_port str
Destination port
ip_version str
IP address version
policy str
'allow' or 'deny' traffic specified by this rule
protocol str
The type of protocol
src_cidr str
Source IP address (in IP or CIDR notation)
src_port str
Source port
vlan str
ncoming traffic VLAN
comment String
Description of the rule (optional)
dstCidr String
Destination IP address (in IP or CIDR notation)
dstPort String
Destination port
ipVersion String
IP address version
policy String
'allow' or 'deny' traffic specified by this rule
protocol String
The type of protocol
srcCidr String
Source IP address (in IP or CIDR notation)
srcPort String
Source port
vlan String
ncoming traffic VLAN

Import

$ pulumi import meraki:networks/switchAccessControlLists:SwitchAccessControlLists example "network_id"
Copy

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.