cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1094
Views
1
Helpful
2
Replies

ACI 6.0 port configuration using the REST API

afonsoferreira
Level 1
Level 1

Hi,

Is it possible to configure interfaces with the new 6.0 "per-port configuration" format, instead of profiles and selectors, via APIC REST API?

All documentation I've found online refers to the GUI configuration.

Cheers,

1 Accepted Solution

Accepted Solutions

Marcel Zehnder
Spotlight
Spotlight

Hi, yes the MO/class is infraPortConfig. For example to attach a vPC Interface Policy Group (VPC-SERVER) to ports eth1/32 of leafs 101 and 102:

 

# POST /api/mo.json
{
   "infraPortConfig": {
      "attributes": {
          "dn": "uni/infra/portconfnode-101-card-1-port-32-sub-0",
          "assocGrp": "uni/infra/funcprof/accbundle-VPC-SERVER"
      }
  }
}

# POST /api/mo.json
{
   "infraPortConfig": {
      "attributes": {
          "dn": "uni/infra/portconfnode-102-card-1-port-32-sub-0",
          "assocGrp": "uni/infra/funcprof/accbundle-VPC-SERVER"
      }
  }
}

 

 See https://developer.cisco.com/docs/apic-rest-api-configuration-guide/#!configuring-leaf-switch-physical-ports-using-the-interface-configuration - There are also more examples under the "Layer 2 Networking" menu on this page.

HTH

View solution in original post

2 Replies 2

Marcel Zehnder
Spotlight
Spotlight

Hi, yes the MO/class is infraPortConfig. For example to attach a vPC Interface Policy Group (VPC-SERVER) to ports eth1/32 of leafs 101 and 102:

 

# POST /api/mo.json
{
   "infraPortConfig": {
      "attributes": {
          "dn": "uni/infra/portconfnode-101-card-1-port-32-sub-0",
          "assocGrp": "uni/infra/funcprof/accbundle-VPC-SERVER"
      }
  }
}

# POST /api/mo.json
{
   "infraPortConfig": {
      "attributes": {
          "dn": "uni/infra/portconfnode-102-card-1-port-32-sub-0",
          "assocGrp": "uni/infra/funcprof/accbundle-VPC-SERVER"
      }
  }
}

 

 See https://developer.cisco.com/docs/apic-rest-api-configuration-guide/#!configuring-leaf-switch-physical-ports-using-the-interface-configuration - There are also more examples under the "Layer 2 Networking" menu on this page.

HTH

afonsoferreira
Level 1
Level 1

Thanks Marcel!

Review Cisco Networking for a $25 gift card

Save 25% on Day-2 Operations Add-On License