Debian Codegraph @

ansible_collections/cisco/meraki/plugins/modules/organizations_snmp.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_snmp
9 short_description: Resource module for organizations _snmp
10 description:
11 - Manage operation update of the resource organizations _snmp.
12 - Update the SNMP settings for an organization.
13 version_added: '1.0.0'
14 extends_documentation_fragment:
15 - cisco.meraki.module
16 author: Francisco Munoz (@fmunoz)
17 options:
18 organizationId:
19 description: OrganizationId path parameter. Organization ID.
20 type: str
21 peerIps:
22 description: The list of IPv4 addresses that are allowed to access the SNMP server.
23 elements: str
24 type: list
25 v2cEnabled:
26 description: Boolean indicating whether SNMP version 2c is enabled for the organization.
27 type: bool
28 v3AuthMode:
29 description: The SNMP version 3 authentication mode. Can be either 'MD5' or 'SHA'.
30 type: str
31 v3AuthPass:
32 description: The SNMP version 3 authentication password. Must be at least 8 characters
33 if specified.
34 type: str
35 v3Enabled:
36 description: Boolean indicating whether SNMP version 3 is enabled for the organization.
37 type: bool
38 v3PrivMode:
39 description: The SNMP version 3 privacy mode. Can be either 'DES' or 'AES128'.
40 type: str
41 v3PrivPass:
42 description: The SNMP version 3 privacy password. Must be at least 8 characters
43 if specified.
44 type: str
45 requirements:
46 - meraki >= 2.4.9
47 - python >= 3.5
48 seealso:
49 - name: Cisco Meraki documentation for organizations updateOrganizationSnmp
50 description: Complete reference of the updateOrganizationSnmp API.
51 link: https://developer.cisco.com/meraki/api-v1/#!update-organization-snmp
52 notes:
53 - SDK Method used are
54 organizations.Organizations.update_organization_snmp,
55 - Paths used are
56 put /organizations/{organizationId}/snmp,
57 """
58
59 EXAMPLES = r"""
60 - name: Update all
61 cisco.meraki.organizations_snmp:
62 meraki_api_key: "{{ meraki_api_key }}"
63 meraki_base_url: "{{ meraki_base_url }}"
64 meraki_single_request_timeout: "{{ meraki_single_request_timeout }}"
65 meraki_certificate_path: "{{ meraki_certificate_path }}"
66 meraki_requests_proxy: "{{ meraki_requests_proxy }}"
67 meraki_wait_on_rate_limit: "{{ meraki_wait_on_rate_limit }}"
68 meraki_nginx_429_retry_wait_time: "{{ meraki_nginx_429_retry_wait_time }}"
69 meraki_action_batch_retry_wait_time: "{{ meraki_action_batch_retry_wait_time }}"
70 meraki_retry_4xx_error: "{{ meraki_retry_4xx_error }}"
71 meraki_retry_4xx_error_wait_time: "{{ meraki_retry_4xx_error_wait_time }}"
72 meraki_maximum_retries: "{{ meraki_maximum_retries }}"
73 meraki_output_log: "{{ meraki_output_log }}"
74 meraki_log_file_prefix: "{{ meraki_log_file_prefix }}"
75 meraki_log_path: "{{ meraki_log_path }}"
76 meraki_print_console: "{{ meraki_print_console }}"
77 meraki_suppress_logging: "{{ meraki_suppress_logging }}"
78 meraki_simulate: "{{ meraki_simulate }}"
79 meraki_be_geo_id: "{{ meraki_be_geo_id }}"
80 meraki_caller: "{{ meraki_caller }}"
81 meraki_use_iterator_for_get_pages: "{{ meraki_use_iterator_for_get_pages }}"
82 meraki_inherit_logging_config: "{{ meraki_inherit_logging_config }}"
83 state: present
84 organizationId: string
85 peerIps:
86 - 123.123.123.1
87 v2cEnabled: false
88 v3AuthMode: SHA
89 v3AuthPass: password
90 v3Enabled: true
91 v3PrivMode: AES128
92 v3PrivPass: password
93 """
94 RETURN = r"""
95 meraki_response:
96 description: A dictionary or list with the response returned by the Cisco Meraki Python SDK
97 returned: always
98 type: dict
99 sample: >
100 {
101 "v2cEnabled": true,
102 "v2CommunityString": "string",
103 "v3Enabled": true,
104 "v3User": "string",
105 "v3AuthMode": "string",
106 "v3PrivMode": "string",
107 "peerIps": [
108 "string"
109 ],
110 "hostname": "string",
111 "port": 0
112 }
113 """