Skip to content

Update ND 4.2 Manage API Fields for Networks, VRFs, and Switches - #500

Open
AKDRG wants to merge 14 commits into
CiscoDevNet:developfrom
AKDRG:fix/nd42-api-field-sync
Open

Update ND 4.2 Manage API Fields for Networks, VRFs, and Switches#500
AKDRG wants to merge 14 commits into
CiscoDevNet:developfrom
AKDRG:fix/nd42-api-field-sync

Conversation

@AKDRG

@AKDRG AKDRG commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Related Issue(s)

Related to #458, #489

Proposed Changes

This PR updates the user-facing module fields and generated payloads to match the ND 4.2 Manage API behavior validated across Networks, VRFs, and Switch bootstrap workflows.

Networks

  • Removed legacy/DCNM-style compatibility aliases from nd_manage_networks.
  • Removed unsupported user-facing options such as query state, network_type, tenant_name, is_l2only, rt_auto, enable_ir, l2_fabric_data, and older shorthand field aliases.
  • Kept ND-native canonical fields such as arp_suppression, mtu, route_target_both, multicast_group_address, and ds_vni.
  • Added user-facing PVLAN support with simple values:
    • normal
    • primary
    • community
    • isolated
  • Internally maps PVLAN values to the ND API values:
    • primary -> privatePrimary
    • community -> privateSecondaryCommunity
    • isolated -> privateSecondaryIsolated
  • Added validation for PVLAN secondary networks:
    • requires primary_network_id
    • rejects L3-only fields
    • places secondary vlan_id in networkTemplateConfig.vlanId
    • omits top-level vlanId for secondary PVLAN payloads
  • Allows network attachments with omitted interfaces, defaulting them to an empty list.
  • Added structured attachment_options support using snake_case fields.
  • Replaced attachment extra_config with freeform_config.

VRFs

  • Removed legacy attachment/config aliases to keep VRF input ND-native and consistent with Networks.
  • Updated VRF docs/templates/tests to reflect canonical field names.

Switches

  • Updated bootstrap import payloads for ND 4.2 fields:
    • uses softwareImage
    • removes legacy imagePolicy
    • supports dhcpBootstrapIp
    • supports seedSwitch
  • Removed software_image from pre-provision input, since pre-provision uses software version rather than software image.
  • Updated switch module documentation and examples accordingly.

Tests

  • Updated Network unit tests for:
    • PVLAN type mapping
    • secondary PVLAN payload generation
    • attachment interface defaults
    • attachment option validation
    • canonical argspec behavior
    • removed legacy aliases
  • Updated VRF and Switch unit/integration coverage impacted by the field cleanup.
  • Updated Network integration playbooks for standalone, MSD, and MCFG flows.

Test Notes

Validated locally:

  • pytest focused Network tests:
    • 104 passed
  • black -l 159 --check
  • git diff --check
  • ansible-test sanity --test validate-modules --test import --test pep8 --test pylint --python 3.11

Live validation was also performed against ND 4.2 Manage workflows for Network field behavior, PVLAN payload handling, and switch bootstrap field handling.

Cisco Nexus Dashboard Version

Developed and validated against Cisco Nexus Dashboard 4.2.x Manage APIs.

Related ND API Resource Category

  • analyze
  • infra
  • manage
  • onemanage
  • other

Checklist

  • Latest commit is rebased from develop with merge conflicts resolved
  • New or updated documentation has been made accordingly
  • Assigned the proper reviewers

@AKDRG
AKDRG force-pushed the fix/nd42-api-field-sync branch from 47cf7c5 to 76db855 Compare August 10, 2026 11:51
@mtarking mtarking added 2.0.0 Release 2.0.0 nac01 NaC ND release 0.0.1 labels Aug 14, 2026
@AKDRG AKDRG self-assigned this Aug 14, 2026
@AKDRG AKDRG added the ready for review Submitter is requesting a PR review label Aug 14, 2026
@AKDRG AKDRG changed the title Align ND 4.2 Manage and OneManage API Fields for nd_manage_switches & nd_manage_networks Align API Fields and remove unsupported specs for nd_manage_switches, nd_manage_vrfs & nd_manage_networks Aug 14, 2026
@AKDRG AKDRG changed the title Align API Fields and remove unsupported specs for nd_manage_switches, nd_manage_vrfs & nd_manage_networks Update ND 4.2 Manage API Fields for Networks, VRFs, and Switches Aug 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

2.0.0 Release 2.0.0 nac01 NaC ND release 0.0.1 ready for review Submitter is requesting a PR review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants