Debian Codegraph @

ansible_collections/cisco/meraki/plugins/modules/networks_topology_link_layer_info.py

raw
1 #!/usr/bin/python
2 # -*- coding: utf-8 -*-
3
4 # Copyright (c) 2021, Cisco Systems
5 # GNU General Public License v3.0+ (see LICENSE or https://www.gnu.org/licenses/gpl-3.0.txt)
6
7 DOCUMENTATION = r"""
8 module: networks_topology_link_layer_info
9 short_description: Information module for networks _topology _linklayer
10 description:
11 - Information module for Networks Topology Linklayer Info.
12 - Get all networks _topology _linklayer.
13 - >
14 List the LLDP and CDP information for all discovered devices and connections in
15 a network. At least one MX or MS device must be in the network in order to build
16 the topology.
17 version_added: '1.0.0'
18 extends_documentation_fragment:
19 - cisco.meraki.module_info
20 author: Francisco Munoz (@fmunoz)
21 options:
22 headers:
23 description: Additional headers.
24 type: dict
25 networkId:
26 description:
27 - Information module for Networks Topology Linklayer Info.
28 - NetworkId path parameter. Network ID.
29 type: str
30 requirements:
31 - meraki >= 2.4.9
32 - python >= 3.5
33 seealso:
34 - name: Cisco Meraki documentation for networks getNetworkTopologyLinkLayer
35 description: Complete reference of the getNetworkTopologyLinkLayer API.
36 link: https://developer.cisco.com/meraki/api-v1/#!get-network-topology-link-layer
37 notes:
38 - SDK Method used are
39 networks.Networks.get_network_topology_link_layer,
40 - Paths used are
41 get /networks/{networkId}/topology/linkLayer,
42 """
43
44 EXAMPLES = r"""
45 - name: Get all networks _topology _linklayer
46 cisco.meraki.networks_topology_link_layer_info:
47 meraki_api_key: "{{ meraki_api_key }}"
48 meraki_base_url: "{{ meraki_base_url }}"
49 meraki_single_request_timeout: "{{ meraki_single_request_timeout }}"
50 meraki_certificate_path: "{{ meraki_certificate_path }}"
51 meraki_requests_proxy: "{{ meraki_requests_proxy }}"
52 meraki_wait_on_rate_limit: "{{ meraki_wait_on_rate_limit }}"
53 meraki_nginx_429_retry_wait_time: "{{ meraki_nginx_429_retry_wait_time }}"
54 meraki_action_batch_retry_wait_time: "{{ meraki_action_batch_retry_wait_time }}"
55 meraki_retry_4xx_error: "{{ meraki_retry_4xx_error }}"
56 meraki_retry_4xx_error_wait_time: "{{ meraki_retry_4xx_error_wait_time }}"
57 meraki_maximum_retries: "{{ meraki_maximum_retries }}"
58 meraki_output_log: "{{ meraki_output_log }}"
59 meraki_log_file_prefix: "{{ meraki_log_file_prefix }}"
60 meraki_log_path: "{{ meraki_log_path }}"
61 meraki_print_console: "{{ meraki_print_console }}"
62 meraki_suppress_logging: "{{ meraki_suppress_logging }}"
63 meraki_simulate: "{{ meraki_simulate }}"
64 meraki_be_geo_id: "{{ meraki_be_geo_id }}"
65 meraki_caller: "{{ meraki_caller }}"
66 meraki_use_iterator_for_get_pages: "{{ meraki_use_iterator_for_get_pages }}"
67 meraki_inherit_logging_config: "{{ meraki_inherit_logging_config }}"
68 networkId: string
69 register: result
70 """
71 RETURN = r"""
72 meraki_response:
73 description: A dictionary or list with the response returned by the Cisco Meraki Python SDK
74 returned: always
75 type: dict
76 sample: >
77 {
78 "nodes": [
79 {
80 "derivedId": "string",
81 "mac": "string",
82 "type": "string",
83 "root": true,
84 "device": {
85 "serial": "string",
86 "name": "string",
87 "model": "string",
88 "productType": "string",
89 "status": "string",
90 "lastReportedAt": "string",
91 "clients": {
92 "counts": {
93 "total": 0
94 }
95 },
96 "uplinks": [
97 {
98 "vlanId": 0
99 }
100 ]
101 },
102 "discovered": {
103 "lldp": {
104 "chassisId": "string",
105 "systemName": "string",
106 "systemDescription": "string",
107 "systemCapabilities": [
108 "string"
109 ],
110 "managementAddress": "string"
111 },
112 "cdp": {
113 "platform": "string",
114 "deviceId": "string",
115 "address": "string",
116 "capabilities": [
117 "string"
118 ],
119 "managementAddress": "string"
120 }
121 },
122 "stack": {
123 "id": 0,
124 "name": "string",
125 "members": [
126 {}
127 ],
128 "clients": {
129 "counts": {
130 "total": 0
131 }
132 }
133 }
134 }
135 ],
136 "links": [
137 {
138 "ends": [
139 {
140 "node": {
141 "derivedId": "string",
142 "type": "string"
143 },
144 "device": {
145 "serial": "string",
146 "name": "string"
147 },
148 "discovered": {
149 "lldp": {
150 "portId": "string",
151 "portDescription": "string"
152 },
153 "cdp": {
154 "portId": "string",
155 "nativeVlan": 0
156 }
157 }
158 }
159 ],
160 "lastReportedAt": "string"
161 }
162 ],
163 "errors": [
164 "string"
165 ]
166 }
167 """