Python or WAPI script to disable a Network

[ Edited ]
Posts: 4
1539     0

I'm looking for a automated way to disable a large number of networks that will eventually be permanently retired and ensure DHCP is no longer in use prior to deletion.


I have the curl commands to accomplish this, but I'm new to Python or the REST API in general and am trying to determine a script to automate this process for a given network address and mask (CIDR notation).


curl -k -u user:pass -X GET https://gm_ip/wapi/v1.2/record:network?network=
curl -k -u user:pass -X PUT https://gm_ip/wapi/v1.0/network/_ref: -d disable='TRUE'



Re: Python or WAPI script to disable a Network

TTiscareno Community Manager
Community Manager
Posts: 340
1540     0

You can find sample scripts at You may be able to take the examples provided there to accomplish what you are looking for here.




Showing results for 
Search instead for 
Do you mean 

Recommended for You

Businesses are investing heavily into securing company resources from cyber-attacks form cybercrimin