CiscoDevNet / ansible-meraki

Cisco Meraki Ansible Collection
GNU General Public License v3.0
60 stars 44 forks source link

meraki_mx_vlan - add groupPolicyId #419

Open DerrickTJ opened 1 year ago

DerrickTJ commented 1 year ago

Would like to have the ability to apply groupPolicyId to the VLAN as it is part of the API.

The easy path is to just ask for the groupPolicyId and be done with it. The extra mile would be to allow for the group policy name instead, and do the look up against {{baseUrl}}/networks/{{networkID}}/groupPolicies for the groupPolicyId

groupPolicyId is an optional field. Not required.

Example VLAN with a groupPolicyId applied

    {
        "id": 4,
        "networkId": "L_#####",
        "name": "PublicWifi",
        "applianceIp": "192.168.#.#",
        "subnet": "192.168.#.0/23",
        "groupPolicyId": "100",
        "fixedIpAssignments": {},
        "reservedIpRanges": [],
        "dnsNameservers": "opendns",
        "dhcpHandling": "Run a DHCP server",
        "dhcpLeaseTime": "1 hour",
        "dhcpBootOptionsEnabled": false,
        "dhcpOptions": [],
        "interfaceId": "###",
        "mandatoryDhcp": {
            "enabled": false
        }
kbreit commented 1 year ago

I can work on this and shouldn't be too bad to accept both ID and name.