gcore 0.1.0a2__py3-none-any.whl → 0.3.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 (293) hide show
  1. gcore/__init__.py +5 -0
  2. gcore/_base_client.py +22 -2
  3. gcore/_client.py +9 -0
  4. gcore/_models.py +2 -0
  5. gcore/_types.py +2 -0
  6. gcore/_utils/_proxy.py +4 -1
  7. gcore/_utils/_resources_proxy.py +24 -0
  8. gcore/_version.py +1 -1
  9. gcore/resources/__init__.py +14 -0
  10. gcore/resources/cloud/baremetal/flavors.py +2 -2
  11. gcore/resources/cloud/baremetal/images.py +2 -2
  12. gcore/resources/cloud/baremetal/servers.py +280 -52
  13. gcore/resources/cloud/billing_reservations.py +24 -0
  14. gcore/resources/cloud/file_shares/file_shares.py +16 -0
  15. gcore/resources/cloud/floating_ips.py +4 -4
  16. gcore/resources/cloud/gpu_baremetal_clusters/gpu_baremetal_clusters.py +358 -8
  17. gcore/resources/cloud/gpu_baremetal_clusters/images.py +206 -2
  18. gcore/resources/cloud/gpu_baremetal_clusters/servers.py +84 -4
  19. gcore/resources/cloud/inference/deployments/deployments.py +328 -10
  20. gcore/resources/cloud/instances/flavors.py +2 -2
  21. gcore/resources/cloud/instances/images.py +318 -2
  22. gcore/resources/cloud/instances/instances.py +534 -70
  23. gcore/resources/cloud/instances/interfaces.py +4 -4
  24. gcore/resources/cloud/load_balancers/flavors.py +2 -2
  25. gcore/resources/cloud/load_balancers/l7_policies/l7_policies.py +302 -20
  26. gcore/resources/cloud/load_balancers/l7_policies/rules.py +326 -0
  27. gcore/resources/cloud/load_balancers/listeners.py +385 -20
  28. gcore/resources/cloud/load_balancers/load_balancers.py +392 -24
  29. gcore/resources/cloud/load_balancers/pools/health_monitors.py +24 -0
  30. gcore/resources/cloud/load_balancers/pools/members.py +34 -6
  31. gcore/resources/cloud/load_balancers/pools/pools.py +388 -8
  32. gcore/resources/cloud/networks/networks.py +72 -16
  33. gcore/resources/cloud/networks/subnets.py +6 -6
  34. gcore/resources/cloud/registries/registries.py +6 -10
  35. gcore/resources/cloud/registries/users.py +4 -10
  36. gcore/resources/cloud/reserved_fixed_ips/reserved_fixed_ips.py +10 -10
  37. gcore/resources/cloud/secrets.py +56 -11
  38. gcore/resources/cloud/security_groups/security_groups.py +2 -2
  39. gcore/resources/cloud/ssh_keys.py +2 -2
  40. gcore/resources/cloud/tasks.py +203 -184
  41. gcore/resources/cloud/users/role_assignments.py +4 -4
  42. gcore/resources/cloud/volumes.py +18 -18
  43. gcore/resources/waap/__init__.py +131 -0
  44. gcore/resources/waap/advanced_rules.py +135 -0
  45. gcore/resources/waap/clients.py +135 -0
  46. gcore/resources/waap/custom_page_sets.py +805 -0
  47. gcore/resources/waap/domains/__init__.py +173 -0
  48. gcore/resources/waap/domains/advanced_rules.py +876 -0
  49. gcore/resources/waap/domains/analytics/__init__.py +33 -0
  50. gcore/resources/waap/domains/analytics/analytics.py +676 -0
  51. gcore/resources/waap/domains/analytics/requests.py +378 -0
  52. gcore/resources/waap/domains/api_discovery/__init__.py +33 -0
  53. gcore/resources/waap/domains/api_discovery/api_discovery.py +530 -0
  54. gcore/resources/waap/domains/api_discovery/scan_results.py +352 -0
  55. gcore/resources/waap/domains/api_path_groups.py +163 -0
  56. gcore/resources/waap/domains/api_paths.py +771 -0
  57. gcore/resources/waap/domains/custom_rules.py +889 -0
  58. gcore/resources/waap/domains/domains.py +914 -0
  59. gcore/resources/waap/domains/firewall_rules.py +884 -0
  60. gcore/resources/waap/domains/insight_silences.py +689 -0
  61. gcore/resources/waap/domains/insights.py +425 -0
  62. gcore/resources/waap/domains/policies.py +173 -0
  63. gcore/resources/waap/domains/settings.py +271 -0
  64. gcore/resources/waap/ip_info.py +1017 -0
  65. gcore/resources/waap/organizations.py +217 -0
  66. gcore/resources/waap/statistics.py +225 -0
  67. gcore/resources/waap/tags.py +233 -0
  68. gcore/resources/waap/waap.py +391 -0
  69. gcore/types/cloud/__init__.py +1 -0
  70. gcore/types/cloud/allowed_address_pairs.py +2 -2
  71. gcore/types/cloud/baremetal/baremetal_server.py +1 -1
  72. gcore/types/cloud/baremetal/image_list_params.py +1 -1
  73. gcore/types/cloud/baremetal/server_create_params.py +9 -9
  74. gcore/types/cloud/baremetal/server_list_params.py +8 -8
  75. gcore/types/cloud/baremetal/server_rebuild_params.py +1 -1
  76. gcore/types/cloud/baremetal_flavor.py +3 -3
  77. gcore/types/cloud/billing_reservation_list_params.py +5 -0
  78. gcore/types/cloud/container_probe_config.py +1 -1
  79. gcore/types/cloud/container_probe_config_create_param.py +2 -3
  80. gcore/types/cloud/container_scale_triggers.py +2 -2
  81. gcore/types/cloud/file_share.py +3 -0
  82. gcore/types/cloud/file_share_list_params.py +7 -1
  83. gcore/types/cloud/floating_ip_detailed.py +1 -1
  84. gcore/types/cloud/floating_ip_list_params.py +2 -2
  85. gcore/types/cloud/gpu_baremetal_cluster.py +1 -1
  86. gcore/types/cloud/gpu_baremetal_cluster_create_params.py +21 -1
  87. gcore/types/cloud/gpu_baremetal_cluster_delete_params.py +1 -1
  88. gcore/types/cloud/gpu_baremetal_cluster_rebuild_params.py +1 -1
  89. gcore/types/cloud/gpu_baremetal_cluster_server.py +1 -1
  90. gcore/types/cloud/gpu_baremetal_clusters/image_upload_params.py +1 -1
  91. gcore/types/cloud/gpu_baremetal_clusters/server_attach_interface_params.py +10 -10
  92. gcore/types/cloud/gpu_baremetal_flavor.py +3 -3
  93. gcore/types/cloud/image.py +1 -1
  94. gcore/types/cloud/inference/deployment_create_params.py +4 -4
  95. gcore/types/cloud/inference/deployment_update_params.py +206 -9
  96. gcore/types/cloud/inference/inference.py +5 -5
  97. gcore/types/cloud/instance.py +1 -1
  98. gcore/types/cloud/instance_create_params.py +8 -10
  99. gcore/types/cloud/instance_list_params.py +8 -8
  100. gcore/types/cloud/instances/flavor_list_suitable_params.py +4 -1
  101. gcore/types/cloud/instances/image_list_params.py +1 -1
  102. gcore/types/cloud/instances/instance_flavor.py +3 -3
  103. gcore/types/cloud/instances/interface_attach_params.py +10 -10
  104. gcore/types/cloud/load_balancer_create_params.py +17 -15
  105. gcore/types/cloud/load_balancer_flavor_detail.py +3 -3
  106. gcore/types/cloud/load_balancer_l7_policy.py +5 -5
  107. gcore/types/cloud/load_balancer_list_params.py +5 -5
  108. gcore/types/cloud/load_balancer_listener_detail.py +17 -17
  109. gcore/types/cloud/load_balancer_pool.py +13 -13
  110. gcore/types/cloud/load_balancer_pool_list.py +99 -4
  111. gcore/types/cloud/load_balancers/l7_policy_create_params.py +5 -5
  112. gcore/types/cloud/load_balancers/l7_policy_replace_params.py +5 -5
  113. gcore/types/cloud/load_balancers/listener_create_params.py +6 -4
  114. gcore/types/cloud/load_balancers/listener_get_params.py +3 -1
  115. gcore/types/cloud/load_balancers/listener_list_params.py +4 -2
  116. gcore/types/cloud/load_balancers/listener_update_params.py +5 -3
  117. gcore/types/cloud/load_balancers/pool_create_params.py +6 -4
  118. gcore/types/cloud/load_balancers/pool_list_params.py +5 -6
  119. gcore/types/cloud/load_balancers/pool_update_params.py +6 -4
  120. gcore/types/cloud/load_balancers/pools/health_monitor_create_params.py +2 -0
  121. gcore/types/cloud/load_balancers/pools/member_add_params.py +5 -3
  122. gcore/types/cloud/member.py +2 -2
  123. gcore/types/cloud/network.py +22 -22
  124. gcore/types/cloud/network_create_params.py +2 -0
  125. gcore/types/cloud/network_details.py +25 -24
  126. gcore/types/cloud/network_list_params.py +15 -10
  127. gcore/types/cloud/network_update_params.py +2 -0
  128. gcore/types/cloud/networks/subnet_create_params.py +1 -1
  129. gcore/types/cloud/networks/subnet_list_params.py +2 -2
  130. gcore/types/cloud/quota_get_all_response.py +18 -0
  131. gcore/types/cloud/quota_get_by_region_response.py +18 -0
  132. gcore/types/cloud/quotas/request_create_params.py +9 -0
  133. gcore/types/cloud/quotas/request_get_response.py +9 -0
  134. gcore/types/cloud/quotas/request_list_response.py +9 -0
  135. gcore/types/cloud/region.py +4 -4
  136. gcore/types/cloud/registries/user_create_multiple_params.py +3 -5
  137. gcore/types/cloud/registries/user_create_params.py +3 -5
  138. gcore/types/cloud/registry_create_params.py +3 -5
  139. gcore/types/cloud/reserved_fixed_ip_create_params.py +2 -2
  140. gcore/types/cloud/reserved_fixed_ip_list_params.py +3 -3
  141. gcore/types/cloud/secret_list_params.py +24 -0
  142. gcore/types/cloud/security_group_list_params.py +1 -1
  143. gcore/types/cloud/session_persistence.py +1 -1
  144. gcore/types/cloud/ssh_key_created.py +3 -6
  145. gcore/types/cloud/task.py +1 -4
  146. gcore/types/cloud/task_list_params.py +56 -46
  147. gcore/types/cloud/users/role_assignment_create_params.py +1 -1
  148. gcore/types/cloud/users/role_assignment_update_params.py +1 -1
  149. gcore/types/cloud/volume_create_params.py +6 -6
  150. gcore/types/cloud/volume_list_params.py +3 -3
  151. gcore/types/waap/__init__.py +108 -0
  152. gcore/types/waap/client_me_response.py +34 -0
  153. gcore/types/waap/custom_page_set_create_params.py +35 -0
  154. gcore/types/waap/custom_page_set_list_params.py +25 -0
  155. gcore/types/waap/custom_page_set_preview_params.py +34 -0
  156. gcore/types/waap/custom_page_set_update_params.py +35 -0
  157. gcore/types/waap/domain_list_params.py +30 -0
  158. gcore/types/waap/domain_list_rule_sets_response.py +10 -0
  159. gcore/types/waap/domain_update_params.py +12 -0
  160. gcore/types/waap/domains/__init__.py +47 -0
  161. gcore/types/waap/domains/advanced_rule_create_params.py +80 -0
  162. gcore/types/waap/domains/advanced_rule_list_params.py +58 -0
  163. gcore/types/waap/domains/advanced_rule_update_params.py +83 -0
  164. gcore/types/waap/domains/analytics/__init__.py +5 -0
  165. gcore/types/waap/domains/analytics/request_list_params.py +53 -0
  166. gcore/types/waap/domains/analytics_get_event_statistics_params.py +34 -0
  167. gcore/types/waap/domains/analytics_list_ddos_attacks_params.py +28 -0
  168. gcore/types/waap/domains/analytics_list_ddos_info_params.py +31 -0
  169. gcore/types/waap/domains/analytics_list_event_traffic_params.py +26 -0
  170. gcore/types/waap/domains/analytics_list_event_traffic_response.py +10 -0
  171. gcore/types/waap/domains/api_discovery/__init__.py +7 -0
  172. gcore/types/waap/domains/api_discovery/scan_result_get_response.py +29 -0
  173. gcore/types/waap/domains/api_discovery/scan_result_list_params.py +41 -0
  174. gcore/types/waap/domains/api_discovery/scan_result_list_response.py +29 -0
  175. gcore/types/waap/domains/api_discovery_get_settings_response.py +36 -0
  176. gcore/types/waap/domains/api_discovery_scan_openapi_response.py +10 -0
  177. gcore/types/waap/domains/api_discovery_update_settings_params.py +34 -0
  178. gcore/types/waap/domains/api_discovery_update_settings_response.py +36 -0
  179. gcore/types/waap/domains/api_discovery_upload_openapi_params.py +19 -0
  180. gcore/types/waap/domains/api_discovery_upload_openapi_response.py +10 -0
  181. gcore/types/waap/domains/api_path_create_params.py +31 -0
  182. gcore/types/waap/domains/api_path_create_response.py +50 -0
  183. gcore/types/waap/domains/api_path_get_response.py +50 -0
  184. gcore/types/waap/domains/api_path_group_list_response.py +12 -0
  185. gcore/types/waap/domains/api_path_list_params.py +62 -0
  186. gcore/types/waap/domains/api_path_list_response.py +50 -0
  187. gcore/types/waap/domains/api_path_update_params.py +29 -0
  188. gcore/types/waap/domains/custom_rule_create_params.py +368 -0
  189. gcore/types/waap/domains/custom_rule_delete_multiple_params.py +13 -0
  190. gcore/types/waap/domains/custom_rule_list_params.py +35 -0
  191. gcore/types/waap/domains/custom_rule_update_params.py +371 -0
  192. gcore/types/waap/domains/firewall_rule_create_params.py +75 -0
  193. gcore/types/waap/domains/firewall_rule_delete_multiple_params.py +13 -0
  194. gcore/types/waap/domains/firewall_rule_list_params.py +33 -0
  195. gcore/types/waap/domains/firewall_rule_update_params.py +78 -0
  196. gcore/types/waap/domains/insight_list_params.py +34 -0
  197. gcore/types/waap/domains/insight_replace_params.py +17 -0
  198. gcore/types/waap/domains/insight_silence_create_params.py +28 -0
  199. gcore/types/waap/domains/insight_silence_list_params.py +33 -0
  200. gcore/types/waap/domains/insight_silence_update_params.py +28 -0
  201. gcore/types/waap/domains/setting_update_params.py +48 -0
  202. gcore/types/waap/ip_info_get_attack_time_series_params.py +12 -0
  203. gcore/types/waap/ip_info_get_attack_time_series_response.py +10 -0
  204. gcore/types/waap/ip_info_get_blocked_requests_params.py +15 -0
  205. gcore/types/waap/ip_info_get_blocked_requests_response.py +10 -0
  206. gcore/types/waap/ip_info_get_counts_params.py +19 -0
  207. gcore/types/waap/ip_info_get_ddos_attack_series_params.py +12 -0
  208. gcore/types/waap/ip_info_get_params.py +12 -0
  209. gcore/types/waap/ip_info_get_top_sessions_params.py +15 -0
  210. gcore/types/waap/ip_info_get_top_sessions_response.py +10 -0
  211. gcore/types/waap/ip_info_get_top_urls_params.py +15 -0
  212. gcore/types/waap/ip_info_get_top_urls_response.py +10 -0
  213. gcore/types/waap/ip_info_get_top_user_agents_params.py +15 -0
  214. gcore/types/waap/ip_info_get_top_user_agents_response.py +10 -0
  215. gcore/types/waap/ip_info_list_attacked_countries_params.py +12 -0
  216. gcore/types/waap/ip_info_list_attacked_countries_response.py +10 -0
  217. gcore/types/waap/organization_list_params.py +22 -0
  218. gcore/types/waap/statistic_get_usage_series_params.py +25 -0
  219. gcore/types/waap/tag_list_params.py +28 -0
  220. gcore/types/waap/waap_advanced_rule.py +83 -0
  221. gcore/types/waap/waap_advanced_rule_descriptor.py +49 -0
  222. gcore/types/waap/waap_advanced_rule_descriptor_list.py +15 -0
  223. gcore/types/waap/waap_block_csrf_page_data.py +28 -0
  224. gcore/types/waap/waap_block_csrf_page_data_param.py +28 -0
  225. gcore/types/waap/waap_block_page_data.py +28 -0
  226. gcore/types/waap/waap_block_page_data_param.py +28 -0
  227. gcore/types/waap/waap_blocked_statistics.py +36 -0
  228. gcore/types/waap/waap_captcha_page_data.py +31 -0
  229. gcore/types/waap/waap_captcha_page_data_param.py +31 -0
  230. gcore/types/waap/waap_common_tag.py +16 -0
  231. gcore/types/waap/waap_cookie_disabled_page_data.py +18 -0
  232. gcore/types/waap/waap_cookie_disabled_page_data_param.py +18 -0
  233. gcore/types/waap/waap_count_statistics.py +36 -0
  234. gcore/types/waap/waap_custom_page_preview.py +10 -0
  235. gcore/types/waap/waap_custom_page_set.py +36 -0
  236. gcore/types/waap/waap_custom_rule.py +373 -0
  237. gcore/types/waap/waap_customer_rule_state.py +7 -0
  238. gcore/types/waap/waap_ddos_attack.py +16 -0
  239. gcore/types/waap/waap_ddos_info.py +17 -0
  240. gcore/types/waap/waap_detailed_domain.py +37 -0
  241. gcore/types/waap/waap_domain_api_settings.py +22 -0
  242. gcore/types/waap/waap_domain_ddos_settings.py +31 -0
  243. gcore/types/waap/waap_domain_policy.py +29 -0
  244. gcore/types/waap/waap_domain_settings_model.py +15 -0
  245. gcore/types/waap/waap_domain_status.py +7 -0
  246. gcore/types/waap/waap_event_statistics.py +15 -0
  247. gcore/types/waap/waap_firewall_rule.py +78 -0
  248. gcore/types/waap/waap_get_account_overview_response.py +34 -0
  249. gcore/types/waap/waap_handshake_page_data.py +25 -0
  250. gcore/types/waap/waap_handshake_page_data_param.py +25 -0
  251. gcore/types/waap/waap_insight.py +38 -0
  252. gcore/types/waap/waap_insight_silence.py +28 -0
  253. gcore/types/waap/waap_insight_silence_sort_by.py +9 -0
  254. gcore/types/waap/waap_insight_sort_by.py +20 -0
  255. gcore/types/waap/waap_insight_status.py +7 -0
  256. gcore/types/waap/waap_ip_country_attack.py +16 -0
  257. gcore/types/waap/waap_ip_ddos_info_model.py +23 -0
  258. gcore/types/waap/waap_ip_info.py +57 -0
  259. gcore/types/waap/waap_ip_info_counts.py +16 -0
  260. gcore/types/waap/waap_javascript_disabled_page_data.py +18 -0
  261. gcore/types/waap/waap_javascript_disabled_page_data_param.py +18 -0
  262. gcore/types/waap/waap_network_details.py +17 -0
  263. gcore/types/waap/waap_organization.py +13 -0
  264. gcore/types/waap/waap_page_type.py +9 -0
  265. gcore/types/waap/waap_paginated_custom_page_set.py +22 -0
  266. gcore/types/waap/waap_paginated_ddos_attack.py +22 -0
  267. gcore/types/waap/waap_paginated_ddos_info.py +22 -0
  268. gcore/types/waap/waap_paginated_request_summary.py +22 -0
  269. gcore/types/waap/waap_pattern_matched_tag.py +37 -0
  270. gcore/types/waap/waap_policy_action.py +7 -0
  271. gcore/types/waap/waap_policy_mode.py +10 -0
  272. gcore/types/waap/waap_request_details.py +92 -0
  273. gcore/types/waap/waap_request_organization.py +13 -0
  274. gcore/types/waap/waap_request_summary.py +59 -0
  275. gcore/types/waap/waap_resolution.py +7 -0
  276. gcore/types/waap/waap_rule_action_type.py +7 -0
  277. gcore/types/waap/waap_rule_blocked_requests.py +16 -0
  278. gcore/types/waap/waap_rule_set.py +41 -0
  279. gcore/types/waap/waap_statistic_item.py +18 -0
  280. gcore/types/waap/waap_statistics_series.py +16 -0
  281. gcore/types/waap/waap_summary_domain.py +26 -0
  282. gcore/types/waap/waap_tag.py +16 -0
  283. gcore/types/waap/waap_time_series_attack.py +23 -0
  284. gcore/types/waap/waap_top_session.py +24 -0
  285. gcore/types/waap/waap_top_url.py +13 -0
  286. gcore/types/waap/waap_top_user_agent.py +13 -0
  287. gcore/types/waap/waap_traffic_metrics.py +68 -0
  288. gcore/types/waap/waap_traffic_type.py +28 -0
  289. gcore/types/waap/waap_user_agent_details.py +40 -0
  290. {gcore-0.1.0a2.dist-info → gcore-0.3.0.dist-info}/METADATA +3 -3
  291. {gcore-0.1.0a2.dist-info → gcore-0.3.0.dist-info}/RECORD +293 -126
  292. {gcore-0.1.0a2.dist-info → gcore-0.3.0.dist-info}/WHEEL +0 -0
  293. {gcore-0.1.0a2.dist-info → gcore-0.3.0.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,371 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import List, Iterable, Optional
6
+ from typing_extensions import Literal, Required, TypedDict
7
+
8
+ __all__ = [
9
+ "CustomRuleUpdateParams",
10
+ "Action",
11
+ "ActionBlock",
12
+ "ActionTag",
13
+ "Condition",
14
+ "ConditionContentType",
15
+ "ConditionCountry",
16
+ "ConditionFileExtension",
17
+ "ConditionHeader",
18
+ "ConditionHeaderExists",
19
+ "ConditionHTTPMethod",
20
+ "ConditionIP",
21
+ "ConditionIPRange",
22
+ "ConditionOrganization",
23
+ "ConditionOwnerTypes",
24
+ "ConditionRequestRate",
25
+ "ConditionResponseHeader",
26
+ "ConditionResponseHeaderExists",
27
+ "ConditionSessionRequestCount",
28
+ "ConditionTags",
29
+ "ConditionURL",
30
+ "ConditionUserAgent",
31
+ "ConditionUserDefinedTags",
32
+ ]
33
+
34
+
35
+ class CustomRuleUpdateParams(TypedDict, total=False):
36
+ domain_id: Required[int]
37
+ """The domain ID"""
38
+
39
+ action: Optional[Action]
40
+ """The action that a WAAP rule takes when triggered"""
41
+
42
+ conditions: Optional[Iterable[Condition]]
43
+ """The conditions required for the WAAP engine to trigger the rule.
44
+
45
+ Rules may have between 1 and 5 conditions. All conditions must pass for the rule
46
+ to trigger
47
+ """
48
+
49
+ description: Optional[str]
50
+ """The description assigned to the rule"""
51
+
52
+ enabled: Optional[bool]
53
+ """Whether or not the rule is enabled"""
54
+
55
+ name: Optional[str]
56
+ """The name assigned to the rule"""
57
+
58
+
59
+ class ActionBlock(TypedDict, total=False):
60
+ action_duration: Optional[str]
61
+ """How long a rule's block action will apply to subsequent requests.
62
+
63
+ Can be specified in seconds or by using a numeral followed by 's', 'm', 'h', or
64
+ 'd' to represent time format (seconds, minutes, hours, or days)
65
+ """
66
+
67
+ status_code: Optional[Literal[403, 405, 418, 429]]
68
+ """Designates the HTTP status code to deliver when a request is blocked."""
69
+
70
+
71
+ class ActionTag(TypedDict, total=False):
72
+ tags: Required[List[str]]
73
+ """The list of user defined tags to tag the request with"""
74
+
75
+
76
+ class Action(TypedDict, total=False):
77
+ allow: Optional[object]
78
+ """The WAAP allowed the request"""
79
+
80
+ block: Optional[ActionBlock]
81
+ """
82
+ WAAP block action behavior could be configured with response status code and
83
+ action duration.
84
+ """
85
+
86
+ captcha: Optional[object]
87
+ """The WAAP presented the user with a captcha"""
88
+
89
+ handshake: Optional[object]
90
+ """The WAAP performed automatic browser validation"""
91
+
92
+ monitor: Optional[object]
93
+ """The WAAP monitored the request but took no action"""
94
+
95
+ tag: Optional[ActionTag]
96
+ """WAAP tag action gets a list of tags to tag the request scope with"""
97
+
98
+
99
+ class ConditionContentType(TypedDict, total=False):
100
+ content_type: Required[List[str]]
101
+ """The list of content types to match against"""
102
+
103
+ negation: bool
104
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
105
+
106
+
107
+ class ConditionCountry(TypedDict, total=False):
108
+ country_code: Required[List[str]]
109
+ """
110
+ A list of ISO 3166-1 alpha-2 formatted strings representing the countries to
111
+ match against
112
+ """
113
+
114
+ negation: bool
115
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
116
+
117
+
118
+ class ConditionFileExtension(TypedDict, total=False):
119
+ file_extension: Required[List[str]]
120
+ """The list of file extensions to match against"""
121
+
122
+ negation: bool
123
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
124
+
125
+
126
+ class ConditionHeader(TypedDict, total=False):
127
+ header: Required[str]
128
+ """The request header name"""
129
+
130
+ value: Required[str]
131
+ """The request header value"""
132
+
133
+ match_type: Literal["Exact", "Contains"]
134
+ """The type of matching condition for header and value."""
135
+
136
+ negation: bool
137
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
138
+
139
+
140
+ class ConditionHeaderExists(TypedDict, total=False):
141
+ header: Required[str]
142
+ """The request header name"""
143
+
144
+ negation: bool
145
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
146
+
147
+
148
+ class ConditionHTTPMethod(TypedDict, total=False):
149
+ http_method: Required[Literal["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"]]
150
+ """HTTP methods and descriptions Methods from the following RFCs are all observed:
151
+
152
+ - RFC 7231: Hypertext Transfer Protocol (HTTP/1.1), obsoletes 2616
153
+ - RFC 5789: PATCH Method for HTTP
154
+ """
155
+
156
+ negation: bool
157
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
158
+
159
+
160
+ class ConditionIP(TypedDict, total=False):
161
+ ip_address: Required[str]
162
+ """A single IPv4 or IPv6 address"""
163
+
164
+ negation: bool
165
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
166
+
167
+
168
+ class ConditionIPRange(TypedDict, total=False):
169
+ lower_bound: Required[str]
170
+ """The lower bound IPv4 or IPv6 address to match against"""
171
+
172
+ upper_bound: Required[str]
173
+ """The upper bound IPv4 or IPv6 address to match against"""
174
+
175
+ negation: bool
176
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
177
+
178
+
179
+ class ConditionOrganization(TypedDict, total=False):
180
+ organization: Required[str]
181
+ """The organization to match against"""
182
+
183
+ negation: bool
184
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
185
+
186
+
187
+ class ConditionOwnerTypes(TypedDict, total=False):
188
+ negation: bool
189
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
190
+
191
+ owner_types: List[
192
+ Literal[
193
+ "COMMERCIAL",
194
+ "EDUCATIONAL",
195
+ "GOVERNMENT",
196
+ "HOSTING_SERVICES",
197
+ "ISP",
198
+ "MOBILE_NETWORK",
199
+ "NETWORK",
200
+ "RESERVED",
201
+ ]
202
+ ]
203
+ """
204
+ Match the type of organization that owns the IP address making an incoming
205
+ request
206
+ """
207
+
208
+
209
+ class ConditionRequestRate(TypedDict, total=False):
210
+ path_pattern: Required[str]
211
+ """A regular expression matching the URL path of the incoming request"""
212
+
213
+ requests: Required[int]
214
+ """
215
+ The number of incoming requests over the given time that can trigger a request
216
+ rate condition
217
+ """
218
+
219
+ time: Required[int]
220
+ """
221
+ The number of seconds that the WAAP measures incoming requests over before
222
+ triggering a request rate condition
223
+ """
224
+
225
+ http_methods: Optional[
226
+ List[Literal["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"]]
227
+ ]
228
+ """Possible HTTP request methods that can trigger a request rate condition"""
229
+
230
+ ips: Optional[List[str]]
231
+ """A list of source IPs that can trigger a request rate condition"""
232
+
233
+ user_defined_tag: Optional[str]
234
+ """
235
+ A user-defined tag that can be included in incoming requests and used to trigger
236
+ a request rate condition
237
+ """
238
+
239
+
240
+ class ConditionResponseHeader(TypedDict, total=False):
241
+ header: Required[str]
242
+ """The response header name"""
243
+
244
+ value: Required[str]
245
+ """The response header value"""
246
+
247
+ match_type: Literal["Exact", "Contains"]
248
+ """The type of matching condition for header and value."""
249
+
250
+ negation: bool
251
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
252
+
253
+
254
+ class ConditionResponseHeaderExists(TypedDict, total=False):
255
+ header: Required[str]
256
+ """The response header name"""
257
+
258
+ negation: bool
259
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
260
+
261
+
262
+ class ConditionSessionRequestCount(TypedDict, total=False):
263
+ request_count: Required[int]
264
+ """The number of dynamic requests in the session"""
265
+
266
+ negation: bool
267
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
268
+
269
+
270
+ class ConditionTags(TypedDict, total=False):
271
+ tags: Required[List[str]]
272
+ """A list of tags to match against the request tags"""
273
+
274
+ negation: bool
275
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
276
+
277
+
278
+ class ConditionURL(TypedDict, total=False):
279
+ url: Required[str]
280
+ """The pattern to match against the request URL.
281
+
282
+ If `match_type` is `Regex` the value must be a valid regular expression that
283
+ does not use lookahead or lookbehind constructs
284
+ """
285
+
286
+ match_type: Literal["Exact", "Contains", "Regex"]
287
+ """The type of matching condition."""
288
+
289
+ negation: bool
290
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
291
+
292
+
293
+ class ConditionUserAgent(TypedDict, total=False):
294
+ user_agent: Required[str]
295
+ """The user agent value to match"""
296
+
297
+ match_type: Literal["Exact", "Contains"]
298
+ """The type of matching condition."""
299
+
300
+ negation: bool
301
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
302
+
303
+
304
+ class ConditionUserDefinedTags(TypedDict, total=False):
305
+ tags: Required[List[str]]
306
+ """A list of user-defined tags to match against the request tags"""
307
+
308
+ negation: bool
309
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
310
+
311
+
312
+ class Condition(TypedDict, total=False):
313
+ content_type: Optional[ConditionContentType]
314
+ """Match the requested Content-Type"""
315
+
316
+ country: Optional[ConditionCountry]
317
+ """Match the country that the request originated from"""
318
+
319
+ file_extension: Optional[ConditionFileExtension]
320
+ """Match the incoming file extension"""
321
+
322
+ header: Optional[ConditionHeader]
323
+ """Match an incoming request header"""
324
+
325
+ header_exists: Optional[ConditionHeaderExists]
326
+ """Match when an incoming request header is present"""
327
+
328
+ http_method: Optional[ConditionHTTPMethod]
329
+ """Match the incoming HTTP method"""
330
+
331
+ ip: Optional[ConditionIP]
332
+ """Match the incoming request against a single IP address"""
333
+
334
+ ip_range: Optional[ConditionIPRange]
335
+ """Match the incoming request against an IP range"""
336
+
337
+ organization: Optional[ConditionOrganization]
338
+ """
339
+ Match the organization the request originated from, as determined by a WHOIS
340
+ lookup of the requesting IP
341
+ """
342
+
343
+ owner_types: Optional[ConditionOwnerTypes]
344
+ """
345
+ Match the type of organization that owns the IP address making an incoming
346
+ request
347
+ """
348
+
349
+ request_rate: Optional[ConditionRequestRate]
350
+ """Match the rate at which requests come in that match certain conditions"""
351
+
352
+ response_header: Optional[ConditionResponseHeader]
353
+ """Match a response header"""
354
+
355
+ response_header_exists: Optional[ConditionResponseHeaderExists]
356
+ """Match when a response header is present"""
357
+
358
+ session_request_count: Optional[ConditionSessionRequestCount]
359
+ """Match the number of dynamic page requests made in a WAAP session"""
360
+
361
+ tags: Optional[ConditionTags]
362
+ """Matches requests based on specified tags"""
363
+
364
+ url: Optional[ConditionURL]
365
+ """Match the incoming request URL"""
366
+
367
+ user_agent: Optional[ConditionUserAgent]
368
+ """Match the user agent making the request"""
369
+
370
+ user_defined_tags: Optional[ConditionUserDefinedTags]
371
+ """Matches requests based on user-defined tags"""
@@ -0,0 +1,75 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Iterable, Optional
6
+ from typing_extensions import Literal, Required, TypedDict
7
+
8
+ __all__ = ["FirewallRuleCreateParams", "Action", "ActionBlock", "Condition", "ConditionIP", "ConditionIPRange"]
9
+
10
+
11
+ class FirewallRuleCreateParams(TypedDict, total=False):
12
+ action: Required[Action]
13
+ """The action that a firewall rule takes when triggered"""
14
+
15
+ conditions: Required[Iterable[Condition]]
16
+ """The condition required for the WAAP engine to trigger the rule."""
17
+
18
+ enabled: Required[bool]
19
+ """Whether or not the rule is enabled"""
20
+
21
+ name: Required[str]
22
+ """The name assigned to the rule"""
23
+
24
+ description: Optional[str]
25
+ """The description assigned to the rule"""
26
+
27
+
28
+ class ActionBlock(TypedDict, total=False):
29
+ action_duration: Optional[str]
30
+ """How long a rule's block action will apply to subsequent requests.
31
+
32
+ Can be specified in seconds or by using a numeral followed by 's', 'm', 'h', or
33
+ 'd' to represent time format (seconds, minutes, hours, or days)
34
+ """
35
+
36
+ status_code: Optional[Literal[403, 405, 418, 429]]
37
+ """Designates the HTTP status code to deliver when a request is blocked."""
38
+
39
+
40
+ class Action(TypedDict, total=False):
41
+ allow: Optional[object]
42
+ """The WAAP allowed the request"""
43
+
44
+ block: Optional[ActionBlock]
45
+ """
46
+ WAAP block action behavior could be configured with response status code and
47
+ action duration.
48
+ """
49
+
50
+
51
+ class ConditionIP(TypedDict, total=False):
52
+ ip_address: Required[str]
53
+ """A single IPv4 or IPv6 address"""
54
+
55
+ negation: bool
56
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
57
+
58
+
59
+ class ConditionIPRange(TypedDict, total=False):
60
+ lower_bound: Required[str]
61
+ """The lower bound IPv4 or IPv6 address to match against"""
62
+
63
+ upper_bound: Required[str]
64
+ """The upper bound IPv4 or IPv6 address to match against"""
65
+
66
+ negation: bool
67
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
68
+
69
+
70
+ class Condition(TypedDict, total=False):
71
+ ip: Optional[ConditionIP]
72
+ """Match the incoming request against a single IP address"""
73
+
74
+ ip_range: Optional[ConditionIPRange]
75
+ """Match the incoming request against an IP range"""
@@ -0,0 +1,13 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Iterable
6
+ from typing_extensions import Required, TypedDict
7
+
8
+ __all__ = ["FirewallRuleDeleteMultipleParams"]
9
+
10
+
11
+ class FirewallRuleDeleteMultipleParams(TypedDict, total=False):
12
+ rule_ids: Required[Iterable[int]]
13
+ """The IDs of the rules to delete"""
@@ -0,0 +1,33 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import Literal, TypedDict
7
+
8
+ __all__ = ["FirewallRuleListParams"]
9
+
10
+
11
+ class FirewallRuleListParams(TypedDict, total=False):
12
+ action: Literal["allow", "block"]
13
+ """Filter to refine results by specific firewall actions"""
14
+
15
+ description: str
16
+ """Filter rules based on their description. Supports '\\**' as a wildcard character."""
17
+
18
+ enabled: bool
19
+ """Filter rules based on their active status"""
20
+
21
+ limit: int
22
+ """Number of items to return"""
23
+
24
+ name: str
25
+ """Filter rules based on their name. Supports '\\**' as a wildcard character."""
26
+
27
+ offset: int
28
+ """Number of items to skip"""
29
+
30
+ ordering: Optional[
31
+ Literal["id", "name", "description", "enabled", "action", "-id", "-name", "-description", "-enabled", "-action"]
32
+ ]
33
+ """Determine the field to order results by"""
@@ -0,0 +1,78 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Iterable, Optional
6
+ from typing_extensions import Literal, Required, TypedDict
7
+
8
+ __all__ = ["FirewallRuleUpdateParams", "Action", "ActionBlock", "Condition", "ConditionIP", "ConditionIPRange"]
9
+
10
+
11
+ class FirewallRuleUpdateParams(TypedDict, total=False):
12
+ domain_id: Required[int]
13
+ """The domain ID"""
14
+
15
+ action: Optional[Action]
16
+ """The action that a firewall rule takes when triggered"""
17
+
18
+ conditions: Optional[Iterable[Condition]]
19
+ """The condition required for the WAAP engine to trigger the rule."""
20
+
21
+ description: Optional[str]
22
+ """The description assigned to the rule"""
23
+
24
+ enabled: Optional[bool]
25
+ """Whether or not the rule is enabled"""
26
+
27
+ name: Optional[str]
28
+ """The name assigned to the rule"""
29
+
30
+
31
+ class ActionBlock(TypedDict, total=False):
32
+ action_duration: Optional[str]
33
+ """How long a rule's block action will apply to subsequent requests.
34
+
35
+ Can be specified in seconds or by using a numeral followed by 's', 'm', 'h', or
36
+ 'd' to represent time format (seconds, minutes, hours, or days)
37
+ """
38
+
39
+ status_code: Optional[Literal[403, 405, 418, 429]]
40
+ """Designates the HTTP status code to deliver when a request is blocked."""
41
+
42
+
43
+ class Action(TypedDict, total=False):
44
+ allow: Optional[object]
45
+ """The WAAP allowed the request"""
46
+
47
+ block: Optional[ActionBlock]
48
+ """
49
+ WAAP block action behavior could be configured with response status code and
50
+ action duration.
51
+ """
52
+
53
+
54
+ class ConditionIP(TypedDict, total=False):
55
+ ip_address: Required[str]
56
+ """A single IPv4 or IPv6 address"""
57
+
58
+ negation: bool
59
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
60
+
61
+
62
+ class ConditionIPRange(TypedDict, total=False):
63
+ lower_bound: Required[str]
64
+ """The lower bound IPv4 or IPv6 address to match against"""
65
+
66
+ upper_bound: Required[str]
67
+ """The upper bound IPv4 or IPv6 address to match against"""
68
+
69
+ negation: bool
70
+ """Whether or not to apply a boolean NOT operation to the rule's condition"""
71
+
72
+
73
+ class Condition(TypedDict, total=False):
74
+ ip: Optional[ConditionIP]
75
+ """Match the incoming request against a single IP address"""
76
+
77
+ ip_range: Optional[ConditionIPRange]
78
+ """Match the incoming request against an IP range"""
@@ -0,0 +1,34 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import List, Optional
6
+ from typing_extensions import TypedDict
7
+
8
+ from ..waap_insight_status import WaapInsightStatus
9
+ from ..waap_insight_sort_by import WaapInsightSortBy
10
+
11
+ __all__ = ["InsightListParams"]
12
+
13
+
14
+ class InsightListParams(TypedDict, total=False):
15
+ id: Optional[List[str]]
16
+ """The ID of the insight"""
17
+
18
+ description: Optional[str]
19
+ """The description of the insight. Supports '\\**' as a wildcard."""
20
+
21
+ insight_type: Optional[List[str]]
22
+ """The type of the insight"""
23
+
24
+ limit: int
25
+ """Number of items to return"""
26
+
27
+ offset: int
28
+ """Number of items to skip"""
29
+
30
+ ordering: WaapInsightSortBy
31
+ """Sort the response by given field."""
32
+
33
+ status: Optional[List[WaapInsightStatus]]
34
+ """The status of the insight"""
@@ -0,0 +1,17 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing_extensions import Required, TypedDict
6
+
7
+ from ..waap_insight_status import WaapInsightStatus
8
+
9
+ __all__ = ["InsightReplaceParams"]
10
+
11
+
12
+ class InsightReplaceParams(TypedDict, total=False):
13
+ domain_id: Required[int]
14
+ """The domain ID"""
15
+
16
+ status: Required[WaapInsightStatus]
17
+ """The different statuses an insight can have"""
@@ -0,0 +1,28 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Dict, Union
6
+ from datetime import datetime
7
+ from typing_extensions import Required, Annotated, TypedDict
8
+
9
+ from ...._utils import PropertyInfo
10
+
11
+ __all__ = ["InsightSilenceCreateParams"]
12
+
13
+
14
+ class InsightSilenceCreateParams(TypedDict, total=False):
15
+ author: Required[str]
16
+ """The author of the silence"""
17
+
18
+ comment: Required[str]
19
+ """A comment explaining the reason for the silence"""
20
+
21
+ insight_type: Required[str]
22
+ """The slug of the insight type"""
23
+
24
+ labels: Required[Dict[str, str]]
25
+ """A hash table of label names and values that apply to the insight silence"""
26
+
27
+ expire_at: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
28
+ """The date and time the silence expires in ISO 8601 format"""
@@ -0,0 +1,33 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import List, Optional
6
+ from typing_extensions import TypedDict
7
+
8
+ from ..waap_insight_silence_sort_by import WaapInsightSilenceSortBy
9
+
10
+ __all__ = ["InsightSilenceListParams"]
11
+
12
+
13
+ class InsightSilenceListParams(TypedDict, total=False):
14
+ id: Optional[List[str]]
15
+ """The ID of the insight silence"""
16
+
17
+ author: Optional[str]
18
+ """The author of the insight silence"""
19
+
20
+ comment: Optional[str]
21
+ """The comment of the insight silence"""
22
+
23
+ insight_type: Optional[List[str]]
24
+ """The type of the insight silence"""
25
+
26
+ limit: int
27
+ """Number of items to return"""
28
+
29
+ offset: int
30
+ """Number of items to skip"""
31
+
32
+ ordering: WaapInsightSilenceSortBy
33
+ """Sort the response by given field."""