Forum Discussion
thuyngnhu
Altostratus
Feb 03, 2023BGP Neighbor API
Hi guys, Is there any way that I can retrieve output of this command "imish -e "show ip bgp neighbors" via API? Or if not, do you know how I can parse the output of this command from netmiko to some...
Nikoolayy1
MVP
Feb 06, 2023Here is a working example:
curl -sku admin:xxxx https://xxxx/mgmt/tm/util/bash -X POST -H "Content-Type: application/json" -d "{\"command\":\"run\", \"utilCmdArgs\":\"-c 'ls -alt /var/log'\"}"
but better trigger a bash script file
curl -sku admin:xxxx https://xxxx/mgmt/tm/util/bash -X POST -H "Content-Type: application/json" -d "{\"command\":\"run\", \"utilCmdArgs\":\"-c 'bash /shared/niki.sh'\"}"
Also as I mentioned Ansible can be added with its commands module :
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects