files-com 1.6.50__py3-none-any.whl → 1.6.51__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of files-com might be problematic. Click here for more details.
- _VERSION +1 -1
- {files_com-1.6.50.dist-info → files_com-1.6.51.dist-info}/METADATA +1 -1
- {files_com-1.6.50.dist-info → files_com-1.6.51.dist-info}/RECORD +11 -10
- files_sdk/__init__.py +5 -1
- files_sdk/models/__init__.py +3 -0
- files_sdk/models/child_site_management_policy.py +276 -0
- files_sdk/models/remote_server_configuration_file.py +1 -1
- files_sdk/models/site.py +1 -0
- {files_com-1.6.50.dist-info → files_com-1.6.51.dist-info}/WHEEL +0 -0
- {files_com-1.6.50.dist-info → files_com-1.6.51.dist-info}/licenses/LICENSE +0 -0
- {files_com-1.6.50.dist-info → files_com-1.6.51.dist-info}/top_level.txt +0 -0
_VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
1.6.
|
|
1
|
+
1.6.51
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
README.md,sha256=g1DcyvuLNh7PXvgnat7MTirGLA0ck1_aI9_WcjSIXmg,28715
|
|
2
|
-
_VERSION,sha256=
|
|
3
|
-
files_com-1.6.
|
|
4
|
-
files_sdk/__init__.py,sha256=
|
|
2
|
+
_VERSION,sha256=3oYuK5Qu_RzVAx8xrAgwDOpvVPXsMCO9sOkHVVYz9nU,7
|
|
3
|
+
files_com-1.6.51.dist-info/licenses/LICENSE,sha256=ziANl9OTD-5-iE8XYIZNm6IYBDxOCHwQ-mdhci7lNew,1102
|
|
4
|
+
files_sdk/__init__.py,sha256=IE-3YPu3q7uhsu7UiPnuJ1ag9xr-FFVEfwnsYifUTp0,13062
|
|
5
5
|
files_sdk/api.py,sha256=HOLk50HLQCbnHwnAr9OElQEWvdA_BABBSEvvFSt1S4A,1846
|
|
6
6
|
files_sdk/api_client.py,sha256=cfFvm-o4Ao8SWADiJv7t7qnJfG_LJmWV3l6ALTC-Opo,11264
|
|
7
7
|
files_sdk/error.py,sha256=JZD-njfO1NG0xGBc1kExiDUCbq9xT5JHjBv9oBXtJ58,64619
|
|
8
8
|
files_sdk/list_obj.py,sha256=MWgmESLAmfh1uaSw76PWxmnf9f6_08TLUHe8_mCYKL4,1157
|
|
9
9
|
files_sdk/path_util.py,sha256=7x8X3JLoMkcqNefCaBeHYXD8MGvPby4AOy-xnBX_LNk,1694
|
|
10
10
|
files_sdk/util.py,sha256=6aA4N0Wq_ykINW7eMrs2ntFAL2hRLM6IvJf6n_yP34c,962
|
|
11
|
-
files_sdk/models/__init__.py,sha256=
|
|
11
|
+
files_sdk/models/__init__.py,sha256=ntJ8gbCdnr7n8WZ2fK5amENs4blNx6Ay_Z-OnzTluLg,5914
|
|
12
12
|
files_sdk/models/account_line_item.py,sha256=8FLg83Aqpz4y_QYy3fZ_KZsZFWv1f1KGD9T5CH1WSGs,1929
|
|
13
13
|
files_sdk/models/action.py,sha256=M1lyMybE7SKht2nGXtYWp2l8b4oVkeImo6KF8DLiCos,2034
|
|
14
14
|
files_sdk/models/action_notification_export.py,sha256=4cdEo2ZCDV3RH3GLSqHV7RWyJ2ONRSUq0glCEi94zd0,6636
|
|
@@ -33,6 +33,7 @@ files_sdk/models/bundle_notification.py,sha256=tMauRH6qmejEisqsneVeprh4rb6UIjB43
|
|
|
33
33
|
files_sdk/models/bundle_path.py,sha256=UQc3Y1zD6s2AWEoFZ1H5_FuXr3cuNoLw18XGHxauMVA,1249
|
|
34
34
|
files_sdk/models/bundle_recipient.py,sha256=cOn-pPcT5xzQAcSxMYN5RtfdkZ5c5T7yI9J8gVBNmx0,6398
|
|
35
35
|
files_sdk/models/bundle_registration.py,sha256=Igvrg3K2dT0re8MO4hmXg6u02ljiR569nOOyG0L7NHE,3910
|
|
36
|
+
files_sdk/models/child_site_management_policy.py,sha256=shzLh4T7tcMk8tVoqkW7WyX17eUtzChIOXvy3fB0TKQ,10755
|
|
36
37
|
files_sdk/models/clickwrap.py,sha256=6xCBvo38zlA2s7U0lIH1nmbEjv2U2A_FL_5pAtbjkGE,11563
|
|
37
38
|
files_sdk/models/dns_record.py,sha256=iXrDPyaovMmPopCGaiPcK1hcuKCYaqnhnsj0Olxjq8g,2370
|
|
38
39
|
files_sdk/models/email_incoming_message.py,sha256=ciP9FI3wxfC7vqzZ0Cx3-_mszoZKfdFwD1sg6QI7tok,5391
|
|
@@ -84,7 +85,7 @@ files_sdk/models/public_key.py,sha256=0cK38pf_YCYLaS28ipczH5ih53T6y92NPsaynjRAqb
|
|
|
84
85
|
files_sdk/models/remote_bandwidth_snapshot.py,sha256=kryNewGqe_ZN4D3JBL26DoVYKDowubUNLXn7NQtEJb8,4476
|
|
85
86
|
files_sdk/models/remote_mount_backend.py,sha256=u4AmTgGotiXC2l55RbcQKVALCnBwkDO2a-X3Xn3ua98,19265
|
|
86
87
|
files_sdk/models/remote_server.py,sha256=crDqrWv56GEYW49Y0vUiZhXCvjymMyn-ByWmqfEof3k,86036
|
|
87
|
-
files_sdk/models/remote_server_configuration_file.py,sha256=
|
|
88
|
+
files_sdk/models/remote_server_configuration_file.py,sha256=So6cK83z_6xwLnHJYgEwzSb9eBkDK5XG2Q4k8kp9nno,3476
|
|
88
89
|
files_sdk/models/request.py,sha256=mWOS36b5pRiAZqDuf1tGidw-FAikYPDqfv5LXdDJA9Q,8867
|
|
89
90
|
files_sdk/models/restore.py,sha256=ukXp-fwsuGFhWl2ULAEWiKarIY3DjOIk3x3hHlshjqE,6685
|
|
90
91
|
files_sdk/models/session.py,sha256=kgRwlDHDtwyMA3U9rk2T37Wfoo8VVr76vwLcZyaJJxM,3790
|
|
@@ -94,7 +95,7 @@ files_sdk/models/sftp_host_key.py,sha256=3r5noHhRg-Hn3TLGBUDQYayKIw_Dn5waB9YmGSf
|
|
|
94
95
|
files_sdk/models/share_group.py,sha256=rw-W2x5XFBPc48rvazaro28HfjOli885417i702Mowc,9066
|
|
95
96
|
files_sdk/models/share_group_member.py,sha256=m0BUE4AhClJIoaV-_kU0yryCOwQ5EloZlyHQ4WaCVdU,1248
|
|
96
97
|
files_sdk/models/siem_http_destination.py,sha256=mWgfHro5CObkwTYgiWnrREQX2X6zJR389Zw7DJgMFac,50185
|
|
97
|
-
files_sdk/models/site.py,sha256=
|
|
98
|
+
files_sdk/models/site.py,sha256=xTX7iT5Zn5pILfd1bu9AfY1gfV6hxQWZRXPYOpJRyEE,69620
|
|
98
99
|
files_sdk/models/snapshot.py,sha256=zmdQWKR8EhUkF1mFQHFzWfreaEVXG1p_jEtmY4j3cKA,9840
|
|
99
100
|
files_sdk/models/sso_strategy.py,sha256=vWNCPfot8z15xUhAoFsS52W-1vg8IpKIqAALZ6pBwd0,9112
|
|
100
101
|
files_sdk/models/status.py,sha256=IIY3RiJ2RZ2yPByAAh8eIq_cgZFTj13eR4UpqHTANQI,1363
|
|
@@ -112,7 +113,7 @@ files_sdk/models/user_request.py,sha256=ykA5Lq0MYB7qTDOMMFBuyKa_R_LgQwGVorC-q-6q
|
|
|
112
113
|
files_sdk/models/user_sftp_client_use.py,sha256=VnOo3ll6fwSc8grG5ZqGK8o3grYKg5P9b5B_hGS4vCs,2827
|
|
113
114
|
files_sdk/models/web_dav_action_log.py,sha256=uMTIkTgSpW5mgKAEWnCmI4U5eqcAL2g8OHqB-lBir3A,76424
|
|
114
115
|
files_sdk/models/webhook_test.py,sha256=AWGH8ULsgltBJL2YtTYGnAJ80cCVekrjZ2sUP0UlWgc,5018
|
|
115
|
-
files_com-1.6.
|
|
116
|
-
files_com-1.6.
|
|
117
|
-
files_com-1.6.
|
|
118
|
-
files_com-1.6.
|
|
116
|
+
files_com-1.6.51.dist-info/METADATA,sha256=0o6swTpJd6EhNHs_eDa95C7OzYQqQynC6Jtrq4ckIIA,29007
|
|
117
|
+
files_com-1.6.51.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
118
|
+
files_com-1.6.51.dist-info/top_level.txt,sha256=p_2P-gluT_8boeXQNixTP3x-tFd1-la2NedKOiln21I,10
|
|
119
|
+
files_com-1.6.51.dist-info/RECORD,,
|
files_sdk/__init__.py
CHANGED
|
@@ -23,6 +23,7 @@ import files_sdk.models.bundle_notification as bundle_notification
|
|
|
23
23
|
import files_sdk.models.bundle_path as bundle_path
|
|
24
24
|
import files_sdk.models.bundle_recipient as bundle_recipient
|
|
25
25
|
import files_sdk.models.bundle_registration as bundle_registration
|
|
26
|
+
import files_sdk.models.child_site_management_policy as child_site_management_policy
|
|
26
27
|
import files_sdk.models.clickwrap as clickwrap
|
|
27
28
|
import files_sdk.models.dns_record as dns_record
|
|
28
29
|
import files_sdk.models.email_incoming_message as email_incoming_message
|
|
@@ -131,6 +132,9 @@ from files_sdk.models.bundle_notification import BundleNotification
|
|
|
131
132
|
from files_sdk.models.bundle_path import BundlePath
|
|
132
133
|
from files_sdk.models.bundle_recipient import BundleRecipient
|
|
133
134
|
from files_sdk.models.bundle_registration import BundleRegistration
|
|
135
|
+
from files_sdk.models.child_site_management_policy import (
|
|
136
|
+
ChildSiteManagementPolicy,
|
|
137
|
+
)
|
|
134
138
|
from files_sdk.models.clickwrap import Clickwrap
|
|
135
139
|
from files_sdk.models.dns_record import DnsRecord
|
|
136
140
|
from files_sdk.models.email_incoming_message import EmailIncomingMessage
|
|
@@ -223,7 +227,7 @@ session_id = None
|
|
|
223
227
|
source_ip = None
|
|
224
228
|
base_url = "https://app.files.com"
|
|
225
229
|
base_path = "api/rest/v1"
|
|
226
|
-
version = "1.6.
|
|
230
|
+
version = "1.6.51"
|
|
227
231
|
|
|
228
232
|
__version__ = version
|
|
229
233
|
|
files_sdk/models/__init__.py
CHANGED
|
@@ -26,6 +26,9 @@ from files_sdk.models.bundle_notification import BundleNotification
|
|
|
26
26
|
from files_sdk.models.bundle_path import BundlePath
|
|
27
27
|
from files_sdk.models.bundle_recipient import BundleRecipient
|
|
28
28
|
from files_sdk.models.bundle_registration import BundleRegistration
|
|
29
|
+
from files_sdk.models.child_site_management_policy import (
|
|
30
|
+
ChildSiteManagementPolicy,
|
|
31
|
+
)
|
|
29
32
|
from files_sdk.models.clickwrap import Clickwrap
|
|
30
33
|
from files_sdk.models.dns_record import DnsRecord
|
|
31
34
|
from files_sdk.models.email_incoming_message import EmailIncomingMessage
|
|
@@ -0,0 +1,276 @@
|
|
|
1
|
+
import builtins # noqa: F401
|
|
2
|
+
from files_sdk.api import Api # noqa: F401
|
|
3
|
+
from files_sdk.list_obj import ListObj
|
|
4
|
+
from files_sdk.error import ( # noqa: F401
|
|
5
|
+
InvalidParameterError,
|
|
6
|
+
MissingParameterError,
|
|
7
|
+
NotImplementedError,
|
|
8
|
+
)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class ChildSiteManagementPolicy:
|
|
12
|
+
default_attributes = {
|
|
13
|
+
"id": None, # int64 - ChildSiteManagementPolicy ID
|
|
14
|
+
"site_id": None, # int64 - ID of the Site managing the policy
|
|
15
|
+
"site_setting_name": None, # string - The name of the setting that is managed by the policy
|
|
16
|
+
"managed_value": None, # string - The value for the setting that will be enforced for all child sites that are not exempt
|
|
17
|
+
"skip_child_site_ids": None, # array(int64) - The list of child site IDs that are exempt from this policy
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
def __init__(self, attributes=None, options=None):
|
|
21
|
+
if not isinstance(attributes, dict):
|
|
22
|
+
attributes = {}
|
|
23
|
+
if not isinstance(options, dict):
|
|
24
|
+
options = {}
|
|
25
|
+
self.set_attributes(attributes)
|
|
26
|
+
self.options = options
|
|
27
|
+
|
|
28
|
+
def set_attributes(self, attributes):
|
|
29
|
+
for (
|
|
30
|
+
attribute,
|
|
31
|
+
default_value,
|
|
32
|
+
) in ChildSiteManagementPolicy.default_attributes.items():
|
|
33
|
+
setattr(self, attribute, attributes.get(attribute, default_value))
|
|
34
|
+
|
|
35
|
+
def get_attributes(self):
|
|
36
|
+
return {
|
|
37
|
+
k: getattr(self, k, None)
|
|
38
|
+
for k in ChildSiteManagementPolicy.default_attributes
|
|
39
|
+
if getattr(self, k, None) is not None
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
# Parameters:
|
|
43
|
+
# site_setting_name (required) - string - The name of the setting that is managed by the policy
|
|
44
|
+
# managed_value (required) - string - The value for the setting that will be enforced for all child sites that are not exempt
|
|
45
|
+
# skip_child_site_ids - array(int64) - The list of child site IDs that are exempt from this policy
|
|
46
|
+
def update(self, params=None):
|
|
47
|
+
if not isinstance(params, dict):
|
|
48
|
+
params = {}
|
|
49
|
+
|
|
50
|
+
if hasattr(self, "id") and self.id:
|
|
51
|
+
params["id"] = self.id
|
|
52
|
+
else:
|
|
53
|
+
raise MissingParameterError("Current object doesn't have a id")
|
|
54
|
+
if "id" not in params:
|
|
55
|
+
raise MissingParameterError("Parameter missing: id")
|
|
56
|
+
if "site_setting_name" not in params:
|
|
57
|
+
raise MissingParameterError("Parameter missing: site_setting_name")
|
|
58
|
+
if "managed_value" not in params:
|
|
59
|
+
raise MissingParameterError("Parameter missing: managed_value")
|
|
60
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
61
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
62
|
+
if "site_setting_name" in params and not isinstance(
|
|
63
|
+
params["site_setting_name"], str
|
|
64
|
+
):
|
|
65
|
+
raise InvalidParameterError(
|
|
66
|
+
"Bad parameter: site_setting_name must be an str"
|
|
67
|
+
)
|
|
68
|
+
if "managed_value" in params and not isinstance(
|
|
69
|
+
params["managed_value"], str
|
|
70
|
+
):
|
|
71
|
+
raise InvalidParameterError(
|
|
72
|
+
"Bad parameter: managed_value must be an str"
|
|
73
|
+
)
|
|
74
|
+
if "skip_child_site_ids" in params and not isinstance(
|
|
75
|
+
params["skip_child_site_ids"], builtins.list
|
|
76
|
+
):
|
|
77
|
+
raise InvalidParameterError(
|
|
78
|
+
"Bad parameter: skip_child_site_ids must be an list"
|
|
79
|
+
)
|
|
80
|
+
response, _options = Api.send_request(
|
|
81
|
+
"PATCH",
|
|
82
|
+
"/child_site_management_policies/{id}".format(id=params["id"]),
|
|
83
|
+
params,
|
|
84
|
+
self.options,
|
|
85
|
+
)
|
|
86
|
+
return response.data
|
|
87
|
+
|
|
88
|
+
def delete(self, params=None):
|
|
89
|
+
if not isinstance(params, dict):
|
|
90
|
+
params = {}
|
|
91
|
+
|
|
92
|
+
if hasattr(self, "id") and self.id:
|
|
93
|
+
params["id"] = self.id
|
|
94
|
+
else:
|
|
95
|
+
raise MissingParameterError("Current object doesn't have a id")
|
|
96
|
+
if "id" not in params:
|
|
97
|
+
raise MissingParameterError("Parameter missing: id")
|
|
98
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
99
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
100
|
+
Api.send_request(
|
|
101
|
+
"DELETE",
|
|
102
|
+
"/child_site_management_policies/{id}".format(id=params["id"]),
|
|
103
|
+
params,
|
|
104
|
+
self.options,
|
|
105
|
+
)
|
|
106
|
+
|
|
107
|
+
def destroy(self, params=None):
|
|
108
|
+
self.delete(params)
|
|
109
|
+
|
|
110
|
+
def save(self):
|
|
111
|
+
if hasattr(self, "id") and self.id:
|
|
112
|
+
new_obj = self.update(self.get_attributes())
|
|
113
|
+
self.set_attributes(new_obj.get_attributes())
|
|
114
|
+
return True
|
|
115
|
+
else:
|
|
116
|
+
new_obj = create(self.get_attributes(), self.options)
|
|
117
|
+
self.set_attributes(new_obj.get_attributes())
|
|
118
|
+
return True
|
|
119
|
+
|
|
120
|
+
|
|
121
|
+
# Parameters:
|
|
122
|
+
# cursor - string - Used for pagination. When a list request has more records available, cursors are provided in the response headers `X-Files-Cursor-Next` and `X-Files-Cursor-Prev`. Send one of those cursor value here to resume an existing list from the next available record. Note: many of our SDKs have iterator methods that will automatically handle cursor-based pagination.
|
|
123
|
+
# per_page - int64 - Number of records to show per page. (Max: 10,000, 1,000 or less is recommended).
|
|
124
|
+
def list(params=None, options=None):
|
|
125
|
+
if not isinstance(params, dict):
|
|
126
|
+
params = {}
|
|
127
|
+
if not isinstance(options, dict):
|
|
128
|
+
options = {}
|
|
129
|
+
if "cursor" in params and not isinstance(params["cursor"], str):
|
|
130
|
+
raise InvalidParameterError("Bad parameter: cursor must be an str")
|
|
131
|
+
if "per_page" in params and not isinstance(params["per_page"], int):
|
|
132
|
+
raise InvalidParameterError("Bad parameter: per_page must be an int")
|
|
133
|
+
return ListObj(
|
|
134
|
+
ChildSiteManagementPolicy,
|
|
135
|
+
"GET",
|
|
136
|
+
"/child_site_management_policies",
|
|
137
|
+
params,
|
|
138
|
+
options,
|
|
139
|
+
)
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
def all(params=None, options=None):
|
|
143
|
+
list(params, options)
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
# Parameters:
|
|
147
|
+
# id (required) - int64 - Child Site Management Policy ID.
|
|
148
|
+
def find(id, params=None, options=None):
|
|
149
|
+
if not isinstance(params, dict):
|
|
150
|
+
params = {}
|
|
151
|
+
if not isinstance(options, dict):
|
|
152
|
+
options = {}
|
|
153
|
+
params["id"] = id
|
|
154
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
155
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
156
|
+
if "id" not in params:
|
|
157
|
+
raise MissingParameterError("Parameter missing: id")
|
|
158
|
+
response, options = Api.send_request(
|
|
159
|
+
"GET",
|
|
160
|
+
"/child_site_management_policies/{id}".format(id=params["id"]),
|
|
161
|
+
params,
|
|
162
|
+
options,
|
|
163
|
+
)
|
|
164
|
+
return ChildSiteManagementPolicy(response.data, options)
|
|
165
|
+
|
|
166
|
+
|
|
167
|
+
def get(id, params=None, options=None):
|
|
168
|
+
find(id, params, options)
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
# Parameters:
|
|
172
|
+
# site_setting_name (required) - string - The name of the setting that is managed by the policy
|
|
173
|
+
# managed_value (required) - string - The value for the setting that will be enforced for all child sites that are not exempt
|
|
174
|
+
# skip_child_site_ids - array(int64) - The list of child site IDs that are exempt from this policy
|
|
175
|
+
def create(params=None, options=None):
|
|
176
|
+
if not isinstance(params, dict):
|
|
177
|
+
params = {}
|
|
178
|
+
if not isinstance(options, dict):
|
|
179
|
+
options = {}
|
|
180
|
+
if "site_setting_name" in params and not isinstance(
|
|
181
|
+
params["site_setting_name"], str
|
|
182
|
+
):
|
|
183
|
+
raise InvalidParameterError(
|
|
184
|
+
"Bad parameter: site_setting_name must be an str"
|
|
185
|
+
)
|
|
186
|
+
if "managed_value" in params and not isinstance(
|
|
187
|
+
params["managed_value"], str
|
|
188
|
+
):
|
|
189
|
+
raise InvalidParameterError(
|
|
190
|
+
"Bad parameter: managed_value must be an str"
|
|
191
|
+
)
|
|
192
|
+
if "skip_child_site_ids" in params and not isinstance(
|
|
193
|
+
params["skip_child_site_ids"], builtins.list
|
|
194
|
+
):
|
|
195
|
+
raise InvalidParameterError(
|
|
196
|
+
"Bad parameter: skip_child_site_ids must be an list"
|
|
197
|
+
)
|
|
198
|
+
if "site_setting_name" not in params:
|
|
199
|
+
raise MissingParameterError("Parameter missing: site_setting_name")
|
|
200
|
+
if "managed_value" not in params:
|
|
201
|
+
raise MissingParameterError("Parameter missing: managed_value")
|
|
202
|
+
response, options = Api.send_request(
|
|
203
|
+
"POST", "/child_site_management_policies", params, options
|
|
204
|
+
)
|
|
205
|
+
return ChildSiteManagementPolicy(response.data, options)
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
# Parameters:
|
|
209
|
+
# site_setting_name (required) - string - The name of the setting that is managed by the policy
|
|
210
|
+
# managed_value (required) - string - The value for the setting that will be enforced for all child sites that are not exempt
|
|
211
|
+
# skip_child_site_ids - array(int64) - The list of child site IDs that are exempt from this policy
|
|
212
|
+
def update(id, params=None, options=None):
|
|
213
|
+
if not isinstance(params, dict):
|
|
214
|
+
params = {}
|
|
215
|
+
if not isinstance(options, dict):
|
|
216
|
+
options = {}
|
|
217
|
+
params["id"] = id
|
|
218
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
219
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
220
|
+
if "site_setting_name" in params and not isinstance(
|
|
221
|
+
params["site_setting_name"], str
|
|
222
|
+
):
|
|
223
|
+
raise InvalidParameterError(
|
|
224
|
+
"Bad parameter: site_setting_name must be an str"
|
|
225
|
+
)
|
|
226
|
+
if "managed_value" in params and not isinstance(
|
|
227
|
+
params["managed_value"], str
|
|
228
|
+
):
|
|
229
|
+
raise InvalidParameterError(
|
|
230
|
+
"Bad parameter: managed_value must be an str"
|
|
231
|
+
)
|
|
232
|
+
if "skip_child_site_ids" in params and not isinstance(
|
|
233
|
+
params["skip_child_site_ids"], builtins.list
|
|
234
|
+
):
|
|
235
|
+
raise InvalidParameterError(
|
|
236
|
+
"Bad parameter: skip_child_site_ids must be an list"
|
|
237
|
+
)
|
|
238
|
+
if "id" not in params:
|
|
239
|
+
raise MissingParameterError("Parameter missing: id")
|
|
240
|
+
if "site_setting_name" not in params:
|
|
241
|
+
raise MissingParameterError("Parameter missing: site_setting_name")
|
|
242
|
+
if "managed_value" not in params:
|
|
243
|
+
raise MissingParameterError("Parameter missing: managed_value")
|
|
244
|
+
response, options = Api.send_request(
|
|
245
|
+
"PATCH",
|
|
246
|
+
"/child_site_management_policies/{id}".format(id=params["id"]),
|
|
247
|
+
params,
|
|
248
|
+
options,
|
|
249
|
+
)
|
|
250
|
+
return ChildSiteManagementPolicy(response.data, options)
|
|
251
|
+
|
|
252
|
+
|
|
253
|
+
def delete(id, params=None, options=None):
|
|
254
|
+
if not isinstance(params, dict):
|
|
255
|
+
params = {}
|
|
256
|
+
if not isinstance(options, dict):
|
|
257
|
+
options = {}
|
|
258
|
+
params["id"] = id
|
|
259
|
+
if "id" in params and not isinstance(params["id"], int):
|
|
260
|
+
raise InvalidParameterError("Bad parameter: id must be an int")
|
|
261
|
+
if "id" not in params:
|
|
262
|
+
raise MissingParameterError("Parameter missing: id")
|
|
263
|
+
Api.send_request(
|
|
264
|
+
"DELETE",
|
|
265
|
+
"/child_site_management_policies/{id}".format(id=params["id"]),
|
|
266
|
+
params,
|
|
267
|
+
options,
|
|
268
|
+
)
|
|
269
|
+
|
|
270
|
+
|
|
271
|
+
def destroy(id, params=None, options=None):
|
|
272
|
+
delete(id, params, options)
|
|
273
|
+
|
|
274
|
+
|
|
275
|
+
def new(*args, **kwargs):
|
|
276
|
+
return ChildSiteManagementPolicy(*args, **kwargs)
|
|
@@ -36,7 +36,7 @@ class RemoteServerConfigurationFile:
|
|
|
36
36
|
# * 10 requests/minute: '10-M'
|
|
37
37
|
# * 1000 requests/hour: '1000-H'
|
|
38
38
|
# * 2000 requests/day: '2000-D'
|
|
39
|
-
"auto_update_policy": None, # string - Auto update policy ['manual_trigger', 'critical_only', 'always'] (default critical_only)
|
|
39
|
+
"auto_update_policy": None, # string - Auto update policy ['manual_trigger', 'critical_only', 'always', 'never'] (default critical_only)
|
|
40
40
|
"api_token": None, # string - Files Agent API Token
|
|
41
41
|
"port": None, # int64 - Incoming port for files agent connections
|
|
42
42
|
"hostname": None, # string
|
files_sdk/models/site.py
CHANGED
|
@@ -181,6 +181,7 @@ class Site:
|
|
|
181
181
|
"welcome_screen": None, # string - Does the welcome screen appear?
|
|
182
182
|
"windows_mode_ftp": None, # boolean - Does FTP user Windows emulation mode?
|
|
183
183
|
"group_admins_can_set_user_password": None, # boolean - Allow group admins set password authentication method
|
|
184
|
+
"managed_site_settings": None, # array(string) - List of site settings managed by the parent site
|
|
184
185
|
}
|
|
185
186
|
|
|
186
187
|
def __init__(self, attributes=None, options=None):
|
|
File without changes
|
|
File without changes
|
|
File without changes
|