09-29-2020 04:36 AM
Hi Folks,
I want to save and export new named configuration snapshot through API call.
I found the API but don't know whether it export the latest details or old one, In UI we have option to save and export the saved configuration but unable to find with API.
Can anyone help me if you already find out the way to export?
Also want to export Device group name but when i go to the API , it fetch all information including device name, it is really tough to fetch on Devicegroup.
Thanks in advance
10-09-2020 03:48 AM
10-27-2020 02:51 AM
Hi @SutareMayur
I believe the below api will only export the configuration, Does it export latest configuration?
like we mostly manually save the named configuration then export it
07-04-2022 02:45 AM
There are a lot differences I can see when I download named configuration with API.
Is there any way to grab the exact named configuration same as we download from portal.
Appreciate your help.
09-13-2022 08:41 AM
There are a few options for getting the running/live config via API, and it depends exactly what you want, there is nuance between the options, and based on this thread so far I'm not sure which is most appropriate, so I will share them all and let you decide which one meets your requirements:
https://{{host}}/api/?key={{key}}&type=config&action=show
https://{{host}}/api/?key={{key}}&type=op&cmd=<show><config><running></running></config></show>&target={{managed-device-serial}}
https://{{host}}/api/?key={{key}}&type=export&category=configuration
Saving the running config as a named "snapshot" can be done with:
https://{{host}}/api/?key={{key}}&type=op&cmd=<save><config><to>{{config-snapshot-name}}</to></config></save>
Hope that helps!
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!