Debian Codegraph @

ansible_collections/cisco/meraki/plugins/modules/organizations_wireless_devices_provisioning_deployments.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: organizations_wireless_devices_provisioning_deployments
9 short_description: Resource module for organizations _wireless _devices _provisioning _deployments
10 description:
11 - Manage operations create, update and delete of the resource organizations _wireless _devices _provisioning _deployments.
12 - Create a zero touch deployment for a wireless access point.
13 - Delete a zero touch deployment.
14 - Update a zero touch deployment.
15 version_added: '1.0.0'
16 extends_documentation_fragment:
17 - cisco.meraki.module
18 author: Francisco Munoz (@fmunoz)
19 options:
20 deploymentId:
21 description: DeploymentId path parameter. Deployment ID.
22 type: str
23 items:
24 description: List of zero touch deployments to create.
25 elements: dict
26 suboptions:
27 completedAt:
28 description: Timestamp of when the zero touch deployment request was completed.
29 type: str
30 createdAt:
31 description: Timestamp of when the zero touch deployment request was created.
32 type: str
33 deploymentId:
34 description: Zero touch deployment request identifier.
35 type: str
36 devices:
37 description: An array composed of old and new devices.
38 suboptions:
39 new:
40 description: New device.
41 suboptions:
42 mac:
43 description: MAC address of the new device.
44 type: str
45 model:
46 description: Model of the new device.
47 type: str
48 name:
49 description: Name of the new device or serial number if not named.
50 type: str
51 rfProfile:
52 description: RF profile of the new device.
53 suboptions:
54 id:
55 description: ID of RfProfile for new device.
56 type: str
57 name:
58 description: Name of RfProfile for new device.
59 type: str
60 type: dict
61 serial:
62 description: Serial number of the new device.
63 type: str
64 tags:
65 description: Tag(s) of the new device.
66 elements: str
67 type: list
68 type: dict
69 old:
70 description: Old device.
71 suboptions:
72 afterAction:
73 description: Action to be taken on the old device.
74 type: str
75 mac:
76 description: MAC address of the old device.
77 type: str
78 model:
79 description: Model of the old device.
80 type: str
81 name:
82 description: Name of the old device.
83 type: str
84 rfProfile:
85 description: RF profile of the old device.
86 suboptions:
87 id:
88 description: ID of the RF profile.
89 type: str
90 name:
91 description: Name of the RF profile.
92 type: str
93 type: dict
94 serial:
95 description: Serial number of the old device.
96 type: str
97 tags:
98 description: Tag(s) of the old device.
99 elements: str
100 type: list
101 type: dict
102 type: dict
103 errors:
104 description: Array of error message(s) if any.
105 elements: str
106 type: list
107 lastUpdatedAt:
108 description: Timestamp of when the zero touch deployment request was last updated.
109 type: str
110 network:
111 description: Network information.
112 suboptions:
113 id:
114 description: ID of the network the device is being added to.
115 type: str
116 name:
117 description: Name of the network the device is being added to.
118 type: str
119 type: dict
120 requestedAt:
121 description: Timestamp of when the zero touch deployment request was created.
122 type: str
123 status:
124 description: Status of the zero touch deployment request. Enum = ready, in progress,
125 completed, failed.
126 type: str
127 type:
128 description: Type of the zero touch deployment request. Enum = deploy, replace.
129 type: str
130 type: list
131 meta:
132 description: Metadata relevant to the paginated dataset.
133 suboptions:
134 counts:
135 description: Counts relating to the paginated dataset.
136 suboptions:
137 items:
138 description: Counts relating to the paginated items.
139 suboptions:
140 remaining:
141 description: The number of items in the dataset that are available on
142 subsequent pages.
143 type: int
144 total:
145 description: The total number of items in the dataset.
146 type: int
147 type: dict
148 type: dict
149 type: dict
150 organizationId:
151 description: OrganizationId path parameter. Organization ID.
152 type: str
153 requirements:
154 - meraki >= 2.4.9
155 - python >= 3.5
156 seealso:
157 - name: Cisco Meraki documentation for wireless createOrganizationWirelessDevicesProvisioningDeployment
158 description: Complete reference of the createOrganizationWirelessDevicesProvisioningDeployment API.
159 link: https://developer.cisco.com/meraki/api-v1/#!create-organization-wireless-devices-provisioning-deployment
160 - name: Cisco Meraki documentation for wireless deleteOrganizationWirelessDevicesProvisioningDeployment
161 description: Complete reference of the deleteOrganizationWirelessDevicesProvisioningDeployment API.
162 link: https://developer.cisco.com/meraki/api-v1/#!delete-organization-wireless-devices-provisioning-deployment
163 - name: Cisco Meraki documentation for wireless updateOrganizationWirelessDevicesProvisioningDeployments
164 description: Complete reference of the updateOrganizationWirelessDevicesProvisioningDeployments API.
165 link: https://developer.cisco.com/meraki/api-v1/#!update-organization-wireless-devices-provisioning-deployments
166 notes:
167 - SDK Method used are
168 wireless.Wireless.create_organization_wireless_devices_provisioning_deployment,
169 wireless.Wireless.delete_organization_wireless_devices_provisioning_deployment,
170 wireless.Wireless.update_organization_wireless_devices_provisioning_deployments,
171
172 - Paths used are
173 post /organizations/{organizationId}/wireless/devices/provisioning/deployments,
174 delete /organizations/{organizationId}/wireless/devices/provisioning/deployments/{deploymentId},
175 put /organizations/{organizationId}/wireless/devices/provisioning/deployments,
176 """
177
178 EXAMPLES = r"""
179 - name: Create
180 cisco.meraki.organizations_wireless_devices_provisioning_deployments:
181 meraki_api_key: "{{ meraki_api_key }}"
182 meraki_base_url: "{{ meraki_base_url }}"
183 meraki_single_request_timeout: "{{ meraki_single_request_timeout }}"
184 meraki_certificate_path: "{{ meraki_certificate_path }}"
185 meraki_requests_proxy: "{{ meraki_requests_proxy }}"
186 meraki_wait_on_rate_limit: "{{ meraki_wait_on_rate_limit }}"
187 meraki_nginx_429_retry_wait_time: "{{ meraki_nginx_429_retry_wait_time }}"
188 meraki_action_batch_retry_wait_time: "{{ meraki_action_batch_retry_wait_time }}"
189 meraki_retry_4xx_error: "{{ meraki_retry_4xx_error }}"
190 meraki_retry_4xx_error_wait_time: "{{ meraki_retry_4xx_error_wait_time }}"
191 meraki_maximum_retries: "{{ meraki_maximum_retries }}"
192 meraki_output_log: "{{ meraki_output_log }}"
193 meraki_log_file_prefix: "{{ meraki_log_file_prefix }}"
194 meraki_log_path: "{{ meraki_log_path }}"
195 meraki_print_console: "{{ meraki_print_console }}"
196 meraki_suppress_logging: "{{ meraki_suppress_logging }}"
197 meraki_simulate: "{{ meraki_simulate }}"
198 meraki_be_geo_id: "{{ meraki_be_geo_id }}"
199 meraki_caller: "{{ meraki_caller }}"
200 meraki_use_iterator_for_get_pages: "{{ meraki_use_iterator_for_get_pages }}"
201 meraki_inherit_logging_config: "{{ meraki_inherit_logging_config }}"
202 state: present
203
204 items:
205 - completedAt: "2018-02-11T00:00:00.090210Z"
206 createdAt: "2018-02-11T00:00:00.090210Z"
207 deploymentId: "1284392014819"
208 devices:
209 new:
210 mac: 00:11:22:33:44:55
211 model: CW9166I
212 name: My AP
213 rfProfile:
214 id: "1284392014819"
215 name: RF Profile Name
216 serial: Q234-ABCD-5678
217 tags:
218 - tag1
219 - tag2
220 old:
221 afterAction: unclaim
222 mac: 00:11:22:33:44:55
223 model: MR34
224 name: My AP
225 rfProfile:
226 id: "1284392014819"
227 name: RF Profile Name
228 serial: Q234-ABCD-5678
229 tags:
230 - tag1
231 - tag2
232 errors:
233 - error message1
234 - error message2
235 lastUpdatedAt: "2018-02-11T00:00:00.090210Z"
236 network:
237 id: N_24329156
238 name: Main Office
239 requestedAt: "2018-02-11T00:00:00.090210Z"
240 status: ready
241 type: replace
242 meta:
243 counts:
244 items:
245 remaining: 0
246 total: 20
247 organizationId: string
248
249 - name: Update all
250 cisco.meraki.organizations_wireless_devices_provisioning_deployments:
251 meraki_api_key: "{{ meraki_api_key }}"
252 meraki_base_url: "{{ meraki_base_url }}"
253 meraki_single_request_timeout: "{{ meraki_single_request_timeout }}"
254 meraki_certificate_path: "{{ meraki_certificate_path }}"
255 meraki_requests_proxy: "{{ meraki_requests_proxy }}"
256 meraki_wait_on_rate_limit: "{{ meraki_wait_on_rate_limit }}"
257 meraki_nginx_429_retry_wait_time: "{{ meraki_nginx_429_retry_wait_time }}"
258 meraki_action_batch_retry_wait_time: "{{ meraki_action_batch_retry_wait_time }}"
259 meraki_retry_4xx_error: "{{ meraki_retry_4xx_error }}"
260 meraki_retry_4xx_error_wait_time: "{{ meraki_retry_4xx_error_wait_time }}"
261 meraki_maximum_retries: "{{ meraki_maximum_retries }}"
262 meraki_output_log: "{{ meraki_output_log }}"
263 meraki_log_file_prefix: "{{ meraki_log_file_prefix }}"
264 meraki_log_path: "{{ meraki_log_path }}"
265 meraki_print_console: "{{ meraki_print_console }}"
266 meraki_suppress_logging: "{{ meraki_suppress_logging }}"
267 meraki_simulate: "{{ meraki_simulate }}"
268 meraki_be_geo_id: "{{ meraki_be_geo_id }}"
269 meraki_caller: "{{ meraki_caller }}"
270 meraki_use_iterator_for_get_pages: "{{ meraki_use_iterator_for_get_pages }}"
271 meraki_inherit_logging_config: "{{ meraki_inherit_logging_config }}"
272 state: present
273
274 items:
275 - completedAt: "2018-02-11T00:00:00.090210Z"
276 createdAt: "2018-02-11T00:00:00.090210Z"
277 deploymentId: "1284392014819"
278 devices:
279 new:
280 mac: 00:11:22:33:44:55
281 model: CW9166I
282 name: My AP
283 rfProfile:
284 id: "1284392014819"
285 name: RF Profile Name
286 serial: Q234-ABCD-5678
287 tags:
288 - tag1
289 - tag2
290 old:
291 afterAction: unclaim
292 mac: 00:11:22:33:44:55
293 model: MR34
294 name: My AP
295 rfProfile:
296 id: "1284392014819"
297 name: RF Profile Name
298 serial: Q234-ABCD-5678
299 tags:
300 - tag1
301 - tag2
302 errors:
303 - error message1
304 - error message2
305 lastUpdatedAt: "2018-02-11T00:00:00.090210Z"
306 network:
307 id: N_24329156
308 name: Main Office
309 requestedAt: "2018-02-11T00:00:00.090210Z"
310 status: ready
311 type: replace
312 meta:
313 counts:
314 items:
315 remaining: 0
316 total: 20
317 organizationId: string
318
319 - name: Delete by id
320 cisco.meraki.organizations_wireless_devices_provisioning_deployments:
321 meraki_api_key: "{{ meraki_api_key }}"
322 meraki_base_url: "{{ meraki_base_url }}"
323 meraki_single_request_timeout: "{{ meraki_single_request_timeout }}"
324 meraki_certificate_path: "{{ meraki_certificate_path }}"
325 meraki_requests_proxy: "{{ meraki_requests_proxy }}"
326 meraki_wait_on_rate_limit: "{{ meraki_wait_on_rate_limit }}"
327 meraki_nginx_429_retry_wait_time: "{{ meraki_nginx_429_retry_wait_time }}"
328 meraki_action_batch_retry_wait_time: "{{ meraki_action_batch_retry_wait_time }}"
329 meraki_retry_4xx_error: "{{ meraki_retry_4xx_error }}"
330 meraki_retry_4xx_error_wait_time: "{{ meraki_retry_4xx_error_wait_time }}"
331 meraki_maximum_retries: "{{ meraki_maximum_retries }}"
332 meraki_output_log: "{{ meraki_output_log }}"
333 meraki_log_file_prefix: "{{ meraki_log_file_prefix }}"
334 meraki_log_path: "{{ meraki_log_path }}"
335 meraki_print_console: "{{ meraki_print_console }}"
336 meraki_suppress_logging: "{{ meraki_suppress_logging }}"
337 meraki_simulate: "{{ meraki_simulate }}"
338 meraki_be_geo_id: "{{ meraki_be_geo_id }}"
339 meraki_caller: "{{ meraki_caller }}"
340 meraki_use_iterator_for_get_pages: "{{ meraki_use_iterator_for_get_pages }}"
341 meraki_inherit_logging_config: "{{ meraki_inherit_logging_config }}"
342 state: absent
343
344 deploymentId: string
345 organizationId: string
346 """
347 RETURN = r"""
348 meraki_response:
349 description: A dictionary or list with the response returned by the Cisco Meraki Python SDK
350 returned: always
351 type: dict
352 sample: >
353 {
354 "items": [
355 {
356 "deploymentId": "string",
357 "devices": {
358 "old": {
359 "serial": "string",
360 "afterAction": "string",
361 "name": "string",
362 "model": "string",
363 "mac": "string",
364 "tags": [
365 "string"
366 ],
367 "rfProfile": {
368 "id": "string",
369 "name": "string"
370 }
371 },
372 "new": {
373 "serial": "string",
374 "name": "string",
375 "model": "string",
376 "mac": "string",
377 "tags": [
378 "string"
379 ],
380 "rfProfile": {
381 "id": "string",
382 "name": "string"
383 }
384 }
385 },
386 "status": "string",
387 "type": "string",
388 "network": {
389 "id": "string",
390 "name": "string"
391 },
392 "createdAt": "string",
393 "requestedAt": "string",
394 "lastUpdatedAt": "string",
395 "completedAt": "string",
396 "errors": [
397 "string"
398 ]
399 }
400 ],
401 "meta": {
402 "counts": {
403 "items": {
404 "total": 0,
405 "remaining": 0
406 }
407 }
408 }
409 }
410 """