33from ucloud .core .typesystem import schema , fields
44
55
6- class AccessConfSchema (schema .ResponseSchema ):
7- """AccessConf - 访问控制"""
8-
9- fields = {
10- "IpBlacklist" : fields .Str (required = False , load_from = "IpBlacklist" ),
11- }
12-
13-
146class CacheConfSchema (schema .ResponseSchema ):
157 """CacheConf - 缓存配置"""
168
@@ -29,6 +21,14 @@ class CacheConfSchema(schema.ResponseSchema):
2921 }
3022
3123
24+ class AccessConfSchema (schema .ResponseSchema ):
25+ """AccessConf - 访问控制"""
26+
27+ fields = {
28+ "IpBlacklist" : fields .Str (required = False , load_from = "IpBlacklist" ),
29+ }
30+
31+
3232class DomainInfoSchema (schema .ResponseSchema ):
3333 """DomainInfo - 域名配置"""
3434
@@ -218,23 +218,52 @@ class RequestInfoSchema(schema.ResponseSchema):
218218 }
219219
220220
221- class BandwidthTrafficInfoSchema (schema .ResponseSchema ):
222- """BandwidthTrafficInfo - BandwidthTrafficInfo """
221+ class RefererListSchema (schema .ResponseSchema ):
222+ """RefererList - RefererList """
223223
224224 fields = {
225- "CdnBandwidth " : fields .Float (required = True , load_from = "CdnBandwidth " ),
226- "Time " : fields .Int (required = True , load_from = "Time " ),
227- "Traffic " : fields .Float (required = True , load_from = "Traffic " ),
225+ "Percent " : fields .Float (required = False , load_from = "Percent " ),
226+ "Referer " : fields .Str (required = False , load_from = "Referer " ),
227+ "RequestTimes " : fields .Int (required = False , load_from = "RequestTimes " ),
228228 }
229229
230230
231- class ReferConfSchema (schema .ResponseSchema ):
232- """ReferConf - refer配置 """
231+ class RefererStatisticsSchema (schema .ResponseSchema ):
232+ """RefererStatistics - RefererStatistics """
233233
234234 fields = {
235- "NullRefer" : fields .Int (required = False , load_from = "NullRefer" ),
236- "ReferList" : fields .List (fields .Str ()),
237- "ReferType" : fields .Int (required = False , load_from = "ReferType" ),
235+ "Date" : fields .Str (required = False , load_from = "Date" ),
236+ "RefererList" : fields .List (RefererListSchema ()),
237+ }
238+
239+
240+ class DownloadStatisticInfoSchema (schema .ResponseSchema ):
241+ """DownloadStatisticInfo - DownloadStatisticInfo"""
242+
243+ fields = {
244+ "DownloadTimes" : fields .Int (required = False , load_from = "DownloadTimes" ),
245+ "Percent" : fields .Float (required = False , load_from = "Percent" ),
246+ "Traffic" : fields .Float (required = False , load_from = "Traffic" ),
247+ "Url" : fields .Str (required = False , load_from = "Url" ),
248+ }
249+
250+
251+ class UrlStatisticsSchema (schema .ResponseSchema ):
252+ """UrlStatistics - UrlStatistics"""
253+
254+ fields = {
255+ "Date" : fields .Str (required = False , load_from = "Date" ),
256+ "UrlList" : fields .List (DownloadStatisticInfoSchema ()),
257+ }
258+
259+
260+ class BandwidthTrafficInfoSchema (schema .ResponseSchema ):
261+ """BandwidthTrafficInfo - BandwidthTrafficInfo"""
262+
263+ fields = {
264+ "CdnBandwidth" : fields .Float (required = True , load_from = "CdnBandwidth" ),
265+ "Time" : fields .Int (required = True , load_from = "Time" ),
266+ "Traffic" : fields .Float (required = True , load_from = "Traffic" ),
238267 }
239268
240269
@@ -248,12 +277,13 @@ class CacheKeyInfoSchema(schema.ResponseSchema):
248277 }
249278
250279
251- class AccessControlConfSchema (schema .ResponseSchema ):
252- """AccessControlConf - 访问控制配置参数 """
280+ class ReferConfSchema (schema .ResponseSchema ):
281+ """ReferConf - refer配置 """
253282
254283 fields = {
255- "IpBlackList" : fields .List (fields .Str ()),
256- "ReferConf" : ReferConfSchema (),
284+ "NullRefer" : fields .Int (required = False , load_from = "NullRefer" ),
285+ "ReferList" : fields .List (fields .Str ()),
286+ "ReferType" : fields .Int (required = False , load_from = "ReferType" ),
257287 }
258288
259289
@@ -307,6 +337,15 @@ class OriginConfSchema(schema.ResponseSchema):
307337 }
308338
309339
340+ class AccessControlConfSchema (schema .ResponseSchema ):
341+ """AccessControlConf - 访问控制配置参数"""
342+
343+ fields = {
344+ "IpBlackList" : fields .List (fields .Str ()),
345+ "ReferConf" : ReferConfSchema (),
346+ }
347+
348+
310349class DomainConfigInfoSchema (schema .ResponseSchema ):
311350 """DomainConfigInfo - 更新域名配置"""
312351
0 commit comments