cisco-en-programmability / dnacentersdk

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

Remove ALL VLANs and SSIDs mapped to VLANs exits with a VALIDATION_ERROR. #175

Open rukapse opened 6 days ago

rukapse commented 6 days ago

Prerequisites

Describe the bug

Expected behavior

Screenshots image

Environment (please complete the following information):

Additional context Add any other context about the problem here.

JosePabloOcampo1212 commented 5 days ago

Hello I hope you are well.

In the documentation of Cisco, which can be found in https://developer.cisco.com/docs/dna-center/add-update-or-remove-ssid-mapping-to-a-vlan/

Here he tells us that the request body must have a specific format. As can be in the following image.

Captura de pantalla 2024-11-07 a las 5 28 10 p  m

This is why you get the error "Invalid parameters”. You need to adjust the payload. An example could be the following.

add_update_or_remove_ssid_mapping_to_a_vlan(fabric_id='b6af9074-b1d8-4b40-82f9-776d34adb0fc', payload= [{"vlanName": "string", "ssidDetails": [ ]}] )

I await your confirmation to see if this was able to resolve your problem.

rukapse commented 5 days ago

Hello Jose,

Thank your for clarifying this, i’lll go ahead and try it out!


From: JosePabloOcampo1212 @.> Sent: Thursday, November 7, 2024 3:58:22 PM To: cisco-en-programmability/dnacentersdk @.> Cc: Rugvedi Kapse (rukapse) @.>; Author @.> Subject: Re: [cisco-en-programmability/dnacentersdk] Remove ALL VLANs and SSIDs mapped to VLANs exits with a VALIDATION_ERROR. (Issue #175)

Hello I hope you are well.

In the documentation of Cisco, which can be found in https://developer.cisco.com/docs/dna-center/add-update-or-remove-ssid-mapping-to-a-vlan/

Here he tells us that the request body must have a specific format. As can be in the following image.

Captura.de.pantalla.2024-11-07.a.las.5.28.10.p.m.png (view on web)https://github.com/user-attachments/assets/8d5536fb-cd29-4d2f-9ada-2a1528e27a56

This is why you get the error "Invalid parameters”. You need to adjust the payload. An example could be the following.

add_update_or_remove_ssid_mapping_to_a_vlan(fabric_id='b6af9074-b1d8-4b40-82f9-776d34adb0fc', payload= [{"vlanName": "string", "ssidDetails": [ ]}] )

I await your confirmation to see if this was able to resolve your problem.

— Reply to this email directly, view it on GitHubhttps://github.com/cisco-en-programmability/dnacentersdk/issues/175#issuecomment-2463452929, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AVKPKMG7QWMUS6LM3NRVQ3LZ7P5B5AVCNFSM6AAAAABRKEUUQGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINRTGQ2TEOJSHE. You are receiving this because you authored the thread.Message ID: @.***>

JosePabloOcampo1212 commented 13 hours ago

Was your problem resolved?