Comments (5)
As documented by the original creator of that script, "report_statuses.py" should be used instead, as "uplink.py" is deprecated. Added command line option "-o /all" to "report_statuses.py" that iterates through all organizations accessible by the given API key.
Please test and let me know if this achieves what you are looking for.
from automation-scripts.
Thanks mpapazog. That script is bugged for me with the following:
'base_url': 'https://api.meraki.com/api/v1', 'single_request_timeout': 60, 'certificate_path': '', 'requests_proxy': '', 'wait_on_rate_limit': True, 'nginx_429_retry_wait_time': 60, 'action_batch_retry_wait_time': 60, 'retry_4xx_error': False, 'retry_4xx_error_wait_time': 60, 'maximum_retries': 2, 'simulate': False, 'be_geo_id': None, 'caller': None}
2020-12-11 10:27:11 meraki: INFO > GET https://api.meraki.com/api/v1/organizations//all/appliance/uplink/statuses
2020-12-11 10:27:12 meraki: ERROR > appliance, getOrganizationApplianceUplinkStatuses - 404 Not Found, b' '
Traceback (most recent call last):
File "report_statuses.py", line 121, in
main()
File "report_statuses.py", line 40, in main
appliance_statuses = dashboard.appliance.getOrganizationApplianceUplinkStatuses(org_id, total_pages='all')
File "C:\Python38\lib\site-packages\meraki\api\appliance.py", line 1522, in getOrganizationApplianceUplinkStatuses
return self._session.get_pages(metadata, resource, params, total_pages, direction)
File "C:\Python38\lib\site-packages\meraki\rest_session.py", line 283, in get_pages
response = self.request(metadata, 'GET', url, params=params)
File "C:\Python38\lib\site-packages\meraki\rest_session.py", line 262, in request
raise APIError(metadata, response)
meraki.exceptions.APIError: appliance, getOrganizationApplianceUplinkStatuses - 404 Not Found, please wait a minute if the key or org was just newly created.
I believe it has to do with the -o /all
Look here:
GET https://api.meraki.com/api/v1/organizations//all/appliance/uplink/statuses
Which would explain the 404 error, because the page doesn't exist. I also looked at the code and don't see a note about the -o /all
My command looked like this:
python report_statuses.py -k 1234 -o /all
Is there another switch for the all portion I should be using? Thanks for your help. I really appreciate your patience.
from automation-scripts.
Sounds like an older version of the script. Could you please make sure you are using the latest one: https://raw.githubusercontent.com/meraki/automation-scripts/master/report_statuses.py
from automation-scripts.
mpapazog, sorry for the delay. The newer version worked. It's weird because I don't loaded the script back about a week back and I assumed everything in there was up to date. Sorry about that, and it is greatly appreciated that you pointed me in the right direction. This issue is closed.
from automation-scripts.
The feature was added just for you, following your support request. ;)
from automation-scripts.
Related Issues (20)
- Migrate code to new API HOT 4
- Merakilicensealert.py keeps returning TypeError: list indices must be integers or slices, not str HOT 5
- "@ ERROR 09: Unable to contact Meraki cloud" for deviceupdownstatus.py HOT 2
- "mxfirewallcontrol.py" does not like "tag" filter HOT 4
- manageadmins.py not adding adminstrators HOT 6
- Rerwite of mxfirewallcontrol.py for Dashboard API v1 HOT 1
- <Tag> all ports with <type> HOT 10
- Rewrite scripts to use API key saved as environment variable HOT 8
- Terraform provider HOT 1
- Two seperate issues for mxfirewallcontrol.py HOT 7
- mxfirewallcontrol.py specify cellularFirewallRules HOT 1
- Single LAN is not available for networks in passthrough mode HOT 5
- Issue with csv writing HOT 4
- backup_configs - Operations CSV Files HOT 1
- migrate_cat3k.py question HOT 7
- AttributeError: 'DashboardAPI' object has no attribute 'mx_l3_firewall' HOT 3
- manageadmins.py stopped working HOT 2
- mx_firewall_control - Unable to update ruleset from input-file or directly HOT 1
- Issue with manage_devices.py and manage_network.py
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from automation-scripts.