Cable Plan

The following are the Cable Plan REST APIs:

Status

The following table details the API Response code, status and, the HTTPS methods.

Status Code
Status
API's HTTPS Method or
HTTPS Method

200

OK

GET

202

Accepted

POST

PUT

DELETE

400

Bad Request

GET

POST

PUT

DELETE

401

Unauthorized

GET

POST

PUT

DELETE

403

Forbidden

GET

POST

PUT

DELETE

404

Not Found

GET

POST

PUT

DELETE

405

Method Not Allowed

GET

POST

PUT

DELETE

500

Internal Server Error

GET

POST

PUT

DELETE

Capture a Cable Plan

Resource Name

/cable-plans/discovery

Description

Extract a cable plan base on the switches discovered by DCNM.

https Method

GET

URL

https://dcnm-ip/rest/cable-plans/discovery

Parameter

Parameter
Type
Description

 

 

 

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

cable-plan-name

S

Name of the cable plan

Generate a Cable Plan

Resource Name

/cable-plans/poap

Description

Generate a cable plan base on the POAP switch definitions from DCNM

https Method

GET

URL

https://dcnm-ip/rest/cable-plans/poap

Parameter

Parameter
Type
Description

 

 

 

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

cable-plan-name

S

Name of the cable plan

Get a Cable Plan

Resource Name

/cable-plans

Description

Get a cable plan

https Method

GET

URL

https://dcnm-ip/rest/cable-plans

https://dcnm-ip/rest/cable-plans?detail=true

Parameter

Parameter
Type
Description

 

 

 

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

cable-plan

O

By default returns cable-plan information, if “detail=true”, then will return CablePlan object.

Save a Cable Plan

Resource Name

/cable-plans

Description

Save a cable plan into the DCNM database.

https Method

POST

URL

https://dcnm-ip/rest/cable-plans

Parameter

Parameter
Type
Description

cable-plan-object

O

Cable-plan-object including cable-plan-name, source-device, source-device-type, source-port, dest-device, dest-device-type, dest-port.

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

 

 

 

Delete a Cable Plan

Resource Name

/cable-plans

Description

Delete cable plan base on the POAP switch definitions from DCNM.

https Method

DELETE

URL

https://dcnm-ip/rest/cable-plans

Parameter

Parameter
Type
Description

 

 

 

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

 

 

 

Get a Cable Plan From Device

Resource Name

/cable-plans/device-xml

Description

Get a cable plan from devices in XML

https Method

POST

URL

https://dcnm-ip/rest/cable-plans/device-xml

Parameter

Parameter
Type
Description

Ip-addresses

S

The Switch IP Address list which derives the cable plan.

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

cable-plan-info

S

Cable plans in XML

View Cable Plan From Device

Resource Name

/cable-plans/device-raw

Description

Get cable plan from devices and return in raw format

https Method

POST

URL

https://dcnm-ip/rest/cable-plans/device-raw

Parameter

Parameter
Type
Description

Ip-addresses

S

The Switch IP Address list which derives the cable plan

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

Cable-plan-info

S

Cable plans in raw format

Import a Cable Plan

Resource Name

/cable-plans/import

Description

Returns Cable Plan object of imported cable plan file.

https Method

POST

URL

https://dcnm-ip/rest/cable-plans/import

Parameter

Parameter
Type
Description

cable-plan

S

You must provide a Name for the cable plan and the cable plan content in the payload.

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

Cable-plan-object

O

Cable plan object

Export a Cable Plan

Resource Name

/cable-plans/xml

Description

Export a cable plan from DCNM in XML format

https Method

GET

URL

https://dcnm-ip/rest/cable-plans/xml

Parameter

Parameter
Type
Description

 

 

 

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

Cable-plan-object

S

Name of the cable plan and content in XML format in the payload.

Deploy a Cable Plan

Resource Name

/cable-plans/fabric

Description

Deploy a cable plan to all the spine and leaf devices

https Method

POST

URL

hhttps://dcnm-ip/rest/cable-plans/fabric

Parameter

Parameter
Type
Description

Ip-addresses

S

Switch IP address list that needs to be deployed.

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description

 

 

 

Revoke a Cable Plan

Resource Name

/cable-plans/revoke

Description

Revoke a cable plan from all the spine and leaf devices

https Method

POST

URL

https://dcnm-ip/rest/cable-plans/revoke

Parameter

Parameter
Type
Description

Ip-addresses

S

Switch IP address list that needs to be deployed.

Return Value

Format: JSON

Type: Object

Attribute Name
Type
Description