Cisco Nexus 5000 Series Reference Manual - Page 4

Browse online or download pdf Reference Manual for Network Router Cisco Nexus 5000 Series. Cisco Nexus 5000 Series 12 pages. Configuring ip source guard
Also for Cisco Nexus 5000 Series: Release Note (26 pages), Quick Reference Manual (14 pages), Release Note (26 pages), Troubleshooting Manual (8 pages), Manual (11 pages), Manual (6 pages), Manual (7 pages), Operation Manual (45 pages), Configuration Manual (6 pages)

Cisco Nexus 5000 Series Reference Manual
</outputs>
</ins_api>
The following example shows a request and its response in JSON format:
Request:
{
"ins_api": {
"version": "0.1",
"type": "cli_show",
"chunk": "0",
"sid": "session1",
"input": "show switchname",
"output_format": "json"
}
}
Response:
{
"ins_api": {
"type": "cli_show",
"version": "0.1",
"sid": "eoc",
"outputs": {
"output": {
"body": {
"hostname": "switch"
},
"input": "show switchname",
"msg": "Success",
"code": "200"
}
}
}
}
Sample NX-API Scripts
The sample scripts demonstrate how a script is used with NX-API. The scripts are available at
https://github.com/datacenter/nxos/tree/master/nxapi/samples.
• Cable Checker (check_cable.py)
• Cable Checker Blueprint (connectivity.json)
NX-API Sandbox
The NX-API Sandbox is the web-based user interface that you use to enter the commands, command type, and output type for the
Cisco Nexus 5000 and 6000 Series device using HTTP/HTTPS. After posting the request, the output response is displayed.
By default, NX-API is disabled. Begin enabling NX-API with the feature manager CLI command on the switch. Then enable NX-API
with the nxapi sandbox command.
Use a browser to access the NX-API Sandbox.
Note
When using the NX-API Sandbox, Cisco recommends that you use the Firefox browser, release 24.0 or
later.
The following example shows how to configure and launch the NX-API Sandbox:
4