Skip to content

Commit

Permalink
Automatically regenerated library to version 1.52.0. (#271)
Browse files Browse the repository at this point in the history
Co-authored-by: GitHub Action <[email protected]>
  • Loading branch information
TKIPisalegacycipher and GitHub Action authored Nov 8, 2024
1 parent 96eec2c commit 41b3cbc
Show file tree
Hide file tree
Showing 14 changed files with 852 additions and 6 deletions.
2 changes: 1 addition & 1 deletion meraki/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
)
from meraki.rest_session import *

__version__ = '1.51.0'
__version__ = '1.52.0'


class DashboardAPI(object):
Expand Down
47 changes: 47 additions & 0 deletions meraki/aio/api/devices.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,53 @@ def getDeviceLiveToolsCableTest(self, serial: str, id: str):



def createDeviceLiveToolsLedsBlink(self, serial: str, duration: int, **kwargs):
"""
**Enqueue a job to blink LEDs on a device**
https://developer.cisco.com/meraki/api-v1/#!create-device-live-tools-leds-blink
- serial (string): Serial
- duration (integer): The duration in seconds to blink LEDs.
- callback (object): Details for the callback. Please include either an httpServerId OR url and sharedSecret
"""

kwargs.update(locals())

metadata = {
'tags': ['devices', 'liveTools', 'leds', 'blink'],
'operation': 'createDeviceLiveToolsLedsBlink'
}
serial = urllib.parse.quote(str(serial), safe='')
resource = f'/devices/{serial}/liveTools/leds/blink'

body_params = ['duration', 'callback', ]
payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params}

return self._session.post(metadata, resource, payload)



def getDeviceLiveToolsLedsBlink(self, serial: str, ledsBlinkId: str):
"""
**Return a blink LEDs job**
https://developer.cisco.com/meraki/api-v1/#!get-device-live-tools-leds-blink
- serial (string): Serial
- ledsBlinkId (string): Leds blink ID
"""

metadata = {
'tags': ['devices', 'liveTools', 'leds', 'blink'],
'operation': 'getDeviceLiveToolsLedsBlink'
}
serial = urllib.parse.quote(str(serial), safe='')
ledsBlinkId = urllib.parse.quote(str(ledsBlinkId), safe='')
resource = f'/devices/{serial}/liveTools/leds/blink/{ledsBlinkId}'

return self._session.get(metadata, resource)



def createDeviceLiveToolsPing(self, serial: str, target: str, **kwargs):
"""
**Enqueue a job to ping a target host from the device**
Expand Down
125 changes: 125 additions & 0 deletions meraki/aio/api/networks.py
Original file line number Diff line number Diff line change
Expand Up @@ -1201,6 +1201,131 @@ def createNetworkFloorPlan(self, networkId: str, name: str, imageContents: str,



def batchNetworkFloorPlansAutoLocateJobs(self, networkId: str, jobs: list):
"""
**Schedule auto locate jobs for one or more floor plans in a network**
https://developer.cisco.com/meraki/api-v1/#!batch-network-floor-plans-auto-locate-jobs
- networkId (string): Network ID
- jobs (array): The list of auto locate jobs to be scheduled. Up to 100 jobs can be provided in a request.
"""

kwargs = locals()

metadata = {
'tags': ['networks', 'configure', 'floorPlans', 'autoLocate', 'jobs'],
'operation': 'batchNetworkFloorPlansAutoLocateJobs'
}
networkId = urllib.parse.quote(str(networkId), safe='')
resource = f'/networks/{networkId}/floorPlans/autoLocate/jobs/batch'

body_params = ['jobs', ]
payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params}

return self._session.post(metadata, resource, payload)



def cancelNetworkFloorPlansAutoLocateJob(self, networkId: str, jobId: str):
"""
**Cancel a scheduled or running auto locate job**
https://developer.cisco.com/meraki/api-v1/#!cancel-network-floor-plans-auto-locate-job
- networkId (string): Network ID
- jobId (string): Job ID
"""

metadata = {
'tags': ['networks', 'configure', 'floorPlans', 'autoLocate', 'jobs'],
'operation': 'cancelNetworkFloorPlansAutoLocateJob'
}
networkId = urllib.parse.quote(str(networkId), safe='')
jobId = urllib.parse.quote(str(jobId), safe='')
resource = f'/networks/{networkId}/floorPlans/autoLocate/jobs/{jobId}/cancel'

return self._session.post(metadata, resource)



def publishNetworkFloorPlansAutoLocateJob(self, networkId: str, jobId: str, **kwargs):
"""
**Update the status of a finished auto locate job to be published, and update device locations**
https://developer.cisco.com/meraki/api-v1/#!publish-network-floor-plans-auto-locate-job
- networkId (string): Network ID
- jobId (string): Job ID
- devices (array): The list of devices to publish positions for
"""

kwargs.update(locals())

metadata = {
'tags': ['networks', 'configure', 'floorPlans', 'autoLocate', 'jobs'],
'operation': 'publishNetworkFloorPlansAutoLocateJob'
}
networkId = urllib.parse.quote(str(networkId), safe='')
jobId = urllib.parse.quote(str(jobId), safe='')
resource = f'/networks/{networkId}/floorPlans/autoLocate/jobs/{jobId}/publish'

body_params = ['devices', ]
payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params}

return self._session.post(metadata, resource, payload)



def recalculateNetworkFloorPlansAutoLocateJob(self, networkId: str, jobId: str, **kwargs):
"""
**Trigger auto locate recalculation for a job, and optionally set anchors**
https://developer.cisco.com/meraki/api-v1/#!recalculate-network-floor-plans-auto-locate-job
- networkId (string): Network ID
- jobId (string): Job ID
- devices (array): The list of devices to update anchor positions for
"""

kwargs.update(locals())

metadata = {
'tags': ['networks', 'configure', 'floorPlans', 'autoLocate', 'jobs'],
'operation': 'recalculateNetworkFloorPlansAutoLocateJob'
}
networkId = urllib.parse.quote(str(networkId), safe='')
jobId = urllib.parse.quote(str(jobId), safe='')
resource = f'/networks/{networkId}/floorPlans/autoLocate/jobs/{jobId}/recalculate'

body_params = ['devices', ]
payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params}

return self._session.post(metadata, resource, payload)



def batchNetworkFloorPlansDevicesUpdate(self, networkId: str, assignments: list):
"""
**Update floorplan assignments for a batch of devices**
https://developer.cisco.com/meraki/api-v1/#!batch-network-floor-plans-devices-update
- networkId (string): Network ID
- assignments (array): List of floorplan assignments to update. Up to 100 floor plan assignments can be provided in a request.
"""

kwargs = locals()

metadata = {
'tags': ['networks', 'configure', 'floorPlans', 'devices'],
'operation': 'batchNetworkFloorPlansDevicesUpdate'
}
networkId = urllib.parse.quote(str(networkId), safe='')
resource = f'/networks/{networkId}/floorPlans/devices/batchUpdate'

body_params = ['assignments', ]
payload = {k.strip(): v for k, v in kwargs.items() if k.strip() in body_params}

return self._session.post(metadata, resource, payload)



def getNetworkFloorPlan(self, networkId: str, floorPlanId: str):
"""
**Find a floor plan by ID**
Expand Down
76 changes: 75 additions & 1 deletion meraki/aio/api/organizations.py
Original file line number Diff line number Diff line change
Expand Up @@ -1908,7 +1908,7 @@ def getOrganizationDevicesAvailabilities(self, organizationId: str, total_pages=
- 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.
- networkIds (array): Optional parameter to filter device availabilities by network ID. This filter uses multiple exact matches.
- productTypes (array): Optional parameter to filter device availabilities by device product types. This filter uses multiple exact matches. Valid types are wireless, appliance, switch, camera, cellularGateway, sensor, and wirelessController
- productTypes (array): Optional parameter to filter device availabilities by device product types. This filter uses multiple exact matches. Valid types are wireless, appliance, switch, camera, cellularGateway, sensor, wirelessController, and campusGateway
- serials (array): Optional parameter to filter device availabilities by device serial numbers. This filter uses multiple exact matches.
- tags (array): An optional parameter to filter devices by tags. The filtering is case-sensitive. If tags are included, 'tagsFilterType' should also be included (see below). This filter uses multiple exact matches.
- tagsFilterType (string): An optional parameter of value 'withAnyTags' or 'withAllTags' to indicate whether to return devices which contain ANY or ALL of the included tags. If no type is included, 'withAnyTags' will be selected.
Expand Down Expand Up @@ -2500,6 +2500,80 @@ def getOrganizationFirmwareUpgradesByDevice(self, organizationId: str, total_pag



def getOrganizationFloorPlansAutoLocateDevices(self, organizationId: str, total_pages=1, direction='next', **kwargs):
"""
**List auto locate details for each device in your organization**
https://developer.cisco.com/meraki/api-v1/#!get-organization-floor-plans-auto-locate-devices
- 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
- perPage (integer): The number of entries per page returned. Acceptable range is 3 - 10000. Default is 1000.
- 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.
- networkIds (array): Optional parameter to filter devices by one or more network IDs
- floorPlanIds (array): Optional parameter to filter devices by one or more floorplan IDs
"""

kwargs.update(locals())

metadata = {
'tags': ['organizations', 'configure', 'floorPlans', 'autoLocate', 'devices'],
'operation': 'getOrganizationFloorPlansAutoLocateDevices'
}
organizationId = urllib.parse.quote(str(organizationId), safe='')
resource = f'/organizations/{organizationId}/floorPlans/autoLocate/devices'

query_params = ['perPage', 'startingAfter', 'endingBefore', 'networkIds', 'floorPlanIds', ]
params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params}

array_params = ['networkIds', 'floorPlanIds', ]
for k, v in kwargs.items():
if k.strip() in array_params:
params[f'{k.strip()}[]'] = kwargs[f'{k}']
params.pop(k.strip())

return self._session.get_pages(metadata, resource, params, total_pages, direction)



def getOrganizationFloorPlansAutoLocateStatuses(self, organizationId: str, total_pages=1, direction='next', **kwargs):
"""
**List the status of auto locate for each floorplan in your organization**
https://developer.cisco.com/meraki/api-v1/#!get-organization-floor-plans-auto-locate-statuses
- 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
- perPage (integer): The number of entries per page returned. Acceptable range is 3 - 10000. Default is 1000.
- 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.
- networkIds (array): Optional parameter to filter floorplans by one or more network IDs
- floorPlanIds (array): Optional parameter to filter floorplans by one or more floorplan IDs
"""

kwargs.update(locals())

metadata = {
'tags': ['organizations', 'configure', 'floorPlans', 'autoLocate', 'statuses'],
'operation': 'getOrganizationFloorPlansAutoLocateStatuses'
}
organizationId = urllib.parse.quote(str(organizationId), safe='')
resource = f'/organizations/{organizationId}/floorPlans/autoLocate/statuses'

query_params = ['perPage', 'startingAfter', 'endingBefore', 'networkIds', 'floorPlanIds', ]
params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params}

array_params = ['networkIds', 'floorPlanIds', ]
for k, v in kwargs.items():
if k.strip() in array_params:
params[f'{k.strip()}[]'] = kwargs[f'{k}']
params.pop(k.strip())

return self._session.get_pages(metadata, resource, params, total_pages, direction)



def claimIntoOrganizationInventory(self, organizationId: str, **kwargs):
"""
**Claim a list of devices, licenses, and/or orders into an organization inventory**
Expand Down
43 changes: 43 additions & 0 deletions meraki/aio/api/switch.py
Original file line number Diff line number Diff line change
Expand Up @@ -2596,3 +2596,46 @@ def getOrganizationSwitchPortsOverview(self, organizationId: str, **kwargs):

return self._session.get(metadata, resource, params)



def getOrganizationSwitchPortsStatusesBySwitch(self, organizationId: str, total_pages=1, direction='next', **kwargs):
"""
**List the switchports in an organization**
https://developer.cisco.com/meraki/api-v1/#!get-organization-switch-ports-statuses-by-switch
- 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
- 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.
- configurationUpdatedAfter (string): Optional parameter to filter items to switches where the configuration has been updated after the given timestamp.
- mac (string): Optional parameter to filter items to switches with MAC addresses that contain the search term or are an exact match.
- macs (array): Optional parameter to filter items to switches that have one of the provided MAC addresses.
- name (string): Optional parameter to filter items to switches with names that contain the search term or are an exact match.
- networkIds (array): Optional parameter to filter items to switches in one of the provided networks.
- portProfileIds (array): Optional parameter to filter items to switches that contain switchports belonging to one of the specified port profiles.
- serial (string): Optional parameter to filter items to switches with serial number that contains the search term or are an exact match.
- serials (array): Optional parameter to filter items to switches that have one of the provided serials.
"""

kwargs.update(locals())

metadata = {
'tags': ['switch', 'monitor', 'ports', 'statuses', 'bySwitch'],
'operation': 'getOrganizationSwitchPortsStatusesBySwitch'
}
organizationId = urllib.parse.quote(str(organizationId), safe='')
resource = f'/organizations/{organizationId}/switch/ports/statuses/bySwitch'

query_params = ['perPage', 'startingAfter', 'endingBefore', 'configurationUpdatedAfter', 'mac', 'macs', 'name', 'networkIds', 'portProfileIds', 'serial', 'serials', ]
params = {k.strip(): v for k, v in kwargs.items() if k.strip() in query_params}

array_params = ['macs', 'networkIds', 'portProfileIds', 'serials', ]
for k, v in kwargs.items():
if k.strip() in array_params:
params[f'{k.strip()}[]'] = kwargs[f'{k}']
params.pop(k.strip())

return self._session.get_pages(metadata, resource, params, total_pages, direction)

Loading

0 comments on commit 41b3cbc

Please sign in to comment.