gcore 0.12.0__py3-none-any.whl → 0.14.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.
- gcore/__init__.py +3 -1
- gcore/_base_client.py +9 -9
- gcore/_client.py +25 -10
- gcore/_models.py +10 -4
- gcore/_qs.py +7 -7
- gcore/_types.py +18 -11
- gcore/_utils/_transform.py +2 -2
- gcore/_utils/_utils.py +4 -4
- gcore/_version.py +1 -1
- gcore/pagination.py +137 -0
- gcore/resources/__init__.py +14 -0
- gcore/resources/cdn/__init__.py +201 -0
- gcore/resources/cdn/audit_log.py +406 -0
- gcore/resources/cdn/cdn.py +957 -0
- gcore/resources/cdn/certificates.py +1062 -0
- gcore/resources/cdn/ip_ranges.py +224 -0
- gcore/resources/cdn/logs/__init__.py +33 -0
- gcore/resources/cdn/logs/logs.py +1424 -0
- gcore/resources/cdn/logs/settings.py +1081 -0
- gcore/resources/cdn/logs_uploader/__init__.py +61 -0
- gcore/resources/cdn/logs_uploader/configs.py +868 -0
- gcore/resources/cdn/logs_uploader/logs_uploader.py +166 -0
- gcore/resources/cdn/logs_uploader/policies.py +1060 -0
- gcore/resources/cdn/logs_uploader/targets.py +811 -0
- gcore/resources/cdn/metrics.py +419 -0
- gcore/resources/cdn/network_capacity.py +139 -0
- gcore/resources/cdn/origin_groups.py +1496 -0
- gcore/resources/cdn/resources/__init__.py +47 -0
- gcore/resources/cdn/resources/resources.py +2060 -0
- gcore/resources/cdn/resources/rules.py +1027 -0
- gcore/resources/cdn/resources/shield.py +259 -0
- gcore/resources/cdn/rule_templates.py +883 -0
- gcore/resources/cdn/shields.py +139 -0
- gcore/resources/cdn/statistics.py +1408 -0
- gcore/resources/cdn/trusted_ca_certificates.py +592 -0
- gcore/resources/cloud/audit_logs.py +33 -29
- gcore/resources/cloud/baremetal/flavors.py +21 -17
- gcore/resources/cloud/baremetal/images.py +19 -15
- gcore/resources/cloud/baremetal/servers.py +141 -119
- gcore/resources/cloud/billing_reservations.py +41 -33
- gcore/resources/cloud/cloud.py +24 -0
- gcore/resources/cloud/cost_reports.py +149 -119
- gcore/resources/cloud/file_shares/access_rules.py +25 -13
- gcore/resources/cloud/file_shares/file_shares.py +107 -71
- gcore/resources/cloud/floating_ips.py +270 -52
- gcore/resources/cloud/gpu_baremetal_clusters/flavors.py +13 -9
- gcore/resources/cloud/gpu_baremetal_clusters/gpu_baremetal_clusters.py +275 -65
- gcore/resources/cloud/gpu_baremetal_clusters/images.py +69 -53
- gcore/resources/cloud/gpu_baremetal_clusters/interfaces.py +9 -5
- gcore/resources/cloud/gpu_baremetal_clusters/servers.py +151 -127
- gcore/resources/cloud/inference/api_keys.py +51 -31
- gcore/resources/cloud/inference/applications/deployments.py +49 -31
- gcore/resources/cloud/inference/applications/templates.py +17 -9
- gcore/resources/cloud/inference/deployments/deployments.py +171 -139
- gcore/resources/cloud/inference/deployments/logs.py +17 -13
- gcore/resources/cloud/inference/flavors.py +21 -13
- gcore/resources/cloud/inference/inference.py +9 -5
- gcore/resources/cloud/inference/registry_credentials.py +45 -25
- gcore/resources/cloud/inference/secrets.py +45 -25
- gcore/resources/cloud/instances/flavors.py +17 -13
- gcore/resources/cloud/instances/images.py +153 -129
- gcore/resources/cloud/instances/instances.py +287 -213
- gcore/resources/cloud/instances/interfaces.py +165 -161
- gcore/resources/cloud/instances/metrics.py +9 -5
- gcore/resources/cloud/ip_ranges.py +25 -15
- gcore/resources/cloud/k8s/clusters/clusters.py +151 -87
- gcore/resources/cloud/k8s/clusters/nodes.py +19 -11
- gcore/resources/cloud/k8s/clusters/pools/nodes.py +19 -11
- gcore/resources/cloud/k8s/clusters/pools/pools.py +83 -59
- gcore/resources/cloud/k8s/flavors.py +13 -9
- gcore/resources/cloud/k8s/k8s.py +9 -5
- gcore/resources/cloud/load_balancers/flavors.py +11 -7
- gcore/resources/cloud/load_balancers/l7_policies/l7_policies.py +103 -83
- gcore/resources/cloud/load_balancers/l7_policies/rules.py +77 -57
- gcore/resources/cloud/load_balancers/listeners.py +125 -105
- gcore/resources/cloud/load_balancers/load_balancers.py +155 -123
- gcore/resources/cloud/load_balancers/metrics.py +9 -5
- gcore/resources/cloud/load_balancers/pools/health_monitors.py +25 -17
- gcore/resources/cloud/load_balancers/pools/members.py +31 -23
- gcore/resources/cloud/load_balancers/pools/pools.py +155 -129
- gcore/resources/cloud/load_balancers/statuses.py +17 -9
- gcore/resources/cloud/networks/networks.py +79 -55
- gcore/resources/cloud/networks/routers.py +75 -47
- gcore/resources/cloud/networks/subnets.py +105 -81
- gcore/resources/cloud/placement_groups.py +33 -17
- gcore/resources/cloud/projects.py +53 -41
- gcore/resources/cloud/quotas/quotas.py +25 -13
- gcore/resources/cloud/quotas/requests.py +41 -25
- gcore/resources/cloud/regions.py +25 -23
- gcore/resources/cloud/registries/artifacts.py +17 -9
- gcore/resources/cloud/registries/registries.py +55 -29
- gcore/resources/cloud/registries/repositories.py +17 -9
- gcore/resources/cloud/registries/tags.py +9 -5
- gcore/resources/cloud/registries/users.py +65 -35
- gcore/resources/cloud/reserved_fixed_ips/reserved_fixed_ips.py +123 -107
- gcore/resources/cloud/reserved_fixed_ips/vip.py +45 -25
- gcore/resources/cloud/secrets.py +43 -27
- gcore/resources/cloud/security_groups/rules.py +55 -43
- gcore/resources/cloud/security_groups/security_groups.py +79 -47
- gcore/resources/cloud/ssh_keys.py +51 -31
- gcore/resources/cloud/tasks.py +57 -45
- gcore/resources/cloud/usage_reports.py +27 -23
- gcore/resources/cloud/users/role_assignments.py +49 -33
- gcore/resources/cloud/volumes.py +237 -201
- gcore/resources/dns/dns.py +17 -13
- gcore/resources/dns/locations.py +29 -17
- gcore/resources/dns/metrics.py +13 -9
- gcore/resources/dns/pickers/pickers.py +5 -5
- gcore/resources/dns/pickers/presets.py +9 -5
- gcore/resources/dns/zones/dnssec.py +19 -11
- gcore/resources/dns/zones/rrsets.py +149 -91
- gcore/resources/dns/zones/zones.py +247 -189
- gcore/resources/fastedge/apps/apps.py +105 -89
- gcore/resources/fastedge/apps/logs.py +25 -21
- gcore/resources/fastedge/binaries.py +33 -17
- gcore/resources/fastedge/fastedge.py +5 -5
- gcore/resources/fastedge/kv_stores.py +43 -31
- gcore/resources/fastedge/secrets.py +69 -45
- gcore/resources/fastedge/statistics.py +25 -17
- gcore/resources/fastedge/templates.py +59 -39
- gcore/resources/iam/api_tokens.py +43 -27
- gcore/resources/iam/iam.py +5 -5
- gcore/resources/iam/users.py +97 -65
- gcore/resources/security/bgp_announces.py +27 -19
- gcore/resources/security/events.py +23 -19
- gcore/resources/security/profile_templates.py +9 -5
- gcore/resources/security/profiles.py +69 -45
- gcore/resources/storage/buckets/buckets.py +37 -25
- gcore/resources/storage/buckets/cors.py +19 -11
- gcore/resources/storage/buckets/lifecycle.py +19 -11
- gcore/resources/storage/buckets/policy.py +25 -13
- gcore/resources/storage/credentials.py +19 -15
- gcore/resources/storage/locations.py +13 -9
- gcore/resources/storage/statistics.py +39 -31
- gcore/resources/storage/storage.py +105 -69
- gcore/resources/streaming/ai_tasks.py +307 -197
- gcore/resources/streaming/broadcasts.py +63 -35
- gcore/resources/streaming/directories.py +65 -39
- gcore/resources/streaming/players.py +47 -31
- gcore/resources/streaming/playlists.py +189 -123
- gcore/resources/streaming/quality_sets.py +69 -39
- gcore/resources/streaming/restreams.py +47 -27
- gcore/resources/streaming/statistics.py +613 -407
- gcore/resources/streaming/streams/overlays.py +107 -67
- gcore/resources/streaming/streams/streams.py +403 -263
- gcore/resources/streaming/videos/subtitles.py +131 -75
- gcore/resources/streaming/videos/videos.py +429 -279
- gcore/resources/waap/advanced_rules.py +9 -5
- gcore/resources/waap/custom_page_sets.py +99 -75
- gcore/resources/waap/domains/advanced_rules.py +157 -99
- gcore/resources/waap/domains/api_discovery.py +71 -47
- gcore/resources/waap/domains/api_path_groups.py +9 -5
- gcore/resources/waap/domains/api_paths.py +79 -83
- gcore/resources/waap/domains/custom_rules.py +89 -59
- gcore/resources/waap/domains/domains.py +59 -41
- gcore/resources/waap/domains/firewall_rules.py +83 -55
- gcore/resources/waap/domains/insight_silences.py +59 -39
- gcore/resources/waap/domains/insights.py +39 -27
- gcore/resources/waap/domains/settings.py +21 -13
- gcore/resources/waap/domains/statistics.py +99 -75
- gcore/resources/waap/insights.py +23 -21
- gcore/resources/waap/ip_info/ip_info.py +70 -38
- gcore/resources/waap/ip_info/metrics.py +11 -7
- gcore/resources/waap/organizations.py +17 -13
- gcore/resources/waap/statistics.py +9 -5
- gcore/resources/waap/tags.py +17 -17
- gcore/resources/waap/waap.py +5 -5
- gcore/types/cdn/__init__.py +80 -0
- gcore/types/cdn/audit_log_list_params.py +73 -0
- gcore/types/cdn/ca_certificate.py +53 -0
- gcore/types/cdn/ca_certificate_list.py +10 -0
- gcore/types/cdn/cdn_account.py +86 -0
- gcore/types/cdn/cdn_account_limits.py +27 -0
- gcore/types/cdn/cdn_audit_log_entry.py +66 -0
- gcore/types/cdn/cdn_available_features.py +46 -0
- gcore/types/cdn/cdn_list_purge_statuses_params.py +67 -0
- gcore/types/cdn/cdn_log_entry.py +70 -0
- gcore/types/cdn/cdn_metrics.py +22 -0
- gcore/types/cdn/cdn_metrics_groups.py +13 -0
- gcore/types/cdn/cdn_metrics_values.py +19 -0
- gcore/types/cdn/cdn_resource.py +1977 -0
- gcore/types/cdn/cdn_resource_list.py +10 -0
- gcore/types/cdn/cdn_update_account_params.py +15 -0
- gcore/types/cdn/certificate_create_params.py +51 -0
- gcore/types/cdn/certificate_get_status_params.py +14 -0
- gcore/types/cdn/certificate_list_params.py +29 -0
- gcore/types/cdn/certificate_replace_params.py +39 -0
- gcore/types/cdn/log_download_params.py +279 -0
- gcore/types/cdn/log_list_params.py +273 -0
- gcore/types/cdn/logs/__init__.py +7 -0
- gcore/types/cdn/logs/log_settings.py +172 -0
- gcore/types/cdn/logs/setting_create_params.py +200 -0
- gcore/types/cdn/logs/setting_update_params.py +200 -0
- gcore/types/cdn/logs_aggregated_stats.py +23 -0
- gcore/types/cdn/logs_uploader/__init__.py +23 -0
- gcore/types/cdn/logs_uploader/config_create_params.py +32 -0
- gcore/types/cdn/logs_uploader/config_list_params.py +16 -0
- gcore/types/cdn/logs_uploader/config_replace_params.py +32 -0
- gcore/types/cdn/logs_uploader/config_update_params.py +32 -0
- gcore/types/cdn/logs_uploader/logs_uploader_config.py +51 -0
- gcore/types/cdn/logs_uploader/logs_uploader_config_list.py +10 -0
- gcore/types/cdn/logs_uploader/logs_uploader_policy.py +73 -0
- gcore/types/cdn/logs_uploader/logs_uploader_policy_list.py +10 -0
- gcore/types/cdn/logs_uploader/logs_uploader_target.py +236 -0
- gcore/types/cdn/logs_uploader/logs_uploader_target_list.py +10 -0
- gcore/types/cdn/logs_uploader/policy_create_params.py +61 -0
- gcore/types/cdn/logs_uploader/policy_list_fields_response.py +8 -0
- gcore/types/cdn/logs_uploader/policy_list_params.py +16 -0
- gcore/types/cdn/logs_uploader/policy_replace_params.py +61 -0
- gcore/types/cdn/logs_uploader/policy_update_params.py +61 -0
- gcore/types/cdn/logs_uploader/target_create_params.py +249 -0
- gcore/types/cdn/logs_uploader/target_list_params.py +16 -0
- gcore/types/cdn/logs_uploader/target_replace_params.py +249 -0
- gcore/types/cdn/logs_uploader/target_update_params.py +249 -0
- gcore/types/cdn/logs_uploader_validation.py +23 -0
- gcore/types/cdn/metric_list_params.py +168 -0
- gcore/types/cdn/network_capacity.py +22 -0
- gcore/types/cdn/origin_group_create_params.py +184 -0
- gcore/types/cdn/origin_group_list_params.py +24 -0
- gcore/types/cdn/origin_group_replace_params.py +190 -0
- gcore/types/cdn/origin_group_update_params.py +190 -0
- gcore/types/cdn/origin_groups.py +212 -0
- gcore/types/cdn/origin_groups_list.py +10 -0
- gcore/types/cdn/public_ip_list.py +15 -0
- gcore/types/cdn/public_network_list.py +15 -0
- gcore/types/cdn/purge_status.py +55 -0
- gcore/types/cdn/resource_aggregated_stats.py +80 -0
- gcore/types/cdn/resource_create_params.py +1825 -0
- gcore/types/cdn/resource_list_params.py +107 -0
- gcore/types/cdn/resource_prefetch_params.py +17 -0
- gcore/types/cdn/resource_purge_params.py +71 -0
- gcore/types/cdn/resource_replace_params.py +1803 -0
- gcore/types/cdn/resource_update_params.py +1794 -0
- gcore/types/cdn/resource_usage_stats.py +111 -0
- gcore/types/cdn/resources/__init__.py +11 -0
- gcore/types/cdn/resources/cdn_resource_rule.py +1695 -0
- gcore/types/cdn/resources/origin_shielding.py +15 -0
- gcore/types/cdn/resources/rule_create_params.py +1652 -0
- gcore/types/cdn/resources/rule_list_response.py +10 -0
- gcore/types/cdn/resources/rule_replace_params.py +1654 -0
- gcore/types/cdn/resources/rule_update_params.py +1654 -0
- gcore/types/cdn/resources/shield_replace_params.py +16 -0
- gcore/types/cdn/rule_template.py +1666 -0
- gcore/types/cdn/rule_template_create_params.py +1636 -0
- gcore/types/cdn/rule_template_list.py +10 -0
- gcore/types/cdn/rule_template_replace_params.py +1636 -0
- gcore/types/cdn/rule_template_update_params.py +1636 -0
- gcore/types/cdn/shield_aggregated_stats.py +23 -0
- gcore/types/cdn/shield_list_response.py +25 -0
- gcore/types/cdn/ssl_detail.py +62 -0
- gcore/types/cdn/ssl_detail_list.py +10 -0
- gcore/types/cdn/ssl_request_status.py +135 -0
- gcore/types/cdn/statistic_get_logs_usage_aggregated_params.py +42 -0
- gcore/types/cdn/statistic_get_logs_usage_series_params.py +35 -0
- gcore/types/cdn/statistic_get_resource_usage_aggregated_params.py +151 -0
- gcore/types/cdn/statistic_get_resource_usage_series_params.py +131 -0
- gcore/types/cdn/statistic_get_shield_usage_aggregated_params.py +42 -0
- gcore/types/cdn/statistic_get_shield_usage_series_params.py +25 -0
- gcore/types/cdn/trusted_ca_certificate_create_params.py +23 -0
- gcore/types/cdn/trusted_ca_certificate_list_params.py +29 -0
- gcore/types/cdn/trusted_ca_certificate_replace_params.py +15 -0
- gcore/types/cdn/usage_series_stats.py +31 -0
- gcore/types/cloud/__init__.py +2 -0
- gcore/types/cloud/file_share.py +4 -0
- gcore/types/cloud/file_share_create_params.py +20 -0
- gcore/types/cloud/file_share_update_params.py +40 -3
- gcore/types/cloud/floating_ip.py +1 -1
- gcore/types/cloud/floating_ip_detailed.py +1 -1
- gcore/types/cloud/floating_ip_update_params.py +43 -0
- gcore/types/cloud/gpu_baremetal_cluster_action_params.py +46 -0
- gcore/types/cloud/inference/inference_deployment.py +3 -1
- gcore/types/cloud/instance_create_params.py +3 -1
- gcore/types/cloud/k8s/cluster_create_params.py +46 -4
- gcore/types/cloud/k8s/cluster_update_params.py +60 -6
- gcore/types/cloud/k8s/clusters/pool_update_params.py +1 -1
- gcore/types/cloud/k8s/k8s_cluster.py +40 -3
- gcore/types/cloud/load_balancer_update_params.py +3 -1
- gcore/types/cloud/network_update_params.py +3 -1
- gcore/types/cloud/networks/subnet_update_params.py +3 -1
- gcore/types/cloud/registries/user_create_multiple_params.py +5 -3
- gcore/types/cloud/registries/user_create_params.py +5 -3
- gcore/types/cloud/registry_create_params.py +5 -3
- gcore/types/cloud/security_group_update_params.py +3 -1
- gcore/types/cloud/ssh_key_created.py +6 -3
- gcore/types/cloud/volume_update_params.py +3 -1
- gcore/types/dns/zone_get_statistics_params.py +12 -9
- gcore/types/dns/zone_get_statistics_response.py +3 -1
- gcore/types/dns/zone_import_params.py +21 -15
- gcore/types/dns/zones/dns_output_rrset.py +7 -3
- gcore/types/iam/account_overview.py +7 -2
- gcore/types/iam/user.py +7 -2
- gcore/types/iam/user_detailed.py +7 -2
- gcore/types/iam/user_invite_params.py +4 -1
- gcore/types/iam/user_update.py +7 -2
- gcore/types/iam/user_update_params.py +7 -2
- gcore/types/streaming/ai_contentmoderation_hardnudity.py +6 -4
- gcore/types/streaming/ai_contentmoderation_nsfw.py +6 -4
- gcore/types/streaming/ai_contentmoderation_softnudity.py +6 -4
- gcore/types/streaming/ai_contentmoderation_sport.py +6 -4
- gcore/types/streaming/ai_task.py +20 -11
- gcore/types/streaming/ai_task_create_params.py +20 -11
- gcore/types/streaming/ai_task_get_response.py +5 -4
- gcore/types/streaming/ai_task_list_params.py +11 -5
- gcore/types/streaming/clip.py +33 -22
- gcore/types/streaming/create_video_param.py +75 -43
- gcore/types/streaming/playlist.py +7 -5
- gcore/types/streaming/playlist_create_params.py +7 -5
- gcore/types/streaming/playlist_update_params.py +7 -5
- gcore/types/streaming/playlist_video.py +75 -43
- gcore/types/streaming/statistic_get_unique_viewers_cdn_params.py +7 -4
- gcore/types/streaming/stream.py +207 -136
- gcore/types/streaming/stream_create_clip_params.py +33 -22
- gcore/types/streaming/stream_create_params.py +41 -24
- gcore/types/streaming/stream_update_params.py +41 -24
- gcore/types/streaming/video.py +138 -76
- gcore/types/streaming/video_list_params.py +4 -2
- gcore/types/streaming/video_update_params.py +75 -43
- gcore/types/waap/__init__.py +2 -1
- gcore/types/waap/domain_update_params.py +2 -2
- gcore/types/waap/domains/advanced_rule_create_params.py +26 -18
- gcore/types/waap/domains/advanced_rule_list_params.py +10 -7
- gcore/types/waap/domains/advanced_rule_update_params.py +22 -17
- gcore/types/waap/domains/api_path_create_params.py +0 -3
- gcore/types/waap/domains/api_path_update_params.py +1 -3
- gcore/types/waap/domains/custom_rule_create_params.py +36 -35
- gcore/types/waap/domains/custom_rule_update_params.py +31 -33
- gcore/types/waap/domains/firewall_rule_create_params.py +6 -6
- gcore/types/waap/domains/firewall_rule_update_params.py +5 -5
- gcore/types/waap/domains/waap_advanced_rule.py +17 -9
- gcore/types/waap/domains/waap_custom_rule.py +5 -2
- gcore/types/waap/domains/waap_firewall_rule.py +1 -1
- gcore/types/waap/domains/waap_insight.py +1 -1
- gcore/types/waap/insight_list_types_params.py +1 -1
- gcore/types/waap/ip_info_get_top_urls_response.py +3 -12
- gcore/types/waap/{ip_info_get_ip_info_response.py → waap_ip_info.py} +2 -2
- gcore/types/waap/waap_top_url.py +13 -0
- {gcore-0.12.0.dist-info → gcore-0.14.0.dist-info}/METADATA +1 -1
- {gcore-0.12.0.dist-info → gcore-0.14.0.dist-info}/RECORD +340 -218
- {gcore-0.12.0.dist-info → gcore-0.14.0.dist-info}/WHEEL +0 -0
- {gcore-0.12.0.dist-info → gcore-0.14.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -12,7 +12,9 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
12
12
|
"""Video name"""
|
|
13
13
|
|
|
14
14
|
auto_transcribe_audio_language: Literal["disable", "auto", "<language_code>"]
|
|
15
|
-
"""Automatic creation of subtitles by transcribing the audio track.
|
|
15
|
+
"""Automatic creation of subtitles by transcribing the audio track.
|
|
16
|
+
|
|
17
|
+
Values:
|
|
16
18
|
|
|
17
19
|
- disable – Do not transcribe.
|
|
18
20
|
- auto – Automatically detects the activation of the option based on the
|
|
@@ -22,7 +24,9 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
22
24
|
language spoken in the audio track, or when auto language detection fails.
|
|
23
25
|
Language is set by 3-letter language code according to ISO-639-2
|
|
24
26
|
(bibliographic code). List of languages is available in `audio_language`
|
|
25
|
-
attribute of API POST /streaming/ai/transcribe .
|
|
27
|
+
attribute of API POST /streaming/ai/transcribe .
|
|
28
|
+
|
|
29
|
+
Example:
|
|
26
30
|
|
|
27
31
|
```
|
|
28
32
|
auto_transcribe_audio_language: "auto"
|
|
@@ -41,16 +45,23 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
41
45
|
"""Automatic translation of auto-transcribed subtitles to the specified
|
|
42
46
|
language(s).
|
|
43
47
|
|
|
44
|
-
Can be used both together with `auto_transcribe_audio_language` option only.
|
|
45
|
-
|
|
46
|
-
|
|
48
|
+
Can be used both together with `auto_transcribe_audio_language` option only.
|
|
49
|
+
|
|
50
|
+
Use it when you want to make automatic subtitles in languages other than the
|
|
51
|
+
original language in audio.
|
|
52
|
+
|
|
53
|
+
Values:
|
|
47
54
|
|
|
48
55
|
- disable – Do not translate.
|
|
49
56
|
- default – There are 3 default languages: eng,fre,ger
|
|
50
57
|
- \\ – Explicit language to translate to, or list of languages separated by a
|
|
51
58
|
comma. Look at list of available languages in description of AI ASR task
|
|
52
|
-
creation.
|
|
53
|
-
|
|
59
|
+
creation.
|
|
60
|
+
|
|
61
|
+
If several languages are specified for translation, a separate subtitle will be
|
|
62
|
+
generated for each language.
|
|
63
|
+
|
|
64
|
+
Example:
|
|
54
65
|
|
|
55
66
|
```
|
|
56
67
|
auto_translate_subtitles_language: default
|
|
@@ -79,9 +90,10 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
79
90
|
"""
|
|
80
91
|
|
|
81
92
|
custom_iframe_url: str
|
|
82
|
-
"""
|
|
83
|
-
|
|
84
|
-
|
|
93
|
+
"""Deprecated.
|
|
94
|
+
|
|
95
|
+
Custom URL of IFrame for video player to be used in share panel in player. Auto
|
|
96
|
+
generated IFrame URL provided by default
|
|
85
97
|
"""
|
|
86
98
|
|
|
87
99
|
description: str
|
|
@@ -94,8 +106,11 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
94
106
|
"""Authorization HTTP request header.
|
|
95
107
|
|
|
96
108
|
Will be used as credentials to authenticate a request to download a file
|
|
97
|
-
(specified in "`origin_url`" parameter) on an external server.
|
|
98
|
-
|
|
109
|
+
(specified in "`origin_url`" parameter) on an external server.
|
|
110
|
+
|
|
111
|
+
Syntax: `Authorization: <auth-scheme> <authorization-parameters>`
|
|
112
|
+
|
|
113
|
+
Examples:
|
|
99
114
|
|
|
100
115
|
- "`origin_http_headers`": "Authorization: Basic ..."
|
|
101
116
|
- "`origin_http_headers`": "Authorization: Bearer ..."
|
|
@@ -121,16 +136,21 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
121
136
|
"""
|
|
122
137
|
|
|
123
138
|
poster: str
|
|
124
|
-
"""
|
|
125
|
-
|
|
139
|
+
"""Poster is your own static image which can be displayed before the video starts.
|
|
140
|
+
|
|
126
141
|
After uploading the video, the system will automatically create several
|
|
127
142
|
screenshots (they will be stored in "screenshots" attribute) from which you can
|
|
128
143
|
select an default screenshot. This "poster" field is for uploading your own
|
|
129
144
|
image. Also use attribute "`screenshot_id`" to select poster as a default
|
|
130
|
-
screnshot.
|
|
145
|
+
screnshot.
|
|
146
|
+
|
|
147
|
+
Attribute accepts single image as base64-encoded string
|
|
131
148
|
[(RFC 2397 – The "data" URL scheme)](https://www.rfc-editor.org/rfc/rfc2397). In
|
|
132
|
-
format: `data:[<mediatype>];base64,<data>`
|
|
133
|
-
|
|
149
|
+
format: `data:[<mediatype>];base64,<data>`
|
|
150
|
+
|
|
151
|
+
MIME-types are image/jpeg, image/webp, and image/png and file sizes up to 1Mb.
|
|
152
|
+
|
|
153
|
+
Examples:
|
|
134
154
|
|
|
135
155
|
- `data:image/jpeg;base64,/9j/4AA...qf/2Q==`
|
|
136
156
|
- `data:image/png;base64,iVBORw0KGg...ggg==`
|
|
@@ -141,13 +161,16 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
141
161
|
"""
|
|
142
162
|
Priority allows you to adjust the urgency of processing some videos before
|
|
143
163
|
others in your account, if your algorithm requires it. For example, when there
|
|
144
|
-
are very urgent video and some regular ones that can wait in the queue.
|
|
145
|
-
|
|
146
|
-
|
|
164
|
+
are very urgent video and some regular ones that can wait in the queue.
|
|
165
|
+
|
|
166
|
+
Value range, integer [-10..10]. -10 is the lowest down-priority, 10 is the
|
|
167
|
+
highest up-priority. Default priority is 0.
|
|
147
168
|
"""
|
|
148
169
|
|
|
149
170
|
projection: str
|
|
150
|
-
"""Deprecated.
|
|
171
|
+
"""Deprecated.
|
|
172
|
+
|
|
173
|
+
Regulates the video format:
|
|
151
174
|
|
|
152
175
|
- **regular** — plays the video as usual
|
|
153
176
|
- **vr360** — plays the video in 360 degree mode
|
|
@@ -166,28 +189,34 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
166
189
|
remote_poster_url: str
|
|
167
190
|
"""
|
|
168
191
|
Poster URL to download from external resource, instead of uploading via "poster"
|
|
169
|
-
attribute.
|
|
192
|
+
attribute.
|
|
193
|
+
|
|
194
|
+
It has the same restrictions as "poster" attribute.
|
|
170
195
|
"""
|
|
171
196
|
|
|
172
197
|
remove_poster: bool
|
|
173
198
|
"""Set it to true to remove poster"""
|
|
174
199
|
|
|
175
200
|
screenshot_id: int
|
|
176
|
-
"""
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
201
|
+
"""Default screenshot index.
|
|
202
|
+
|
|
203
|
+
Specify an ID from the "screenshots" array, so that the URL of the required
|
|
204
|
+
screenshot appears in the "screenshot" attribute as the default screenshot. By
|
|
205
|
+
default 5 static screenshots will be taken from different places in the video
|
|
206
|
+
after transcoding. If the video is short, there may be fewer screenshots.
|
|
207
|
+
|
|
208
|
+
Counting from 0. A value of -1 sets the default screenshot to the URL of your
|
|
209
|
+
own image from the "poster" attribute.
|
|
210
|
+
|
|
211
|
+
Look at "screenshot" attribute in GET /videos/{`video_id`} for details.
|
|
184
212
|
"""
|
|
185
213
|
|
|
186
214
|
share_url: str
|
|
187
|
-
"""
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
sharing is
|
|
215
|
+
"""Deprecated.
|
|
216
|
+
|
|
217
|
+
Custom URL or iframe displayed in the link field when a user clicks on a sharing
|
|
218
|
+
button in player. If empty, the link field and social network sharing is
|
|
219
|
+
disabled
|
|
191
220
|
"""
|
|
192
221
|
|
|
193
222
|
source_bitrate_limit: bool
|
|
@@ -200,16 +229,19 @@ class VideoUpdateParams(TypedDict, total=False):
|
|
|
200
229
|
By default `source_bitrate_limit: true` this option allows you to have the
|
|
201
230
|
output bitrate not more than in the original video, thus to transcode video
|
|
202
231
|
faster and to deliver it to end-viewers faster as well. At the same time, the
|
|
203
|
-
quality will be similar to the original.
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
232
|
+
quality will be similar to the original.
|
|
233
|
+
|
|
234
|
+
If for some reason you need more byte-space in the output quality when encoding,
|
|
235
|
+
you can set this option to `source_bitrate_limit: false`. Then, when
|
|
236
|
+
transcoding, the quality ceiling will be raised from the bitrate of the original
|
|
237
|
+
video to the maximum possible limit specified in our the Product Documentation.
|
|
238
|
+
For example, this may be needed when:
|
|
209
239
|
|
|
210
240
|
- to improve the visual quality parameters using PSNR, SSIM, VMAF metrics,
|
|
211
241
|
- to improve the picture quality on dynamic scenes,
|
|
212
|
-
- etc.
|
|
213
|
-
|
|
214
|
-
|
|
242
|
+
- etc.
|
|
243
|
+
|
|
244
|
+
The option is applied only at the video creation stage and cannot be changed
|
|
245
|
+
later. If you want to re-transcode the video using new value, then you need to
|
|
246
|
+
create and upload a new video only.
|
|
215
247
|
"""
|
gcore/types/waap/__init__.py
CHANGED
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
5
|
from .waap_tag import WaapTag as WaapTag
|
|
6
|
+
from .waap_ip_info import WaapIPInfo as WaapIPInfo
|
|
7
|
+
from .waap_top_url import WaapTopURL as WaapTopURL
|
|
6
8
|
from .waap_rule_set import WaapRuleSet as WaapRuleSet
|
|
7
9
|
from .tag_list_params import TagListParams as TagListParams
|
|
8
10
|
from .waap_policy_mode import WaapPolicyMode as WaapPolicyMode
|
|
@@ -30,7 +32,6 @@ from .waap_domain_settings_model import WaapDomainSettingsModel as WaapDomainSet
|
|
|
30
32
|
from .waap_rule_blocked_requests import WaapRuleBlockedRequests as WaapRuleBlockedRequests
|
|
31
33
|
from .custom_page_set_list_params import CustomPageSetListParams as CustomPageSetListParams
|
|
32
34
|
from .ip_info_get_top_urls_params import IPInfoGetTopURLsParams as IPInfoGetTopURLsParams
|
|
33
|
-
from .ip_info_get_ip_info_response import IPInfoGetIPInfoResponse as IPInfoGetIPInfoResponse
|
|
34
35
|
from .custom_page_set_create_params import CustomPageSetCreateParams as CustomPageSetCreateParams
|
|
35
36
|
from .custom_page_set_update_params import CustomPageSetUpdateParams as CustomPageSetUpdateParams
|
|
36
37
|
from .ip_info_get_top_urls_response import IPInfoGetTopURLsResponse as IPInfoGetTopURLsResponse
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
-
from typing_extensions import Literal, TypedDict
|
|
5
|
+
from typing_extensions import Literal, Required, TypedDict
|
|
6
6
|
|
|
7
7
|
__all__ = ["DomainUpdateParams"]
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
class DomainUpdateParams(TypedDict, total=False):
|
|
11
|
-
status: Literal["active", "monitor"]
|
|
11
|
+
status: Required[Literal["active", "monitor"]]
|
|
12
12
|
"""The current status of the domain"""
|
|
@@ -12,7 +12,10 @@ __all__ = ["AdvancedRuleCreateParams", "Action", "ActionBlock", "ActionTag"]
|
|
|
12
12
|
|
|
13
13
|
class AdvancedRuleCreateParams(TypedDict, total=False):
|
|
14
14
|
action: Required[Action]
|
|
15
|
-
"""The action that the rule takes when triggered
|
|
15
|
+
"""The action that the rule takes when triggered.
|
|
16
|
+
|
|
17
|
+
Only one action can be set per rule.
|
|
18
|
+
"""
|
|
16
19
|
|
|
17
20
|
enabled: Required[bool]
|
|
18
21
|
"""Whether or not the rule is enabled"""
|
|
@@ -24,26 +27,31 @@ class AdvancedRuleCreateParams(TypedDict, total=False):
|
|
|
24
27
|
"""A CEL syntax expression that contains the rule's conditions.
|
|
25
28
|
|
|
26
29
|
Allowed objects are: request, whois, session, response, tags,
|
|
27
|
-
`user_defined_tags`, `user_agent`, `client_data`.
|
|
30
|
+
`user_defined_tags`, `user_agent`, `client_data`.
|
|
31
|
+
|
|
32
|
+
More info can be found here:
|
|
28
33
|
https://gcore.com/docs/waap/waap-rules/advanced-rules
|
|
29
34
|
"""
|
|
30
35
|
|
|
31
|
-
description:
|
|
36
|
+
description: str
|
|
32
37
|
"""The description assigned to the rule"""
|
|
33
38
|
|
|
34
39
|
phase: Optional[Literal["access", "header_filter", "body_filter"]]
|
|
35
|
-
"""The WAAP request/response phase for applying the rule.
|
|
40
|
+
"""The WAAP request/response phase for applying the rule. Default is "access".
|
|
41
|
+
|
|
42
|
+
The "access" phase is responsible for modifying the request before it is sent to
|
|
43
|
+
the origin server.
|
|
44
|
+
|
|
45
|
+
The "`header_filter`" phase is responsible for modifying the HTTP headers of a
|
|
46
|
+
response before they are sent back to the client.
|
|
36
47
|
|
|
37
|
-
|
|
38
|
-
before it is sent to the
|
|
39
|
-
responsible for modifying the HTTP headers of a response before they are sent
|
|
40
|
-
back to the client. The "`body_filter`" phase is responsible for modifying the
|
|
41
|
-
body of a response before it is sent back to the client.
|
|
48
|
+
The "`body_filter`" phase is responsible for modifying the body of a response
|
|
49
|
+
before it is sent back to the client.
|
|
42
50
|
"""
|
|
43
51
|
|
|
44
52
|
|
|
45
53
|
class ActionBlock(TypedDict, total=False):
|
|
46
|
-
action_duration:
|
|
54
|
+
action_duration: str
|
|
47
55
|
"""How long a rule's block action will apply to subsequent requests.
|
|
48
56
|
|
|
49
57
|
Can be specified in seconds or by using a numeral followed by 's', 'm', 'h', or
|
|
@@ -51,8 +59,8 @@ class ActionBlock(TypedDict, total=False):
|
|
|
51
59
|
intervals are not allowed.
|
|
52
60
|
"""
|
|
53
61
|
|
|
54
|
-
status_code:
|
|
55
|
-
"""
|
|
62
|
+
status_code: Literal[403, 405, 418, 429]
|
|
63
|
+
"""A custom HTTP status code that the WAAP returns if a rule blocks a request"""
|
|
56
64
|
|
|
57
65
|
|
|
58
66
|
class ActionTag(TypedDict, total=False):
|
|
@@ -61,23 +69,23 @@ class ActionTag(TypedDict, total=False):
|
|
|
61
69
|
|
|
62
70
|
|
|
63
71
|
class Action(TypedDict, total=False):
|
|
64
|
-
allow:
|
|
72
|
+
allow: object
|
|
65
73
|
"""The WAAP allowed the request"""
|
|
66
74
|
|
|
67
|
-
block:
|
|
75
|
+
block: ActionBlock
|
|
68
76
|
"""
|
|
69
77
|
WAAP block action behavior could be configured with response status code and
|
|
70
78
|
action duration.
|
|
71
79
|
"""
|
|
72
80
|
|
|
73
|
-
captcha:
|
|
81
|
+
captcha: object
|
|
74
82
|
"""The WAAP presented the user with a captcha"""
|
|
75
83
|
|
|
76
|
-
handshake:
|
|
84
|
+
handshake: object
|
|
77
85
|
"""The WAAP performed automatic browser validation"""
|
|
78
86
|
|
|
79
|
-
monitor:
|
|
87
|
+
monitor: object
|
|
80
88
|
"""The WAAP monitored the request but took no action"""
|
|
81
89
|
|
|
82
|
-
tag:
|
|
90
|
+
tag: ActionTag
|
|
83
91
|
"""WAAP tag action gets a list of tags to tag the request scope with"""
|
|
@@ -46,11 +46,14 @@ class AdvancedRuleListParams(TypedDict, total=False):
|
|
|
46
46
|
"""Determine the field to order results by"""
|
|
47
47
|
|
|
48
48
|
phase: Literal["access", "header_filter", "body_filter"]
|
|
49
|
-
"""
|
|
50
|
-
|
|
51
|
-
"access" phase is responsible for modifying the request before it is sent to
|
|
52
|
-
origin server.
|
|
53
|
-
|
|
54
|
-
"`
|
|
55
|
-
|
|
49
|
+
"""Filter rules based on the WAAP request/response phase for applying the rule.
|
|
50
|
+
|
|
51
|
+
The "access" phase is responsible for modifying the request before it is sent to
|
|
52
|
+
the origin server.
|
|
53
|
+
|
|
54
|
+
The "`header_filter`" phase is responsible for modifying the HTTP headers of a
|
|
55
|
+
response before they are sent back to the client.
|
|
56
|
+
|
|
57
|
+
The "`body_filter`" phase is responsible for modifying the body of a response
|
|
58
|
+
before it is sent back to the client.
|
|
56
59
|
"""
|
|
@@ -15,7 +15,7 @@ class AdvancedRuleUpdateParams(TypedDict, total=False):
|
|
|
15
15
|
"""The domain ID"""
|
|
16
16
|
|
|
17
17
|
action: Optional[Action]
|
|
18
|
-
"""The action that a WAAP rule takes when triggered"""
|
|
18
|
+
"""The action that a WAAP rule takes when triggered."""
|
|
19
19
|
|
|
20
20
|
description: Optional[str]
|
|
21
21
|
"""The description assigned to the rule"""
|
|
@@ -27,26 +27,31 @@ class AdvancedRuleUpdateParams(TypedDict, total=False):
|
|
|
27
27
|
"""The name assigned to the rule"""
|
|
28
28
|
|
|
29
29
|
phase: Optional[Literal["access", "header_filter", "body_filter"]]
|
|
30
|
-
"""
|
|
31
|
-
|
|
32
|
-
responsible for modifying the request before it is sent to
|
|
30
|
+
"""The WAAP request/response phase for applying the rule.
|
|
31
|
+
|
|
32
|
+
The "access" phase is responsible for modifying the request before it is sent to
|
|
33
|
+
the origin server.
|
|
34
|
+
|
|
33
35
|
The "`header_filter`" phase is responsible for modifying the HTTP headers of a
|
|
34
|
-
response before they are sent back to the client.
|
|
35
|
-
|
|
36
|
-
|
|
36
|
+
response before they are sent back to the client.
|
|
37
|
+
|
|
38
|
+
The "`body_filter`" phase is responsible for modifying the body of a response
|
|
39
|
+
before it is sent back to the client.
|
|
37
40
|
"""
|
|
38
41
|
|
|
39
42
|
source: Optional[str]
|
|
40
43
|
"""A CEL syntax expression that contains the rule's conditions.
|
|
41
44
|
|
|
42
45
|
Allowed objects are: request, whois, session, response, tags,
|
|
43
|
-
`user_defined_tags`, `user_agent`, `client_data`.
|
|
46
|
+
`user_defined_tags`, `user_agent`, `client_data`.
|
|
47
|
+
|
|
48
|
+
More info can be found here:
|
|
44
49
|
https://gcore.com/docs/waap/waap-rules/advanced-rules
|
|
45
50
|
"""
|
|
46
51
|
|
|
47
52
|
|
|
48
53
|
class ActionBlock(TypedDict, total=False):
|
|
49
|
-
action_duration:
|
|
54
|
+
action_duration: str
|
|
50
55
|
"""How long a rule's block action will apply to subsequent requests.
|
|
51
56
|
|
|
52
57
|
Can be specified in seconds or by using a numeral followed by 's', 'm', 'h', or
|
|
@@ -54,8 +59,8 @@ class ActionBlock(TypedDict, total=False):
|
|
|
54
59
|
intervals are not allowed.
|
|
55
60
|
"""
|
|
56
61
|
|
|
57
|
-
status_code:
|
|
58
|
-
"""
|
|
62
|
+
status_code: Literal[403, 405, 418, 429]
|
|
63
|
+
"""A custom HTTP status code that the WAAP returns if a rule blocks a request"""
|
|
59
64
|
|
|
60
65
|
|
|
61
66
|
class ActionTag(TypedDict, total=False):
|
|
@@ -64,23 +69,23 @@ class ActionTag(TypedDict, total=False):
|
|
|
64
69
|
|
|
65
70
|
|
|
66
71
|
class Action(TypedDict, total=False):
|
|
67
|
-
allow:
|
|
72
|
+
allow: object
|
|
68
73
|
"""The WAAP allowed the request"""
|
|
69
74
|
|
|
70
|
-
block:
|
|
75
|
+
block: ActionBlock
|
|
71
76
|
"""
|
|
72
77
|
WAAP block action behavior could be configured with response status code and
|
|
73
78
|
action duration.
|
|
74
79
|
"""
|
|
75
80
|
|
|
76
|
-
captcha:
|
|
81
|
+
captcha: object
|
|
77
82
|
"""The WAAP presented the user with a captcha"""
|
|
78
83
|
|
|
79
|
-
handshake:
|
|
84
|
+
handshake: object
|
|
80
85
|
"""The WAAP performed automatic browser validation"""
|
|
81
86
|
|
|
82
|
-
monitor:
|
|
87
|
+
monitor: object
|
|
83
88
|
"""The WAAP monitored the request but took no action"""
|
|
84
89
|
|
|
85
|
-
tag:
|
|
90
|
+
tag: ActionTag
|
|
86
91
|
"""WAAP tag action gets a list of tags to tag the request scope with"""
|
|
@@ -23,10 +23,7 @@ class APIPathCreateParams(TypedDict, total=False):
|
|
|
23
23
|
"""
|
|
24
24
|
|
|
25
25
|
api_groups: SequenceNotStr[str]
|
|
26
|
-
"""An array of api groups associated with the API path"""
|
|
27
26
|
|
|
28
27
|
api_version: str
|
|
29
|
-
"""The API version"""
|
|
30
28
|
|
|
31
29
|
tags: SequenceNotStr[str]
|
|
32
|
-
"""An array of tags associated with the API path"""
|
|
@@ -14,7 +14,6 @@ class APIPathUpdateParams(TypedDict, total=False):
|
|
|
14
14
|
"""The domain ID"""
|
|
15
15
|
|
|
16
16
|
api_groups: SequenceNotStr[str]
|
|
17
|
-
"""An array of api groups associated with the API path"""
|
|
18
17
|
|
|
19
18
|
path: str
|
|
20
19
|
"""The updated API path.
|
|
@@ -24,7 +23,6 @@ class APIPathUpdateParams(TypedDict, total=False):
|
|
|
24
23
|
"""
|
|
25
24
|
|
|
26
25
|
status: Literal["CONFIRMED_API", "POTENTIAL_API", "NOT_API", "DELISTED_API"]
|
|
27
|
-
"""The
|
|
26
|
+
"""The different statuses an API path can have"""
|
|
28
27
|
|
|
29
28
|
tags: SequenceNotStr[str]
|
|
30
|
-
"""An array of tags associated with the API path"""
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
-
from typing import List, Iterable
|
|
5
|
+
from typing import List, Iterable
|
|
6
6
|
from typing_extensions import Literal, Required, TypedDict
|
|
7
7
|
|
|
8
8
|
from ...._types import SequenceNotStr
|
|
@@ -36,7 +36,10 @@ __all__ = [
|
|
|
36
36
|
|
|
37
37
|
class CustomRuleCreateParams(TypedDict, total=False):
|
|
38
38
|
action: Required[Action]
|
|
39
|
-
"""The action that the rule takes when triggered
|
|
39
|
+
"""The action that the rule takes when triggered.
|
|
40
|
+
|
|
41
|
+
Only one action can be set per rule.
|
|
42
|
+
"""
|
|
40
43
|
|
|
41
44
|
conditions: Required[Iterable[Condition]]
|
|
42
45
|
"""The conditions required for the WAAP engine to trigger the rule.
|
|
@@ -51,12 +54,12 @@ class CustomRuleCreateParams(TypedDict, total=False):
|
|
|
51
54
|
name: Required[str]
|
|
52
55
|
"""The name assigned to the rule"""
|
|
53
56
|
|
|
54
|
-
description:
|
|
57
|
+
description: str
|
|
55
58
|
"""The description assigned to the rule"""
|
|
56
59
|
|
|
57
60
|
|
|
58
61
|
class ActionBlock(TypedDict, total=False):
|
|
59
|
-
action_duration:
|
|
62
|
+
action_duration: str
|
|
60
63
|
"""How long a rule's block action will apply to subsequent requests.
|
|
61
64
|
|
|
62
65
|
Can be specified in seconds or by using a numeral followed by 's', 'm', 'h', or
|
|
@@ -64,8 +67,8 @@ class ActionBlock(TypedDict, total=False):
|
|
|
64
67
|
intervals are not allowed.
|
|
65
68
|
"""
|
|
66
69
|
|
|
67
|
-
status_code:
|
|
68
|
-
"""
|
|
70
|
+
status_code: Literal[403, 405, 418, 429]
|
|
71
|
+
"""A custom HTTP status code that the WAAP returns if a rule blocks a request"""
|
|
69
72
|
|
|
70
73
|
|
|
71
74
|
class ActionTag(TypedDict, total=False):
|
|
@@ -74,25 +77,25 @@ class ActionTag(TypedDict, total=False):
|
|
|
74
77
|
|
|
75
78
|
|
|
76
79
|
class Action(TypedDict, total=False):
|
|
77
|
-
allow:
|
|
80
|
+
allow: object
|
|
78
81
|
"""The WAAP allowed the request"""
|
|
79
82
|
|
|
80
|
-
block:
|
|
83
|
+
block: ActionBlock
|
|
81
84
|
"""
|
|
82
85
|
WAAP block action behavior could be configured with response status code and
|
|
83
86
|
action duration.
|
|
84
87
|
"""
|
|
85
88
|
|
|
86
|
-
captcha:
|
|
89
|
+
captcha: object
|
|
87
90
|
"""The WAAP presented the user with a captcha"""
|
|
88
91
|
|
|
89
|
-
handshake:
|
|
92
|
+
handshake: object
|
|
90
93
|
"""The WAAP performed automatic browser validation"""
|
|
91
94
|
|
|
92
|
-
monitor:
|
|
95
|
+
monitor: object
|
|
93
96
|
"""The WAAP monitored the request but took no action"""
|
|
94
97
|
|
|
95
|
-
tag:
|
|
98
|
+
tag: ActionTag
|
|
96
99
|
"""WAAP tag action gets a list of tags to tag the request scope with"""
|
|
97
100
|
|
|
98
101
|
|
|
@@ -218,15 +221,13 @@ class ConditionRequestRate(TypedDict, total=False):
|
|
|
218
221
|
triggering a request rate condition
|
|
219
222
|
"""
|
|
220
223
|
|
|
221
|
-
http_methods:
|
|
222
|
-
List[Literal["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"]]
|
|
223
|
-
]
|
|
224
|
+
http_methods: List[Literal["CONNECT", "DELETE", "GET", "HEAD", "OPTIONS", "PATCH", "POST", "PUT", "TRACE"]]
|
|
224
225
|
"""Possible HTTP request methods that can trigger a request rate condition"""
|
|
225
226
|
|
|
226
|
-
ips:
|
|
227
|
+
ips: SequenceNotStr[str]
|
|
227
228
|
"""A list of source IPs that can trigger a request rate condition"""
|
|
228
229
|
|
|
229
|
-
user_defined_tag:
|
|
230
|
+
user_defined_tag: str
|
|
230
231
|
"""
|
|
231
232
|
A user-defined tag that can be included in incoming requests and used to trigger
|
|
232
233
|
a request rate condition
|
|
@@ -310,62 +311,62 @@ class ConditionUserDefinedTags(TypedDict, total=False):
|
|
|
310
311
|
|
|
311
312
|
|
|
312
313
|
class Condition(TypedDict, total=False):
|
|
313
|
-
content_type:
|
|
314
|
+
content_type: ConditionContentType
|
|
314
315
|
"""Match the requested Content-Type"""
|
|
315
316
|
|
|
316
|
-
country:
|
|
317
|
+
country: ConditionCountry
|
|
317
318
|
"""Match the country that the request originated from"""
|
|
318
319
|
|
|
319
|
-
file_extension:
|
|
320
|
+
file_extension: ConditionFileExtension
|
|
320
321
|
"""Match the incoming file extension"""
|
|
321
322
|
|
|
322
|
-
header:
|
|
323
|
+
header: ConditionHeader
|
|
323
324
|
"""Match an incoming request header"""
|
|
324
325
|
|
|
325
|
-
header_exists:
|
|
326
|
+
header_exists: ConditionHeaderExists
|
|
326
327
|
"""Match when an incoming request header is present"""
|
|
327
328
|
|
|
328
|
-
http_method:
|
|
329
|
+
http_method: ConditionHTTPMethod
|
|
329
330
|
"""Match the incoming HTTP method"""
|
|
330
331
|
|
|
331
|
-
ip:
|
|
332
|
+
ip: ConditionIP
|
|
332
333
|
"""Match the incoming request against a single IP address"""
|
|
333
334
|
|
|
334
|
-
ip_range:
|
|
335
|
+
ip_range: ConditionIPRange
|
|
335
336
|
"""Match the incoming request against an IP range"""
|
|
336
337
|
|
|
337
|
-
organization:
|
|
338
|
+
organization: ConditionOrganization
|
|
338
339
|
"""
|
|
339
340
|
Match the organization the request originated from, as determined by a WHOIS
|
|
340
341
|
lookup of the requesting IP
|
|
341
342
|
"""
|
|
342
343
|
|
|
343
|
-
owner_types:
|
|
344
|
+
owner_types: ConditionOwnerTypes
|
|
344
345
|
"""
|
|
345
346
|
Match the type of organization that owns the IP address making an incoming
|
|
346
347
|
request
|
|
347
348
|
"""
|
|
348
349
|
|
|
349
|
-
request_rate:
|
|
350
|
+
request_rate: ConditionRequestRate
|
|
350
351
|
"""Match the rate at which requests come in that match certain conditions"""
|
|
351
352
|
|
|
352
|
-
response_header:
|
|
353
|
+
response_header: ConditionResponseHeader
|
|
353
354
|
"""Match a response header"""
|
|
354
355
|
|
|
355
|
-
response_header_exists:
|
|
356
|
+
response_header_exists: ConditionResponseHeaderExists
|
|
356
357
|
"""Match when a response header is present"""
|
|
357
358
|
|
|
358
|
-
session_request_count:
|
|
359
|
+
session_request_count: ConditionSessionRequestCount
|
|
359
360
|
"""Match the number of dynamic page requests made in a WAAP session"""
|
|
360
361
|
|
|
361
|
-
tags:
|
|
362
|
+
tags: ConditionTags
|
|
362
363
|
"""Matches requests based on specified tags"""
|
|
363
364
|
|
|
364
|
-
url:
|
|
365
|
+
url: ConditionURL
|
|
365
366
|
"""Match the incoming request URL"""
|
|
366
367
|
|
|
367
|
-
user_agent:
|
|
368
|
+
user_agent: ConditionUserAgent
|
|
368
369
|
"""Match the user agent making the request"""
|
|
369
370
|
|
|
370
|
-
user_defined_tags:
|
|
371
|
+
user_defined_tags: ConditionUserDefinedTags
|
|
371
372
|
"""Matches requests based on user-defined tags"""
|