-
- Introduction to Cisco Enterprise NFVIS REST APIs
- System and IP Configuration APIs
- PnP APIs
- Resource APIs
- Networks and Bridges APIs
- VM Lifecycle Management APIs
- System Monitoring APIs
- System Operations APIs
- SPAN Session and Packet Capture APIs
- Upgrade Package APIs
- Factory Default Reset APIs
- Syslog Support APIs
- SNMP Support APIs
- TACACS and RADIUS Support APIs
- Port and Port Channel APIs
- Port Security APIs
- Secure Overlay APIs
- BGP Support APIs
Port Security APIs
Example: Max Number of MAC Addresses
https://209.165.201.1/api/running/switch/interface/gigabitEthernet
Payload:
<gigabitEthernet>
<name>1/0</name>
<port-security>
<max>2</max>
</port-security>
</gigabitEthernet>
Example: Violation Discard
https://209.165.201.1/api/running/switch/interface/gigabitEthernet
Payload:
<gigabitEthernet>
<name>1/0</name>
<port-security>
<violation>discard</violation>
</port-security>
</gigabitEthernet>
Example: Enable Port Security
https://209.165.201.1/api/running/switch/interface/gigabitEthernet
Payload:
<gigabitEthernet>
<name>1/0</name>
<port-security>
<enable/>
</port-security>
</gigabitEthernet>
Example: Secure Static MAC
https://209.165.201.1/api/running/switch/mac
Payload:
<mac>
<address-table>
<static>
<mac-entries>
<mac-addr>18:65:90:cb:e6:10</mac-addr>
<vlan>1</vlan>
<interface>
<gigabitEthernet>1/0</gigabitEthernet>
</interface>
<type>secure</type>
</mac-entries>
</static>
</address-table>
</mac>
Example: show switch interface port-security
GET https://209.165.201.1/api/operational/switch/interface/port-security?deep
Example: no port security enable
DELETE https://209.165.201.1/api/running/switch/interface/gigabitEthernet/"1/0"/port-security/enable
Example: no mac address-table static
DELETE https://209.165.201.1/api/running/switch/mac/address-table/static/mac-entries