Last active
June 21, 2023 18:36
Revisions
-
jaimegago renamed this gist
Mar 5, 2015 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
jaimegago created this gist
Mar 5, 2015 .There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,16 @@ #!/usr/bin/python -tt import requests user = 'nsroot' password = 'nsroot' netscaler = 'my_netscaler_fqdn_or_ip' url = 'http://%s/nitro/v1/config/' % netscaler response = requests.get(url, auth=(user, password)) data = response.json() for config_object in data['configobjects']: stat_url_test = 'http://%s/nitro/v1/stat/%s' % (netscaler, config_object) response = requests.get(stat_url_test, auth=(user, password)) if response.status_code == 200: print config_object