Configuring NX-API Management

Configuring an HTTPS Key File

Configuring an HTTPS Key File
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "certFile": "bootflash:/ssl.crt"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <certFile>bootflash:/ssl.crt</certFile>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi certificate httpscrt certfile ssl.crt

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
certFileos:OsString
(naming:Name)
Certificate file for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Enabling an NX-API Certificate

Enabling an NX-API Certificate
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "certEnable": "yes"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <certEnable>true</certEnable>
  </nxapi-items>
</System>

Note: You cannot enable a certificate in the same request used to configure a key and/or certificate file; the request to enable the certificate must be sent separately.


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi certificate enable

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
certEnablescalar:Bool
Certificate status of NX-APISELECTION: true or false


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Setting SSL Protocols

Setting SSL Protocols
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "sslProtocols": "TLSv1 TLSv1.1 TLSv1.2"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <sslProtocols>TLSv1 TLSv1.1 TLSv1.2</sslProtocols>
  </nxapi-items>
</System>

The nxapi ssl protocols TLSv1 TLSv1.1 TLSv1.2 command enables the TLS versions specified in the string. The no nxapi ssl protocols TLSv1 TLSv1.1 TLSv1.2 form of the command changes it to default (by default only TLS1.1 and TLS1.2 will be enabled).


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi ssl protocols TLSv1 TLSv1.1 TLSv1.2

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
sslProtocolsnxapi:SslProtocols
(os:OsString)
String of space separated SSL protocols to be supported
RANGE: [0 , 256]
DEFAULT: TLSv1.2


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Unconfiguring the SSL Protocols

Unconfiguring the SSL Protocols
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "sslProtocols": "TLSv1.1 TLSv1.2"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <sslProtocols>TLSv1.1 TLSv1.2</sslProtocols>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

no nxapi ssl protocols TLSv1 TLSv1.1 TLSv1.2

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
sslProtocolsnxapi:SslProtocols
(os:OsString)
String of space separated SSL protocols to be supported
RANGE: [0 , 256]
DEFAULT: TLSv1.2


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Configuring an HTTPS Certificate File

Configuring an HTTPS Certificate File
POST http://<mgmt0_IP>/api/mo/sys.json
{
"topSystem": {
  "children": [
    {
        "nxapiInst": {
          "attributes": {
            "certFile": "volatile:/server.crt"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <certFile>volatile:/server.crt</certFile>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi certificate httpscrt certfile volatile:/server.crt

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
certFileos:OsString
(naming:Name)
Certificate file for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Configuring a VRF to be Used for NX-API Management

Configuring a VRF to be Used for NX-API Management
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "useVrf": "management"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <useVrf>management</useVrf>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi use-vrf management

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
useVrfos:OsString
(naming:Name)
Vrf for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Deleting a VRF to be Used for NX-API Management

Deleting a VRF to be Used for NX-API Management
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "useVrf": ""
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <useVrf></useVrf>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

no nxapi use-vrf management

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
useVrfos:OsString
(naming:Name)
Vrf for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Configuring a Default VRF

Configuring a Default VRF
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "useVrf": "default"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <useVrf>default</useVrf>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi use-vrf default

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
useVrfos:OsString
(naming:Name)
Vrf for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Deleting a Default VRF

Deleting a Default VRF
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "useVrf": ""
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <useVrf></useVrf>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

no nxapi use-vrf default

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
useVrfos:OsString
(naming:Name)
Vrf for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Configuring a VRF to be Used for NX-API Communication

Configuring a VRF to be Used for NX-API Communication
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "useVrf": "VRF_1"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <useVrf>VRF_1</useVrf>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi use-vrf VRF_1

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
useVrfos:OsString
(naming:Name)
Vrf for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Deleting a VRF to be Used for NX-API Communication

Deleting a VRF to be Used for NX-API Communication
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "useVrf": ""
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <useVrf></useVrf>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

no nxapi use-vrf VRF_1

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
useVrfos:OsString
(naming:Name)
Vrf for NX-API
RANGE: [0 , 256]


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Configuring a Port Number

Configuring a Port Number
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "httpPort": "123"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <httpPort>123</httpPort>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi http port 123

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
httpPortnxapi:HttpPort
(scalar:Sint32)
HTTP Port
RANGE: [-1 , 65535]
DEFAULT: -1


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Deleting a Port Number

Deleting a Port Number
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "httpPort": "-1"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <httpPort>-1</httpPort>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

no nxapi http port 123

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
httpPortnxapi:HttpPort
(scalar:Sint32)
HTTP Port
RANGE: [-1 , 65535]
DEFAULT: -1


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Configuring a Port Number (HTTPS Private Key)

Configuring a Port Number (HTTPS Private Key)
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "httpsPort": "123"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <httpsPort>123</httpsPort>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi https port 123

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
httpsPortnxapi:HttpsPort
(scalar:Sint32)
HTTPS Port
RANGE: [-1 , 65535]
DEFAULT: 443


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Deleting a Port Number (HTTPS Private Key)

Deleting a Port Number (HTTPS Private Key)
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "httpsPort": "443"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <httpsPort>443</httpsPort>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

no nxapi https port 123

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
httpsPortnxapi:HttpsPort
(scalar:Sint32)
HTTPS Port
RANGE: [-1 , 65535]
DEFAULT: 443


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Configuring to Allow Weak Ciphers

Configuring to Allow Weak Ciphers
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "sslCiphersWeak": "yes"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <sslCiphersWeak>true</sslCiphersWeak>
  </nxapi-items>
</System>

The nxapi ssl ciphers weak example enables the weak ciphers for NGINX. The no nxapi ssl ciphers weak example changes it to default (by default weak ciphers is disabled).


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

nxapi ssl ciphers weak

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
sslCiphersWeakscalar:Bool
Enable Weak Ciphers for SSLSELECTION: true or false
DEFAULT: 0


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Unconfiguring Weak Ciphers

Unconfiguring Weak Ciphers
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "nxapiInst": {
          "attributes": {
            "sslCiphersWeak": "no"
}}}]}}
{
    imdata:[]
}
POST:  http://<IP_Address>/restconf/data/Cisco-NX-OS-device:
<System xmlns="http://cisco.com/ns/yang/cisco-nx-os-device">
  <nxapi-items>
    <sslCiphersWeak>false</sslCiphersWeak>
  </nxapi-items>
</System>


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

no nxapi ssl ciphers weak

Note: The property information for this example was added in Release 9.3(3).


Verifying a DME Configuration
The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
nxapiInst sys/nxapi


nxapiInst Properties

The following table contains information about the nxapiInst properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
sslCiphersWeakscalar:Bool
Enable Weak Ciphers for SSLSELECTION: true or false
DEFAULT: 0


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html