cisco.dnac.assurance_issues_v1_info 模块 – Assurance Issues V1 信息模块

注意

此模块是 cisco.dnac 集合 (版本 6.25.0) 的一部分。

如果您正在使用 ansible 包,则可能已经安装了此集合。它不包含在 ansible-core 中。要检查它是否已安装,请运行 ansible-galaxy collection list

要安装它,请使用:ansible-galaxy collection install cisco.dnac。您需要其他要求才能使用此模块,请参阅 要求 获取详细信息。

要在 playbook 中使用它,请指定:cisco.dnac.assurance_issues_v1_info

cisco.dnac 6.15.0 中的新增功能

概要

  • 获取所有 Assurance Issues V1。

  • 按 ID 获取 Assurance Issues V1。

  • 返回每个问题的全部详细信息以及针对在查询参数中指定的过滤器集的建议操作。如果没有开始时间和/或结束时间,则结束时间将默认为当前时间,开始时间将默认为结束时间之前的 24 小时。所有字符串类型的查询参数都支持使用 * 的通配符搜索。例如,siteHierarchy=Global/San Jose/* 返回所有 siteHierarchy 以“Global/San Jose/”开头的站点下的问题。Https //github.com/cisco-en-programmability/catalyst-center-api- specs/blob/main/Assurance/CE_Cat_Center_Org-IssuesList-1.0.0-resolved.yaml。

  • 返回给定问题 ID 的问题的全部详细信息和建议操作。Https //github.com/cisco-en- programmability/catalyst-center-api-specs/blob/main/Assurance/CE_Cat_Center_Org-IssuesList-1.0.0-resolved.yaml。

注意

此模块具有相应的 action 插件

要求

执行此模块的主机需要以下要求。

  • dnacentersdk >= 2.4.9

  • python >= 3.5

参数

参数

注释

aiDriven

布尔型

AiDriven 查询参数。指示问题是否是 AI 驱动的问题。

选项

  • false

  • true

attribute

字符串

Attribute 查询参数。与问题相关的属性列表。如果提供这些属性,则只有这些属性将成为响应的一部分,以及默认属性。请参阅 `IssuesResponseAttribute` 模型以了解受支持的属性。示例 `attribute=deviceType`(请求单个属性)`attribute=deviceType&attribute=updatedBy`(请求多个属性)。

category

字符串

Category 查询参数。问题的类别。支持单个类别和多个类别。示例 category=availability(请求单个状态)category=availability&category=onboarding(请求多个类别)。

deviceType

字符串

DeviceType 查询参数。此问题所属设备的设备类型。支持单个设备类型和多个设备类型。示例 deviceType=wireless controller(请求单个设备类型)deviceType=wireless controller&deviceType=core(请求多个设备类型)。

dnac_debug

布尔型

用于 Cisco DNA Center SDK 的标志,用于启用调试。

选项

  • false ← (默认)

  • true

dnac_host

字符串 / 必填

Cisco DNA Center 主机名。

dnac_password

字符串

用于身份验证的 Cisco DNA Center 密码。

dnac_port

整数

Cisco DNA Center 端口。

默认值: 443

dnac_username

别名:user

字符串

用于身份验证的 Cisco DNA Center 用户名。

默认值: "admin"

dnac_verify

布尔型

启用或禁用 SSL 证书验证的标志。

选项

  • false

  • true ← (默认)

dnac_version

字符串

告知 SDK 使用哪个版本的 Cisco DNA Center。

默认值: "2.3.7.6"

endTime

浮点型

EndTime 查询参数。API 查询与资源相关的 DataSet 的结束时间。必须以毫秒为单位以 UNIX 纪元时间指定。值包含在内。

entityId

字符串

EntityId 查询参数。此问题所属实体的 ID。例如,它可能是 AP 的 MAC 地址或传感器的 UUID 示例 68 ca e4 79 3f 20 4de02167-901b-43cf-8822-cffd3caa286f 示例 entityId=68 ca e4 79 3f 20(请求单个实体 ID)entityId=68 ca e4 79 3f 20&entityId=864d0421-02c0-43a6-9c52-81cad45f66d8(请求多个实体 ID)。

entityType

字符串

EntityType 查询参数。问题的实体类型。支持单个实体类型和多个实体类型。例如 entityType=networkDevice(请求单个实体类型) entityType=network device&entityType=client(请求多个实体类型)。

fabricDriven

布尔型

FabricDriven 查询参数。标志该问题是否与 Fabric 站点、虚拟网络或中转站相关。

选项

  • false

  • true

fabricSiteDriven

布尔型

FabricSiteDriven 查询参数。标志该问题是否是 Fabric 站点驱动的问题。

选项

  • false

  • true

fabricSiteId

字符串

FabricSiteId 查询参数。Fabric 站点的 UUID。(例如,“flooruuid”) 例如 fabricSiteId=e52aecfe-b142-4287-a587-11a16ba6dd26(请求单个 ID) fabricSiteId=e52aecfe-b142-4287-a587-11a16ba6dd26,864d0421-02c0-43a6-9c52-81cad45f66d8(请求多个 ID)。

fabricTransitDriven

布尔型

FabricTransitDriven 查询参数。标志该问题是否是 Fabric 中转站驱动的问题。

选项

  • false

  • true

fabricTransitSiteId

字符串

FabricTransitSiteId 查询参数。Fabric 中转站的 UUID。(例如,“flooruuid”) 例如 fabricTransitSiteId=e52aecfe-b142-4287-a587-11a16ba6dd26(请求单个 ID) fabricTransitSiteId=e52aecfe-b142-4287-a587-11a16ba6dd26&fabricTransitSiteId=864d0421-02c0-43a6-9c52-81cad45f66d8(请求多个 ID)。

fabricVnDriven

布尔型

FabricVnDriven 查询参数。标志该问题是否是 Fabric 虚拟网络驱动的问题。

选项

  • false

  • true

fabricVnName

字符串

FabricVnName 查询参数。Fabric 虚拟网络的名称。例如 fabricVnName=name1(请求单个 Fabric 虚拟网络名称) fabricVnName=name1&fabricVnName=name2&fabricVnName=name3(请求多个 Fabric 虚拟网络名称)。

headers

字典

附加头。

id

字符串

Id 路径参数。问题的 UUID。

isGlobal

布尔型

IsGlobal 查询参数。全局问题是指影响许多设备和站点的问题。它们也会显示在 Catalyst Center UI 的问题仪表板上。非全局问题仅显示在客户端 360 或设备 360 页面上。如果此标志为“true”,则仅返回全局问题。如果此标志为“false”,则返回所有问题。

选项

  • false

  • true

issueId

字符串

IssueId 查询参数。问题的 UUID。例如 issueId=e52aecfe-b142-4287-a587-11a16ba6dd26(请求单个问题 ID) issueId=e52aecfe-b142-4287-a587-11a16ba6dd26&issueId=864d0421-02c0-43a6-9c52-81cad45f66d8(请求多个问题 ID)。

limit

浮点型

Limit 查询参数。要返回的最大问题数。

macAddress

字符串

MacAddress 查询参数。网络设备或客户端的 macAddress。此字段支持基于通配符(`*`)字符的搜索。例如 `*AB AB AB*` 或 `AB AB AB*` 或 `*AB AB AB`。例如 `macAddress=AB AB AB CD CD CD`(请求单个 macAddress) `macAddress=AB AB AB CD CD DC&macAddress=AB AB AB CD CD FE`(请求多个 macAddress)。

name

字符串

Name 查询参数。问题的名称。例如 name=ap_down(请求单个问题名称) name=ap_down&name=wlc_monitor(请求多个问题名称)。可以使用 API - /data/api/v1/assuranceIssueConfigurations 获取问题名称。

networkDeviceId

字符串

NetworkDeviceId 查询参数。网络设备 UUID 列表。(例如,`6bef213c-19ca-4170-8375-b694e251101c`) 例如 `networkDeviceId=6bef213c-19ca-4170-8375-b694e251101c`(请求单个 networkDeviceId) `networkDeviceId=6bef213c-19ca-4170-8375-b694e251101c&networkDeviceId=32219612-819e-4b5e-a96b-cf22aca13dd9&networkDeviceId=2541e9a7-b80d-4955-8aa2-79b233318ba0`(使用 & 分隔符的多个 networkDeviceIds)。

networkDeviceIpAddress

字符串

NetworkDeviceIpAddress 查询参数。网络设备管理 IP 地址列表。(例如,`121.1.1.10`)此字段支持基于通配符(`*`)字符的搜索。例如 `*1.1*` 或 `1.1*` 或 `*1.1`。例如 `networkDeviceIpAddress=121.1.1.10` `networkDeviceIpAddress=121.1.1.10&networkDeviceIpAddress=172.20.1.10&networkDeviceIpAddress=10.10.20.10`(使用 & 分隔符的多个网络设备 IP 地址)。

offset

浮点型

Offset 查询参数。指定 API 返回的所有记录中的起始点。它是基于 1 的偏移量。起始值为 1。

order

字符串

Order 查询参数。字段的排序顺序,升序或降序。

priority

字符串

Priority 查询参数。问题的优先级。支持单个优先级和多个优先级。例如 priority=P1(请求单个优先级) priority=P1&priority=P2&priority=P3(请求多个优先级)。

severity

字符串

Severity 查询参数。问题的严重性。支持单个严重性和多个严重性。例如 severity=high(请求单个严重性) severity=high&severity=medium(请求多个严重性)。

siteHierarchy

字符串

SiteHierarchy 查询参数。从全局站点名称开始到特定站点名称结束的站点树的完整层次结构细分。根站点名为“Global”(例如,`Global/AreaName/BuildingName/FloorName`)此字段支持通配符星号 (*) 字符搜索支持。例如 */San*, */San, /San*。例如 `?siteHierarchy=Global/AreaName/BuildingName/FloorName`(请求单个 siteHierarchy) `?siteHierarchy=Global/AreaName/BuildingName/FloorName&siteHierarchy=Global/AreaName2/BuildingName2/FloorName2`(请求多个 siteHierarchies)。

siteHierarchyId

字符串

SiteHierarchyId 查询参数。站点树的完整层次结构细分,以 ID 形式表示,从全局站点 UUID 开始到特定站点 UUID 结束。(例如,`globalUuid/areaUuid/buildingUuid/floorUuid`)此字段支持通配符星号 (*) 字符搜索支持。例如 `*uuid*, *uuid, uuid*。例如 `?siteHierarchyId=globalUuid/areaUuid/buildingUuid/floorUuid `(请求单个 siteHierarchyId) `?siteHierarchyId=globalUuid/areaUuid/buildingUuid/floorUuid&siteHierarchyId=globalUuid/areaUuid2/buildingUuid2/floorUuid2`(请求多个 siteHierarchyIds)。

siteId

字符串

SiteId 查询参数。站点的 UUID。(例如,`flooruuid`)此字段支持通配符星号 (*) 字符搜索支持。例如 *flooruuid*, *flooruuid, flooruuid*。例如 `?siteId=id1`(请求单个 ID) `?siteId=id1&siteId=id2&siteId=id3`(请求多个 ID)。

siteName

字符串

SiteName 查询参数。站点的名称。(例如,`FloorName`)此字段支持通配符星号 (*) 字符搜索支持。例如 *San*, *San, San*。例如 `?siteName=building1`(请求单个 siteName) `?siteName=building1&siteName=building2&siteName=building3`(请求多个 siteNames)。

sortBy

字符串

SortBy 查询参数。

startTime

浮点型

StartTime 查询参数。API 查询与资源相关的数据库的起始时间。必须以毫秒为单位的 UNIX 纪元时间指定。值为包含值。如果未提供 `startTime`,则 API 将默认为当前时间。

status

字符串

Status 查询参数。问题的状态。支持单个状态和多个状态。例如 status=active(请求单个状态) status=active&status=resolved(请求多个状态)。

updatedBy

字符串

UpdatedBy 查询参数。最后更新此问题的用户。例如 updatedBy=admin(请求单个 updatedBy) updatedBy=admin&updatedBy=john(请求多个 updatedBy)。

validate_response_schema

布尔型

用于 Cisco DNA Center SDK 的标志,用于启用根据 JSON 模式验证请求正文。

选项

  • false

  • true ← (默认)

view

字符串

View 查询参数。视图的名称。每个视图代表一个特定的数据集。请参阅 `IssuesView` 模型以了解受支持的视图。View 是 API 支持的预定义属性集。只有与给定视图相关的属性以及默认属性才会成为 API 响应的一部分。如果提供了多个视图,则响应将包含所有这些视图的属性。如果没有指定视图,则将返回所有属性。| 视图名称 | 包含的属性 | | — | — | | `update` | updatedTime, updatedBy | | `site` | siteName, siteHierarchy, siteId, siteHierarchyId | 例如 `view=update`(请求单个视图) `view=update&view=site`(请求多个视图)。

备注

注意

  • 使用的 SDK 方法为 issues.Issues.get_all_the_details_and_suggested_actions_of_an_issue_for_the_given_issue_id_v1、issues.Issues.get_the_details_of_issues_for_given_set_of_filters_know_your_network_v1,

  • 使用的路径为 get /dna/data/api/v1/assuranceIssues、get /dna/data/api/v1/assuranceIssues/{id},

  • 支持 check_mode

  • 插件在控制节点上运行,不使用任何 Ansible 连接插件,而是使用 Cisco DNAC SDK 中的嵌入式连接管理器。

  • 以 dnac_ 开头的参数由 Cisco DNAC Python SDK 用于建立连接。

另请参见

另请参见

Cisco DNA Center 文档,了解 Issues GetAllTheDetailsAndSuggestedActionsOfAnIssueForTheGivenIssueIdV1

GetAllTheDetailsAndSuggestedActionsOfAnIssueForTheGivenIssueIdV1 API 的完整参考。

Cisco DNA Center 文档,了解 Issues GetTheDetailsOfIssuesForGivenSetOfFiltersKnowYourNetworkV1

GetTheDetailsOfIssuesForGivenSetOfFiltersKnowYourNetworkV1 API 的完整参考。

示例

- name: Get all Assurance Issues V1
  cisco.dnac.assurance_issues_v1_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}}"
    startTime: 0
    endTime: 0
    limit: 0
    offset: 0
    sortBy: string
    order: string
    isGlobal: True
    priority: string
    severity: string
    status: string
    entityType: string
    category: string
    deviceType: string
    name: string
    issueId: string
    entityId: string
    updatedBy: string
    siteHierarchy: string
    siteHierarchyId: string
    siteName: string
    siteId: string
    fabricSiteId: string
    fabricVnName: string
    fabricTransitSiteId: string
    networkDeviceId: string
    networkDeviceIpAddress: string
    macAddress: string
    view: string
    attribute: string
    aiDriven: True
    fabricDriven: True
    fabricSiteDriven: True
    fabricVnDriven: True
    fabricTransitDriven: True
  register: result

- name: Get Assurance Issues V1 by id
  cisco.dnac.assurance_issues_v1_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}}"
    view: string
    attribute: string
    id: string
  register: result

返回值

公共返回值已记录在 此处,以下是此模块特有的字段

描述

dnac_response

字典

包含 Cisco DNAC Python SDK 返回的响应的字典或列表。

返回值:始终

示例: {"response": {"additionalAttributes": [{"key": "string", "value": "string"}], "category": "string", "description": "string", "deviceType": "string", "entityId": "string", "entityType": "string", "firstOccurredTime": 0, "isGlobal": true, "issueId": "string", "mostRecentOccurredTime": 0, "name": "string", "notes": {}, "priority": "string", "severity": "string", "siteHierarchy": {}, "siteHierarchyId": {}, "siteId": {}, "siteName": {}, "status": "string", "suggestedActions": [{"message": "string", "steps": [{}]}], "summary": "string", "updatedBy": "string", "updatedTime": 0}, "version": "string"}

作者

  • Rafael Campos (@racampos)