cisco.dnac.site_workflow_manager module – Manage hierarchical sites in Cisco Catalyst Center
Note
This module is part of the cisco.dnac collection (version 6.39.0).
You might already have this collection installed if you are using the ansible
package.
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install cisco.dnac
.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: cisco.dnac.site_workflow_manager
.
New in cisco.dnac 6.6.0
Synopsis
Complete management of sites in Cisco Catalyst Center, including hierarchical structures of areas, buildings, and floors.
Creates single or multiple sites with specified hierarchical relationships.
Updates existing site configurations, including physical attributes and RF characteristics.
Deletes sites and their components when no longer needed.
Supports bulk operations for efficiently managing multiple sites simultaneously.
Handles floor maps and RF modeling for wireless network planning.
Provides verification of site configurations after changes are applied.
Requirements
The below requirements are needed on the host that executes this module.
dnacentersdk == 2.4.5
python >= 3.9
Parameters
Parameter |
Comments |
---|---|
List of site configurations to be created, updated, or deleted. Each item represents a single site operation. Required for all operations as it defines the target sites and their configurations. |
|
Contains the detailed configuration for the site being managed. Only one site component type (area, building, or floor) should be specified in each config entry. |
|
Configuration specific to an area-type site. Areas represent the highest level in the site hierarchy, typically representing geographical regions, campuses, or other logical divisions. |
|
Name of the area to create, update, or delete. Must be unique within its parent site. |
|
Full hierarchical path of the parent site. Format should be slash-separated notation (For example, “Global/USA”). For top-level areas, the parent is typically “Global”. |
|
Configuration specific to a building-type site. Buildings represent physical structures within an area and contain floors. |
|
Physical street address of the building. Used for geographical positioning and identification. |
|
The country where the building is located. Optional parameter for additional geolocation context. |
|
Geographical latitude coordinate of the building. Must be between -90.0 and +90.0 degrees. For Example, 37.338 for a location in San Jose, California. Required for creating buildings, optional when updating. |
|
Geographical longitude coordinate of the building. Must be between -180.0 and +180.0 degrees. For Example, -121.832 for a location in San Jose, California. Required for creating buildings, optional when updating. |
|
Name of the building to create, update, or delete. Must be unique within its parent area. |
|
Full hierarchical path of the parent area. Format should be slash-separated (e.g., “Global/USA/California”). The parent must exist before creating the building. |
|
Configuration specific to a floor-type site. Floors represent levels within a building and can contain network devices and floor plans. |
|
Numerical identifier for the floor within the building. - Required for floor creation from Catalyst Center version 2.3.7.6 onwards. - Once set, this value cannot be modified. - For example, 1 for first floor, 0 for ground floor, -1 for basement. |
|
Controls whether to upload or update the floor image. - When true, the floor image specified in upload_floor_image_path will be uploaded or updated, even if the floor already has an image. - When false, image upload is skipped during updates. - During initial floor creation, if upload_floor_image_path is provided, the image will be uploaded regardless of this setting. - Set to true to replace an existing floor image during an update operation. Choices:
|
|
Height of the floor in the specified units (default is feet). Represents the ceiling height, important for RF planning and signal propagation modeling. |
|
Length of the floor in the specified units (default is feet). Used for defining the floor dimensions for mapping purposes. |
|
Name of the floor to create, update, or delete. Must be unique within its parent building. |
|
Full hierarchical path of the parent building. Format should be slash-separated notation (For example, “Global/USA/California/Building_1”). |
|
RF (Radio Frequency) model type for the floor, essential for wireless network planning. Select one of the following options based on your environment: - “Cubes And Walled Offices”: For indoor areas with cubicles or walled offices, where signal propagation is affected by walls and partitions. - “Drywall Office Only”: For environments with drywall partitions (typically office spaces), which have moderate signal attenuation. - “Indoor High Ceiling”: For spaces with high ceilings (e.g., auditoriums, warehouses), where vertical propagation patterns differ significantly. - “Outdoor Open Space”: For outdoor areas with minimal obstruction, suitable for outdoor deployments or open campuses. The chosen RF model affects how the system calculates wireless coverage and capacity. Choices:
|
|
Unit of measurement for floor dimensions (height, length, and width). - Available from Catalyst Center version 2.3.7.6 onwards. - Default is ‘feet’ if not specified. Choices:
|
|
Local file path to an image that will be uploaded as the floor plan. Supported formats include JPG, PNG, and PDF. Feature available from Catalyst Center version 2.3.7.6 onwards. |
|
Width of the floor in the specified units (default is feet). Used for defining the floor dimensions for mapping purposes. |
|
Specifies the type of site component to manage. Must be one of “area”, “building”, or “floor”. Choices:
|
|
Controls whether to verify site configurations after applying changes. When set to true, the module will confirm that site creation, updates, or deletion operations have been successfully completed in Cisco Catalyst Center. Choices:
|
|
Defines the timeout in seconds for API calls to retrieve task details. If the task details are not received within this period, the process will end, and a timeout notification will be logged. Default: |
|
Indicates whether debugging is enabled in the Cisco Catalyst Center SDK. Choices:
|
|
The hostname of the Cisco Catalyst Center. |
|
Flag to enable/disable playbook execution logging. When true and dnac_log_file_path is provided, - Create the log file at the execution location with the specified name. When true and dnac_log_file_path is not provided, - Create the log file at the execution location with the name ‘dnac.log’. When false, - Logging is disabled. If the log file doesn’t exist, - It is created in append or write mode based on the “dnac_log_append” flag. If the log file exists, - It is overwritten or appended based on the “dnac_log_append” flag. Choices:
|
|
Determines the mode of the file. Set to True for ‘append’ mode. Set to False for ‘write’ mode. Choices:
|
|
Governs logging. Logs are recorded if dnac_log is True. If path is not specified, - When ‘dnac_log_append’ is True, ‘dnac.log’ is generated in the current Ansible directory; logs are appended. - When ‘dnac_log_append’ is False, ‘dnac.log’ is generated; logs are overwritten. If path is specified, - When ‘dnac_log_append’ is True, the file opens in append mode. - When ‘dnac_log_append’ is False, the file opens in write (w) mode. - In shared file scenarios, without append mode, content is overwritten after each module execution. - For a shared log file, set append to False for the 1st module (to overwrite); for subsequent modules, set append to True. Default: |
|
Sets the threshold for log level. Messages with a level equal to or higher than this will be logged. Levels are listed in order of severity [CRITICAL, ERROR, WARNING, INFO, DEBUG]. CRITICAL indicates serious errors halting the program. Displays only CRITICAL messages. ERROR indicates problems preventing a function. Displays ERROR and CRITICAL messages. WARNING indicates potential future issues. Displays WARNING, ERROR, CRITICAL messages. INFO tracks normal operation. Displays INFO, WARNING, ERROR, CRITICAL messages. DEBUG provides detailed diagnostic info. Displays all log messages. Default: |
|
The password for authentication at the Cisco Catalyst Center. |
|
Specifies the port number associated with the Cisco Catalyst Center. Default: |
|
Specifies the interval in seconds between successive calls to the API to retrieve task details. Default: |
|
The username for authentication at the Cisco Catalyst Center. Default: |
|
Flag to enable or disable SSL certificate verification. Choices:
|
|
Specifies the version of the Cisco Catalyst Center that the SDK should use. Default: |
|
Defines the intended state of the sites after module execution.
Choices:
|
|
Flag for Cisco Catalyst Center SDK to enable the validation of request bodies against a JSON schema. Choices:
|
Notes
Note
Floor number and units_of_measure require Catalyst Center version 2.3.7.6 or later.
Floor image upload is available from version 2.3.7.6 onwards.
Module requires dnacentersdk 2.4.5 or later.
Primary SDK Methods - sites.Sites.create_site, sites.Sites.update_site, sites.Sites.delete_site - site.Sites.create_sites, site.Sites.update_a_floor, site.Sites.update_a_building - site.Sites.update_an_area, site.Sites.delete_a_floor, site.Sites.delete_a_building - site.Sites.delete_an_area, site.Sites.get_site_assigned_network_devices
API Endpoints - POST /dna/intent/api/v1/site, PUT dna/intent/api/v1/site/{siteId} - DELETE dna/intent/api/v1/site/{siteId} DELETE/dna/intent/api/v2/buildings/{id} - DELETE/dna/intent/api/v1/areas/{id} DELETE/dna/intent/api/v2/floors/{id} PUT/dna/intent/api/v2/floors/{id} - PUT/dna/intent/api/v1/areas/{id} PUT/dna/intent/api/v2/buildings/{id} GET/dna/intent/api/v1/sites - POST/dna/intent/api/v1/sites/bulk GET/dna/intent/api/v1/networkDevices/assignedToSite
Sites must be created in order - areas first, then buildings, then floors.
Deleting a parent site will automatically delete all child sites.
RF models significantly impact wireless planning and should be selected based on the actual physical environment.
Floor dimensions (height, length, width) and RF models can be updated after creation, but floor_number cannot be modified once set.
Floor images, once uploaded, remain associated with the floor until explicitly replaced using force_upload_floor_image to true.
Large floor plan images may take time to upload; ensure the connection to Catalyst Center remains stable during upload.
Latitude must be between -90.0 and +90.0 degrees, with positive values representing north of the equator.
Longitude must be between -180.0 and +180.0 degrees, with positive values representing east of the prime meridian.
Use precise coordinates for buildings to ensure accurate positioning on maps and integration with location services.
Use unique names for sites to avoid confusion in complex hierarchies.
For bulk operations, limit the number of sites to avoid timeout issues.
Floor image uploads for multiple floors may impact performance; consider spreading large uploads across multiple tasks.
Site operations on a large scale (many floors or buildings) may take considerable time to complete.
Site names are case-sensitive in Catalyst Center; ensure consistent casing in your playbooks.
Does not support
check_mode
The plugin runs on the control node and does not use any ansible connection plugins instead embedded connection manager from Cisco Catalyst Center SDK
The parameters starting with dnac_ are used by the Cisco Catalyst Center Python SDK to establish the connection
See Also
See also
- Cisco Catalyst Center API Documentation
Complete API reference for device management.
- Site Management API
Specific documentation for site operations in Catalyst Center version.
Examples
- name: Create a new area site
cisco.dnac.site_workflow_manager:
dnac_host: "{{dnac_host}}"
dnac_username: "{{dnac_username}}"
dnac_password: "{{dnac_password}}"
dnac_verify: "{{dnac_verify}}"
dnac_port: "{{dnac_port}}"
dnac_version: "{{dnac_version}}"
dnac_debug: "{{dnac_debug}}"
dnac_log_level: "{{dnac_log_level}}"
dnac_log: "{{dnac_log}}"
state: merged
config:
- site:
area:
name: Test
parent_name: Global/India
site_type: area
- name: Create a new building site
cisco.dnac.site_workflow_manager:
dnac_host: "{{dnac_host}}"
dnac_username: "{{dnac_username}}"
dnac_password: "{{dnac_password}}"
dnac_verify: "{{dnac_verify}}"
dnac_port: "{{dnac_port}}"
dnac_version: "{{dnac_version}}"
dnac_debug: "{{dnac_debug}}"
dnac_log_level: "{{dnac_log_level}}"
dnac_log: "{{dnac_log}}"
state: merged
config:
- site:
building:
name: Building_1
parent_name: Global/India
address: Bengaluru, Karnataka, India
latitude: 24.12
longitude: 23.45
site_type: building
- name: Create a Floor site under the building
cisco.dnac.site_workflow_manager:
dnac_host: "{{dnac_host}}"
dnac_username: "{{dnac_username}}"
dnac_password: "{{dnac_password}}"
dnac_verify: "{{dnac_verify}}"
dnac_port: "{{dnac_port}}"
dnac_version: "{{dnac_version}}"
dnac_debug: "{{dnac_debug}}"
dnac_log_level: "{{dnac_log_level}}"
dnac_log: "{{dnac_log}}"
state: merged
config:
- site:
floor:
name: Floor_1
parent_name: Global/India/Building_1
length: 75.76
width: 35.54
height: 30.12
rf_model: Cubes And Walled Offices
floor_number: 2
site_type: floor
- name: Updating the Floor details under the building
cisco.dnac.site_workflow_manager:
dnac_host: "{{dnac_host}}"
dnac_username: "{{dnac_username}}"
dnac_password: "{{dnac_password}}"
dnac_verify: "{{dnac_verify}}"
dnac_port: "{{dnac_port}}"
dnac_version: "{{dnac_version}}"
dnac_debug: "{{dnac_debug}}"
dnac_log_level: "{{dnac_log_level}}"
dnac_log: "{{dnac_log}}"
state: merged
config:
- site:
floor:
name: Floor_1
parent_name: Global/India/Building_1
length: 75.76
width: 35.54
height: 30.12
site_type: floor
- name: Deleting any site you need site name and parent name
cisco.dnac.site_workflow_manager:
dnac_host: "{{dnac_host}}"
dnac_username: "{{dnac_username}}"
dnac_password: "{{dnac_password}}"
dnac_verify: "{{dnac_verify}}"
dnac_port: "{{dnac_port}}"
dnac_version: "{{dnac_version}}"
dnac_debug: "{{dnac_debug}}"
dnac_log_level: "{{dnac_log_level}}"
dnac_log: "{{dnac_log}}"
state: deleted
config:
- site:
floor:
name: Floor_1
parent_name: Global/India/Building_1
site_type: floor
- name: Create bulk sites and upload floor map
cisco.dnac.site_workflow_manager:
dnac_host: "{{dnac_host}}"
dnac_username: "{{dnac_username}}"
dnac_password: "{{dnac_password}}"
dnac_verify: "{{dnac_verify}}"
dnac_port: "{{dnac_port}}"
dnac_version: "{{dnac_version}}"
dnac_debug: "{{dnac_debug}}"
dnac_log: true
dnac_log_level: DEBUG
config_verify: true
state: merged
config:
- site:
area:
name: bangalore99
parent_name: Global
type: area
- site:
building:
name: s1
address: 1234 Elm Street3
parent_name: Global/bangalore99
latitude: 37.373
longitude: -121.873
country: india
type: building
- site:
floor:
name: cherry88
parent_name: Global/bangalore99/s1
rf_model: Outdoor Open Space
width: 117
length: 117
height: 13
floor_number: 3
units_of_measure: "feet"
upload_floor_image_path: "/Users/skesali/Downloads/pngegg.png"
force_upload_floor_image: true
type: floor
- site:
floor:
name: cherry5
parent_name: Global/bangalore9/s1
rf_model: Outdoor Open Space
width: 113
length: 113
height: 13
floor_number: 3
units_of_measure: "feet"
upload_floor_image_path: "/Users/skesali/Downloads/pngegg.png"
force_upload_floor_image: true
type: floor
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
Detailed API execution results when a site is successfully created, updated, or deleted. Contains execution IDs, timestamps, status, and site identifiers. Returned: when a site operation succeeds Sample: |
|
Information about sites that already exist and do not require an update. Useful for idempotency checks and verification that sites are in the desired state. Returned: when a site exists but doesn’t need updating Sample: |
|
Error details when site creation, update, or deletion operations fail. Contains error messages, execution IDs, and timestamps to assist with troubleshooting. Returned: when a site operation fails Sample: |
|
Empty response returned when attempting to delete a site that doesn’t exist. Helps identify when deletion operations target non-existent sites. Returned: when trying to delete a site that doesn’t exist Sample: |
|
Task status information for bulk site creation operations. Includes progress indicators, operation IDs, and status details. Returned: when bulk site creation is performed Sample: |