gcore 0.13.0__py3-none-any.whl → 0.15.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 (345) hide show
  1. gcore/__init__.py +3 -1
  2. gcore/_base_client.py +9 -9
  3. gcore/_client.py +25 -10
  4. gcore/_models.py +10 -4
  5. gcore/_qs.py +7 -7
  6. gcore/_types.py +18 -11
  7. gcore/_utils/_transform.py +2 -2
  8. gcore/_utils/_utils.py +4 -4
  9. gcore/_version.py +1 -1
  10. gcore/pagination.py +137 -0
  11. gcore/resources/__init__.py +14 -0
  12. gcore/resources/cdn/__init__.py +201 -0
  13. gcore/resources/cdn/audit_log.py +406 -0
  14. gcore/resources/cdn/cdn.py +957 -0
  15. gcore/resources/cdn/certificates.py +1062 -0
  16. gcore/resources/cdn/ip_ranges.py +224 -0
  17. gcore/resources/cdn/logs/__init__.py +33 -0
  18. gcore/resources/cdn/logs/logs.py +1424 -0
  19. gcore/resources/cdn/logs/settings.py +1081 -0
  20. gcore/resources/cdn/logs_uploader/__init__.py +61 -0
  21. gcore/resources/cdn/logs_uploader/configs.py +868 -0
  22. gcore/resources/cdn/logs_uploader/logs_uploader.py +166 -0
  23. gcore/resources/cdn/logs_uploader/policies.py +1060 -0
  24. gcore/resources/cdn/logs_uploader/targets.py +811 -0
  25. gcore/resources/cdn/metrics.py +419 -0
  26. gcore/resources/cdn/network_capacity.py +139 -0
  27. gcore/resources/cdn/origin_groups.py +1496 -0
  28. gcore/resources/cdn/resources/__init__.py +47 -0
  29. gcore/resources/cdn/resources/resources.py +2060 -0
  30. gcore/resources/cdn/resources/rules.py +1027 -0
  31. gcore/resources/cdn/resources/shield.py +259 -0
  32. gcore/resources/cdn/rule_templates.py +883 -0
  33. gcore/resources/cdn/shields.py +139 -0
  34. gcore/resources/cdn/statistics.py +1408 -0
  35. gcore/resources/cdn/trusted_ca_certificates.py +592 -0
  36. gcore/resources/cloud/audit_logs.py +33 -29
  37. gcore/resources/cloud/baremetal/flavors.py +21 -17
  38. gcore/resources/cloud/baremetal/images.py +19 -15
  39. gcore/resources/cloud/baremetal/servers.py +141 -119
  40. gcore/resources/cloud/billing_reservations.py +41 -33
  41. gcore/resources/cloud/cloud.py +24 -0
  42. gcore/resources/cloud/cost_reports.py +149 -119
  43. gcore/resources/cloud/file_shares/access_rules.py +25 -13
  44. gcore/resources/cloud/file_shares/file_shares.py +107 -71
  45. gcore/resources/cloud/floating_ips.py +101 -59
  46. gcore/resources/cloud/gpu_baremetal_clusters/flavors.py +13 -9
  47. gcore/resources/cloud/gpu_baremetal_clusters/gpu_baremetal_clusters.py +275 -65
  48. gcore/resources/cloud/gpu_baremetal_clusters/images.py +69 -53
  49. gcore/resources/cloud/gpu_baremetal_clusters/interfaces.py +9 -5
  50. gcore/resources/cloud/gpu_baremetal_clusters/servers.py +151 -127
  51. gcore/resources/cloud/inference/api_keys.py +51 -31
  52. gcore/resources/cloud/inference/applications/deployments.py +49 -31
  53. gcore/resources/cloud/inference/applications/templates.py +17 -9
  54. gcore/resources/cloud/inference/deployments/deployments.py +171 -139
  55. gcore/resources/cloud/inference/deployments/logs.py +17 -13
  56. gcore/resources/cloud/inference/flavors.py +21 -13
  57. gcore/resources/cloud/inference/inference.py +9 -5
  58. gcore/resources/cloud/inference/registry_credentials.py +45 -25
  59. gcore/resources/cloud/inference/secrets.py +45 -25
  60. gcore/resources/cloud/instances/flavors.py +17 -13
  61. gcore/resources/cloud/instances/images.py +153 -129
  62. gcore/resources/cloud/instances/instances.py +287 -213
  63. gcore/resources/cloud/instances/interfaces.py +165 -161
  64. gcore/resources/cloud/instances/metrics.py +9 -5
  65. gcore/resources/cloud/ip_ranges.py +25 -15
  66. gcore/resources/cloud/k8s/clusters/clusters.py +151 -87
  67. gcore/resources/cloud/k8s/clusters/nodes.py +19 -11
  68. gcore/resources/cloud/k8s/clusters/pools/nodes.py +19 -11
  69. gcore/resources/cloud/k8s/clusters/pools/pools.py +83 -59
  70. gcore/resources/cloud/k8s/flavors.py +13 -9
  71. gcore/resources/cloud/k8s/k8s.py +9 -5
  72. gcore/resources/cloud/load_balancers/flavors.py +11 -7
  73. gcore/resources/cloud/load_balancers/l7_policies/l7_policies.py +103 -83
  74. gcore/resources/cloud/load_balancers/l7_policies/rules.py +77 -57
  75. gcore/resources/cloud/load_balancers/listeners.py +125 -105
  76. gcore/resources/cloud/load_balancers/load_balancers.py +155 -123
  77. gcore/resources/cloud/load_balancers/metrics.py +9 -5
  78. gcore/resources/cloud/load_balancers/pools/health_monitors.py +25 -17
  79. gcore/resources/cloud/load_balancers/pools/members.py +31 -23
  80. gcore/resources/cloud/load_balancers/pools/pools.py +155 -129
  81. gcore/resources/cloud/load_balancers/statuses.py +17 -9
  82. gcore/resources/cloud/networks/networks.py +79 -55
  83. gcore/resources/cloud/networks/routers.py +75 -47
  84. gcore/resources/cloud/networks/subnets.py +109 -87
  85. gcore/resources/cloud/placement_groups.py +33 -17
  86. gcore/resources/cloud/projects.py +53 -41
  87. gcore/resources/cloud/quotas/quotas.py +25 -13
  88. gcore/resources/cloud/quotas/requests.py +41 -25
  89. gcore/resources/cloud/regions.py +25 -23
  90. gcore/resources/cloud/registries/artifacts.py +17 -9
  91. gcore/resources/cloud/registries/registries.py +55 -29
  92. gcore/resources/cloud/registries/repositories.py +17 -9
  93. gcore/resources/cloud/registries/tags.py +9 -5
  94. gcore/resources/cloud/registries/users.py +65 -35
  95. gcore/resources/cloud/reserved_fixed_ips/reserved_fixed_ips.py +233 -108
  96. gcore/resources/cloud/reserved_fixed_ips/vip.py +45 -25
  97. gcore/resources/cloud/secrets.py +43 -27
  98. gcore/resources/cloud/security_groups/rules.py +55 -43
  99. gcore/resources/cloud/security_groups/security_groups.py +79 -47
  100. gcore/resources/cloud/ssh_keys.py +51 -31
  101. gcore/resources/cloud/tasks.py +57 -45
  102. gcore/resources/cloud/usage_reports.py +27 -23
  103. gcore/resources/cloud/users/role_assignments.py +49 -33
  104. gcore/resources/cloud/volumes.py +237 -201
  105. gcore/resources/dns/dns.py +17 -13
  106. gcore/resources/dns/locations.py +29 -17
  107. gcore/resources/dns/metrics.py +13 -9
  108. gcore/resources/dns/pickers/pickers.py +5 -5
  109. gcore/resources/dns/pickers/presets.py +9 -5
  110. gcore/resources/dns/zones/dnssec.py +19 -11
  111. gcore/resources/dns/zones/rrsets.py +149 -91
  112. gcore/resources/dns/zones/zones.py +245 -187
  113. gcore/resources/fastedge/apps/apps.py +105 -89
  114. gcore/resources/fastedge/apps/logs.py +25 -21
  115. gcore/resources/fastedge/binaries.py +33 -17
  116. gcore/resources/fastedge/fastedge.py +5 -5
  117. gcore/resources/fastedge/kv_stores.py +43 -31
  118. gcore/resources/fastedge/secrets.py +69 -45
  119. gcore/resources/fastedge/statistics.py +25 -17
  120. gcore/resources/fastedge/templates.py +59 -39
  121. gcore/resources/iam/api_tokens.py +47 -29
  122. gcore/resources/iam/iam.py +5 -5
  123. gcore/resources/iam/users.py +97 -65
  124. gcore/resources/security/bgp_announces.py +27 -19
  125. gcore/resources/security/events.py +23 -19
  126. gcore/resources/security/profile_templates.py +9 -5
  127. gcore/resources/security/profiles.py +69 -45
  128. gcore/resources/storage/buckets/buckets.py +37 -25
  129. gcore/resources/storage/buckets/cors.py +19 -11
  130. gcore/resources/storage/buckets/lifecycle.py +19 -11
  131. gcore/resources/storage/buckets/policy.py +25 -13
  132. gcore/resources/storage/credentials.py +19 -15
  133. gcore/resources/storage/locations.py +13 -9
  134. gcore/resources/storage/statistics.py +39 -31
  135. gcore/resources/storage/storage.py +105 -69
  136. gcore/resources/streaming/ai_tasks.py +307 -197
  137. gcore/resources/streaming/broadcasts.py +63 -35
  138. gcore/resources/streaming/directories.py +65 -39
  139. gcore/resources/streaming/players.py +47 -31
  140. gcore/resources/streaming/playlists.py +189 -123
  141. gcore/resources/streaming/quality_sets.py +69 -39
  142. gcore/resources/streaming/restreams.py +47 -27
  143. gcore/resources/streaming/statistics.py +613 -407
  144. gcore/resources/streaming/streams/overlays.py +107 -67
  145. gcore/resources/streaming/streams/streams.py +403 -263
  146. gcore/resources/streaming/videos/subtitles.py +131 -75
  147. gcore/resources/streaming/videos/videos.py +429 -279
  148. gcore/resources/waap/advanced_rules.py +9 -5
  149. gcore/resources/waap/custom_page_sets.py +99 -75
  150. gcore/resources/waap/domains/advanced_rules.py +157 -99
  151. gcore/resources/waap/domains/api_discovery.py +71 -47
  152. gcore/resources/waap/domains/api_path_groups.py +9 -5
  153. gcore/resources/waap/domains/api_paths.py +79 -83
  154. gcore/resources/waap/domains/custom_rules.py +89 -59
  155. gcore/resources/waap/domains/domains.py +59 -41
  156. gcore/resources/waap/domains/firewall_rules.py +83 -55
  157. gcore/resources/waap/domains/insight_silences.py +59 -39
  158. gcore/resources/waap/domains/insights.py +39 -27
  159. gcore/resources/waap/domains/settings.py +21 -13
  160. gcore/resources/waap/domains/statistics.py +99 -75
  161. gcore/resources/waap/insights.py +23 -21
  162. gcore/resources/waap/ip_info/ip_info.py +65 -33
  163. gcore/resources/waap/ip_info/metrics.py +11 -7
  164. gcore/resources/waap/organizations.py +17 -13
  165. gcore/resources/waap/statistics.py +9 -5
  166. gcore/resources/waap/tags.py +17 -17
  167. gcore/resources/waap/waap.py +5 -5
  168. gcore/types/cdn/__init__.py +80 -0
  169. gcore/types/cdn/audit_log_list_params.py +73 -0
  170. gcore/types/cdn/ca_certificate.py +53 -0
  171. gcore/types/cdn/ca_certificate_list.py +10 -0
  172. gcore/types/cdn/cdn_account.py +86 -0
  173. gcore/types/cdn/cdn_account_limits.py +27 -0
  174. gcore/types/cdn/cdn_audit_log_entry.py +66 -0
  175. gcore/types/cdn/cdn_available_features.py +46 -0
  176. gcore/types/cdn/cdn_list_purge_statuses_params.py +67 -0
  177. gcore/types/cdn/cdn_log_entry.py +70 -0
  178. gcore/types/cdn/cdn_metrics.py +22 -0
  179. gcore/types/cdn/cdn_metrics_groups.py +13 -0
  180. gcore/types/cdn/cdn_metrics_values.py +19 -0
  181. gcore/types/cdn/cdn_resource.py +1997 -0
  182. gcore/types/cdn/cdn_resource_list.py +10 -0
  183. gcore/types/cdn/cdn_update_account_params.py +15 -0
  184. gcore/types/cdn/certificate_create_params.py +51 -0
  185. gcore/types/cdn/certificate_get_status_params.py +14 -0
  186. gcore/types/cdn/certificate_list_params.py +29 -0
  187. gcore/types/cdn/certificate_replace_params.py +39 -0
  188. gcore/types/cdn/log_download_params.py +279 -0
  189. gcore/types/cdn/log_list_params.py +273 -0
  190. gcore/types/cdn/logs/__init__.py +7 -0
  191. gcore/types/cdn/logs/log_settings.py +172 -0
  192. gcore/types/cdn/logs/setting_create_params.py +200 -0
  193. gcore/types/cdn/logs/setting_update_params.py +200 -0
  194. gcore/types/cdn/logs_aggregated_stats.py +23 -0
  195. gcore/types/cdn/logs_uploader/__init__.py +23 -0
  196. gcore/types/cdn/logs_uploader/config_create_params.py +32 -0
  197. gcore/types/cdn/logs_uploader/config_list_params.py +16 -0
  198. gcore/types/cdn/logs_uploader/config_replace_params.py +32 -0
  199. gcore/types/cdn/logs_uploader/config_update_params.py +32 -0
  200. gcore/types/cdn/logs_uploader/logs_uploader_config.py +51 -0
  201. gcore/types/cdn/logs_uploader/logs_uploader_config_list.py +10 -0
  202. gcore/types/cdn/logs_uploader/logs_uploader_policy.py +73 -0
  203. gcore/types/cdn/logs_uploader/logs_uploader_policy_list.py +10 -0
  204. gcore/types/cdn/logs_uploader/logs_uploader_target.py +236 -0
  205. gcore/types/cdn/logs_uploader/logs_uploader_target_list.py +10 -0
  206. gcore/types/cdn/logs_uploader/policy_create_params.py +61 -0
  207. gcore/types/cdn/logs_uploader/policy_list_fields_response.py +8 -0
  208. gcore/types/cdn/logs_uploader/policy_list_params.py +16 -0
  209. gcore/types/cdn/logs_uploader/policy_replace_params.py +61 -0
  210. gcore/types/cdn/logs_uploader/policy_update_params.py +61 -0
  211. gcore/types/cdn/logs_uploader/target_create_params.py +249 -0
  212. gcore/types/cdn/logs_uploader/target_list_params.py +16 -0
  213. gcore/types/cdn/logs_uploader/target_replace_params.py +249 -0
  214. gcore/types/cdn/logs_uploader/target_update_params.py +249 -0
  215. gcore/types/cdn/logs_uploader_validation.py +23 -0
  216. gcore/types/cdn/metric_list_params.py +168 -0
  217. gcore/types/cdn/network_capacity.py +22 -0
  218. gcore/types/cdn/origin_group_create_params.py +184 -0
  219. gcore/types/cdn/origin_group_list_params.py +24 -0
  220. gcore/types/cdn/origin_group_replace_params.py +190 -0
  221. gcore/types/cdn/origin_group_update_params.py +190 -0
  222. gcore/types/cdn/origin_groups.py +212 -0
  223. gcore/types/cdn/origin_groups_list.py +10 -0
  224. gcore/types/cdn/public_ip_list.py +15 -0
  225. gcore/types/cdn/public_network_list.py +15 -0
  226. gcore/types/cdn/purge_status.py +55 -0
  227. gcore/types/cdn/resource_aggregated_stats.py +80 -0
  228. gcore/types/cdn/resource_create_params.py +1845 -0
  229. gcore/types/cdn/resource_list_params.py +107 -0
  230. gcore/types/cdn/resource_prefetch_params.py +17 -0
  231. gcore/types/cdn/resource_purge_params.py +71 -0
  232. gcore/types/cdn/resource_replace_params.py +1823 -0
  233. gcore/types/cdn/resource_update_params.py +1814 -0
  234. gcore/types/cdn/resource_usage_stats.py +111 -0
  235. gcore/types/cdn/resources/__init__.py +11 -0
  236. gcore/types/cdn/resources/cdn_resource_rule.py +1715 -0
  237. gcore/types/cdn/resources/origin_shielding.py +15 -0
  238. gcore/types/cdn/resources/rule_create_params.py +1672 -0
  239. gcore/types/cdn/resources/rule_list_response.py +10 -0
  240. gcore/types/cdn/resources/rule_replace_params.py +1674 -0
  241. gcore/types/cdn/resources/rule_update_params.py +1674 -0
  242. gcore/types/cdn/resources/shield_replace_params.py +16 -0
  243. gcore/types/cdn/rule_template.py +1686 -0
  244. gcore/types/cdn/rule_template_create_params.py +1656 -0
  245. gcore/types/cdn/rule_template_list.py +10 -0
  246. gcore/types/cdn/rule_template_replace_params.py +1656 -0
  247. gcore/types/cdn/rule_template_update_params.py +1656 -0
  248. gcore/types/cdn/shield_aggregated_stats.py +23 -0
  249. gcore/types/cdn/shield_list_response.py +25 -0
  250. gcore/types/cdn/ssl_detail.py +62 -0
  251. gcore/types/cdn/ssl_detail_list.py +10 -0
  252. gcore/types/cdn/ssl_request_status.py +135 -0
  253. gcore/types/cdn/statistic_get_logs_usage_aggregated_params.py +42 -0
  254. gcore/types/cdn/statistic_get_logs_usage_series_params.py +35 -0
  255. gcore/types/cdn/statistic_get_resource_usage_aggregated_params.py +151 -0
  256. gcore/types/cdn/statistic_get_resource_usage_series_params.py +131 -0
  257. gcore/types/cdn/statistic_get_shield_usage_aggregated_params.py +42 -0
  258. gcore/types/cdn/statistic_get_shield_usage_series_params.py +25 -0
  259. gcore/types/cdn/trusted_ca_certificate_create_params.py +23 -0
  260. gcore/types/cdn/trusted_ca_certificate_list_params.py +29 -0
  261. gcore/types/cdn/trusted_ca_certificate_replace_params.py +15 -0
  262. gcore/types/cdn/usage_series_stats.py +31 -0
  263. gcore/types/cloud/__init__.py +2 -0
  264. gcore/types/cloud/file_share.py +4 -0
  265. gcore/types/cloud/file_share_create_params.py +20 -0
  266. gcore/types/cloud/file_share_update_params.py +40 -3
  267. gcore/types/cloud/floating_ip_update_params.py +3 -1
  268. gcore/types/cloud/gpu_baremetal_cluster_action_params.py +46 -0
  269. gcore/types/cloud/gpu_baremetal_clusters/gpu_baremetal_flavor.py +12 -0
  270. gcore/types/cloud/inference/inference_deployment.py +3 -1
  271. gcore/types/cloud/instance_create_params.py +3 -1
  272. gcore/types/cloud/k8s/cluster_create_params.py +46 -4
  273. gcore/types/cloud/k8s/cluster_update_params.py +60 -6
  274. gcore/types/cloud/k8s/clusters/pool_update_params.py +1 -1
  275. gcore/types/cloud/k8s/k8s_cluster.py +40 -3
  276. gcore/types/cloud/load_balancer_update_params.py +3 -1
  277. gcore/types/cloud/network_update_params.py +3 -1
  278. gcore/types/cloud/networks/subnet_update_params.py +3 -1
  279. gcore/types/cloud/quota_get_all_response.py +8 -8
  280. gcore/types/cloud/quota_get_by_region_response.py +8 -8
  281. gcore/types/cloud/quotas/request_create_params.py +4 -4
  282. gcore/types/cloud/quotas/request_get_response.py +4 -4
  283. gcore/types/cloud/quotas/request_list_response.py +4 -4
  284. gcore/types/cloud/registries/user_create_multiple_params.py +5 -3
  285. gcore/types/cloud/registries/user_create_params.py +5 -3
  286. gcore/types/cloud/registry_create_params.py +5 -3
  287. gcore/types/cloud/reserved_fixed_ip_update_params.py +16 -0
  288. gcore/types/cloud/security_group_update_params.py +3 -1
  289. gcore/types/cloud/ssh_key_created.py +6 -3
  290. gcore/types/cloud/volume_update_params.py +3 -1
  291. gcore/types/dns/zone_get_statistics_params.py +12 -9
  292. gcore/types/dns/zone_get_statistics_response.py +3 -1
  293. gcore/types/dns/zone_import_params.py +21 -15
  294. gcore/types/dns/zones/dns_output_rrset.py +7 -3
  295. gcore/types/iam/account_overview.py +31 -28
  296. gcore/types/iam/api_token.py +24 -24
  297. gcore/types/iam/api_token_create_params.py +2 -1
  298. gcore/types/iam/api_token_list.py +24 -24
  299. gcore/types/iam/user.py +7 -2
  300. gcore/types/iam/user_detailed.py +22 -17
  301. gcore/types/iam/user_invite.py +2 -4
  302. gcore/types/iam/user_invite_params.py +4 -1
  303. gcore/types/iam/user_update.py +22 -17
  304. gcore/types/iam/user_update_params.py +7 -2
  305. gcore/types/streaming/ai_contentmoderation_hardnudity.py +6 -4
  306. gcore/types/streaming/ai_contentmoderation_nsfw.py +6 -4
  307. gcore/types/streaming/ai_contentmoderation_softnudity.py +6 -4
  308. gcore/types/streaming/ai_contentmoderation_sport.py +6 -4
  309. gcore/types/streaming/ai_task.py +20 -11
  310. gcore/types/streaming/ai_task_create_params.py +20 -11
  311. gcore/types/streaming/ai_task_get_response.py +5 -4
  312. gcore/types/streaming/ai_task_list_params.py +11 -5
  313. gcore/types/streaming/clip.py +33 -22
  314. gcore/types/streaming/create_video_param.py +75 -43
  315. gcore/types/streaming/playlist.py +7 -5
  316. gcore/types/streaming/playlist_create_params.py +7 -5
  317. gcore/types/streaming/playlist_update_params.py +7 -5
  318. gcore/types/streaming/playlist_video.py +75 -43
  319. gcore/types/streaming/statistic_get_unique_viewers_cdn_params.py +7 -4
  320. gcore/types/streaming/stream.py +207 -136
  321. gcore/types/streaming/stream_create_clip_params.py +33 -22
  322. gcore/types/streaming/stream_create_params.py +41 -24
  323. gcore/types/streaming/stream_update_params.py +41 -24
  324. gcore/types/streaming/video.py +138 -76
  325. gcore/types/streaming/video_list_params.py +4 -2
  326. gcore/types/streaming/video_update_params.py +75 -43
  327. gcore/types/waap/domain_update_params.py +2 -2
  328. gcore/types/waap/domains/advanced_rule_create_params.py +26 -18
  329. gcore/types/waap/domains/advanced_rule_list_params.py +10 -7
  330. gcore/types/waap/domains/advanced_rule_update_params.py +22 -17
  331. gcore/types/waap/domains/api_path_create_params.py +0 -3
  332. gcore/types/waap/domains/api_path_update_params.py +1 -3
  333. gcore/types/waap/domains/custom_rule_create_params.py +36 -35
  334. gcore/types/waap/domains/custom_rule_update_params.py +31 -33
  335. gcore/types/waap/domains/firewall_rule_create_params.py +6 -6
  336. gcore/types/waap/domains/firewall_rule_update_params.py +5 -5
  337. gcore/types/waap/domains/waap_advanced_rule.py +17 -9
  338. gcore/types/waap/domains/waap_custom_rule.py +5 -2
  339. gcore/types/waap/domains/waap_firewall_rule.py +1 -1
  340. gcore/types/waap/domains/waap_insight.py +1 -1
  341. gcore/types/waap/insight_list_types_params.py +1 -1
  342. {gcore-0.13.0.dist-info → gcore-0.15.0.dist-info}/METADATA +1 -1
  343. {gcore-0.13.0.dist-info → gcore-0.15.0.dist-info}/RECORD +345 -224
  344. {gcore-0.13.0.dist-info → gcore-0.15.0.dist-info}/WHEEL +0 -0
  345. {gcore-0.13.0.dist-info → gcore-0.15.0.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,1674 @@
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, List, Iterable, Optional
6
+ from typing_extensions import Literal, Required, Annotated, TypedDict
7
+
8
+ from ...._types import SequenceNotStr
9
+ from ...._utils import PropertyInfo
10
+
11
+ __all__ = [
12
+ "RuleReplaceParams",
13
+ "Options",
14
+ "OptionsAllowedHTTPMethods",
15
+ "OptionsBotProtection",
16
+ "OptionsBotProtectionBotChallenge",
17
+ "OptionsBrotliCompression",
18
+ "OptionsBrowserCacheSettings",
19
+ "OptionsCacheHTTPHeaders",
20
+ "OptionsCors",
21
+ "OptionsCountryACL",
22
+ "OptionsDisableCache",
23
+ "OptionsDisableProxyForceRanges",
24
+ "OptionsEdgeCacheSettings",
25
+ "OptionsFastedge",
26
+ "OptionsFastedgeOnRequestBody",
27
+ "OptionsFastedgeOnRequestHeaders",
28
+ "OptionsFastedgeOnResponseBody",
29
+ "OptionsFastedgeOnResponseHeaders",
30
+ "OptionsFetchCompressed",
31
+ "OptionsFollowOriginRedirect",
32
+ "OptionsForceReturn",
33
+ "OptionsForceReturnTimeInterval",
34
+ "OptionsForwardHostHeader",
35
+ "OptionsGzipOn",
36
+ "OptionsHostHeader",
37
+ "OptionsIgnoreCookie",
38
+ "OptionsIgnoreQueryString",
39
+ "OptionsImageStack",
40
+ "OptionsIPAddressACL",
41
+ "OptionsLimitBandwidth",
42
+ "OptionsProxyCacheKey",
43
+ "OptionsProxyCacheMethodsSet",
44
+ "OptionsProxyConnectTimeout",
45
+ "OptionsProxyReadTimeout",
46
+ "OptionsQueryParamsBlacklist",
47
+ "OptionsQueryParamsWhitelist",
48
+ "OptionsQueryStringForwarding",
49
+ "OptionsRedirectHTTPToHTTPS",
50
+ "OptionsRedirectHTTPSToHTTP",
51
+ "OptionsReferrerACL",
52
+ "OptionsRequestLimiter",
53
+ "OptionsResponseHeadersHidingPolicy",
54
+ "OptionsRewrite",
55
+ "OptionsSecureKey",
56
+ "OptionsSlice",
57
+ "OptionsSni",
58
+ "OptionsStale",
59
+ "OptionsStaticResponseHeaders",
60
+ "OptionsStaticResponseHeadersValue",
61
+ "OptionsStaticHeaders",
62
+ "OptionsStaticRequestHeaders",
63
+ "OptionsUserAgentACL",
64
+ "OptionsWaap",
65
+ "OptionsWebsockets",
66
+ ]
67
+
68
+
69
+ class RuleReplaceParams(TypedDict, total=False):
70
+ resource_id: Required[int]
71
+
72
+ rule: Required[str]
73
+ """Path to the file or folder for which the rule will be applied.
74
+
75
+ The rule is applied if the requested URI matches the rule path.
76
+
77
+ We add a leading forward slash to any rule path. Specify a path without a
78
+ forward slash.
79
+ """
80
+
81
+ rule_type: Required[Annotated[int, PropertyInfo(alias="ruleType")]]
82
+ """Rule type.
83
+
84
+ Possible values:
85
+
86
+ - **Type 0** - Regular expression. Must start with '^/' or '/'.
87
+ - **Type 1** - Regular expression. Note that for this rule type we automatically
88
+ add / to each rule pattern before your regular expression. This type is
89
+ **legacy**, please use Type 0.
90
+ """
91
+
92
+ active: bool
93
+ """Enables or disables a rule.
94
+
95
+ Possible values:
96
+
97
+ - **true** - Rule is active, rule settings are applied.
98
+ - **false** - Rule is inactive, rule settings are not applied.
99
+ """
100
+
101
+ name: str
102
+ """Rule name."""
103
+
104
+ options: Options
105
+ """List of options that can be configured for the rule.
106
+
107
+ In case of `null` value the option is not added to the rule. Option inherits its
108
+ value from the CDN resource settings.
109
+ """
110
+
111
+ origin_group: Annotated[Optional[int], PropertyInfo(alias="originGroup")]
112
+ """ID of the origin group to which the rule is applied.
113
+
114
+ If the origin group is not specified, the rule is applied to the origin group
115
+ that the CDN resource is associated with.
116
+ """
117
+
118
+ override_origin_protocol: Annotated[
119
+ Optional[Literal["HTTPS", "HTTP", "MATCH"]], PropertyInfo(alias="overrideOriginProtocol")
120
+ ]
121
+ """
122
+ Sets a protocol other than the one specified in the CDN resource settings to
123
+ connect to the origin.
124
+
125
+ Possible values:
126
+
127
+ - **HTTPS** - CDN servers connect to origin via HTTPS protocol.
128
+ - **HTTP** - CDN servers connect to origin via HTTP protocol.
129
+ - **MATCH** - Connection protocol is chosen automatically; in this case, content
130
+ on origin source should be available for the CDN both through HTTP and HTTPS
131
+ protocols.
132
+ - **null** - `originProtocol` setting is inherited from the CDN resource
133
+ settings.
134
+ """
135
+
136
+ weight: int
137
+ """Rule execution order: from lowest (1) to highest.
138
+
139
+ If requested URI matches multiple rules, the one higher in the order of the
140
+ rules will be applied.
141
+ """
142
+
143
+
144
+ class OptionsAllowedHTTPMethods(TypedDict, total=False):
145
+ enabled: Required[bool]
146
+ """Controls the option state.
147
+
148
+ Possible values:
149
+
150
+ - **true** - Option is enabled.
151
+ - **false** - Option is disabled.
152
+ """
153
+
154
+ value: Required[List[Literal["GET", "HEAD", "POST", "PUT", "PATCH", "DELETE", "OPTIONS"]]]
155
+
156
+
157
+ class OptionsBotProtectionBotChallenge(TypedDict, total=False):
158
+ enabled: bool
159
+ """Possible values:
160
+
161
+ - **true** - Bot challenge is enabled.
162
+ - **false** - Bot challenge is disabled.
163
+ """
164
+
165
+
166
+ class OptionsBotProtection(TypedDict, total=False):
167
+ bot_challenge: Required[OptionsBotProtectionBotChallenge]
168
+ """Controls the bot challenge module state."""
169
+
170
+ enabled: Required[bool]
171
+ """Controls the option state.
172
+
173
+ Possible values:
174
+
175
+ - **true** - Option is enabled.
176
+ - **false** - Option is disabled.
177
+ """
178
+
179
+
180
+ class OptionsBrotliCompression(TypedDict, total=False):
181
+ enabled: Required[bool]
182
+ """Controls the option state.
183
+
184
+ Possible values:
185
+
186
+ - **true** - Option is enabled.
187
+ - **false** - Option is disabled.
188
+ """
189
+
190
+ value: Required[
191
+ List[
192
+ Literal[
193
+ "application/javascript",
194
+ "application/json",
195
+ "application/vnd.ms-fontobject",
196
+ "application/wasm",
197
+ "application/x-font-ttf",
198
+ "application/x-javascript",
199
+ "application/xml",
200
+ "application/xml+rss",
201
+ "image/svg+xml",
202
+ "image/x-icon",
203
+ "text/css",
204
+ "text/html",
205
+ "text/javascript",
206
+ "text/plain",
207
+ "text/xml",
208
+ ]
209
+ ]
210
+ ]
211
+ """Allows to select the content types you want to compress.
212
+
213
+ `text/html` is a mandatory content type.
214
+ """
215
+
216
+
217
+ class OptionsBrowserCacheSettings(TypedDict, total=False):
218
+ enabled: Required[bool]
219
+ """Controls the option state.
220
+
221
+ Possible values:
222
+
223
+ - **true** - Option is enabled.
224
+ - **false** - Option is disabled.
225
+ """
226
+
227
+ value: Required[str]
228
+ """Set the cache expiration time to '0s' to disable caching.
229
+
230
+ The maximum duration is any equivalent to `1y`.
231
+ """
232
+
233
+
234
+ class OptionsCacheHTTPHeaders(TypedDict, total=False):
235
+ enabled: Required[bool]
236
+ """Controls the option state.
237
+
238
+ Possible values:
239
+
240
+ - **true** - Option is enabled.
241
+ - **false** - Option is disabled.
242
+ """
243
+
244
+ value: Required[SequenceNotStr[str]]
245
+
246
+
247
+ class OptionsCors(TypedDict, total=False):
248
+ enabled: Required[bool]
249
+ """Controls the option state.
250
+
251
+ Possible values:
252
+
253
+ - **true** - Option is enabled.
254
+ - **false** - Option is disabled.
255
+ """
256
+
257
+ value: Required[SequenceNotStr[str]]
258
+ """Value of the Access-Control-Allow-Origin header.
259
+
260
+ Possible values:
261
+
262
+ - **Adds \\** as the Access-Control-Allow-Origin header value** - Content will be
263
+ uploaded for requests from any domain. `"value": ["\\**"]`
264
+ - **Adds "$`http_origin`" as the Access-Control-Allow-Origin header value if the
265
+ origin matches one of the listed domains** - Content will be uploaded only for
266
+ requests from the domains specified in the field.
267
+ `"value": ["domain.com", "second.dom.com"]`
268
+ - **Adds "$`http_origin`" as the Access-Control-Allow-Origin header value** -
269
+ Content will be uploaded for requests from any domain, and the domain from
270
+ which the request was sent will be added to the "Access-Control-Allow-Origin"
271
+ header in the response. `"value": ["$`http_origin`"]`
272
+ """
273
+
274
+ always: bool
275
+ """
276
+ Defines whether the Access-Control-Allow-Origin header should be added to a
277
+ response from CDN regardless of response code.
278
+
279
+ Possible values:
280
+
281
+ - **true** - Header will be added to a response regardless of response code.
282
+ - **false** - Header will only be added to responses with codes: 200, 201, 204,
283
+ 206, 301, 302, 303, 304, 307, 308.
284
+ """
285
+
286
+
287
+ class OptionsCountryACL(TypedDict, total=False):
288
+ enabled: Required[bool]
289
+ """Controls the option state.
290
+
291
+ Possible values:
292
+
293
+ - **true** - Option is enabled.
294
+ - **false** - Option is disabled.
295
+ """
296
+
297
+ excepted_values: Required[SequenceNotStr[str]]
298
+ """List of countries according to ISO-3166-1.
299
+
300
+ The meaning of the parameter depends on `policy_type` value:
301
+
302
+ - **allow** - List of countries for which access is prohibited.
303
+ - **deny** - List of countries for which access is allowed.
304
+ """
305
+
306
+ policy_type: Required[Literal["allow", "deny"]]
307
+ """Defines the type of CDN resource access policy.
308
+
309
+ Possible values:
310
+
311
+ - **allow** - Access is allowed for all the countries except for those specified
312
+ in `excepted_values` field.
313
+ - **deny** - Access is denied for all the countries except for those specified
314
+ in `excepted_values` field.
315
+ """
316
+
317
+
318
+ class OptionsDisableCache(TypedDict, total=False):
319
+ enabled: Required[bool]
320
+ """Controls the option state.
321
+
322
+ Possible values:
323
+
324
+ - **true** - Option is enabled.
325
+ - **false** - Option is disabled.
326
+ """
327
+
328
+ value: Required[bool]
329
+ """Possible values:
330
+
331
+ - **true** - content caching is disabled.
332
+ - **false** - content caching is enabled.
333
+ """
334
+
335
+
336
+ class OptionsDisableProxyForceRanges(TypedDict, total=False):
337
+ enabled: Required[bool]
338
+ """Controls the option state.
339
+
340
+ Possible values:
341
+
342
+ - **true** - Option is enabled.
343
+ - **false** - Option is disabled.
344
+ """
345
+
346
+ value: Required[bool]
347
+ """Possible values:
348
+
349
+ - **true** - Option is enabled.
350
+ - **false** - Option is disabled.
351
+ """
352
+
353
+
354
+ class OptionsEdgeCacheSettings(TypedDict, total=False):
355
+ enabled: Required[bool]
356
+ """Controls the option state.
357
+
358
+ Possible values:
359
+
360
+ - **true** - Option is enabled.
361
+ - **false** - Option is disabled.
362
+ """
363
+
364
+ custom_values: Dict[str, str]
365
+ """
366
+ A MAP object representing the caching time in seconds for a response with a
367
+ specific response code.
368
+
369
+ These settings have a higher priority than the `value` field.
370
+
371
+ - Use `any` key to specify caching time for all response codes.
372
+ - Use `0s` value to disable caching for a specific response code.
373
+ """
374
+
375
+ default: str
376
+ """Enables content caching according to the origin cache settings.
377
+
378
+ The value is applied to the following response codes 200, 201, 204, 206, 301,
379
+ 302, 303, 304, 307, 308, if an origin server does not have caching HTTP headers.
380
+
381
+ Responses with other codes will not be cached.
382
+
383
+ The maximum duration is any equivalent to `1y`.
384
+ """
385
+
386
+ value: str
387
+ """Caching time.
388
+
389
+ The value is applied to the following response codes: 200, 206, 301, 302.
390
+ Responses with codes 4xx, 5xx will not be cached.
391
+
392
+ Use `0s` to disable caching.
393
+
394
+ The maximum duration is any equivalent to `1y`.
395
+ """
396
+
397
+
398
+ class OptionsFastedgeOnRequestBody(TypedDict, total=False):
399
+ app_id: Required[str]
400
+ """The ID of the application in FastEdge."""
401
+
402
+ enabled: bool
403
+ """
404
+ Determines if the FastEdge application should be called whenever HTTP request
405
+ headers are received.
406
+ """
407
+
408
+ execute_on_edge: bool
409
+ """Determines if the request should be executed at the edge nodes."""
410
+
411
+ execute_on_shield: bool
412
+ """Determines if the request should be executed at the shield nodes."""
413
+
414
+ interrupt_on_error: bool
415
+ """Determines if the request execution should be interrupted when an error occurs."""
416
+
417
+
418
+ class OptionsFastedgeOnRequestHeaders(TypedDict, total=False):
419
+ app_id: Required[str]
420
+ """The ID of the application in FastEdge."""
421
+
422
+ enabled: bool
423
+ """
424
+ Determines if the FastEdge application should be called whenever HTTP request
425
+ headers are received.
426
+ """
427
+
428
+ execute_on_edge: bool
429
+ """Determines if the request should be executed at the edge nodes."""
430
+
431
+ execute_on_shield: bool
432
+ """Determines if the request should be executed at the shield nodes."""
433
+
434
+ interrupt_on_error: bool
435
+ """Determines if the request execution should be interrupted when an error occurs."""
436
+
437
+
438
+ class OptionsFastedgeOnResponseBody(TypedDict, total=False):
439
+ app_id: Required[str]
440
+ """The ID of the application in FastEdge."""
441
+
442
+ enabled: bool
443
+ """
444
+ Determines if the FastEdge application should be called whenever HTTP request
445
+ headers are received.
446
+ """
447
+
448
+ execute_on_edge: bool
449
+ """Determines if the request should be executed at the edge nodes."""
450
+
451
+ execute_on_shield: bool
452
+ """Determines if the request should be executed at the shield nodes."""
453
+
454
+ interrupt_on_error: bool
455
+ """Determines if the request execution should be interrupted when an error occurs."""
456
+
457
+
458
+ class OptionsFastedgeOnResponseHeaders(TypedDict, total=False):
459
+ app_id: Required[str]
460
+ """The ID of the application in FastEdge."""
461
+
462
+ enabled: bool
463
+ """
464
+ Determines if the FastEdge application should be called whenever HTTP request
465
+ headers are received.
466
+ """
467
+
468
+ execute_on_edge: bool
469
+ """Determines if the request should be executed at the edge nodes."""
470
+
471
+ execute_on_shield: bool
472
+ """Determines if the request should be executed at the shield nodes."""
473
+
474
+ interrupt_on_error: bool
475
+ """Determines if the request execution should be interrupted when an error occurs."""
476
+
477
+
478
+ class OptionsFastedge(TypedDict, total=False):
479
+ enabled: Required[bool]
480
+ """Controls the option state.
481
+
482
+ Possible values:
483
+
484
+ - **true** - Option is enabled.
485
+ - **false** - Option is disabled.
486
+ """
487
+
488
+ on_request_body: OptionsFastedgeOnRequestBody
489
+ """
490
+ Allows to configure FastEdge application that will be called to handle request
491
+ body as soon as CDN receives incoming HTTP request.
492
+ """
493
+
494
+ on_request_headers: OptionsFastedgeOnRequestHeaders
495
+ """
496
+ Allows to configure FastEdge application that will be called to handle request
497
+ headers as soon as CDN receives incoming HTTP request.
498
+ """
499
+
500
+ on_response_body: OptionsFastedgeOnResponseBody
501
+ """
502
+ Allows to configure FastEdge application that will be called to handle response
503
+ body before CDN sends the HTTP response.
504
+ """
505
+
506
+ on_response_headers: OptionsFastedgeOnResponseHeaders
507
+ """
508
+ Allows to configure FastEdge application that will be called to handle response
509
+ headers before CDN sends the HTTP response.
510
+ """
511
+
512
+
513
+ class OptionsFetchCompressed(TypedDict, total=False):
514
+ enabled: Required[bool]
515
+ """Controls the option state.
516
+
517
+ Possible values:
518
+
519
+ - **true** - Option is enabled.
520
+ - **false** - Option is disabled.
521
+ """
522
+
523
+ value: Required[bool]
524
+ """Possible values:
525
+
526
+ - **true** - Option is enabled.
527
+ - **false** - Option is disabled.
528
+ """
529
+
530
+
531
+ class OptionsFollowOriginRedirect(TypedDict, total=False):
532
+ codes: Required[Iterable[Literal[301, 302, 303, 307, 308]]]
533
+ """Redirect status code that the origin server returns.
534
+
535
+ To serve up to date content to end users, you will need to purge the cache after
536
+ managing the option.
537
+ """
538
+
539
+ enabled: Required[bool]
540
+ """Controls the option state.
541
+
542
+ Possible values:
543
+
544
+ - **true** - Option is enabled.
545
+ - **false** - Option is disabled.
546
+ """
547
+
548
+
549
+ class OptionsForceReturnTimeInterval(TypedDict, total=False):
550
+ end_time: Required[str]
551
+ """Time until which a custom HTTP response code should be applied.
552
+
553
+ Indicated in 24-hour format.
554
+ """
555
+
556
+ start_time: Required[str]
557
+ """Time from which a custom HTTP response code should be applied.
558
+
559
+ Indicated in 24-hour format.
560
+ """
561
+
562
+ time_zone: str
563
+ """Time zone used to calculate time."""
564
+
565
+
566
+ class OptionsForceReturn(TypedDict, total=False):
567
+ body: Required[str]
568
+ """URL for redirection or text."""
569
+
570
+ code: Required[int]
571
+ """Status code value."""
572
+
573
+ enabled: Required[bool]
574
+ """Controls the option state.
575
+
576
+ Possible values:
577
+
578
+ - **true** - Option is enabled.
579
+ - **false** - Option is disabled.
580
+ """
581
+
582
+ time_interval: Optional[OptionsForceReturnTimeInterval]
583
+ """Controls the time at which a custom HTTP response code should be applied.
584
+
585
+ By default, a custom HTTP response code is applied at any time.
586
+ """
587
+
588
+
589
+ class OptionsForwardHostHeader(TypedDict, total=False):
590
+ enabled: Required[bool]
591
+ """Controls the option state.
592
+
593
+ Possible values:
594
+
595
+ - **true** - Option is enabled.
596
+ - **false** - Option is disabled.
597
+ """
598
+
599
+ value: Required[bool]
600
+ """Possible values:
601
+
602
+ - **true** - Option is enabled.
603
+ - **false** - Option is disabled.
604
+ """
605
+
606
+
607
+ class OptionsGzipOn(TypedDict, total=False):
608
+ enabled: Required[bool]
609
+ """Controls the option state.
610
+
611
+ Possible values:
612
+
613
+ - **true** - Option is enabled.
614
+ - **false** - Option is disabled.
615
+ """
616
+
617
+ value: Required[bool]
618
+ """Possible values:
619
+
620
+ - **true** - Option is enabled.
621
+ - **false** - Option is disabled.
622
+ """
623
+
624
+
625
+ class OptionsHostHeader(TypedDict, total=False):
626
+ enabled: Required[bool]
627
+ """Controls the option state.
628
+
629
+ Possible values:
630
+
631
+ - **true** - Option is enabled.
632
+ - **false** - Option is disabled.
633
+ """
634
+
635
+ value: Required[str]
636
+ """Host Header value."""
637
+
638
+
639
+ class OptionsIgnoreCookie(TypedDict, total=False):
640
+ enabled: Required[bool]
641
+ """Controls the option state.
642
+
643
+ Possible values:
644
+
645
+ - **true** - Option is enabled.
646
+ - **false** - Option is disabled.
647
+ """
648
+
649
+ value: Required[bool]
650
+ """Possible values:
651
+
652
+ - **true** - Option is enabled, files with cookies are cached as one file.
653
+ - **false** - Option is disabled, files with cookies are cached as different
654
+ files.
655
+ """
656
+
657
+
658
+ class OptionsIgnoreQueryString(TypedDict, total=False):
659
+ enabled: Required[bool]
660
+ """Controls the option state.
661
+
662
+ Possible values:
663
+
664
+ - **true** - Option is enabled.
665
+ - **false** - Option is disabled.
666
+ """
667
+
668
+ value: Required[bool]
669
+ """Possible values:
670
+
671
+ - **true** - Option is enabled.
672
+ - **false** - Option is disabled.
673
+ """
674
+
675
+
676
+ class OptionsImageStack(TypedDict, total=False):
677
+ enabled: Required[bool]
678
+ """Controls the option state.
679
+
680
+ Possible values:
681
+
682
+ - **true** - Option is enabled.
683
+ - **false** - Option is disabled.
684
+ """
685
+
686
+ avif_enabled: bool
687
+ """Enables or disables automatic conversion of JPEG and PNG images to AVI format."""
688
+
689
+ png_lossless: bool
690
+ """Enables or disables compression without quality loss for PNG format."""
691
+
692
+ quality: int
693
+ """Defines quality settings for JPG and PNG images.
694
+
695
+ The higher the value, the better the image quality, and the larger the file size
696
+ after conversion.
697
+ """
698
+
699
+ webp_enabled: bool
700
+ """Enables or disables automatic conversion of JPEG and PNG images to WebP format."""
701
+
702
+
703
+ class OptionsIPAddressACL(TypedDict, total=False):
704
+ enabled: Required[bool]
705
+ """Controls the option state.
706
+
707
+ Possible values:
708
+
709
+ - **true** - Option is enabled.
710
+ - **false** - Option is disabled.
711
+ """
712
+
713
+ excepted_values: Required[SequenceNotStr[str]]
714
+ """List of IP addresses with a subnet mask.
715
+
716
+ The meaning of the parameter depends on `policy_type` value:
717
+
718
+ - **allow** - List of IP addresses for which access is prohibited.
719
+ - **deny** - List of IP addresses for which access is allowed.
720
+
721
+ Examples:
722
+
723
+ - `192.168.3.2/32`
724
+ - `2a03:d000:2980:7::8/128`
725
+ """
726
+
727
+ policy_type: Required[Literal["allow", "deny"]]
728
+ """IP access policy type.
729
+
730
+ Possible values:
731
+
732
+ - **allow** - Allow access to all IPs except IPs specified in
733
+ "`excepted_values`" field.
734
+ - **deny** - Deny access to all IPs except IPs specified in "`excepted_values`"
735
+ field.
736
+ """
737
+
738
+
739
+ class OptionsLimitBandwidth(TypedDict, total=False):
740
+ enabled: Required[bool]
741
+ """Controls the option state.
742
+
743
+ Possible values:
744
+
745
+ - **true** - Option is enabled.
746
+ - **false** - Option is disabled.
747
+ """
748
+
749
+ limit_type: Required[Literal["static", "dynamic"]]
750
+ """Method of controlling the download speed per connection.
751
+
752
+ Possible values:
753
+
754
+ - **static** - Use speed and buffer fields to set the download speed limit.
755
+ - **dynamic** - Use query strings **speed** and **buffer** to set the download
756
+ speed limit.
757
+
758
+ For example, when requesting content at the link
759
+
760
+ ```
761
+ http://cdn.example.com/video.mp4?speed=50k&buffer=500k
762
+ ```
763
+
764
+ the download speed will be limited to 50kB/s after 500 kB.
765
+ """
766
+
767
+ buffer: int
768
+ """Amount of downloaded data after which the user will be rate limited."""
769
+
770
+ speed: int
771
+ """Maximum download speed per connection."""
772
+
773
+
774
+ class OptionsProxyCacheKey(TypedDict, total=False):
775
+ enabled: Required[bool]
776
+ """Controls the option state.
777
+
778
+ Possible values:
779
+
780
+ - **true** - Option is enabled.
781
+ - **false** - Option is disabled.
782
+ """
783
+
784
+ value: Required[str]
785
+ """Key for caching."""
786
+
787
+
788
+ class OptionsProxyCacheMethodsSet(TypedDict, total=False):
789
+ enabled: Required[bool]
790
+ """Controls the option state.
791
+
792
+ Possible values:
793
+
794
+ - **true** - Option is enabled.
795
+ - **false** - Option is disabled.
796
+ """
797
+
798
+ value: Required[bool]
799
+ """Possible values:
800
+
801
+ - **true** - Option is enabled.
802
+ - **false** - Option is disabled.
803
+ """
804
+
805
+
806
+ class OptionsProxyConnectTimeout(TypedDict, total=False):
807
+ enabled: Required[bool]
808
+ """Controls the option state.
809
+
810
+ Possible values:
811
+
812
+ - **true** - Option is enabled.
813
+ - **false** - Option is disabled.
814
+ """
815
+
816
+ value: Required[str]
817
+ """Timeout value in seconds."""
818
+
819
+
820
+ class OptionsProxyReadTimeout(TypedDict, total=False):
821
+ enabled: Required[bool]
822
+ """Controls the option state.
823
+
824
+ Possible values:
825
+
826
+ - **true** - Option is enabled.
827
+ - **false** - Option is disabled.
828
+ """
829
+
830
+ value: Required[str]
831
+ """Timeout value in seconds."""
832
+
833
+
834
+ class OptionsQueryParamsBlacklist(TypedDict, total=False):
835
+ enabled: Required[bool]
836
+ """Controls the option state.
837
+
838
+ Possible values:
839
+
840
+ - **true** - Option is enabled.
841
+ - **false** - Option is disabled.
842
+ """
843
+
844
+ value: Required[SequenceNotStr[str]]
845
+ """List of query parameters."""
846
+
847
+
848
+ class OptionsQueryParamsWhitelist(TypedDict, total=False):
849
+ enabled: Required[bool]
850
+ """Controls the option state.
851
+
852
+ Possible values:
853
+
854
+ - **true** - Option is enabled.
855
+ - **false** - Option is disabled.
856
+ """
857
+
858
+ value: Required[SequenceNotStr[str]]
859
+ """List of query parameters."""
860
+
861
+
862
+ class OptionsQueryStringForwarding(TypedDict, total=False):
863
+ enabled: Required[bool]
864
+ """Controls the option state.
865
+
866
+ Possible values:
867
+
868
+ - **true** - Option is enabled.
869
+ - **false** - Option is disabled.
870
+ """
871
+
872
+ forward_from_file_types: Required[SequenceNotStr[str]]
873
+ """
874
+ The `forward_from_files_types` field specifies the types of playlist files from
875
+ which parameters will be extracted and forwarded. This typically includes
876
+ formats that list multiple media chunk references, such as HLS and DASH
877
+ playlists. Parameters associated with these playlist files (like query strings
878
+ or headers) will be propagated to the chunks they reference.
879
+ """
880
+
881
+ forward_to_file_types: Required[SequenceNotStr[str]]
882
+ """
883
+ The field specifies the types of media chunk files to which parameters,
884
+ extracted from playlist files, will be forwarded. These refer to the actual
885
+ segments of media content that are delivered to viewers. Ensuring the correct
886
+ parameters are forwarded to these files is crucial for maintaining the integrity
887
+ of the streaming session.
888
+ """
889
+
890
+ forward_except_keys: SequenceNotStr[str]
891
+ """
892
+ The `forward_except_keys` field provides a mechanism to exclude specific
893
+ parameters from being forwarded from playlist files to media chunk files. By
894
+ listing certain keys in this field, you can ensure that these parameters are
895
+ omitted during the forwarding process. This is particularly useful for
896
+ preventing sensitive or irrelevant information from being included in requests
897
+ for media chunks, thereby enhancing security and optimizing performance.
898
+ """
899
+
900
+ forward_only_keys: SequenceNotStr[str]
901
+ """
902
+ The `forward_only_keys` field allows for granular control over which specific
903
+ parameters are forwarded from playlist files to media chunk files. By specifying
904
+ certain keys, only those parameters will be propagated, ensuring that only
905
+ relevant information is passed along. This is particularly useful for security
906
+ and performance optimization, as it prevents unnecessary or sensitive data from
907
+ being included in requests for media chunks.
908
+ """
909
+
910
+
911
+ class OptionsRedirectHTTPToHTTPS(TypedDict, total=False):
912
+ enabled: Required[bool]
913
+ """Controls the option state.
914
+
915
+ Possible values:
916
+
917
+ - **true** - Option is enabled.
918
+ - **false** - Option is disabled.
919
+ """
920
+
921
+ value: Required[bool]
922
+ """Possible values:
923
+
924
+ - **true** - Option is enabled.
925
+ - **false** - Option is disabled.
926
+ """
927
+
928
+
929
+ class OptionsRedirectHTTPSToHTTP(TypedDict, total=False):
930
+ enabled: Required[bool]
931
+ """Controls the option state.
932
+
933
+ Possible values:
934
+
935
+ - **true** - Option is enabled.
936
+ - **false** - Option is disabled.
937
+ """
938
+
939
+ value: Required[bool]
940
+ """Possible values:
941
+
942
+ - **true** - Option is enabled.
943
+ - **false** - Option is disabled.
944
+ """
945
+
946
+
947
+ class OptionsReferrerACL(TypedDict, total=False):
948
+ enabled: Required[bool]
949
+ """Controls the option state.
950
+
951
+ Possible values:
952
+
953
+ - **true** - Option is enabled.
954
+ - **false** - Option is disabled.
955
+ """
956
+
957
+ excepted_values: Required[SequenceNotStr[str]]
958
+ """
959
+ List of domain names or wildcard domains (without protocol: `http://` or
960
+ `https://`.)
961
+
962
+ The meaning of the parameter depends on `policy_type` value:
963
+
964
+ - **allow** - List of domain names for which access is prohibited.
965
+ - **deny** - List of IP domain names for which access is allowed.
966
+
967
+ Examples:
968
+
969
+ - `example.com`
970
+ - `\\**.example.com`
971
+ """
972
+
973
+ policy_type: Required[Literal["allow", "deny"]]
974
+ """Policy type.
975
+
976
+ Possible values:
977
+
978
+ - **allow** - Allow access to all domain names except the domain names specified
979
+ in `excepted_values` field.
980
+ - **deny** - Deny access to all domain names except the domain names specified
981
+ in `excepted_values` field.
982
+ """
983
+
984
+
985
+ class OptionsRequestLimiter(TypedDict, total=False):
986
+ enabled: Required[bool]
987
+ """Controls the option state.
988
+
989
+ Possible values:
990
+
991
+ - **true** - Option is enabled.
992
+ - **false** - Option is disabled.
993
+ """
994
+
995
+ rate: Required[int]
996
+ """Maximum request rate."""
997
+
998
+ rate_unit: Literal["r/s", "r/m"]
999
+ """Units of measurement for the `rate` field.
1000
+
1001
+ Possible values:
1002
+
1003
+ - **r/s** - Requests per second.
1004
+ - **r/m** - Requests per minute.
1005
+
1006
+ If the rate is less than one request per second, it is specified in request per
1007
+ minute (r/m.)
1008
+ """
1009
+
1010
+
1011
+ class OptionsResponseHeadersHidingPolicy(TypedDict, total=False):
1012
+ enabled: Required[bool]
1013
+ """Controls the option state.
1014
+
1015
+ Possible values:
1016
+
1017
+ - **true** - Option is enabled.
1018
+ - **false** - Option is disabled.
1019
+ """
1020
+
1021
+ excepted: Required[SequenceNotStr[str]]
1022
+ """List of HTTP headers.
1023
+
1024
+ Parameter meaning depends on the value of the `mode` field:
1025
+
1026
+ - **show** - List of HTTP headers to hide from response.
1027
+ - **hide** - List of HTTP headers to include in response. Other HTTP headers
1028
+ will be hidden.
1029
+
1030
+ The following headers are required and cannot be hidden from response:
1031
+
1032
+ - `Connection`
1033
+ - `Content-Length`
1034
+ - `Content-Type`
1035
+ - `Date`
1036
+ - `Server`
1037
+ """
1038
+
1039
+ mode: Required[Literal["hide", "show"]]
1040
+ """How HTTP headers are hidden from the response.
1041
+
1042
+ Possible values:
1043
+
1044
+ - **show** - Hide only HTTP headers listed in the `excepted` field.
1045
+ - **hide** - Hide all HTTP headers except headers listed in the "excepted"
1046
+ field.
1047
+ """
1048
+
1049
+
1050
+ class OptionsRewrite(TypedDict, total=False):
1051
+ body: Required[str]
1052
+ """Path for the Rewrite option.
1053
+
1054
+ Example:
1055
+
1056
+ - `/(.\\**) /media/$1`
1057
+ """
1058
+
1059
+ enabled: Required[bool]
1060
+ """Controls the option state.
1061
+
1062
+ Possible values:
1063
+
1064
+ - **true** - Option is enabled.
1065
+ - **false** - Option is disabled.
1066
+ """
1067
+
1068
+ flag: Literal["break", "last", "redirect", "permanent"]
1069
+ """Flag for the Rewrite option.
1070
+
1071
+ Possible values:
1072
+
1073
+ - **last** - Stop processing the current set of `ngx_http_rewrite_module`
1074
+ directives and start a search for a new location matching changed URI.
1075
+ - **break** - Stop processing the current set of the Rewrite option.
1076
+ - **redirect** - Return a temporary redirect with the 302 code; used when a
1077
+ replacement string does not start with `http://`, `https://`, or `$scheme`.
1078
+ - **permanent** - Return a permanent redirect with the 301 code.
1079
+ """
1080
+
1081
+
1082
+ class OptionsSecureKey(TypedDict, total=False):
1083
+ enabled: Required[bool]
1084
+ """Controls the option state.
1085
+
1086
+ Possible values:
1087
+
1088
+ - **true** - Option is enabled.
1089
+ - **false** - Option is disabled.
1090
+ """
1091
+
1092
+ key: Required[Optional[str]]
1093
+ """Key generated on your side that will be used for URL signing."""
1094
+
1095
+ type: Literal[0, 2]
1096
+ """Type of URL signing.
1097
+
1098
+ Possible types:
1099
+
1100
+ - **Type 0** - Includes end user IP to secure token generation.
1101
+ - **Type 2** - Excludes end user IP from secure token generation.
1102
+ """
1103
+
1104
+
1105
+ class OptionsSlice(TypedDict, total=False):
1106
+ enabled: Required[bool]
1107
+ """Controls the option state.
1108
+
1109
+ Possible values:
1110
+
1111
+ - **true** - Option is enabled.
1112
+ - **false** - Option is disabled.
1113
+ """
1114
+
1115
+ value: Required[bool]
1116
+ """Possible values:
1117
+
1118
+ - **true** - Option is enabled.
1119
+ - **false** - Option is disabled.
1120
+ """
1121
+
1122
+
1123
+ class OptionsSni(TypedDict, total=False):
1124
+ custom_hostname: Required[str]
1125
+ """Custom SNI hostname.
1126
+
1127
+ It is required if `sni_type` is set to custom.
1128
+ """
1129
+
1130
+ enabled: Required[bool]
1131
+ """Controls the option state.
1132
+
1133
+ Possible values:
1134
+
1135
+ - **true** - Option is enabled.
1136
+ - **false** - Option is disabled.
1137
+ """
1138
+
1139
+ sni_type: Literal["dynamic", "custom"]
1140
+ """SNI (Server Name Indication) type.
1141
+
1142
+ Possible values:
1143
+
1144
+ - **dynamic** - SNI hostname depends on `hostHeader` and `forward_host_header`
1145
+ options. It has several possible combinations:
1146
+ - If the `hostHeader` option is enabled and specified, SNI hostname matches the
1147
+ Host header.
1148
+ - If the `forward_host_header` option is enabled and has true value, SNI
1149
+ hostname matches the Host header used in the request made to a CDN.
1150
+ - If the `hostHeader` and `forward_host_header` options are disabled, SNI
1151
+ hostname matches the primary CNAME.
1152
+ - **custom** - custom SNI hostname is in use.
1153
+ """
1154
+
1155
+
1156
+ class OptionsStale(TypedDict, total=False):
1157
+ enabled: Required[bool]
1158
+ """Controls the option state.
1159
+
1160
+ Possible values:
1161
+
1162
+ - **true** - Option is enabled.
1163
+ - **false** - Option is disabled.
1164
+ """
1165
+
1166
+ value: Required[
1167
+ List[
1168
+ Literal[
1169
+ "error",
1170
+ "http_403",
1171
+ "http_404",
1172
+ "http_429",
1173
+ "http_500",
1174
+ "http_502",
1175
+ "http_503",
1176
+ "http_504",
1177
+ "invalid_header",
1178
+ "timeout",
1179
+ "updating",
1180
+ ]
1181
+ ]
1182
+ ]
1183
+ """Defines list of errors for which "Always online" option is applied."""
1184
+
1185
+
1186
+ class OptionsStaticResponseHeadersValue(TypedDict, total=False):
1187
+ name: Required[str]
1188
+ """HTTP Header name.
1189
+
1190
+ Restrictions:
1191
+
1192
+ - Maximum 128 symbols.
1193
+ - Latin letters (A-Z, a-z,) numbers (0-9,) dashes, and underscores only.
1194
+ """
1195
+
1196
+ value: Required[SequenceNotStr[str]]
1197
+ """Header value.
1198
+
1199
+ Restrictions:
1200
+
1201
+ - Maximum 512 symbols.
1202
+ - Letters (a-z), numbers (0-9), spaces, and symbols (`~!@#%%^&\\**()-\\__=+
1203
+ /|\";:?.,><{}[]).
1204
+ - Must start with a letter, number, asterisk or {.
1205
+ - Multiple values can be added.
1206
+ """
1207
+
1208
+ always: bool
1209
+ """
1210
+ Defines whether the header will be added to a response from CDN regardless of
1211
+ response code.
1212
+
1213
+ Possible values:
1214
+
1215
+ - **true** - Header will be added to a response from CDN regardless of response
1216
+ code.
1217
+ - **false** - Header will be added only to the following response codes: 200,
1218
+ 201, 204, 206, 301, 302, 303, 304, 307, 308.
1219
+ """
1220
+
1221
+
1222
+ class OptionsStaticResponseHeaders(TypedDict, total=False):
1223
+ enabled: Required[bool]
1224
+ """Controls the option state.
1225
+
1226
+ Possible values:
1227
+
1228
+ - **true** - Option is enabled.
1229
+ - **false** - Option is disabled.
1230
+ """
1231
+
1232
+ value: Required[Iterable[OptionsStaticResponseHeadersValue]]
1233
+
1234
+
1235
+ class OptionsStaticHeaders(TypedDict, total=False):
1236
+ enabled: Required[bool]
1237
+ """Controls the option state.
1238
+
1239
+ Possible values:
1240
+
1241
+ - **true** - Option is enabled.
1242
+ - **false** - Option is disabled.
1243
+ """
1244
+
1245
+ value: Required[Dict[str, str]]
1246
+ """A MAP for static headers in a format of `header_name: header_value`.
1247
+
1248
+ Restrictions:
1249
+
1250
+ - **Header name** - Maximum 128 symbols, may contain Latin letters (A-Z, a-z),
1251
+ numbers (0-9), dashes, and underscores.
1252
+ - **Header value** - Maximum 512 symbols, may contain letters (a-z), numbers
1253
+ (0-9), spaces, and symbols (`~!@#%%^&\\**()-\\__=+ /|\";:?.,><{}[]). Must start
1254
+ with a letter, number, asterisk or {.
1255
+ """
1256
+
1257
+
1258
+ class OptionsStaticRequestHeaders(TypedDict, total=False):
1259
+ enabled: Required[bool]
1260
+ """Controls the option state.
1261
+
1262
+ Possible values:
1263
+
1264
+ - **true** - Option is enabled.
1265
+ - **false** - Option is disabled.
1266
+ """
1267
+
1268
+ value: Required[Dict[str, str]]
1269
+ """A MAP for static headers in a format of `header_name: header_value`.
1270
+
1271
+ Restrictions:
1272
+
1273
+ - **Header name** - Maximum 255 symbols, may contain Latin letters (A-Z, a-z),
1274
+ numbers (0-9), dashes, and underscores.
1275
+ - **Header value** - Maximum 512 symbols, may contain letters (a-z), numbers
1276
+ (0-9), spaces, and symbols (`~!@#%%^&\\**()-\\__=+ /|\";:?.,><{}[]). Must start
1277
+ with a letter, number, asterisk or {.
1278
+ """
1279
+
1280
+
1281
+ class OptionsUserAgentACL(TypedDict, total=False):
1282
+ enabled: Required[bool]
1283
+ """Controls the option state.
1284
+
1285
+ Possible values:
1286
+
1287
+ - **true** - Option is enabled.
1288
+ - **false** - Option is disabled.
1289
+ """
1290
+
1291
+ excepted_values: Required[SequenceNotStr[str]]
1292
+ """List of User-Agents that will be allowed/denied.
1293
+
1294
+ The meaning of the parameter depends on `policy_type`:
1295
+
1296
+ - **allow** - List of User-Agents for which access is prohibited.
1297
+ - **deny** - List of User-Agents for which access is allowed.
1298
+
1299
+ Use an empty string `""` to allow/deny access when the User-Agent header is
1300
+ empty.
1301
+ """
1302
+
1303
+ policy_type: Required[Literal["allow", "deny"]]
1304
+ """User-Agents policy type.
1305
+
1306
+ Possible values:
1307
+
1308
+ - **allow** - Allow access for all User-Agents except specified in
1309
+ `excepted_values` field.
1310
+ - **deny** - Deny access for all User-Agents except specified in
1311
+ `excepted_values` field.
1312
+ """
1313
+
1314
+
1315
+ class OptionsWaap(TypedDict, total=False):
1316
+ enabled: Required[bool]
1317
+ """Controls the option state.
1318
+
1319
+ Possible values:
1320
+
1321
+ - **true** - Option is enabled.
1322
+ - **false** - Option is disabled.
1323
+ """
1324
+
1325
+ value: Required[bool]
1326
+ """Possible values:
1327
+
1328
+ - **true** - Option is enabled.
1329
+ - **false** - Option is disabled.
1330
+ """
1331
+
1332
+
1333
+ class OptionsWebsockets(TypedDict, total=False):
1334
+ enabled: Required[bool]
1335
+ """Controls the option state.
1336
+
1337
+ Possible values:
1338
+
1339
+ - **true** - Option is enabled.
1340
+ - **false** - Option is disabled.
1341
+ """
1342
+
1343
+ value: Required[bool]
1344
+ """Possible values:
1345
+
1346
+ - **true** - Option is enabled.
1347
+ - **false** - Option is disabled.
1348
+ """
1349
+
1350
+
1351
+ class Options(TypedDict, total=False):
1352
+ allowed_http_methods: Annotated[Optional[OptionsAllowedHTTPMethods], PropertyInfo(alias="allowedHttpMethods")]
1353
+ """HTTP methods allowed for content requests from the CDN."""
1354
+
1355
+ bot_protection: Optional[OptionsBotProtection]
1356
+ """
1357
+ Allows to prevent online services from overloading and ensure your business
1358
+ workflow running smoothly.
1359
+ """
1360
+
1361
+ brotli_compression: Optional[OptionsBrotliCompression]
1362
+ """Compresses content with Brotli on the CDN side.
1363
+
1364
+ CDN servers will request only uncompressed content from the origin.
1365
+
1366
+ Notes:
1367
+
1368
+ 1. CDN only supports "Brotli compression" when the "origin shielding" feature is
1369
+ activated.
1370
+ 2. If a precache server is not active for a CDN resource, no compression occurs,
1371
+ even if the option is enabled.
1372
+ 3. `brotli_compression` is not supported with `fetch_compressed` or `slice`
1373
+ options enabled.
1374
+ 4. `fetch_compressed` option in CDN resource settings overrides
1375
+ `brotli_compression` in rules. If you enabled `fetch_compressed` in CDN
1376
+ resource and want to enable `brotli_compression` in a rule, you must specify
1377
+ `fetch_compressed:false` in the rule.
1378
+ """
1379
+
1380
+ browser_cache_settings: Optional[OptionsBrowserCacheSettings]
1381
+ """Cache expiration time for users browsers in seconds.
1382
+
1383
+ Cache expiration time is applied to the following response codes: 200, 201, 204,
1384
+ 206, 301, 302, 303, 304, 307, 308.
1385
+
1386
+ Responses with other codes will not be cached.
1387
+ """
1388
+
1389
+ cache_http_headers: Optional[OptionsCacheHTTPHeaders]
1390
+ """**Legacy option**. Use the `response_headers_hiding_policy` option instead.
1391
+
1392
+ HTTP Headers that must be included in the response.
1393
+ """
1394
+
1395
+ cors: Optional[OptionsCors]
1396
+ """Enables or disables CORS (Cross-Origin Resource Sharing) header support.
1397
+
1398
+ CORS header support allows the CDN to add the Access-Control-Allow-Origin header
1399
+ to a response to a browser.
1400
+ """
1401
+
1402
+ country_acl: Optional[OptionsCountryACL]
1403
+ """Enables control access to content for specified countries."""
1404
+
1405
+ disable_cache: Optional[OptionsDisableCache]
1406
+ """**Legacy option**. Use the `edge_cache_settings` option instead.
1407
+
1408
+ Allows the complete disabling of content caching.
1409
+ """
1410
+
1411
+ disable_proxy_force_ranges: Optional[OptionsDisableProxyForceRanges]
1412
+ """Allows 206 responses regardless of the settings of an origin source."""
1413
+
1414
+ edge_cache_settings: Optional[OptionsEdgeCacheSettings]
1415
+ """Cache expiration time for CDN servers.
1416
+
1417
+ `value` and `default` fields cannot be used simultaneously.
1418
+ """
1419
+
1420
+ fastedge: Optional[OptionsFastedge]
1421
+ """
1422
+ Allows to configure FastEdge app to be called on different request/response
1423
+ phases.
1424
+
1425
+ Note: At least one of `on_request_headers`, `on_request_body`,
1426
+ `on_response_headers`, or `on_response_body` must be specified.
1427
+ """
1428
+
1429
+ fetch_compressed: Optional[OptionsFetchCompressed]
1430
+ """Makes the CDN request compressed content from the origin.
1431
+
1432
+ The origin server should support compression. CDN servers will not decompress
1433
+ your content even if a user browser does not accept compression.
1434
+
1435
+ Notes:
1436
+
1437
+ 1. `fetch_compressed` is not supported with `gzipON` or `brotli_compression` or
1438
+ `slice` options enabled.
1439
+ 2. `fetch_compressed` overrides `gzipON` and `brotli_compression` in rule. If
1440
+ you enable it in CDN resource and want to use `gzipON` and
1441
+ `brotli_compression` in a rule, you have to specify
1442
+ `"`fetch_compressed`": false` in the rule.
1443
+ """
1444
+
1445
+ follow_origin_redirect: Optional[OptionsFollowOriginRedirect]
1446
+ """
1447
+ Enables redirection from origin. If the origin server returns a redirect, the
1448
+ option allows the CDN to pull the requested content from the origin server that
1449
+ was returned in the redirect.
1450
+ """
1451
+
1452
+ force_return: Optional[OptionsForceReturn]
1453
+ """Applies custom HTTP response codes for CDN content.
1454
+
1455
+ The following codes are reserved by our system and cannot be specified in this
1456
+ option: 408, 444, 477, 494, 495, 496, 497, 499.
1457
+ """
1458
+
1459
+ forward_host_header: Optional[OptionsForwardHostHeader]
1460
+ """Forwards the Host header from a end-user request to an origin server.
1461
+
1462
+ `hostHeader` and `forward_host_header` options cannot be enabled simultaneously.
1463
+ """
1464
+
1465
+ gzip_on: Annotated[Optional[OptionsGzipOn], PropertyInfo(alias="gzipOn")]
1466
+ """Compresses content with gzip on the CDN end.
1467
+
1468
+ CDN servers will request only uncompressed content from the origin.
1469
+
1470
+ Notes:
1471
+
1472
+ 1. Compression with gzip is not supported with `fetch_compressed` or `slice`
1473
+ options enabled.
1474
+ 2. `fetch_compressed` option in CDN resource settings overrides `gzipON` in
1475
+ rules. If you enable `fetch_compressed` in CDN resource and want to enable
1476
+ `gzipON` in rules, you need to specify `"`fetch_compressed`":false` for
1477
+ rules.
1478
+ """
1479
+
1480
+ host_header: Annotated[Optional[OptionsHostHeader], PropertyInfo(alias="hostHeader")]
1481
+ """
1482
+ Sets the Host header that CDN servers use when request content from an origin
1483
+ server. Your server must be able to process requests with the chosen header.
1484
+
1485
+ If the option is `null`, the Host Header value is equal to first CNAME.
1486
+
1487
+ `hostHeader` and `forward_host_header` options cannot be enabled simultaneously.
1488
+ """
1489
+
1490
+ ignore_cookie: Optional[OptionsIgnoreCookie]
1491
+ """
1492
+ Defines whether the files with the Set-Cookies header are cached as one file or
1493
+ as different ones.
1494
+ """
1495
+
1496
+ ignore_query_string: Annotated[Optional[OptionsIgnoreQueryString], PropertyInfo(alias="ignoreQueryString")]
1497
+ """
1498
+ How a file with different query strings is cached: either as one object (option
1499
+ is enabled) or as different objects (option is disabled.)
1500
+
1501
+ `ignoreQueryString`, `query_params_whitelist` and `query_params_blacklist`
1502
+ options cannot be enabled simultaneously.
1503
+ """
1504
+
1505
+ image_stack: Optional[OptionsImageStack]
1506
+ """
1507
+ Transforms JPG and PNG images (for example, resize or crop) and automatically
1508
+ converts them to WebP or AVIF format.
1509
+ """
1510
+
1511
+ ip_address_acl: Optional[OptionsIPAddressACL]
1512
+ """Controls access to the CDN resource content for specific IP addresses.
1513
+
1514
+ If you want to use IPs from our CDN servers IP list for IP ACL configuration,
1515
+ you have to independently monitor their relevance. We recommend you use a script
1516
+ for automatically update IP ACL.
1517
+ [Read more.](/docs/api-reference/cdn/ip-addresses-list/get-cdn-servers-ip-addresses)
1518
+ """
1519
+
1520
+ limit_bandwidth: Optional[OptionsLimitBandwidth]
1521
+ """Allows to control the download speed per connection."""
1522
+
1523
+ proxy_cache_key: Optional[OptionsProxyCacheKey]
1524
+ """Allows you to modify your cache key.
1525
+
1526
+ If omitted, the default value is `$request_uri`.
1527
+
1528
+ Combine the specified variables to create a key for caching.
1529
+
1530
+ - **$`request_uri`**
1531
+ - **$scheme**
1532
+ - **$uri**
1533
+
1534
+ **Warning**: Enabling and changing this option can invalidate your current cache
1535
+ and affect the cache hit ratio. Furthermore, the "Purge by pattern" option will
1536
+ not work.
1537
+ """
1538
+
1539
+ proxy_cache_methods_set: Optional[OptionsProxyCacheMethodsSet]
1540
+ """Caching for POST requests along with default GET and HEAD."""
1541
+
1542
+ proxy_connect_timeout: Optional[OptionsProxyConnectTimeout]
1543
+ """The time limit for establishing a connection with the origin."""
1544
+
1545
+ proxy_read_timeout: Optional[OptionsProxyReadTimeout]
1546
+ """
1547
+ The time limit for receiving a partial response from the origin. If no response
1548
+ is received within this time, the connection will be closed.
1549
+
1550
+ **Note:** When used with a WebSocket connection, this option supports values
1551
+ only in the range 1–20 seconds (instead of the usual 1–30 seconds).
1552
+ """
1553
+
1554
+ query_params_blacklist: Optional[OptionsQueryParamsBlacklist]
1555
+ """
1556
+ Files with the specified query parameters are cached as one object, files with
1557
+ other parameters are cached as different objects.
1558
+
1559
+ `ignoreQueryString`, `query_params_whitelist` and `query_params_blacklist`
1560
+ options cannot be enabled simultaneously.
1561
+ """
1562
+
1563
+ query_params_whitelist: Optional[OptionsQueryParamsWhitelist]
1564
+ """
1565
+ Files with the specified query parameters are cached as different objects, files
1566
+ with other parameters are cached as one object.
1567
+
1568
+ `ignoreQueryString`, `query_params_whitelist` and `query_params_blacklist`
1569
+ options cannot be enabled simultaneously.
1570
+ """
1571
+
1572
+ query_string_forwarding: Optional[OptionsQueryStringForwarding]
1573
+ """
1574
+ The Query String Forwarding feature allows for the seamless transfer of
1575
+ parameters embedded in playlist files to the corresponding media chunk files.
1576
+ This functionality ensures that specific attributes, such as authentication
1577
+ tokens or tracking information, are consistently passed along from the playlist
1578
+ manifest to the individual media segments. This is particularly useful for
1579
+ maintaining continuity in security, analytics, and any other parameter-based
1580
+ operations across the entire media delivery workflow.
1581
+ """
1582
+
1583
+ redirect_http_to_https: Optional[OptionsRedirectHTTPToHTTPS]
1584
+ """Enables redirect from HTTP to HTTPS.
1585
+
1586
+ `redirect_http_to_https` and `redirect_https_to_http` options cannot be enabled
1587
+ simultaneously.
1588
+ """
1589
+
1590
+ redirect_https_to_http: Optional[OptionsRedirectHTTPSToHTTP]
1591
+ """Enables redirect from HTTPS to HTTP.
1592
+
1593
+ `redirect_http_to_https` and `redirect_https_to_http` options cannot be enabled
1594
+ simultaneously.
1595
+ """
1596
+
1597
+ referrer_acl: Optional[OptionsReferrerACL]
1598
+ """Controls access to the CDN resource content for specified domain names."""
1599
+
1600
+ request_limiter: Optional[OptionsRequestLimiter]
1601
+ """Option allows to limit the amount of HTTP requests."""
1602
+
1603
+ response_headers_hiding_policy: Optional[OptionsResponseHeadersHidingPolicy]
1604
+ """Hides HTTP headers from an origin server in the CDN response."""
1605
+
1606
+ rewrite: Optional[OptionsRewrite]
1607
+ """Changes and redirects requests from the CDN to the origin.
1608
+
1609
+ It operates according to the
1610
+ [Nginx](https://nginx.org/en/docs/http/ngx_http_rewrite_module.html#rewrite)
1611
+ configuration.
1612
+ """
1613
+
1614
+ secure_key: Optional[OptionsSecureKey]
1615
+ """Configures access with tokenized URLs.
1616
+
1617
+ This makes impossible to access content without a valid (unexpired) token.
1618
+ """
1619
+
1620
+ slice: Optional[OptionsSlice]
1621
+ """
1622
+ Requests and caches files larger than 10 MB in parts (no larger than 10 MB per
1623
+ part.) This reduces time to first byte.
1624
+
1625
+ The option is based on the
1626
+ [Slice](https://nginx.org/en/docs/http/ngx_http_slice_module.html) module.
1627
+
1628
+ Notes:
1629
+
1630
+ 1. Origin must support HTTP Range requests.
1631
+ 2. Not supported with `gzipON`, `brotli_compression` or `fetch_compressed`
1632
+ options enabled.
1633
+ """
1634
+
1635
+ sni: Optional[OptionsSni]
1636
+ """
1637
+ The hostname that is added to SNI requests from CDN servers to the origin server
1638
+ via HTTPS.
1639
+
1640
+ SNI is generally only required if your origin uses shared hosting or does not
1641
+ have a dedicated IP address. If the origin server presents multiple
1642
+ certificates, SNI allows the origin server to know which certificate to use for
1643
+ the connection.
1644
+
1645
+ The option works only if `originProtocol` parameter is `HTTPS` or `MATCH`.
1646
+ """
1647
+
1648
+ stale: Optional[OptionsStale]
1649
+ """Serves stale cached content in case of origin unavailability."""
1650
+
1651
+ static_response_headers: Optional[OptionsStaticResponseHeaders]
1652
+ """Custom HTTP Headers that a CDN server adds to a response."""
1653
+
1654
+ static_headers: Annotated[Optional[OptionsStaticHeaders], PropertyInfo(alias="staticHeaders")]
1655
+ """**Legacy option**. Use the `static_response_headers` option instead.
1656
+
1657
+ Custom HTTP Headers that a CDN server adds to response. Up to fifty custom HTTP
1658
+ Headers can be specified. May contain a header with multiple values.
1659
+ """
1660
+
1661
+ static_request_headers: Annotated[Optional[OptionsStaticRequestHeaders], PropertyInfo(alias="staticRequestHeaders")]
1662
+ """Custom HTTP Headers for a CDN server to add to request.
1663
+
1664
+ Up to fifty custom HTTP Headers can be specified.
1665
+ """
1666
+
1667
+ user_agent_acl: Optional[OptionsUserAgentACL]
1668
+ """Controls access to the content for specified User-Agents."""
1669
+
1670
+ waap: Optional[OptionsWaap]
1671
+ """Allows to enable WAAP (Web Application and API Protection)."""
1672
+
1673
+ websockets: Optional[OptionsWebsockets]
1674
+ """Enables or disables WebSockets connections to an origin server."""