gcore 0.8.0__py3-none-any.whl → 0.10.0__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 gcore might be problematic. Click here for more details.

Files changed (164) hide show
  1. gcore/_base_client.py +4 -1
  2. gcore/_client.py +9 -0
  3. gcore/_files.py +4 -4
  4. gcore/_version.py +1 -1
  5. gcore/resources/__init__.py +14 -0
  6. gcore/resources/cloud/cost_reports.py +24 -0
  7. gcore/resources/cloud/load_balancers/pools/health_monitors.py +8 -4
  8. gcore/resources/cloud/load_balancers/pools/members.py +2 -2
  9. gcore/resources/cloud/quotas/requests.py +7 -15
  10. gcore/resources/fastedge/binaries.py +81 -1
  11. gcore/resources/security/__init__.py +75 -0
  12. gcore/resources/security/bgp_announces.py +308 -0
  13. gcore/resources/security/events.py +234 -0
  14. gcore/resources/security/profile_templates.py +143 -0
  15. gcore/resources/security/profiles.py +661 -0
  16. gcore/resources/security/security.py +198 -0
  17. gcore/resources/waap/__init__.py +14 -0
  18. gcore/resources/waap/custom_page_sets.py +40 -34
  19. gcore/resources/waap/domains/__init__.py +14 -28
  20. gcore/resources/waap/domains/advanced_rules.py +5 -8
  21. gcore/resources/waap/domains/{api_discovery/api_discovery.py → api_discovery.py} +292 -59
  22. gcore/resources/waap/domains/api_path_groups.py +5 -5
  23. gcore/resources/waap/domains/api_paths.py +15 -17
  24. gcore/resources/waap/domains/custom_rules.py +5 -8
  25. gcore/resources/waap/domains/domains.py +120 -64
  26. gcore/resources/waap/domains/firewall_rules.py +3 -5
  27. gcore/resources/waap/domains/insight_silences.py +28 -5
  28. gcore/resources/waap/domains/insights.py +36 -10
  29. gcore/resources/waap/domains/{analytics/analytics.py → statistics.py} +514 -213
  30. gcore/resources/waap/insights.py +233 -0
  31. gcore/resources/waap/ip_info/__init__.py +33 -0
  32. gcore/resources/waap/{ip_info.py → ip_info/ip_info.py} +149 -235
  33. gcore/resources/waap/ip_info/metrics.py +203 -0
  34. gcore/resources/waap/waap.py +40 -8
  35. gcore/types/cloud/cost_report_get_aggregated_monthly_params.py +3 -0
  36. gcore/types/cloud/cost_report_get_aggregated_params.py +3 -0
  37. gcore/types/cloud/cost_report_get_detailed_params.py +3 -0
  38. gcore/types/cloud/gpu_baremetal_flavor.py +16 -0
  39. gcore/types/cloud/health_monitor.py +6 -0
  40. gcore/types/cloud/load_balancer_create_params.py +8 -3
  41. gcore/types/cloud/load_balancers/pool_create_params.py +8 -3
  42. gcore/types/cloud/load_balancers/pool_update_params.py +8 -3
  43. gcore/types/cloud/load_balancers/pools/health_monitor_create_params.py +7 -2
  44. gcore/types/cloud/load_balancers/pools/member_add_params.py +1 -1
  45. gcore/types/cloud/quotas/request_list_params.py +2 -2
  46. gcore/types/cloud/region.py +6 -6
  47. gcore/types/fastedge/__init__.py +1 -0
  48. gcore/types/fastedge/binary_create_params.py +11 -0
  49. gcore/types/security/__init__.py +18 -0
  50. gcore/types/security/bgp_announce_list_params.py +18 -0
  51. gcore/types/security/bgp_announce_list_response.py +10 -0
  52. gcore/types/security/bgp_announce_toggle_params.py +16 -0
  53. gcore/types/security/client_announce.py +15 -0
  54. gcore/types/security/client_profile.py +56 -0
  55. gcore/types/security/client_profile_template.py +43 -0
  56. gcore/types/security/client_view.py +29 -0
  57. gcore/types/security/event_list_params.py +38 -0
  58. gcore/types/security/profile_create_params.py +24 -0
  59. gcore/types/security/profile_list_params.py +17 -0
  60. gcore/types/security/profile_list_response.py +10 -0
  61. gcore/types/security/profile_recreate_params.py +24 -0
  62. gcore/types/security/profile_replace_params.py +24 -0
  63. gcore/types/security/profile_template_list_response.py +10 -0
  64. gcore/types/waap/__init__.py +6 -54
  65. gcore/types/waap/custom_page_set_create_params.py +121 -14
  66. gcore/types/waap/custom_page_set_preview_params.py +11 -4
  67. gcore/types/waap/custom_page_set_update_params.py +122 -15
  68. gcore/types/waap/domain_list_params.py +1 -3
  69. gcore/types/waap/domains/__init__.py +28 -18
  70. gcore/types/waap/domains/advanced_rule_list_params.py +1 -3
  71. gcore/types/waap/domains/{api_discovery/scan_result_list_params.py → api_discovery_list_scan_results_params.py} +2 -2
  72. gcore/types/waap/domains/{api_path_group_list_response.py → api_path_group_list.py} +2 -2
  73. gcore/types/waap/domains/custom_rule_list_params.py +1 -3
  74. gcore/types/waap/domains/insight_list_params.py +16 -6
  75. gcore/types/waap/domains/insight_replace_params.py +2 -4
  76. gcore/types/waap/domains/insight_silence_list_params.py +13 -4
  77. gcore/types/waap/domains/{analytics_list_ddos_attacks_params.py → statistic_get_ddos_attacks_params.py} +2 -2
  78. gcore/types/waap/domains/{analytics_list_ddos_info_params.py → statistic_get_ddos_info_params.py} +2 -2
  79. gcore/types/waap/domains/{analytics_get_event_statistics_params.py → statistic_get_events_aggregated_params.py} +2 -2
  80. gcore/types/waap/domains/{analytics/request_list_params.py → statistic_get_requests_series_params.py} +27 -5
  81. gcore/types/waap/domains/{analytics_list_event_traffic_params.py → statistic_get_traffic_series_params.py} +4 -5
  82. gcore/types/waap/domains/statistic_get_traffic_series_response.py +10 -0
  83. gcore/types/waap/{waap_advanced_rule.py → domains/waap_advanced_rule.py} +1 -1
  84. gcore/types/waap/domains/{api_discovery_get_settings_response.py → waap_api_discovery_settings.py} +2 -2
  85. gcore/types/waap/domains/{api_path_get_response.py → waap_api_path.py} +2 -2
  86. gcore/types/waap/domains/{api_discovery/scan_result_get_response.py → waap_api_scan_result.py} +3 -3
  87. gcore/types/waap/{waap_blocked_statistics.py → domains/waap_blocked_statistics.py} +1 -1
  88. gcore/types/waap/{waap_count_statistics.py → domains/waap_count_statistics.py} +1 -1
  89. gcore/types/waap/{waap_custom_rule.py → domains/waap_custom_rule.py} +1 -1
  90. gcore/types/waap/{waap_ddos_attack.py → domains/waap_ddos_attack.py} +1 -1
  91. gcore/types/waap/{waap_ddos_info.py → domains/waap_ddos_info.py} +1 -1
  92. gcore/types/waap/{waap_event_statistics.py → domains/waap_event_statistics.py} +1 -1
  93. gcore/types/waap/{waap_firewall_rule.py → domains/waap_firewall_rule.py} +1 -1
  94. gcore/types/waap/{waap_insight.py → domains/waap_insight.py} +3 -3
  95. gcore/types/waap/{waap_insight_silence.py → domains/waap_insight_silence.py} +1 -1
  96. gcore/types/waap/domains/waap_request_details.py +185 -0
  97. gcore/types/waap/{waap_request_summary.py → domains/waap_request_summary.py} +1 -1
  98. gcore/types/waap/domains/{api_discovery_scan_openapi_response.py → waap_task_id.py} +2 -2
  99. gcore/types/waap/{waap_traffic_metrics.py → domains/waap_traffic_metrics.py} +1 -1
  100. gcore/types/waap/insight_list_types_params.py +28 -0
  101. gcore/types/waap/ip_info/__init__.py +6 -0
  102. gcore/types/waap/{ip_info_get_counts_params.py → ip_info/metric_list_params.py} +2 -2
  103. gcore/types/waap/{waap_ip_info_counts.py → ip_info/waap_ip_info_counts.py} +1 -1
  104. gcore/types/waap/{ip_info_get_params.py → ip_info_get_ip_info_params.py} +2 -2
  105. gcore/types/waap/{waap_ip_info.py → ip_info_get_ip_info_response.py} +2 -2
  106. gcore/types/waap/ip_info_get_top_urls_response.py +12 -3
  107. gcore/types/waap/{ip_info_get_top_sessions_params.py → ip_info_get_top_user_sessions_params.py} +2 -2
  108. gcore/types/waap/{ip_info_get_top_sessions_response.py → ip_info_get_top_user_sessions_response.py} +2 -2
  109. gcore/types/waap/waap_custom_page_set.py +113 -13
  110. gcore/types/waap/waap_detailed_domain.py +2 -2
  111. gcore/types/waap/waap_insight_type.py +33 -0
  112. gcore/types/waap/waap_rule_set.py +26 -3
  113. gcore/types/waap/waap_summary_domain.py +2 -2
  114. {gcore-0.8.0.dist-info → gcore-0.10.0.dist-info}/METADATA +1 -1
  115. {gcore-0.8.0.dist-info → gcore-0.10.0.dist-info}/RECORD +117 -134
  116. gcore/resources/waap/domains/analytics/__init__.py +0 -33
  117. gcore/resources/waap/domains/analytics/requests.py +0 -378
  118. gcore/resources/waap/domains/api_discovery/__init__.py +0 -33
  119. gcore/resources/waap/domains/api_discovery/scan_results.py +0 -352
  120. gcore/resources/waap/domains/policies.py +0 -173
  121. gcore/types/waap/domains/analytics/__init__.py +0 -5
  122. gcore/types/waap/domains/analytics_list_event_traffic_response.py +0 -10
  123. gcore/types/waap/domains/api_discovery/__init__.py +0 -7
  124. gcore/types/waap/domains/api_discovery/scan_result_list_response.py +0 -29
  125. gcore/types/waap/domains/api_discovery_update_settings_response.py +0 -36
  126. gcore/types/waap/domains/api_discovery_upload_openapi_response.py +0 -10
  127. gcore/types/waap/domains/api_path_create_response.py +0 -50
  128. gcore/types/waap/domains/api_path_list_response.py +0 -50
  129. gcore/types/waap/waap_block_csrf_page_data.py +0 -28
  130. gcore/types/waap/waap_block_csrf_page_data_param.py +0 -28
  131. gcore/types/waap/waap_block_page_data.py +0 -28
  132. gcore/types/waap/waap_block_page_data_param.py +0 -28
  133. gcore/types/waap/waap_captcha_page_data.py +0 -31
  134. gcore/types/waap/waap_captcha_page_data_param.py +0 -31
  135. gcore/types/waap/waap_common_tag.py +0 -16
  136. gcore/types/waap/waap_cookie_disabled_page_data.py +0 -18
  137. gcore/types/waap/waap_cookie_disabled_page_data_param.py +0 -18
  138. gcore/types/waap/waap_customer_rule_state.py +0 -7
  139. gcore/types/waap/waap_domain_policy.py +0 -29
  140. gcore/types/waap/waap_domain_status.py +0 -7
  141. gcore/types/waap/waap_handshake_page_data.py +0 -25
  142. gcore/types/waap/waap_handshake_page_data_param.py +0 -25
  143. gcore/types/waap/waap_insight_silence_sort_by.py +0 -9
  144. gcore/types/waap/waap_insight_sort_by.py +0 -20
  145. gcore/types/waap/waap_insight_status.py +0 -7
  146. gcore/types/waap/waap_javascript_disabled_page_data.py +0 -18
  147. gcore/types/waap/waap_javascript_disabled_page_data_param.py +0 -18
  148. gcore/types/waap/waap_network_details.py +0 -17
  149. gcore/types/waap/waap_page_type.py +0 -9
  150. gcore/types/waap/waap_paginated_custom_page_set.py +0 -22
  151. gcore/types/waap/waap_paginated_ddos_attack.py +0 -22
  152. gcore/types/waap/waap_paginated_ddos_info.py +0 -22
  153. gcore/types/waap/waap_paginated_request_summary.py +0 -22
  154. gcore/types/waap/waap_pattern_matched_tag.py +0 -37
  155. gcore/types/waap/waap_policy_action.py +0 -7
  156. gcore/types/waap/waap_request_details.py +0 -92
  157. gcore/types/waap/waap_request_organization.py +0 -13
  158. gcore/types/waap/waap_resolution.py +0 -7
  159. gcore/types/waap/waap_rule_action_type.py +0 -7
  160. gcore/types/waap/waap_top_url.py +0 -13
  161. gcore/types/waap/waap_traffic_type.py +0 -28
  162. gcore/types/waap/waap_user_agent_details.py +0 -40
  163. {gcore-0.8.0.dist-info → gcore-0.10.0.dist-info}/WHEEL +0 -0
  164. {gcore-0.8.0.dist-info → gcore-0.10.0.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,198 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from .events import (
6
+ EventsResource,
7
+ AsyncEventsResource,
8
+ EventsResourceWithRawResponse,
9
+ AsyncEventsResourceWithRawResponse,
10
+ EventsResourceWithStreamingResponse,
11
+ AsyncEventsResourceWithStreamingResponse,
12
+ )
13
+ from .profiles import (
14
+ ProfilesResource,
15
+ AsyncProfilesResource,
16
+ ProfilesResourceWithRawResponse,
17
+ AsyncProfilesResourceWithRawResponse,
18
+ ProfilesResourceWithStreamingResponse,
19
+ AsyncProfilesResourceWithStreamingResponse,
20
+ )
21
+ from ..._compat import cached_property
22
+ from ..._resource import SyncAPIResource, AsyncAPIResource
23
+ from .bgp_announces import (
24
+ BgpAnnouncesResource,
25
+ AsyncBgpAnnouncesResource,
26
+ BgpAnnouncesResourceWithRawResponse,
27
+ AsyncBgpAnnouncesResourceWithRawResponse,
28
+ BgpAnnouncesResourceWithStreamingResponse,
29
+ AsyncBgpAnnouncesResourceWithStreamingResponse,
30
+ )
31
+ from .profile_templates import (
32
+ ProfileTemplatesResource,
33
+ AsyncProfileTemplatesResource,
34
+ ProfileTemplatesResourceWithRawResponse,
35
+ AsyncProfileTemplatesResourceWithRawResponse,
36
+ ProfileTemplatesResourceWithStreamingResponse,
37
+ AsyncProfileTemplatesResourceWithStreamingResponse,
38
+ )
39
+
40
+ __all__ = ["SecurityResource", "AsyncSecurityResource"]
41
+
42
+
43
+ class SecurityResource(SyncAPIResource):
44
+ @cached_property
45
+ def events(self) -> EventsResource:
46
+ return EventsResource(self._client)
47
+
48
+ @cached_property
49
+ def bgp_announces(self) -> BgpAnnouncesResource:
50
+ return BgpAnnouncesResource(self._client)
51
+
52
+ @cached_property
53
+ def profile_templates(self) -> ProfileTemplatesResource:
54
+ return ProfileTemplatesResource(self._client)
55
+
56
+ @cached_property
57
+ def profiles(self) -> ProfilesResource:
58
+ return ProfilesResource(self._client)
59
+
60
+ @cached_property
61
+ def with_raw_response(self) -> SecurityResourceWithRawResponse:
62
+ """
63
+ This property can be used as a prefix for any HTTP method call to return
64
+ the raw response object instead of the parsed content.
65
+
66
+ For more information, see https://www.github.com/G-Core/gcore-python#accessing-raw-response-data-eg-headers
67
+ """
68
+ return SecurityResourceWithRawResponse(self)
69
+
70
+ @cached_property
71
+ def with_streaming_response(self) -> SecurityResourceWithStreamingResponse:
72
+ """
73
+ An alternative to `.with_raw_response` that doesn't eagerly read the response body.
74
+
75
+ For more information, see https://www.github.com/G-Core/gcore-python#with_streaming_response
76
+ """
77
+ return SecurityResourceWithStreamingResponse(self)
78
+
79
+
80
+ class AsyncSecurityResource(AsyncAPIResource):
81
+ @cached_property
82
+ def events(self) -> AsyncEventsResource:
83
+ return AsyncEventsResource(self._client)
84
+
85
+ @cached_property
86
+ def bgp_announces(self) -> AsyncBgpAnnouncesResource:
87
+ return AsyncBgpAnnouncesResource(self._client)
88
+
89
+ @cached_property
90
+ def profile_templates(self) -> AsyncProfileTemplatesResource:
91
+ return AsyncProfileTemplatesResource(self._client)
92
+
93
+ @cached_property
94
+ def profiles(self) -> AsyncProfilesResource:
95
+ return AsyncProfilesResource(self._client)
96
+
97
+ @cached_property
98
+ def with_raw_response(self) -> AsyncSecurityResourceWithRawResponse:
99
+ """
100
+ This property can be used as a prefix for any HTTP method call to return
101
+ the raw response object instead of the parsed content.
102
+
103
+ For more information, see https://www.github.com/G-Core/gcore-python#accessing-raw-response-data-eg-headers
104
+ """
105
+ return AsyncSecurityResourceWithRawResponse(self)
106
+
107
+ @cached_property
108
+ def with_streaming_response(self) -> AsyncSecurityResourceWithStreamingResponse:
109
+ """
110
+ An alternative to `.with_raw_response` that doesn't eagerly read the response body.
111
+
112
+ For more information, see https://www.github.com/G-Core/gcore-python#with_streaming_response
113
+ """
114
+ return AsyncSecurityResourceWithStreamingResponse(self)
115
+
116
+
117
+ class SecurityResourceWithRawResponse:
118
+ def __init__(self, security: SecurityResource) -> None:
119
+ self._security = security
120
+
121
+ @cached_property
122
+ def events(self) -> EventsResourceWithRawResponse:
123
+ return EventsResourceWithRawResponse(self._security.events)
124
+
125
+ @cached_property
126
+ def bgp_announces(self) -> BgpAnnouncesResourceWithRawResponse:
127
+ return BgpAnnouncesResourceWithRawResponse(self._security.bgp_announces)
128
+
129
+ @cached_property
130
+ def profile_templates(self) -> ProfileTemplatesResourceWithRawResponse:
131
+ return ProfileTemplatesResourceWithRawResponse(self._security.profile_templates)
132
+
133
+ @cached_property
134
+ def profiles(self) -> ProfilesResourceWithRawResponse:
135
+ return ProfilesResourceWithRawResponse(self._security.profiles)
136
+
137
+
138
+ class AsyncSecurityResourceWithRawResponse:
139
+ def __init__(self, security: AsyncSecurityResource) -> None:
140
+ self._security = security
141
+
142
+ @cached_property
143
+ def events(self) -> AsyncEventsResourceWithRawResponse:
144
+ return AsyncEventsResourceWithRawResponse(self._security.events)
145
+
146
+ @cached_property
147
+ def bgp_announces(self) -> AsyncBgpAnnouncesResourceWithRawResponse:
148
+ return AsyncBgpAnnouncesResourceWithRawResponse(self._security.bgp_announces)
149
+
150
+ @cached_property
151
+ def profile_templates(self) -> AsyncProfileTemplatesResourceWithRawResponse:
152
+ return AsyncProfileTemplatesResourceWithRawResponse(self._security.profile_templates)
153
+
154
+ @cached_property
155
+ def profiles(self) -> AsyncProfilesResourceWithRawResponse:
156
+ return AsyncProfilesResourceWithRawResponse(self._security.profiles)
157
+
158
+
159
+ class SecurityResourceWithStreamingResponse:
160
+ def __init__(self, security: SecurityResource) -> None:
161
+ self._security = security
162
+
163
+ @cached_property
164
+ def events(self) -> EventsResourceWithStreamingResponse:
165
+ return EventsResourceWithStreamingResponse(self._security.events)
166
+
167
+ @cached_property
168
+ def bgp_announces(self) -> BgpAnnouncesResourceWithStreamingResponse:
169
+ return BgpAnnouncesResourceWithStreamingResponse(self._security.bgp_announces)
170
+
171
+ @cached_property
172
+ def profile_templates(self) -> ProfileTemplatesResourceWithStreamingResponse:
173
+ return ProfileTemplatesResourceWithStreamingResponse(self._security.profile_templates)
174
+
175
+ @cached_property
176
+ def profiles(self) -> ProfilesResourceWithStreamingResponse:
177
+ return ProfilesResourceWithStreamingResponse(self._security.profiles)
178
+
179
+
180
+ class AsyncSecurityResourceWithStreamingResponse:
181
+ def __init__(self, security: AsyncSecurityResource) -> None:
182
+ self._security = security
183
+
184
+ @cached_property
185
+ def events(self) -> AsyncEventsResourceWithStreamingResponse:
186
+ return AsyncEventsResourceWithStreamingResponse(self._security.events)
187
+
188
+ @cached_property
189
+ def bgp_announces(self) -> AsyncBgpAnnouncesResourceWithStreamingResponse:
190
+ return AsyncBgpAnnouncesResourceWithStreamingResponse(self._security.bgp_announces)
191
+
192
+ @cached_property
193
+ def profile_templates(self) -> AsyncProfileTemplatesResourceWithStreamingResponse:
194
+ return AsyncProfileTemplatesResourceWithStreamingResponse(self._security.profile_templates)
195
+
196
+ @cached_property
197
+ def profiles(self) -> AsyncProfilesResourceWithStreamingResponse:
198
+ return AsyncProfilesResourceWithStreamingResponse(self._security.profiles)
@@ -32,6 +32,14 @@ from .ip_info import (
32
32
  IPInfoResourceWithStreamingResponse,
33
33
  AsyncIPInfoResourceWithStreamingResponse,
34
34
  )
35
+ from .insights import (
36
+ InsightsResource,
37
+ AsyncInsightsResource,
38
+ InsightsResourceWithRawResponse,
39
+ AsyncInsightsResourceWithRawResponse,
40
+ InsightsResourceWithStreamingResponse,
41
+ AsyncInsightsResourceWithStreamingResponse,
42
+ )
35
43
  from .statistics import (
36
44
  StatisticsResource,
37
45
  AsyncStatisticsResource,
@@ -102,6 +110,12 @@ __all__ = [
102
110
  "AsyncOrganizationsResourceWithRawResponse",
103
111
  "OrganizationsResourceWithStreamingResponse",
104
112
  "AsyncOrganizationsResourceWithStreamingResponse",
113
+ "InsightsResource",
114
+ "AsyncInsightsResource",
115
+ "InsightsResourceWithRawResponse",
116
+ "AsyncInsightsResourceWithRawResponse",
117
+ "InsightsResourceWithStreamingResponse",
118
+ "AsyncInsightsResourceWithStreamingResponse",
105
119
  "IPInfoResource",
106
120
  "AsyncIPInfoResource",
107
121
  "IPInfoResourceWithRawResponse",
@@ -19,22 +19,14 @@ from ..._response import (
19
19
  )
20
20
  from ...pagination import SyncOffsetPage, AsyncOffsetPage
21
21
  from ...types.waap import (
22
- WaapPageType,
23
22
  custom_page_set_list_params,
24
23
  custom_page_set_create_params,
25
24
  custom_page_set_update_params,
26
25
  custom_page_set_preview_params,
27
26
  )
28
27
  from ..._base_client import AsyncPaginator, make_request_options
29
- from ...types.waap.waap_page_type import WaapPageType
30
28
  from ...types.waap.waap_custom_page_set import WaapCustomPageSet
31
29
  from ...types.waap.waap_custom_page_preview import WaapCustomPagePreview
32
- from ...types.waap.waap_block_page_data_param import WaapBlockPageDataParam
33
- from ...types.waap.waap_captcha_page_data_param import WaapCaptchaPageDataParam
34
- from ...types.waap.waap_handshake_page_data_param import WaapHandshakePageDataParam
35
- from ...types.waap.waap_block_csrf_page_data_param import WaapBlockCsrfPageDataParam
36
- from ...types.waap.waap_cookie_disabled_page_data_param import WaapCookieDisabledPageDataParam
37
- from ...types.waap.waap_javascript_disabled_page_data_param import WaapJavascriptDisabledPageDataParam
38
30
 
39
31
  __all__ = ["CustomPageSetsResource", "AsyncCustomPageSetsResource"]
40
32
 
@@ -63,13 +55,13 @@ class CustomPageSetsResource(SyncAPIResource):
63
55
  self,
64
56
  *,
65
57
  name: str,
66
- block: Optional[WaapBlockPageDataParam] | NotGiven = NOT_GIVEN,
67
- block_csrf: Optional[WaapBlockCsrfPageDataParam] | NotGiven = NOT_GIVEN,
68
- captcha: Optional[WaapCaptchaPageDataParam] | NotGiven = NOT_GIVEN,
69
- cookie_disabled: Optional[WaapCookieDisabledPageDataParam] | NotGiven = NOT_GIVEN,
58
+ block: Optional[custom_page_set_create_params.Block] | NotGiven = NOT_GIVEN,
59
+ block_csrf: Optional[custom_page_set_create_params.BlockCsrf] | NotGiven = NOT_GIVEN,
60
+ captcha: Optional[custom_page_set_create_params.Captcha] | NotGiven = NOT_GIVEN,
61
+ cookie_disabled: Optional[custom_page_set_create_params.CookieDisabled] | NotGiven = NOT_GIVEN,
70
62
  domains: Optional[Iterable[int]] | NotGiven = NOT_GIVEN,
71
- handshake: Optional[WaapHandshakePageDataParam] | NotGiven = NOT_GIVEN,
72
- javascript_disabled: Optional[WaapJavascriptDisabledPageDataParam] | NotGiven = NOT_GIVEN,
63
+ handshake: Optional[custom_page_set_create_params.Handshake] | NotGiven = NOT_GIVEN,
64
+ javascript_disabled: Optional[custom_page_set_create_params.JavascriptDisabled] | NotGiven = NOT_GIVEN,
73
65
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
74
66
  # The extra values given here take precedence over values defined on the client or passed to this method.
75
67
  extra_headers: Headers | None = None,
@@ -120,13 +112,13 @@ class CustomPageSetsResource(SyncAPIResource):
120
112
  self,
121
113
  set_id: int,
122
114
  *,
123
- block: Optional[WaapBlockPageDataParam] | NotGiven = NOT_GIVEN,
124
- block_csrf: Optional[WaapBlockCsrfPageDataParam] | NotGiven = NOT_GIVEN,
125
- captcha: Optional[WaapCaptchaPageDataParam] | NotGiven = NOT_GIVEN,
126
- cookie_disabled: Optional[WaapCookieDisabledPageDataParam] | NotGiven = NOT_GIVEN,
115
+ block: Optional[custom_page_set_update_params.Block] | NotGiven = NOT_GIVEN,
116
+ block_csrf: Optional[custom_page_set_update_params.BlockCsrf] | NotGiven = NOT_GIVEN,
117
+ captcha: Optional[custom_page_set_update_params.Captcha] | NotGiven = NOT_GIVEN,
118
+ cookie_disabled: Optional[custom_page_set_update_params.CookieDisabled] | NotGiven = NOT_GIVEN,
127
119
  domains: Optional[Iterable[int]] | NotGiven = NOT_GIVEN,
128
- handshake: Optional[WaapHandshakePageDataParam] | NotGiven = NOT_GIVEN,
129
- javascript_disabled: Optional[WaapJavascriptDisabledPageDataParam] | NotGiven = NOT_GIVEN,
120
+ handshake: Optional[custom_page_set_update_params.Handshake] | NotGiven = NOT_GIVEN,
121
+ javascript_disabled: Optional[custom_page_set_update_params.JavascriptDisabled] | NotGiven = NOT_GIVEN,
130
122
  name: Optional[str] | NotGiven = NOT_GIVEN,
131
123
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
132
124
  # The extra values given here take precedence over values defined on the client or passed to this method.
@@ -309,7 +301,14 @@ class CustomPageSetsResource(SyncAPIResource):
309
301
  def preview(
310
302
  self,
311
303
  *,
312
- page_type: WaapPageType,
304
+ page_type: Literal[
305
+ "block.html",
306
+ "block_csrf.html",
307
+ "captcha.html",
308
+ "cookieDisabled.html",
309
+ "handshake.html",
310
+ "javascriptDisabled.html",
311
+ ],
313
312
  error: Optional[str] | NotGiven = NOT_GIVEN,
314
313
  header: Optional[str] | NotGiven = NOT_GIVEN,
315
314
  logo: Optional[str] | NotGiven = NOT_GIVEN,
@@ -398,13 +397,13 @@ class AsyncCustomPageSetsResource(AsyncAPIResource):
398
397
  self,
399
398
  *,
400
399
  name: str,
401
- block: Optional[WaapBlockPageDataParam] | NotGiven = NOT_GIVEN,
402
- block_csrf: Optional[WaapBlockCsrfPageDataParam] | NotGiven = NOT_GIVEN,
403
- captcha: Optional[WaapCaptchaPageDataParam] | NotGiven = NOT_GIVEN,
404
- cookie_disabled: Optional[WaapCookieDisabledPageDataParam] | NotGiven = NOT_GIVEN,
400
+ block: Optional[custom_page_set_create_params.Block] | NotGiven = NOT_GIVEN,
401
+ block_csrf: Optional[custom_page_set_create_params.BlockCsrf] | NotGiven = NOT_GIVEN,
402
+ captcha: Optional[custom_page_set_create_params.Captcha] | NotGiven = NOT_GIVEN,
403
+ cookie_disabled: Optional[custom_page_set_create_params.CookieDisabled] | NotGiven = NOT_GIVEN,
405
404
  domains: Optional[Iterable[int]] | NotGiven = NOT_GIVEN,
406
- handshake: Optional[WaapHandshakePageDataParam] | NotGiven = NOT_GIVEN,
407
- javascript_disabled: Optional[WaapJavascriptDisabledPageDataParam] | NotGiven = NOT_GIVEN,
405
+ handshake: Optional[custom_page_set_create_params.Handshake] | NotGiven = NOT_GIVEN,
406
+ javascript_disabled: Optional[custom_page_set_create_params.JavascriptDisabled] | NotGiven = NOT_GIVEN,
408
407
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
409
408
  # The extra values given here take precedence over values defined on the client or passed to this method.
410
409
  extra_headers: Headers | None = None,
@@ -455,13 +454,13 @@ class AsyncCustomPageSetsResource(AsyncAPIResource):
455
454
  self,
456
455
  set_id: int,
457
456
  *,
458
- block: Optional[WaapBlockPageDataParam] | NotGiven = NOT_GIVEN,
459
- block_csrf: Optional[WaapBlockCsrfPageDataParam] | NotGiven = NOT_GIVEN,
460
- captcha: Optional[WaapCaptchaPageDataParam] | NotGiven = NOT_GIVEN,
461
- cookie_disabled: Optional[WaapCookieDisabledPageDataParam] | NotGiven = NOT_GIVEN,
457
+ block: Optional[custom_page_set_update_params.Block] | NotGiven = NOT_GIVEN,
458
+ block_csrf: Optional[custom_page_set_update_params.BlockCsrf] | NotGiven = NOT_GIVEN,
459
+ captcha: Optional[custom_page_set_update_params.Captcha] | NotGiven = NOT_GIVEN,
460
+ cookie_disabled: Optional[custom_page_set_update_params.CookieDisabled] | NotGiven = NOT_GIVEN,
462
461
  domains: Optional[Iterable[int]] | NotGiven = NOT_GIVEN,
463
- handshake: Optional[WaapHandshakePageDataParam] | NotGiven = NOT_GIVEN,
464
- javascript_disabled: Optional[WaapJavascriptDisabledPageDataParam] | NotGiven = NOT_GIVEN,
462
+ handshake: Optional[custom_page_set_update_params.Handshake] | NotGiven = NOT_GIVEN,
463
+ javascript_disabled: Optional[custom_page_set_update_params.JavascriptDisabled] | NotGiven = NOT_GIVEN,
465
464
  name: Optional[str] | NotGiven = NOT_GIVEN,
466
465
  # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
467
466
  # The extra values given here take precedence over values defined on the client or passed to this method.
@@ -644,7 +643,14 @@ class AsyncCustomPageSetsResource(AsyncAPIResource):
644
643
  async def preview(
645
644
  self,
646
645
  *,
647
- page_type: WaapPageType,
646
+ page_type: Literal[
647
+ "block.html",
648
+ "block_csrf.html",
649
+ "captcha.html",
650
+ "cookieDisabled.html",
651
+ "handshake.html",
652
+ "javascriptDisabled.html",
653
+ ],
648
654
  error: Optional[str] | NotGiven = NOT_GIVEN,
649
655
  header: Optional[str] | NotGiven = NOT_GIVEN,
650
656
  logo: Optional[str] | NotGiven = NOT_GIVEN,
@@ -16,14 +16,6 @@ from .insights import (
16
16
  InsightsResourceWithStreamingResponse,
17
17
  AsyncInsightsResourceWithStreamingResponse,
18
18
  )
19
- from .policies import (
20
- PoliciesResource,
21
- AsyncPoliciesResource,
22
- PoliciesResourceWithRawResponse,
23
- AsyncPoliciesResourceWithRawResponse,
24
- PoliciesResourceWithStreamingResponse,
25
- AsyncPoliciesResourceWithStreamingResponse,
26
- )
27
19
  from .settings import (
28
20
  SettingsResource,
29
21
  AsyncSettingsResource,
@@ -32,14 +24,6 @@ from .settings import (
32
24
  SettingsResourceWithStreamingResponse,
33
25
  AsyncSettingsResourceWithStreamingResponse,
34
26
  )
35
- from .analytics import (
36
- AnalyticsResource,
37
- AsyncAnalyticsResource,
38
- AnalyticsResourceWithRawResponse,
39
- AsyncAnalyticsResourceWithRawResponse,
40
- AnalyticsResourceWithStreamingResponse,
41
- AsyncAnalyticsResourceWithStreamingResponse,
42
- )
43
27
  from .api_paths import (
44
28
  APIPathsResource,
45
29
  AsyncAPIPathsResource,
@@ -48,6 +32,14 @@ from .api_paths import (
48
32
  APIPathsResourceWithStreamingResponse,
49
33
  AsyncAPIPathsResourceWithStreamingResponse,
50
34
  )
35
+ from .statistics import (
36
+ StatisticsResource,
37
+ AsyncStatisticsResource,
38
+ StatisticsResourceWithRawResponse,
39
+ AsyncStatisticsResourceWithRawResponse,
40
+ StatisticsResourceWithStreamingResponse,
41
+ AsyncStatisticsResourceWithStreamingResponse,
42
+ )
51
43
  from .custom_rules import (
52
44
  CustomRulesResource,
53
45
  AsyncCustomRulesResource,
@@ -134,18 +126,12 @@ __all__ = [
134
126
  "AsyncInsightSilencesResourceWithRawResponse",
135
127
  "InsightSilencesResourceWithStreamingResponse",
136
128
  "AsyncInsightSilencesResourceWithStreamingResponse",
137
- "PoliciesResource",
138
- "AsyncPoliciesResource",
139
- "PoliciesResourceWithRawResponse",
140
- "AsyncPoliciesResourceWithRawResponse",
141
- "PoliciesResourceWithStreamingResponse",
142
- "AsyncPoliciesResourceWithStreamingResponse",
143
- "AnalyticsResource",
144
- "AsyncAnalyticsResource",
145
- "AnalyticsResourceWithRawResponse",
146
- "AsyncAnalyticsResourceWithRawResponse",
147
- "AnalyticsResourceWithStreamingResponse",
148
- "AsyncAnalyticsResourceWithStreamingResponse",
129
+ "StatisticsResource",
130
+ "AsyncStatisticsResource",
131
+ "StatisticsResourceWithRawResponse",
132
+ "AsyncStatisticsResourceWithRawResponse",
133
+ "StatisticsResourceWithStreamingResponse",
134
+ "AsyncStatisticsResourceWithStreamingResponse",
149
135
  "CustomRulesResource",
150
136
  "AsyncCustomRulesResource",
151
137
  "CustomRulesResourceWithRawResponse",
@@ -18,12 +18,9 @@ from ...._response import (
18
18
  async_to_streamed_response_wrapper,
19
19
  )
20
20
  from ....pagination import SyncOffsetPage, AsyncOffsetPage
21
- from ....types.waap import WaapRuleActionType, WaapCustomerRuleState
22
21
  from ...._base_client import AsyncPaginator, make_request_options
23
22
  from ....types.waap.domains import advanced_rule_list_params, advanced_rule_create_params, advanced_rule_update_params
24
- from ....types.waap.waap_advanced_rule import WaapAdvancedRule
25
- from ....types.waap.waap_rule_action_type import WaapRuleActionType
26
- from ....types.waap.waap_customer_rule_state import WaapCustomerRuleState
23
+ from ....types.waap.domains.waap_advanced_rule import WaapAdvancedRule
27
24
 
28
25
  __all__ = ["AdvancedRulesResource", "AsyncAdvancedRulesResource"]
29
26
 
@@ -196,7 +193,7 @@ class AdvancedRulesResource(SyncAPIResource):
196
193
  self,
197
194
  domain_id: int,
198
195
  *,
199
- action: WaapRuleActionType | NotGiven = NOT_GIVEN,
196
+ action: Literal["allow", "block", "captcha", "handshake", "monitor", "tag"] | NotGiven = NOT_GIVEN,
200
197
  description: str | NotGiven = NOT_GIVEN,
201
198
  enabled: bool | NotGiven = NOT_GIVEN,
202
199
  limit: int | NotGiven = NOT_GIVEN,
@@ -363,7 +360,7 @@ class AdvancedRulesResource(SyncAPIResource):
363
360
 
364
361
  def toggle(
365
362
  self,
366
- action: WaapCustomerRuleState,
363
+ action: Literal["enable", "disable"],
367
364
  *,
368
365
  domain_id: int,
369
366
  rule_id: int,
@@ -572,7 +569,7 @@ class AsyncAdvancedRulesResource(AsyncAPIResource):
572
569
  self,
573
570
  domain_id: int,
574
571
  *,
575
- action: WaapRuleActionType | NotGiven = NOT_GIVEN,
572
+ action: Literal["allow", "block", "captcha", "handshake", "monitor", "tag"] | NotGiven = NOT_GIVEN,
576
573
  description: str | NotGiven = NOT_GIVEN,
577
574
  enabled: bool | NotGiven = NOT_GIVEN,
578
575
  limit: int | NotGiven = NOT_GIVEN,
@@ -739,7 +736,7 @@ class AsyncAdvancedRulesResource(AsyncAPIResource):
739
736
 
740
737
  async def toggle(
741
738
  self,
742
- action: WaapCustomerRuleState,
739
+ action: Literal["enable", "disable"],
743
740
  *,
744
741
  domain_id: int,
745
742
  rule_id: int,