diff --git a/docs/generation-report.md b/docs/generation-report.md index d186ba8..292e724 100644 --- a/docs/generation-report.md +++ b/docs/generation-report.md @@ -1,5 +1,11 @@ # Generation Report +## 2026-11-18 | Library v4.7.0b2 | API 1.76.0-beta.2 + + +No Python keyword parameter conflicts detected. + + ## 2026-11-11 | Library v4.7.0b1 | API 1.76.0-beta.1 diff --git a/meraki/__init__.py b/meraki/__init__.py index bfcb7b2..849895d 100644 --- a/meraki/__init__.py +++ b/meraki/__init__.py @@ -57,7 +57,7 @@ from meraki.exceptions import APIError, APIKeyError, APIResponseError, AsyncAPIError from meraki.rest_session import RestSession -__api_version__ = "1.76.0-beta.1" +__api_version__ = "1.76.0-beta.2" __all__ = [ "APIError", diff --git a/meraki/_version.py b/meraki/_version.py index 91ca231..55428e5 100644 --- a/meraki/_version.py +++ b/meraki/_version.py @@ -1 +1 @@ -__version__ = "4.7.0b1" +__version__ = "4.7.0b2" diff --git a/meraki/aio/api/appliance.py b/meraki/aio/api/appliance.py index 0b5608b..7cd5dc3 100644 --- a/meraki/aio/api/appliance.py +++ b/meraki/aio/api/appliance.py @@ -2685,13 +2685,13 @@ def updateNetworkApplianceTrafficShapingUplinkSelection(self, networkId: str, ** def updateNetworkApplianceTrafficShapingVpnExclusions(self, networkId: str, **kwargs): """ - **Update VPN exclusion rules for an MX network.** + **Update VPN exclusion rules for a Security Appliance or Secure Router network.** https://developer.cisco.com/meraki/api-v1/#!update-network-appliance-traffic-shaping-vpn-exclusions - networkId (string): Network ID - custom (array): Custom VPN exclusion rules. Pass an empty array to clear existing rules. - majorApplications (array): Major Application based VPN exclusion rules. Pass an empty array to clear existing rules. - - applications (array): NBAR application-based VPN exclusion rules. The documented example is a Secure Router NBAR catalog entry. On Secure Router networks, the ID and name must identify the same enabled NBAR application; traffic-shaping application IDs are not interchangeable. Available for networks on firmware >= 19.2. + - applications (array): NBAR application-based VPN exclusion rules. The documented example is a NBAR catalog entry. On Secure Router networks, the ID and name must identify the same enabled NBAR application; traffic-shaping application IDs are not interchangeable with NBAR application IDs. Available for networks on firmware >= 19.2. - applicationCategoryMapping (object): Options for mapping configured majorApplications to application categories. """ @@ -5790,7 +5790,7 @@ def getOrganizationApplianceTrafficShapingVpnExclusionsByNetwork( self, organizationId: str, total_pages=1, direction="next", **kwargs ): """ - **Display VPN exclusion rules for MX networks.** + **Display VPN exclusion rules for Security Appliance and Secure Router networks.** https://developer.cisco.com/meraki/api-v1/#!get-organization-appliance-traffic-shaping-vpn-exclusions-by-network - organizationId (string): Organization ID diff --git a/meraki/aio/api/campusGateway.py b/meraki/aio/api/campusGateway.py index 56179dd..6789e13 100644 --- a/meraki/aio/api/campusGateway.py +++ b/meraki/aio/api/campusGateway.py @@ -576,7 +576,7 @@ def provisionOrganizationCampusGatewayClusters( **kwargs, ): """ - **Provisions a cluster,adds campus gateways to it and associate/dissociate failover targets.** + **Provision a campus gateway cluster, add campus gateways, configure AP-assignment load balancing, and associate or dissociate failover targets** https://developer.cisco.com/meraki/api-v1/#!provision-organization-campus-gateway-clusters - organizationId (string): Organization ID diff --git a/meraki/aio/api/devices.py b/meraki/aio/api/devices.py index 9ce0e1c..dddb294 100644 --- a/meraki/aio/api/devices.py +++ b/meraki/aio/api/devices.py @@ -538,6 +538,68 @@ def getDeviceLiveToolsDhcpLease(self, serial: str, dhcpLeasesId: str): return self._session.get(metadata, resource) + def createDeviceLiveToolsDnsLookup(self, serial: str, hostname: str, dnsServer: str, queryType: str, **kwargs): + """ + **Enqueue a DNS lookup job from the device** + https://developer.cisco.com/meraki/api-v1/#!create-device-live-tools-dns-lookup + + - serial (string): Serial + - hostname (string): Hostname for the device to resolve. + - dnsServer (string): IPv4 or IPv6 DNS server address. + - queryType (string): DNS record type to request. + - callback (object): Details for the callback. Please include either an httpServerId OR url and sharedSecret + """ + + kwargs.update(locals()) + + if "queryType" in kwargs: + options = ["A", "AAAA"] + assert kwargs["queryType"] in options, ( + f'''"queryType" cannot be "{kwargs["queryType"]}", & must be set to one of: {options}''' + ) + + metadata = { + "tags": ["devices", "liveTools", "dnsLookup"], + "operation": "createDeviceLiveToolsDnsLookup", + } + serial = urllib.parse.quote(str(serial), safe="") + resource = f"/devices/{serial}/liveTools/dnsLookup" + + body_params = [ + "hostname", + "dnsServer", + "queryType", + "callback", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning(f"createDeviceLiveToolsDnsLookup: ignoring unrecognized kwargs: {invalid}") + + return self._session.post(metadata, resource, payload) + + def getDeviceLiveToolsDnsLookup(self, serial: str, id: str): + """ + **Return a DNS lookup job.** + https://developer.cisco.com/meraki/api-v1/#!get-device-live-tools-dns-lookup + + - serial (string): Serial + - id (string): ID + """ + + metadata = { + "tags": ["devices", "liveTools", "dnsLookup"], + "operation": "getDeviceLiveToolsDnsLookup", + } + serial = urllib.parse.quote(str(serial), safe="") + id = urllib.parse.quote(str(id), safe="") + resource = f"/devices/{serial}/liveTools/dnsLookup/{id}" + + return self._session.get(metadata, resource) + def createDeviceLiveToolsLedsBlink(self, serial: str, duration: int, **kwargs): """ **Enqueue a job to blink LEDs on a device** diff --git a/meraki/aio/api/networks.py b/meraki/aio/api/networks.py index 7089a9a..77e63bd 100644 --- a/meraki/aio/api/networks.py +++ b/meraki/aio/api/networks.py @@ -3268,6 +3268,73 @@ def getNetworkTrafficShapingDscpTaggingOptions(self, networkId: str): return self._session.get(metadata, resource) + def getNetworkUmbrellaAccount(self, networkId: str): + """ + **Show network-wide Umbrella account settings** + https://developer.cisco.com/meraki/api-v1/#!get-network-umbrella-account + + - networkId (string): Network ID + """ + + metadata = { + "tags": ["networks", "configure", "umbrella", "account"], + "operation": "getNetworkUmbrellaAccount", + } + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/umbrella/account" + + return self._session.get(metadata, resource) + + def updateNetworkUmbrellaAccount(self, networkId: str, key: str, secret: str, **kwargs): + """ + **Update network-wide Umbrella account settings** + https://developer.cisco.com/meraki/api-v1/#!update-network-umbrella-account + + - networkId (string): Network ID + - key (string): API key generated from Umbrella dashboard + - secret (string): API secret generated from Umbrella dashboard + """ + + kwargs = locals() + + metadata = { + "tags": ["networks", "configure", "umbrella", "account"], + "operation": "updateNetworkUmbrellaAccount", + } + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/umbrella/account" + + body_params = [ + "key", + "secret", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning(f"updateNetworkUmbrellaAccount: ignoring unrecognized kwargs: {invalid}") + + return self._session.put(metadata, resource, payload) + + def getNetworkUmbrellaPolicies(self, networkId: str): + """ + **Return a list of Umbrella protection policies available for applying on an SSID or Group Policy** + https://developer.cisco.com/meraki/api-v1/#!get-network-umbrella-policies + + - networkId (string): Network ID + """ + + metadata = { + "tags": ["networks", "configure", "umbrella", "policies"], + "operation": "getNetworkUmbrellaPolicies", + } + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/umbrella/policies" + + return self._session.get(metadata, resource) + def unbindNetwork(self, networkId: str, **kwargs): """ **Unbind a network from a template.** diff --git a/meraki/aio/api/switch.py b/meraki/aio/api/switch.py index 9f18000..212e63e 100644 --- a/meraki/aio/api/switch.py +++ b/meraki/aio/api/switch.py @@ -210,7 +210,6 @@ def updateDeviceSwitchPort(self, serial: str, portId: str, **kwargs): - vlan (integer): The VLAN of the switch port. For a trunk port, this is the native VLAN. A null value will clear the value set for trunk ports. - voiceVlan (integer): The voice VLAN of the switch port. Only applicable to access ports. - allowedVlans (string): The VLANs allowed on the switch port. Only applicable to trunk ports. - - activeVlans (string): The VLANs that are active on the switch port. Only applicable to trunk ports. - isolationEnabled (boolean): The isolation status of the switch port. - rstpEnabled (boolean): The rapid spanning tree protocol status. - stpGuard (string): The state of the STP guard ('disabled', 'root guard', 'bpdu guard' or 'loop guard'). @@ -273,7 +272,6 @@ def updateDeviceSwitchPort(self, serial: str, portId: str, **kwargs): "vlan", "voiceVlan", "allowedVlans", - "activeVlans", "isolationEnabled", "rstpEnabled", "stpGuard", @@ -3635,7 +3633,6 @@ def updateOrganizationConfigTemplateSwitchProfilePort( - vlan (integer): The VLAN of the switch template port. For a trunk port, this is the native VLAN. A null value will clear the value set for trunk ports. - voiceVlan (integer): The voice VLAN of the switch template port. Only applicable to access ports. - allowedVlans (string): The VLANs allowed on the switch template port. Only applicable to trunk ports. - - activeVlans (string): The VLANs that are active on the switch template port. Only applicable to trunk ports. - isolationEnabled (boolean): The isolation status of the switch template port. - rstpEnabled (boolean): The rapid spanning tree protocol status. - stpGuard (string): The state of the STP guard ('disabled', 'root guard', 'bpdu guard' or 'loop guard'). @@ -3700,7 +3697,6 @@ def updateOrganizationConfigTemplateSwitchProfilePort( "vlan", "voiceVlan", "allowedVlans", - "activeVlans", "isolationEnabled", "rstpEnabled", "stpGuard", diff --git a/meraki/aio/api/wireless.py b/meraki/aio/api/wireless.py index 2b72bb0..7f40bbe 100644 --- a/meraki/aio/api/wireless.py +++ b/meraki/aio/api/wireless.py @@ -3156,6 +3156,43 @@ def updateNetworkWirelessSsid(self, networkId: str, number: str, **kwargs): return self._session.put(metadata, resource, payload) + def updateNetworkWirelessSsidAddressingGuards(self, networkId: str, number: str, **kwargs): + """ + **Update the DHCP Guard and Router Advertisement (RA) Guard settings for an SSID.** + https://developer.cisco.com/meraki/api-v1/#!update-network-wireless-ssid-addressing-guards + + - networkId (string): Network ID + - number (string): Number + - dhcp (object): DHCP Guard configuration for the SSID. + - ra (object): Router Advertisement (RA) Guard configuration for the SSID. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "addressing", "guards"], + "operation": "updateNetworkWirelessSsidAddressingGuards", + } + networkId = urllib.parse.quote(str(networkId), safe="") + number = urllib.parse.quote(str(number), safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/addressing/guards" + + body_params = [ + "dhcp", + "ra", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"updateNetworkWirelessSsidAddressingGuards: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.put(metadata, resource, payload) + def getNetworkWirelessSsidBonjourForwarding(self, networkId: str, number: str): """ **List the Bonjour forwarding setting and rules for the SSID** @@ -3519,6 +3556,43 @@ def updateNetworkWirelessSsidHotspot20(self, networkId: str, number: str, **kwar return self._session.put(metadata, resource, payload) + def updateNetworkWirelessSsidHttpProxies(self, number: int, networkId: str, **kwargs): + """ + **Update the HTTP force proxy settings for an SSID.** + https://developer.cisco.com/meraki/api-v1/#!update-network-wireless-ssid-http-proxies + + - number (integer): SSID number. Valid values are 0-14. + - networkId (string): Network ID + - enabled (boolean): Whether clients on the SSID are forced through the HTTP proxy. + - server (object): HTTP proxy server that intercepted traffic is forwarded to. + - exclusions (array): Destinations excluded from forced proxying. A supplied array replaces the list; an empty array clears it while the proxy is enabled. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "http", "proxies"], + "operation": "updateNetworkWirelessSsidHttpProxies", + } + number = urllib.parse.quote(str(number), safe="") + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/http/proxies" + + body_params = [ + "enabled", + "server", + "exclusions", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning(f"updateNetworkWirelessSsidHttpProxies: ignoring unrecognized kwargs: {invalid}") + + return self._session.put(metadata, resource, payload) + def getNetworkWirelessSsidIdentityPsks(self, networkId: str, number: str): """ **List all Identity PSKs in a wireless network** @@ -4139,6 +4213,41 @@ def getNetworkWirelessSsidTrafficShapingRules(self, networkId: str, number: str) return self._session.get(metadata, resource) + def createNetworkWirelessSsidUmbrellaProtectionJob(self, networkId: str, number: str, request: dict, **kwargs): + """ + **Apply Umbrella protection on an SSID of an MR network** + https://developer.cisco.com/meraki/api-v1/#!create-network-wireless-ssid-umbrella-protection-job + + - networkId (string): Network ID + - number (string): Number + - request (object): Umbrella protection configuration to apply. + """ + + kwargs = locals() + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "jobs"], + "operation": "createNetworkWirelessSsidUmbrellaProtectionJob", + } + networkId = urllib.parse.quote(str(networkId), safe="") + number = urllib.parse.quote(str(number), safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/umbrella/protection/jobs" + + body_params = [ + "request", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"createNetworkWirelessSsidUmbrellaProtectionJob: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.post(metadata, resource, payload) + def getNetworkWirelessSsidVpn(self, networkId: str, number: str): """ **List the VPN settings for the SSID.** @@ -6583,7 +6692,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetwork( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6595,7 +6704,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetwork( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetwork", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6649,7 +6758,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByBand( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6661,7 +6770,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByBand( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byBand"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byBand"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByBand", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6715,7 +6824,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClient( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6727,7 +6836,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClient( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byClient"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byClient"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClient", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6781,7 +6890,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientOs( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6793,7 +6902,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientOs( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byClientOs"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byClientOs"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientOs", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6847,7 +6956,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientType - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6859,7 +6968,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientType kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byClientType"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byClientType"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientType", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6913,7 +7022,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByDevice( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6925,7 +7034,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByDevice( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byDevice"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byDevice"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByDevice", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -7047,7 +7156,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByServer( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -7059,7 +7168,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByServer( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byServer"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byServer"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByServer", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -7113,7 +7222,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkBySsid( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -7125,7 +7234,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkBySsid( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "bySsid"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "bySsid"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkBySsid", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -7177,9 +7286,9 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectInsightsByNetwork( - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages - direction (string): direction to paginate, either "next" (default) or "prev" page - networkIds (array): Filter results by network. - - serials (array): Filter results by device serial. + - serials (array): Filter results by SSID number. Valid values are 0-14. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - insights (string): Source used to compute insights. Defaults to dashboard. - contributor (string): Contributor for which to retrieve insights. If not specified, returns overall insights. - subContributor (string): Sub-contributor for which to retrieve insights. If not specified, returns all sub contributor insights. @@ -7205,7 +7314,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectInsightsByNetwork( ) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "insights", "byNetwork"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "insights", "byNetwork"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectInsightsByNetwork", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -10825,6 +10934,121 @@ def byOrganizationWirelessOpportunisticPcapLicenseNetwork(self, organizationId: return self._session.get(metadata, resource, params) + def getOrganizationWirelessPolicyApplications(self, organizationId: str, total_pages=1, direction="next", **kwargs): + """ + **List wireless policy applications and their categories for eligible wireless sources (standalone networks and configuration templates) in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-policy-applications + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional inclusive-OR filter on standalone wireless network IDs. Mutually exclusive with configTemplateIds. Maximum 50 IDs. + - configTemplateIds (array): Optional inclusive-OR filter on wireless configuration-template IDs. Mutually exclusive with networkIds. Maximum 50 IDs. + - resourceIds (array): Optional inclusive-OR filter on returned applicationId values. Maximum 50 IDs. + - categoryIds (array): Optional inclusive-OR filter on category.id; returns only applications in the selected categories. Maximum 50 IDs. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 50. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "policy", "applications"], + "operation": "getOrganizationWirelessPolicyApplications", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/policy/applications" + + query_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + "categoryIds", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + "categoryIds", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessPolicyApplications: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + + def getOrganizationWirelessPolicyApplicationsCategories( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List wireless policy application categories for eligible wireless sources (standalone networks and configuration templates) in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-policy-applications-categories + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional inclusive-OR filter on standalone wireless network IDs. Mutually exclusive with configTemplateIds. Maximum 50 IDs. + - configTemplateIds (array): Optional inclusive-OR filter on wireless configuration-template IDs. Mutually exclusive with networkIds. Maximum 50 IDs. + - resourceIds (array): Optional inclusive-OR filter on returned categoryId values. Maximum 50 IDs. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 50. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "policy", "applications", "categories"], + "operation": "getOrganizationWirelessPolicyApplicationsCategories", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/policy/applications/categories" + + query_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessPolicyApplicationsCategories: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessRadioAfcPositionByDevice(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **List the AFC power limits of an organization by device** @@ -11389,50 +11613,6 @@ def getOrganizationWirelessRadioRrmByNetwork(self, organizationId: str, total_pa return self._session.get_pages(metadata, resource, params, total_pages, direction) - def getOrganizationWirelessRadioStatusByNetwork(self, organizationId: str, **kwargs): - """ - **Show the status of this organization's radios, categorized by network and device** - https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-radio-status-by-network - - - organizationId (string): Organization ID - - networkIds (array): Networks for which radio status should be returned. - - serials (array): Serials for which radio status should be returned. - """ - - kwargs.update(locals()) - - metadata = { - "tags": ["wireless", "configure", "radio", "status", "byNetwork"], - "operation": "getOrganizationWirelessRadioStatusByNetwork", - } - organizationId = urllib.parse.quote(str(organizationId), safe="") - resource = f"/organizations/{organizationId}/wireless/radio/status/byNetwork" - - query_params = [ - "networkIds", - "serials", - ] - params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} - - array_params = [ - "networkIds", - "serials", - ] - for k, v in kwargs.items(): - if k.strip() in array_params: - params[f"{k.strip()}[]"] = kwargs[f"{k}"] - params.pop(k.strip()) - - if self._session._validate_kwargs: - all_params = query_params + array_params - invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] - if invalid and self._session._logger: - self._session._logger.warning( - f"getOrganizationWirelessRadioStatusByNetwork: ignoring unrecognized kwargs: {invalid}" - ) - - return self._session.get(metadata, resource, params) - def getOrganizationWirelessRadioStatusesByDevice(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **List a paginated snapshot of current radio status for wireless devices in an organization** @@ -11605,6 +11785,58 @@ def getOrganizationWirelessRoamingByNetworkByInterval(self, organizationId: str, return self._session.get(metadata, resource, params) + def getOrganizationWirelessSsidsAddressingGuards(self, organizationId: str, total_pages=1, direction="next", **kwargs): + """ + **List the DHCP Guard and Router Advertisement (RA) Guard settings for SSIDs in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-addressing-guards + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional parameter to filter results by network IDs. Maximum 100 network IDs. + - ssidNumbers (array): Optional parameter to filter results by SSID numbers. Valid values are 0-14. Maximum 15 SSID numbers. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 1000. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "addressing", "guards"], + "operation": "getOrganizationWirelessSsidsAddressingGuards", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/addressing/guards" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsAddressingGuards: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessSsidsFirewallIsolationAllowlistEntries( self, organizationId: str, total_pages=1, direction="next", **kwargs ): @@ -11756,6 +11988,58 @@ def updateOrganizationWirelessSsidsFirewallIsolationAllowlistEntry(self, organiz return self._session.put(metadata, resource, payload) + def getOrganizationWirelessSsidsHttpProxies(self, organizationId: str, total_pages=1, direction="next", **kwargs): + """ + **List the HTTP force proxy settings for SSIDs in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-http-proxies + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional parameter to filter results by network IDs. Maximum 100 network IDs. + - ssidNumbers (array): Optional parameter to filter results by SSID numbers. Valid values are 0-14. Maximum 15 SSID numbers. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 1000. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "http", "proxies"], + "operation": "getOrganizationWirelessSsidsHttpProxies", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/http/proxies" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsHttpProxies: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessSsidsOpenRoamingByNetwork(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **Returns an array of objects, each containing SSID OpenRoaming configs for the corresponding network** @@ -12448,6 +12732,171 @@ def getOrganizationWirelessSsidsStatusesByDevice(self, organizationId: str, tota return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessSsidsUmbrellaProtectionBySsid( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List Umbrella protection settings and lifecycle availability for SSIDs in an organization.** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-umbrella-protection-by-ssid + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional filter by network IDs. Maximum 100 IDs. + - ssidNumbers (array): Optional filter by SSID numbers. Valid values are 0-14. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "bySsid"], + "operation": "getOrganizationWirelessSsidsUmbrellaProtectionBySsid", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/umbrella/protection/bySsid" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsUmbrellaProtectionBySsid: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + + def getOrganizationWirelessSsidsUmbrellaProtectionJobs( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List Umbrella protection jobs for SSIDs in an organization.** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-umbrella-protection-jobs + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional filter by network IDs. Maximum 100 IDs. + - ssidNumbers (array): Optional filter by SSID numbers. Valid values are 0-14. + - jobIds (array): Optional filter by Umbrella protection job IDs. Maximum 100 IDs. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "jobs"], + "operation": "getOrganizationWirelessSsidsUmbrellaProtectionJobs", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/umbrella/protection/jobs" + + query_params = [ + "networkIds", + "ssidNumbers", + "jobIds", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + "jobIds", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsUmbrellaProtectionJobs: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + + def getOrganizationWirelessSsidsUmbrellaProtectionPoliciesBySsid( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List Umbrella policies applied to SSIDs in an organization.** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-umbrella-protection-policies-by-ssid + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional filter by network IDs. Maximum 100 IDs. + - ssidNumbers (array): Optional filter by SSID numbers. Valid values are 0-14. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 20. Default is 10. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "policies", "bySsid"], + "operation": "getOrganizationWirelessSsidsUmbrellaProtectionPoliciesBySsid", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/umbrella/protection/policies/bySsid" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsUmbrellaProtectionPoliciesBySsid: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessZigbeeByNetwork(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **Return list of Zigbee configs** diff --git a/meraki/api/appliance.py b/meraki/api/appliance.py index e9a0173..fca0374 100644 --- a/meraki/api/appliance.py +++ b/meraki/api/appliance.py @@ -2685,13 +2685,13 @@ def updateNetworkApplianceTrafficShapingUplinkSelection(self, networkId: str, ** def updateNetworkApplianceTrafficShapingVpnExclusions(self, networkId: str, **kwargs): """ - **Update VPN exclusion rules for an MX network.** + **Update VPN exclusion rules for a Security Appliance or Secure Router network.** https://developer.cisco.com/meraki/api-v1/#!update-network-appliance-traffic-shaping-vpn-exclusions - networkId (string): Network ID - custom (array): Custom VPN exclusion rules. Pass an empty array to clear existing rules. - majorApplications (array): Major Application based VPN exclusion rules. Pass an empty array to clear existing rules. - - applications (array): NBAR application-based VPN exclusion rules. The documented example is a Secure Router NBAR catalog entry. On Secure Router networks, the ID and name must identify the same enabled NBAR application; traffic-shaping application IDs are not interchangeable. Available for networks on firmware >= 19.2. + - applications (array): NBAR application-based VPN exclusion rules. The documented example is a NBAR catalog entry. On Secure Router networks, the ID and name must identify the same enabled NBAR application; traffic-shaping application IDs are not interchangeable with NBAR application IDs. Available for networks on firmware >= 19.2. - applicationCategoryMapping (object): Options for mapping configured majorApplications to application categories. """ @@ -5790,7 +5790,7 @@ def getOrganizationApplianceTrafficShapingVpnExclusionsByNetwork( self, organizationId: str, total_pages=1, direction="next", **kwargs ): """ - **Display VPN exclusion rules for MX networks.** + **Display VPN exclusion rules for Security Appliance and Secure Router networks.** https://developer.cisco.com/meraki/api-v1/#!get-organization-appliance-traffic-shaping-vpn-exclusions-by-network - organizationId (string): Organization ID diff --git a/meraki/api/batch/appliance.py b/meraki/api/batch/appliance.py index 37aaab0..7a8cb9c 100644 --- a/meraki/api/batch/appliance.py +++ b/meraki/api/batch/appliance.py @@ -1189,13 +1189,13 @@ def updateNetworkApplianceTrafficShapingUplinkSelection(self, networkId: str, ** def updateNetworkApplianceTrafficShapingVpnExclusions(self, networkId: str, **kwargs): """ - **Update VPN exclusion rules for an MX network.** + **Update VPN exclusion rules for a Security Appliance or Secure Router network.** https://developer.cisco.com/meraki/api-v1/#!update-network-appliance-traffic-shaping-vpn-exclusions - networkId (string): Network ID - custom (array): Custom VPN exclusion rules. Pass an empty array to clear existing rules. - majorApplications (array): Major Application based VPN exclusion rules. Pass an empty array to clear existing rules. - - applications (array): NBAR application-based VPN exclusion rules. The documented example is a Secure Router NBAR catalog entry. On Secure Router networks, the ID and name must identify the same enabled NBAR application; traffic-shaping application IDs are not interchangeable. Available for networks on firmware >= 19.2. + - applications (array): NBAR application-based VPN exclusion rules. The documented example is a NBAR catalog entry. On Secure Router networks, the ID and name must identify the same enabled NBAR application; traffic-shaping application IDs are not interchangeable with NBAR application IDs. Available for networks on firmware >= 19.2. - applicationCategoryMapping (object): Options for mapping configured majorApplications to application categories. """ @@ -1682,7 +1682,7 @@ def updateNetworkApplianceVpnBgp(self, networkId: str, enabled: bool, **kwargs): def updateNetworkApplianceVpnSiteToSiteHubVrfs(self, networkId: str, hubNetworkId: str, vrfs: list, **kwargs): """ - **Replace the complete VRF mapping for a source network and hub pair. The required 'vrfs' array replaces the current VRF selection. An omitted array returns a 400 response and does not change the mapping. For a spoke source, an empty array selects only the default VRF. For a hub source, the array must contain at least one item. In a non-empty array, use VRF ID '0' to select the default VRF, either alone or alongside non-default VRFs.** + **Replace the complete VRF mapping for a source network and hub pair. Both the source and hub must be MX networks in the same organization. Configuration templates are not supported. The source network must support site-to-site VPN and VRF mappings and must use spoke or hub mode. For a spoke source, the specified hub must already be configured as a default-route hub. For a hub source, the specified hub must already be configured as an exit hub. The required 'vrfs' array replaces the current VRF selection. An omitted array returns a 400 response and does not change the mapping. For a spoke source, an empty array selects only the default VRF. For a hub source, the array must contain at least one item. In a non-empty array, use VRF ID '0' to select the default VRF, either alone or alongside non-default VRFs.** https://developer.cisco.com/meraki/api-v1/#!update-network-appliance-vpn-site-to-site-hub-vrfs - networkId (string): Network ID diff --git a/meraki/api/batch/campusGateway.py b/meraki/api/batch/campusGateway.py index 989c10e..290f92e 100644 --- a/meraki/api/batch/campusGateway.py +++ b/meraki/api/batch/campusGateway.py @@ -219,7 +219,7 @@ def provisionOrganizationCampusGatewayClusters( **kwargs, ): """ - **Provisions a cluster,adds campus gateways to it and associate/dissociate failover targets.** + **Provision a campus gateway cluster, add campus gateways, configure AP-assignment load balancing, and associate or dissociate failover targets. Invalid loadBalancing mode and primary serial combinations return 400 Bad Request with the standard errors string-array response.** https://developer.cisco.com/meraki/api-v1/#!provision-organization-campus-gateway-clusters - organizationId (string): Organization ID diff --git a/meraki/api/batch/devices.py b/meraki/api/batch/devices.py index 6337b7a..8d5eed6 100644 --- a/meraki/api/batch/devices.py +++ b/meraki/api/batch/devices.py @@ -7,7 +7,7 @@ def __init__(self): def updateDevice(self, serial: str, **kwargs): """ - **Update the attributes of a device** + **Update the attributes of a device. After a successful claim, updates may return HTTP 404 for a few minutes. Retry with increasing delays and a timeout. See the Claim Network Devices endpoint.** https://developer.cisco.com/meraki/api-v1/#!update-device - serial (string): Serial @@ -151,6 +151,43 @@ def revokeDeviceCertificate(self, serial: str, certificateSerial: str, **kwargs) } return action + def createDeviceLiveToolsDnsLookup(self, serial: str, hostname: str, dnsServer: str, queryType: str, **kwargs): + """ + **Enqueue a DNS lookup job from the device. This endpoint has a sustained rate limit of one request every five seconds per device, with an allowed burst of five requests.** + https://developer.cisco.com/meraki/api-v1/#!create-device-live-tools-dns-lookup + + - serial (string): Serial + - hostname (string): Hostname for the device to resolve. + - dnsServer (string): IPv4 or IPv6 DNS server address. + - queryType (string): DNS record type to request. + - callback (object): Details for the callback. Please include either an httpServerId OR url and sharedSecret + """ + + kwargs.update(locals()) + + if "queryType" in kwargs: + options = ["A", "AAAA"] + assert kwargs["queryType"] in options, ( + f'''"queryType" cannot be "{kwargs["queryType"]}", & must be set to one of: {options}''' + ) + + serial = urllib.parse.quote(serial, safe="") + resource = f"/devices/{serial}/liveTools/dnsLookup" + + body_params = [ + "hostname", + "dnsServer", + "queryType", + "callback", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + action = { + "resource": resource, + "operation": "lookup", + "body": payload, + } + return action + def createDeviceLiveToolsLedsBlink(self, serial: str, duration: int, **kwargs): """ **Enqueue a job to blink LEDs on a device. This endpoint has a rate limit of one request every 10 seconds.** diff --git a/meraki/api/batch/organizations.py b/meraki/api/batch/organizations.py index d0f9b94..0b06aa0 100644 --- a/meraki/api/batch/organizations.py +++ b/meraki/api/batch/organizations.py @@ -2272,7 +2272,7 @@ def updateOrganizationLoginSecurity(self, organizationId: str, **kwargs): def deleteMcfOrganization(self, organizationId: str): """ - **Removes the associated Multicloud Fabric organization from active use while retaining its configuration and related resource records. All onboarded VPCs and Sites must be removed first. A successful removal allows the same Meraki Dashboard organization to onboard again as a new Multicloud Fabric organization. Repeating removal before onboarding again returns 404.** + **Removes the associated Multicloud Fabric organization from active use while retaining its configuration and related resource records. All VPC and Site onboardings must be removed first, including incomplete, failed, and removal-in-progress onboardings. A successful removal allows the same Meraki Dashboard organization to onboard again as a new Multicloud Fabric organization. Repeating removal before onboarding again returns 404.** https://developer.cisco.com/meraki/api-v1/#!delete-mcf-organization - organizationId (string): Organization ID @@ -2723,7 +2723,7 @@ def claimOrganizationSubscription( self, organizationId: str, type: str, ccwWebOrderSubscriptionRefIdPair: dict, termsAcceptance: dict, **kwargs ): """ - **Claims a CCW subscription using its original Web Order ID and subscription reference ID. Creates the Multicloud Fabric organization if needed and records acceptance of the current commercial terms. An already claimed purchase returns a conflict, including when requested by its owner. When the organization has no `ACTIVE` CCW subscriptions, the purchase's coverage must have started by the current UTC day. Otherwise, it must start on the UTC day immediately after the latest term of the organization's `ACTIVE` CCW subscriptions ends; that start may be in the future. Only `ACTIVE` CCW subscriptions establish this coverage boundary; `PENDING`, `CANCELLED`, and `EXPIRED` purchases do not. Gaps and overlaps with active coverage are rejected. An organization can claim only one future paid subscription at a time: another claim is rejected when it already has two or more `ACTIVE` CCW subscriptions. Each subscription counts once regardless of its number of terms. When one `ACTIVE` CCW subscription exists, turn off its auto-renewal in Cisco Commerce Workspace (CCW) before claiming another purchase. Trial, cancelled, and expired subscriptions do not count toward this limit. Claiming a CCW purchase cancels an existing active trial and closes its open term at the claim time, preserving trial history and usage. When the claim creates an organization, the optional `MCF-Shell` header records its creation source: `meraki` (Meraki Dashboard) or `ccc` (Cisco Cloud Control). Only one exact, case-sensitive value is recognized. Missing or invalid values, including repeated headers, leave the source unknown without causing a request error. The source is not returned in the response. Existing organizations retain their original source, including an unknown source.** + **Claims a CCW subscription using its original Web Order ID and subscription reference ID. Creates the Multicloud Fabric organization if needed and records acceptance of the current commercial terms. An already claimed purchase returns a conflict, including when requested by its owner. When the organization has no `ACTIVE` CCW subscriptions, the purchase's coverage must have started by the current UTC day. Otherwise, it must start on the UTC day immediately after the latest term of the organization's `ACTIVE` CCW subscriptions ends; that start may be in the future. Only `ACTIVE` CCW subscriptions establish this coverage boundary; `PENDING`, `CANCELLED`, and `EXPIRED` purchases do not. Gaps and overlaps with active coverage are rejected. An organization can claim only one future paid subscription at a time: another claim is rejected when it already has two or more `ACTIVE` CCW subscriptions. Each subscription counts once regardless of its number of terms. When one `ACTIVE` CCW subscription exists, turn off its auto-renewal in Cisco Commerce Workspace (CCW) before claiming another purchase. Trial, cancelled, and expired subscriptions do not count toward this limit. Claiming a CCW purchase cancels an existing active trial and closes its open term at the claim time, preserving trial history and usage. When the claim creates an organization, the optional `MCF-Shell` header records its creation source: `meraki` (Meraki Dashboard) or `ccc` (Cisco Cloud Control). Only one exact, case-sensitive value is recognized. Missing or invalid values, including repeated headers, record `api` (direct API access) without causing a request error. The source is not returned in the response. Existing organizations retain their original source, including an unknown source.** https://developer.cisco.com/meraki/api-v1/#!claim-organization-subscription - organizationId (string): Organization ID @@ -2756,7 +2756,7 @@ def claimOrganizationSubscription( def createOrganizationTrialSubscription(self, organizationId: str, termsAcceptance: dict, **kwargs): """ - **Starts a Multicloud Fabric trial for an organization that has not enabled Multicloud Fabric. An organization that already has Multicloud Fabric enabled cannot start a trial. The optional `MCF-Shell` header records the new organization's creation source: `meraki` (Meraki Dashboard) or `ccc` (Cisco Cloud Control). Only one exact, case-sensitive value is recognized. Missing or invalid values, including repeated headers, leave the source unknown without causing a request error. The source is not returned in the response.** + **Starts a Multicloud Fabric trial for an organization that has not enabled Multicloud Fabric. An organization that already has Multicloud Fabric enabled cannot start a trial. The optional `MCF-Shell` header records the new organization's creation source: `meraki` (Meraki Dashboard) or `ccc` (Cisco Cloud Control). Only one exact, case-sensitive value is recognized. Missing or invalid values, including repeated headers, record `api` (direct API access) without causing a request error. The source is not returned in the response.** https://developer.cisco.com/meraki/api-v1/#!create-organization-trial-subscription - organizationId (string): Organization ID diff --git a/meraki/api/batch/switch.py b/meraki/api/batch/switch.py index 9844e29..1d563ff 100644 --- a/meraki/api/batch/switch.py +++ b/meraki/api/batch/switch.py @@ -81,7 +81,6 @@ def updateDeviceSwitchPort(self, serial: str, portId: str, **kwargs): - vlan (integer): The VLAN of the switch port. For a trunk port, this is the native VLAN. A null value will clear the value set for trunk ports. - voiceVlan (integer): The voice VLAN of the switch port. Only applicable to access ports. - allowedVlans (string): The VLANs allowed on the switch port. Only applicable to trunk ports. - - activeVlans (string): The VLANs that are active on the switch port. Only applicable to trunk ports. - isolationEnabled (boolean): The isolation status of the switch port. - rstpEnabled (boolean): The rapid spanning tree protocol status. - stpGuard (string): The state of the STP guard ('disabled', 'root guard', 'bpdu guard' or 'loop guard'). @@ -140,7 +139,6 @@ def updateDeviceSwitchPort(self, serial: str, portId: str, **kwargs): "vlan", "voiceVlan", "allowedVlans", - "activeVlans", "isolationEnabled", "rstpEnabled", "stpGuard", @@ -2096,7 +2094,6 @@ def updateOrganizationConfigTemplateSwitchProfilePort( - vlan (integer): The VLAN of the switch template port. For a trunk port, this is the native VLAN. A null value will clear the value set for trunk ports. - voiceVlan (integer): The voice VLAN of the switch template port. Only applicable to access ports. - allowedVlans (string): The VLANs allowed on the switch template port. Only applicable to trunk ports. - - activeVlans (string): The VLANs that are active on the switch template port. Only applicable to trunk ports. - isolationEnabled (boolean): The isolation status of the switch template port. - rstpEnabled (boolean): The rapid spanning tree protocol status. - stpGuard (string): The state of the STP guard ('disabled', 'root guard', 'bpdu guard' or 'loop guard'). @@ -2157,7 +2154,6 @@ def updateOrganizationConfigTemplateSwitchProfilePort( "vlan", "voiceVlan", "allowedVlans", - "activeVlans", "isolationEnabled", "rstpEnabled", "stpGuard", diff --git a/meraki/api/batch/wireless.py b/meraki/api/batch/wireless.py index 74eabca..edcae91 100644 --- a/meraki/api/batch/wireless.py +++ b/meraki/api/batch/wireless.py @@ -1279,6 +1279,35 @@ def updateNetworkWirelessSsid(self, networkId: str, number: str, **kwargs): } return action + def updateNetworkWirelessSsidAddressingGuards(self, networkId: str, number: str, **kwargs): + """ + **Update the DHCP Guard and Router Advertisement (RA) Guard settings for an SSID.** + https://developer.cisco.com/meraki/api-v1/#!update-network-wireless-ssid-addressing-guards + + - networkId (string): Network ID + - number (string): Number + - dhcp (object): DHCP Guard configuration for the SSID. + - ra (object): Router Advertisement (RA) Guard configuration for the SSID. + """ + + kwargs.update(locals()) + + networkId = urllib.parse.quote(networkId, safe="") + number = urllib.parse.quote(number, safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/addressing/guards" + + body_params = [ + "dhcp", + "ra", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + action = { + "resource": resource, + "operation": "update", + "body": payload, + } + return action + def updateNetworkWirelessSsidBonjourForwarding(self, networkId: str, number: str, **kwargs): """ **Update the bonjour forwarding setting and rules for the SSID** @@ -1484,6 +1513,37 @@ def updateNetworkWirelessSsidHotspot20(self, networkId: str, number: str, **kwar } return action + def updateNetworkWirelessSsidHttpProxies(self, number: int, networkId: str, **kwargs): + """ + **Update the HTTP force proxy settings for an SSID.** + https://developer.cisco.com/meraki/api-v1/#!update-network-wireless-ssid-http-proxies + + - number (integer): SSID number. Valid values are 0-14. + - networkId (string): Network ID + - enabled (boolean): Whether clients on the SSID are forced through the HTTP proxy. + - server (object): HTTP proxy server that intercepted traffic is forwarded to. + - exclusions (array): Destinations excluded from forced proxying. A supplied array replaces the list; an empty array clears it while the proxy is enabled. + """ + + kwargs.update(locals()) + + number = urllib.parse.quote(number, safe="") + networkId = urllib.parse.quote(networkId, safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/http/proxies" + + body_params = [ + "enabled", + "server", + "exclusions", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + action = { + "resource": resource, + "operation": "update", + "body": payload, + } + return action + def createNetworkWirelessSsidIdentityPsk(self, networkId: str, number: str, name: str, groupPolicyId: str, **kwargs): """ **Create an Identity PSK** diff --git a/meraki/api/campusGateway.py b/meraki/api/campusGateway.py index 31eae25..2d0d337 100644 --- a/meraki/api/campusGateway.py +++ b/meraki/api/campusGateway.py @@ -576,7 +576,7 @@ def provisionOrganizationCampusGatewayClusters( **kwargs, ): """ - **Provisions a cluster,adds campus gateways to it and associate/dissociate failover targets.** + **Provision a campus gateway cluster, add campus gateways, configure AP-assignment load balancing, and associate or dissociate failover targets** https://developer.cisco.com/meraki/api-v1/#!provision-organization-campus-gateway-clusters - organizationId (string): Organization ID diff --git a/meraki/api/devices.py b/meraki/api/devices.py index 00e8855..6b3baaf 100644 --- a/meraki/api/devices.py +++ b/meraki/api/devices.py @@ -538,6 +538,68 @@ def getDeviceLiveToolsDhcpLease(self, serial: str, dhcpLeasesId: str): return self._session.get(metadata, resource) + def createDeviceLiveToolsDnsLookup(self, serial: str, hostname: str, dnsServer: str, queryType: str, **kwargs): + """ + **Enqueue a DNS lookup job from the device** + https://developer.cisco.com/meraki/api-v1/#!create-device-live-tools-dns-lookup + + - serial (string): Serial + - hostname (string): Hostname for the device to resolve. + - dnsServer (string): IPv4 or IPv6 DNS server address. + - queryType (string): DNS record type to request. + - callback (object): Details for the callback. Please include either an httpServerId OR url and sharedSecret + """ + + kwargs.update(locals()) + + if "queryType" in kwargs: + options = ["A", "AAAA"] + assert kwargs["queryType"] in options, ( + f'''"queryType" cannot be "{kwargs["queryType"]}", & must be set to one of: {options}''' + ) + + metadata = { + "tags": ["devices", "liveTools", "dnsLookup"], + "operation": "createDeviceLiveToolsDnsLookup", + } + serial = urllib.parse.quote(str(serial), safe="") + resource = f"/devices/{serial}/liveTools/dnsLookup" + + body_params = [ + "hostname", + "dnsServer", + "queryType", + "callback", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning(f"createDeviceLiveToolsDnsLookup: ignoring unrecognized kwargs: {invalid}") + + return self._session.post(metadata, resource, payload) + + def getDeviceLiveToolsDnsLookup(self, serial: str, id: str): + """ + **Return a DNS lookup job.** + https://developer.cisco.com/meraki/api-v1/#!get-device-live-tools-dns-lookup + + - serial (string): Serial + - id (string): ID + """ + + metadata = { + "tags": ["devices", "liveTools", "dnsLookup"], + "operation": "getDeviceLiveToolsDnsLookup", + } + serial = urllib.parse.quote(str(serial), safe="") + id = urllib.parse.quote(str(id), safe="") + resource = f"/devices/{serial}/liveTools/dnsLookup/{id}" + + return self._session.get(metadata, resource) + def createDeviceLiveToolsLedsBlink(self, serial: str, duration: int, **kwargs): """ **Enqueue a job to blink LEDs on a device** diff --git a/meraki/api/networks.py b/meraki/api/networks.py index 1e82f9f..977e998 100644 --- a/meraki/api/networks.py +++ b/meraki/api/networks.py @@ -3268,6 +3268,73 @@ def getNetworkTrafficShapingDscpTaggingOptions(self, networkId: str): return self._session.get(metadata, resource) + def getNetworkUmbrellaAccount(self, networkId: str): + """ + **Show network-wide Umbrella account settings** + https://developer.cisco.com/meraki/api-v1/#!get-network-umbrella-account + + - networkId (string): Network ID + """ + + metadata = { + "tags": ["networks", "configure", "umbrella", "account"], + "operation": "getNetworkUmbrellaAccount", + } + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/umbrella/account" + + return self._session.get(metadata, resource) + + def updateNetworkUmbrellaAccount(self, networkId: str, key: str, secret: str, **kwargs): + """ + **Update network-wide Umbrella account settings** + https://developer.cisco.com/meraki/api-v1/#!update-network-umbrella-account + + - networkId (string): Network ID + - key (string): API key generated from Umbrella dashboard + - secret (string): API secret generated from Umbrella dashboard + """ + + kwargs = locals() + + metadata = { + "tags": ["networks", "configure", "umbrella", "account"], + "operation": "updateNetworkUmbrellaAccount", + } + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/umbrella/account" + + body_params = [ + "key", + "secret", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning(f"updateNetworkUmbrellaAccount: ignoring unrecognized kwargs: {invalid}") + + return self._session.put(metadata, resource, payload) + + def getNetworkUmbrellaPolicies(self, networkId: str): + """ + **Return a list of Umbrella protection policies available for applying on an SSID or Group Policy** + https://developer.cisco.com/meraki/api-v1/#!get-network-umbrella-policies + + - networkId (string): Network ID + """ + + metadata = { + "tags": ["networks", "configure", "umbrella", "policies"], + "operation": "getNetworkUmbrellaPolicies", + } + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/umbrella/policies" + + return self._session.get(metadata, resource) + def unbindNetwork(self, networkId: str, **kwargs): """ **Unbind a network from a template.** diff --git a/meraki/api/switch.py b/meraki/api/switch.py index b213c33..3eb0bd7 100644 --- a/meraki/api/switch.py +++ b/meraki/api/switch.py @@ -210,7 +210,6 @@ def updateDeviceSwitchPort(self, serial: str, portId: str, **kwargs): - vlan (integer): The VLAN of the switch port. For a trunk port, this is the native VLAN. A null value will clear the value set for trunk ports. - voiceVlan (integer): The voice VLAN of the switch port. Only applicable to access ports. - allowedVlans (string): The VLANs allowed on the switch port. Only applicable to trunk ports. - - activeVlans (string): The VLANs that are active on the switch port. Only applicable to trunk ports. - isolationEnabled (boolean): The isolation status of the switch port. - rstpEnabled (boolean): The rapid spanning tree protocol status. - stpGuard (string): The state of the STP guard ('disabled', 'root guard', 'bpdu guard' or 'loop guard'). @@ -273,7 +272,6 @@ def updateDeviceSwitchPort(self, serial: str, portId: str, **kwargs): "vlan", "voiceVlan", "allowedVlans", - "activeVlans", "isolationEnabled", "rstpEnabled", "stpGuard", @@ -3635,7 +3633,6 @@ def updateOrganizationConfigTemplateSwitchProfilePort( - vlan (integer): The VLAN of the switch template port. For a trunk port, this is the native VLAN. A null value will clear the value set for trunk ports. - voiceVlan (integer): The voice VLAN of the switch template port. Only applicable to access ports. - allowedVlans (string): The VLANs allowed on the switch template port. Only applicable to trunk ports. - - activeVlans (string): The VLANs that are active on the switch template port. Only applicable to trunk ports. - isolationEnabled (boolean): The isolation status of the switch template port. - rstpEnabled (boolean): The rapid spanning tree protocol status. - stpGuard (string): The state of the STP guard ('disabled', 'root guard', 'bpdu guard' or 'loop guard'). @@ -3700,7 +3697,6 @@ def updateOrganizationConfigTemplateSwitchProfilePort( "vlan", "voiceVlan", "allowedVlans", - "activeVlans", "isolationEnabled", "rstpEnabled", "stpGuard", diff --git a/meraki/api/wireless.py b/meraki/api/wireless.py index 7cfa7bd..9368d86 100644 --- a/meraki/api/wireless.py +++ b/meraki/api/wireless.py @@ -3156,6 +3156,43 @@ def updateNetworkWirelessSsid(self, networkId: str, number: str, **kwargs): return self._session.put(metadata, resource, payload) + def updateNetworkWirelessSsidAddressingGuards(self, networkId: str, number: str, **kwargs): + """ + **Update the DHCP Guard and Router Advertisement (RA) Guard settings for an SSID.** + https://developer.cisco.com/meraki/api-v1/#!update-network-wireless-ssid-addressing-guards + + - networkId (string): Network ID + - number (string): Number + - dhcp (object): DHCP Guard configuration for the SSID. + - ra (object): Router Advertisement (RA) Guard configuration for the SSID. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "addressing", "guards"], + "operation": "updateNetworkWirelessSsidAddressingGuards", + } + networkId = urllib.parse.quote(str(networkId), safe="") + number = urllib.parse.quote(str(number), safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/addressing/guards" + + body_params = [ + "dhcp", + "ra", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"updateNetworkWirelessSsidAddressingGuards: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.put(metadata, resource, payload) + def getNetworkWirelessSsidBonjourForwarding(self, networkId: str, number: str): """ **List the Bonjour forwarding setting and rules for the SSID** @@ -3519,6 +3556,43 @@ def updateNetworkWirelessSsidHotspot20(self, networkId: str, number: str, **kwar return self._session.put(metadata, resource, payload) + def updateNetworkWirelessSsidHttpProxies(self, number: int, networkId: str, **kwargs): + """ + **Update the HTTP force proxy settings for an SSID.** + https://developer.cisco.com/meraki/api-v1/#!update-network-wireless-ssid-http-proxies + + - number (integer): SSID number. Valid values are 0-14. + - networkId (string): Network ID + - enabled (boolean): Whether clients on the SSID are forced through the HTTP proxy. + - server (object): HTTP proxy server that intercepted traffic is forwarded to. + - exclusions (array): Destinations excluded from forced proxying. A supplied array replaces the list; an empty array clears it while the proxy is enabled. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "http", "proxies"], + "operation": "updateNetworkWirelessSsidHttpProxies", + } + number = urllib.parse.quote(str(number), safe="") + networkId = urllib.parse.quote(str(networkId), safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/http/proxies" + + body_params = [ + "enabled", + "server", + "exclusions", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning(f"updateNetworkWirelessSsidHttpProxies: ignoring unrecognized kwargs: {invalid}") + + return self._session.put(metadata, resource, payload) + def getNetworkWirelessSsidIdentityPsks(self, networkId: str, number: str): """ **List all Identity PSKs in a wireless network** @@ -4139,6 +4213,41 @@ def getNetworkWirelessSsidTrafficShapingRules(self, networkId: str, number: str) return self._session.get(metadata, resource) + def createNetworkWirelessSsidUmbrellaProtectionJob(self, networkId: str, number: str, request: dict, **kwargs): + """ + **Apply Umbrella protection on an SSID of an MR network** + https://developer.cisco.com/meraki/api-v1/#!create-network-wireless-ssid-umbrella-protection-job + + - networkId (string): Network ID + - number (string): Number + - request (object): Umbrella protection configuration to apply. + """ + + kwargs = locals() + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "jobs"], + "operation": "createNetworkWirelessSsidUmbrellaProtectionJob", + } + networkId = urllib.parse.quote(str(networkId), safe="") + number = urllib.parse.quote(str(number), safe="") + resource = f"/networks/{networkId}/wireless/ssids/{number}/umbrella/protection/jobs" + + body_params = [ + "request", + ] + payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params} + + if self._session._validate_kwargs: + all_params = [] + body_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"createNetworkWirelessSsidUmbrellaProtectionJob: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.post(metadata, resource, payload) + def getNetworkWirelessSsidVpn(self, networkId: str, number: str): """ **List the VPN settings for the SSID.** @@ -6583,7 +6692,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetwork( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6595,7 +6704,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetwork( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetwork", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6649,7 +6758,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByBand( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6661,7 +6770,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByBand( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byBand"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byBand"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByBand", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6715,7 +6824,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClient( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6727,7 +6836,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClient( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byClient"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byClient"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClient", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6781,7 +6890,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientOs( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6793,7 +6902,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientOs( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byClientOs"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byClientOs"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientOs", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6847,7 +6956,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientType - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6859,7 +6968,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientType kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byClientType"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byClientType"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByClientType", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -6913,7 +7022,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByDevice( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -6925,7 +7034,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByDevice( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byDevice"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byDevice"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByDevice", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -7047,7 +7156,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByServer( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -7059,7 +7168,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByServer( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "byServer"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "byServer"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkByServer", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -7113,7 +7222,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkBySsid( - networkIds (array): Filter results by network. - serials (array): Filter results by device serial. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - t0 (string): The beginning of the timespan for the data. The maximum lookback period is 14 days from today. - t1 (string): The end of the timespan for the data. t1 can be a maximum of 14 days after t0. - timespan (number): The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be greater than or equal to 15 minutes and be less than or equal to 14 days. The default is 2 hours. @@ -7125,7 +7234,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkBySsid( kwargs.update(locals()) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "byNetwork", "bySsid"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "byNetwork", "bySsid"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectByNetworkBySsid", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -7177,9 +7286,9 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectInsightsByNetwork( - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages - direction (string): direction to paginate, either "next" (default) or "prev" page - networkIds (array): Filter results by network. - - serials (array): Filter results by device serial. + - serials (array): Filter results by SSID number. Valid values are 0-14. - ssidNumbers (array): Filter results by SSID number. - - bands (array): Filter results by band. + - bands (array): Filter results by wireless band in GHz (2.4, 5, or 6). - insights (string): Source used to compute insights. Defaults to dashboard. - contributor (string): Contributor for which to retrieve insights. If not specified, returns overall insights. - subContributor (string): Sub-contributor for which to retrieve insights. If not specified, returns all sub contributor insights. @@ -7205,7 +7314,7 @@ def getOrganizationAssuranceWirelessExperienceTimeToConnectInsightsByNetwork( ) metadata = { - "tags": ["wireless", "configure", "experience", "timeToConnect", "insights", "byNetwork"], + "tags": ["wireless", "monitor", "experience", "timeToConnect", "insights", "byNetwork"], "operation": "getOrganizationAssuranceWirelessExperienceTimeToConnectInsightsByNetwork", } organizationId = urllib.parse.quote(str(organizationId), safe="") @@ -10825,6 +10934,121 @@ def byOrganizationWirelessOpportunisticPcapLicenseNetwork(self, organizationId: return self._session.get(metadata, resource, params) + def getOrganizationWirelessPolicyApplications(self, organizationId: str, total_pages=1, direction="next", **kwargs): + """ + **List wireless policy applications and their categories for eligible wireless sources (standalone networks and configuration templates) in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-policy-applications + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional inclusive-OR filter on standalone wireless network IDs. Mutually exclusive with configTemplateIds. Maximum 50 IDs. + - configTemplateIds (array): Optional inclusive-OR filter on wireless configuration-template IDs. Mutually exclusive with networkIds. Maximum 50 IDs. + - resourceIds (array): Optional inclusive-OR filter on returned applicationId values. Maximum 50 IDs. + - categoryIds (array): Optional inclusive-OR filter on category.id; returns only applications in the selected categories. Maximum 50 IDs. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 50. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "policy", "applications"], + "operation": "getOrganizationWirelessPolicyApplications", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/policy/applications" + + query_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + "categoryIds", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + "categoryIds", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessPolicyApplications: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + + def getOrganizationWirelessPolicyApplicationsCategories( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List wireless policy application categories for eligible wireless sources (standalone networks and configuration templates) in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-policy-applications-categories + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional inclusive-OR filter on standalone wireless network IDs. Mutually exclusive with configTemplateIds. Maximum 50 IDs. + - configTemplateIds (array): Optional inclusive-OR filter on wireless configuration-template IDs. Mutually exclusive with networkIds. Maximum 50 IDs. + - resourceIds (array): Optional inclusive-OR filter on returned categoryId values. Maximum 50 IDs. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 50. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "policy", "applications", "categories"], + "operation": "getOrganizationWirelessPolicyApplicationsCategories", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/policy/applications/categories" + + query_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "configTemplateIds", + "resourceIds", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessPolicyApplicationsCategories: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessRadioAfcPositionByDevice(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **List the AFC power limits of an organization by device** @@ -11389,50 +11613,6 @@ def getOrganizationWirelessRadioRrmByNetwork(self, organizationId: str, total_pa return self._session.get_pages(metadata, resource, params, total_pages, direction) - def getOrganizationWirelessRadioStatusByNetwork(self, organizationId: str, **kwargs): - """ - **Show the status of this organization's radios, categorized by network and device** - https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-radio-status-by-network - - - organizationId (string): Organization ID - - networkIds (array): Networks for which radio status should be returned. - - serials (array): Serials for which radio status should be returned. - """ - - kwargs.update(locals()) - - metadata = { - "tags": ["wireless", "configure", "radio", "status", "byNetwork"], - "operation": "getOrganizationWirelessRadioStatusByNetwork", - } - organizationId = urllib.parse.quote(str(organizationId), safe="") - resource = f"/organizations/{organizationId}/wireless/radio/status/byNetwork" - - query_params = [ - "networkIds", - "serials", - ] - params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} - - array_params = [ - "networkIds", - "serials", - ] - for k, v in kwargs.items(): - if k.strip() in array_params: - params[f"{k.strip()}[]"] = kwargs[f"{k}"] - params.pop(k.strip()) - - if self._session._validate_kwargs: - all_params = query_params + array_params - invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] - if invalid and self._session._logger: - self._session._logger.warning( - f"getOrganizationWirelessRadioStatusByNetwork: ignoring unrecognized kwargs: {invalid}" - ) - - return self._session.get(metadata, resource, params) - def getOrganizationWirelessRadioStatusesByDevice(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **List a paginated snapshot of current radio status for wireless devices in an organization** @@ -11605,6 +11785,58 @@ def getOrganizationWirelessRoamingByNetworkByInterval(self, organizationId: str, return self._session.get(metadata, resource, params) + def getOrganizationWirelessSsidsAddressingGuards(self, organizationId: str, total_pages=1, direction="next", **kwargs): + """ + **List the DHCP Guard and Router Advertisement (RA) Guard settings for SSIDs in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-addressing-guards + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional parameter to filter results by network IDs. Maximum 100 network IDs. + - ssidNumbers (array): Optional parameter to filter results by SSID numbers. Valid values are 0-14. Maximum 15 SSID numbers. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 1000. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "addressing", "guards"], + "operation": "getOrganizationWirelessSsidsAddressingGuards", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/addressing/guards" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsAddressingGuards: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessSsidsFirewallIsolationAllowlistEntries( self, organizationId: str, total_pages=1, direction="next", **kwargs ): @@ -11756,6 +11988,58 @@ def updateOrganizationWirelessSsidsFirewallIsolationAllowlistEntry(self, organiz return self._session.put(metadata, resource, payload) + def getOrganizationWirelessSsidsHttpProxies(self, organizationId: str, total_pages=1, direction="next", **kwargs): + """ + **List the HTTP force proxy settings for SSIDs in an organization** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-http-proxies + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional parameter to filter results by network IDs. Maximum 100 network IDs. + - ssidNumbers (array): Optional parameter to filter results by SSID numbers. Valid values are 0-14. Maximum 15 SSID numbers. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 1000. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "http", "proxies"], + "operation": "getOrganizationWirelessSsidsHttpProxies", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/http/proxies" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsHttpProxies: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessSsidsOpenRoamingByNetwork(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **Returns an array of objects, each containing SSID OpenRoaming configs for the corresponding network** @@ -12448,6 +12732,171 @@ def getOrganizationWirelessSsidsStatusesByDevice(self, organizationId: str, tota return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessSsidsUmbrellaProtectionBySsid( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List Umbrella protection settings and lifecycle availability for SSIDs in an organization.** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-umbrella-protection-by-ssid + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional filter by network IDs. Maximum 100 IDs. + - ssidNumbers (array): Optional filter by SSID numbers. Valid values are 0-14. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "bySsid"], + "operation": "getOrganizationWirelessSsidsUmbrellaProtectionBySsid", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/umbrella/protection/bySsid" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsUmbrellaProtectionBySsid: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + + def getOrganizationWirelessSsidsUmbrellaProtectionJobs( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List Umbrella protection jobs for SSIDs in an organization.** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-umbrella-protection-jobs + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional filter by network IDs. Maximum 100 IDs. + - ssidNumbers (array): Optional filter by SSID numbers. Valid values are 0-14. + - jobIds (array): Optional filter by Umbrella protection job IDs. Maximum 100 IDs. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 100. Default is 100. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "jobs"], + "operation": "getOrganizationWirelessSsidsUmbrellaProtectionJobs", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/umbrella/protection/jobs" + + query_params = [ + "networkIds", + "ssidNumbers", + "jobIds", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + "jobIds", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsUmbrellaProtectionJobs: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + + def getOrganizationWirelessSsidsUmbrellaProtectionPoliciesBySsid( + self, organizationId: str, total_pages=1, direction="next", **kwargs + ): + """ + **List Umbrella policies applied to SSIDs in an organization.** + https://developer.cisco.com/meraki/api-v1/#!get-organization-wireless-ssids-umbrella-protection-policies-by-ssid + + - organizationId (string): Organization ID + - total_pages (integer or string): use with perPage to get total results up to total_pages*perPage; -1 or "all" for all pages + - direction (string): direction to paginate, either "next" (default) or "prev" page + - networkIds (array): Optional filter by network IDs. Maximum 100 IDs. + - ssidNumbers (array): Optional filter by SSID numbers. Valid values are 0-14. + - perPage (integer): The number of entries per page returned. Acceptable range is 3 - 20. Default is 10. + - startingAfter (string): A token used by the server to indicate the start of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + - endingBefore (string): A token used by the server to indicate the end of the page. Often this is a timestamp or an ID but it is not limited to those. This parameter should not be defined by client applications. The link for the first, last, prev, or next page in the HTTP Link header should define it. + """ + + kwargs.update(locals()) + + metadata = { + "tags": ["wireless", "configure", "ssids", "umbrella", "protection", "policies", "bySsid"], + "operation": "getOrganizationWirelessSsidsUmbrellaProtectionPoliciesBySsid", + } + organizationId = urllib.parse.quote(str(organizationId), safe="") + resource = f"/organizations/{organizationId}/wireless/ssids/umbrella/protection/policies/bySsid" + + query_params = [ + "networkIds", + "ssidNumbers", + "perPage", + "startingAfter", + "endingBefore", + ] + params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params} + + array_params = [ + "networkIds", + "ssidNumbers", + ] + for k, v in kwargs.items(): + if k.strip() in array_params: + params[f"{k.strip()}[]"] = kwargs[f"{k}"] + params.pop(k.strip()) + + if self._session._validate_kwargs: + all_params = query_params + array_params + invalid = [k for k in kwargs if k.strip() not in all_params and k != "self"] + if invalid and self._session._logger: + self._session._logger.warning( + f"getOrganizationWirelessSsidsUmbrellaProtectionPoliciesBySsid: ignoring unrecognized kwargs: {invalid}" + ) + + return self._session.get_pages(metadata, resource, params, total_pages, direction) + def getOrganizationWirelessZigbeeByNetwork(self, organizationId: str, total_pages=1, direction="next", **kwargs): """ **Return list of Zigbee configs** diff --git a/pyproject.toml b/pyproject.toml index c8d738a..0c78ea4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "meraki" -version = "4.7.0b1" +version = "4.7.0b2" description = "Cisco Meraki Dashboard API library" authors = [ {name = "Cisco Meraki", email = "api-feedback@meraki.net"} diff --git a/uv.lock b/uv.lock index d38731c..288d2db 100644 --- a/uv.lock +++ b/uv.lock @@ -591,7 +591,7 @@ wheels = [ [[package]] name = "meraki" -version = "4.7.0b1" +version = "4.7.0b2" source = { editable = "." } dependencies = [ { name = "aiohttp" },