cisco-en-programmability / dnacentersdk

Cisco DNA Center Python SDK
https://dnacentersdk.readthedocs.io/en/latest/
MIT License
70 stars 33 forks source link

SDK function for version 2.3.3.x (v2_3_3_0 /device_onboarding_pnp.py) input requirment does not match with API schema from dnac, #103

Closed DNACENSolutions closed 1 year ago

DNACENSolutions commented 1 year ago

Prerequisites

Describe the bug The schema of API on 2.3.3.x version from DNAC is different then the required parameters in this function. def claim_a_device_to_a_site(self, configInfo=None, deviceId=None, gateway=None, hostname=None, <<======Not in API schema imageId=None, <<=======Not in API Schema imageInfo=None, ipInterfaceName=None, removeInactive=None, <<========Not in API schema. rfProfile=None, siteId=None, staticIP=None, subnetMask=None, type=None, vlanId=None, headers=None, payload=None, active_validation=True, **request_parameters):

Missing field fromAPI Schema: sensorProfile DNAC version: 2.3.3.7

Expected behavior Schema from DNAC: root (map, required) : SiteProvisionRequest deviceId (string, required) siteId (string, required) type (string, optional, enum: Default, StackSwitch, AccessPoint, Sensor, CatalystWLC, MobilityExpress) imageInfo (map, optional) : for Default/StackSwitch imageId (string, optional) skip (boolean, optional) configInfo (array, optional) : for Default/StackSwitch configId (string, optional) configParameters (map, optional) key (string, optional) value (string, optional) rfProfile (string, required) : for Access Points staticIP (string, required) : for CatalystWLC/MobilityExpress subnetMask (string, required) : for CatalystWLC/MobilityExpress gateway (string, required) : for CatalystWLC/MobilityExpress vlanID (string, optional) : for Catalyst 9800 WLC interfaceName (string, optional) : for Catalyst 9800 WLC sensorProfile (string, required) : for Sensors

Sample: { "deviceId": "string", "siteId": "string", "type": "string", "imageInfo": { "imageId": "string", "skip": "boolean" }, "configInfo": [ { "configId": "string", "configParameters": { "key": "string", "value": "string" } } ], "rfProfile": "string", "staticIP": "string", "subnetMask": "string", "gateway": "string", "vlanID": "string", "interfaceName": "string", "sensorProfile": "string" }

Screenshots Please provide an screenshot of the successful API call with cuRL, Postman, etc.

Environment (please complete the following information):

Additional context Add any other context about the problem here.

DNACENSolutions commented 1 year ago

Also vlanId ==> vlanID

fmunozmiranda commented 1 year ago

Hi @DNACENSolutions please verify it in new SDK version, let us know if it works now.