Cisco Cisco ASA for Nexus 1000V Series Switch

ページ / 29
 
About the ASA REST API v1.2.1 
Write memory API 
 
27 
Write memory API 
Changes to the ASA configuration made by REST API calls are not persisted to the startup configuration; that is, changes 
are assigned only to the running configuration. This 'Wirte Memory API' can be used to save the current running 
configuration to the startup configuration. 
POST URL: /api/commands/writemem 
Request payload is empty. 
REST-API Online Documentation  
The on-line documentation interface (Doc-UI) combines the functionality of a user interface with all the information 
contained in the embedded API documentation. The Doc-UI can be run in any of the following browsers: Chrome 
(current), Firefox (current), Internet Explorer 9+, Safari 5.1+, Opera (current). Older versions may work, but Internet 
Explorer 8 and below will not. 
The REST API Agent must be enabled to access the Doc UI; the Doc-UI is accessible from https://<asa management 
interface ip>/doc/ (note that the ending '/' is necessary for accessing the Doc-UI). 
Types of Scripts 
There are three types of scripts that can be generated by the Doc-UI that will allow you to perform REST API operations: 
Javascript, Python, and Perl. 
Prerequisites for Using Generated Scripts 
The Javascript scripts require the installation of node.js, which can be found at 
. Node.js allows you to 
use Javascript, typically written for a browser, like a command line script (such as Python or Perl). Simply follow the 
installation instructions, and run your script with: 
node script.js  
The Python scripts require you to install Python, found at 
. Once you have installed Python, you 
can run your script with: 
python script.py <username> <password>  
The Perl scripts require some additional set-up. You will need five components: Perl itself, and four Perl libraries: 
Perl, found at
Bundle::CPAN, found at
REST::Client, found at
MIME::Base64, found at