cisco.dnac.access_groups_info module -- Information module for Access Groups
Note
This module is part of the cisco.dnac collection (version 6.46.0).
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.access_groups_info.
New in cisco.dnac 6.46.0
Synopsis
Get all Access Groups.
Get Access Groups by id.
Get all access groups in the system.
Get an access group in the system.
Note
This module has a corresponding action plugin.
Requirements
The below requirements are needed on the host that executes this module.
dnacentersdk >= 2.11.0
python >= 3.12
Parameters
Parameter |
Comments |
|---|---|
Flag for Cisco DNA Center SDK to enable debugging. Choices: |
|
The Cisco DNA Center hostname. |
|
The Cisco DNA Center password to authenticate. |
|
The Cisco DNA Center port. Default: :ansible-option-default:`443` |
|
The Cisco DNA Center username to authenticate. Default: :ansible-option-default:`"admin"` |
|
Flag to enable or disable SSL certificate verification. Choices: |
|
Informs the SDK which version of Cisco DNA Center to use. Default: :ansible-option-default:`"3.1.6.0"` |
|
Additional headers. |
|
Id path parameter. Id of the access group to query. |
|
Ids query parameter. Get access groups by passing a comma separated list of their ids. |
|
Limit query parameter. Limit on the number of access groups on a page. Default page size is 20. |
|
Names query parameter. Get access groups by passing comma separated list of names. It performs an exact character match. |
|
Offset query parameter. An integer representing the starting access group in the page returned. |
|
SourceResourceIds query parameter. Get access groups by passing the ids of the resource associated with it such as the site hierarchy id. |
|
Type query parameter. Get access groups by passing the type of the resource such as site. |
|
UserCount query parameter. If set to true, it will return number of users associated with each access group. Default is false. |
|
Flag for Cisco DNA Center SDK to enable the validation of request bodies against a JSON schema. Choices: |
Notes
Note
SDK Method used are userand_roles.UserandRoles.get_access_group, userand_roles.UserandRoles.get_access_groups,
Paths used are get /dna/system/api/v1/accessGroups, get /dna/system/api/v1/accessGroups/{id},
Supports
check_modeThe plugin runs on the control node and does not use any ansible connection plugins, but instead the embedded connection manager from Cisco DNAC SDK
The parameters starting with dnac_ are used by the Cisco DNAC Python SDK to establish the connection
See Also
See also
- Cisco DNA Center documentation for User and Roles GetAccessGroup
Complete reference of the GetAccessGroup API.
- Cisco DNA Center documentation for User and Roles GetAccessGroups
Complete reference of the GetAccessGroups API.
Examples
---
- name: Get all Access Groups
cisco.dnac.access_groups_info:
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}}"
headers: "{{my_headers | from_json}}"
userCount: string
names: string
type: string
sourceResourceIds: string
ids: string
offset: 0
limit: 0
register: result
- name: Get Access Groups by id
cisco.dnac.access_groups_info:
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}}"
headers: "{{my_headers | from_json}}"
id: string
register: result
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
|---|---|
A dictionary or list with the response returned by the Cisco DNAC Python SDK Returned: always |