fastly 17.2.0 → 18.0.0
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +45 -1
- data/Gemfile.lock +1 -1
- data/README.md +73 -2
- data/docs/AiRuntimeControlProviderConnectionsApi.md +210 -0
- data/docs/AiRuntimeControlProvidersApi.md +121 -0
- data/docs/AiRuntimeControlResponseBodyEnable.md +12 -0
- data/docs/AiRuntimeControlResponseCustomer.md +10 -0
- data/docs/AiRuntimeControlResponseLinks.md +10 -0
- data/docs/AiRuntimeControlResponseLinksLinks.md +10 -0
- data/docs/AiRuntimeControlResponseProduct.md +10 -0
- data/docs/AiRuntimeControlResponseProductProduct.md +11 -0
- data/docs/AiRuntimeControlSessionsApi.md +69 -0
- data/docs/AiRuntimeControlUsageMetricsApi.md +113 -0
- data/docs/AiRuntimeControlVirtualKeysApi.md +334 -0
- data/docs/ArcBedrockSetupResponse.md +11 -0
- data/docs/ArcCreateVirtualKeyResponse.md +19 -0
- data/docs/ArcError.md +12 -0
- data/docs/ArcFailoverTarget.md +10 -0
- data/docs/ArcGetProviderConnectionResponse.md +19 -0
- data/docs/ArcGetProviderConnectionResponseExtra.md +10 -0
- data/docs/ArcModel.md +12 -0
- data/docs/ArcModelsMeta.md +10 -0
- data/docs/ArcModelsResponse.md +11 -0
- data/docs/ArcProvider.md +13 -0
- data/docs/ArcProviderConnectionApiKey.md +14 -0
- data/docs/ArcProviderConnectionAwsIam.md +14 -0
- data/docs/ArcProviderConnectionListItemResponse.md +19 -0
- data/docs/ArcProviderConnectionListItemResponseExtra.md +10 -0
- data/docs/ArcProviderConnectionRequest.md +49 -0
- data/docs/ArcProviderConnectionResponse.md +18 -0
- data/docs/ArcProviderConnectionsMeta.md +11 -0
- data/docs/ArcProviderConnectionsResponse.md +11 -0
- data/docs/ArcProvidersMeta.md +10 -0
- data/docs/ArcProvidersResponse.md +11 -0
- data/docs/ArcRotateVirtualKeyRequest.md +10 -0
- data/docs/ArcRotateVirtualKeyResponse.md +17 -0
- data/docs/ArcSession.md +28 -0
- data/docs/ArcSessionLogEntry.md +12 -0
- data/docs/ArcSessionsMeta.md +14 -0
- data/docs/ArcSessionsResponse.md +11 -0
- data/docs/ArcUpdateProviderConnectionRequest.md +14 -0
- data/docs/ArcUpdateVirtualKeyRequest.md +16 -0
- data/docs/ArcUpdateVirtualKeyResponse.md +20 -0
- data/docs/ArcUsageMetric.md +18 -0
- data/docs/ArcUsageMetricsMeta.md +11 -0
- data/docs/ArcUsageMetricsResponse.md +11 -0
- data/docs/ArcVirtualKey.md +15 -0
- data/docs/ArcVirtualKeyFailoverRequest.md +13 -0
- data/docs/ArcVirtualKeyFailoverResponse.md +13 -0
- data/docs/ArcVirtualKeyListItemResponse.md +26 -0
- data/docs/ArcVirtualKeyListItemResponseExtra.md +20 -0
- data/docs/ArcVirtualKeyResponse.md +25 -0
- data/docs/ArcVirtualKeyResponseExtra.md +19 -0
- data/docs/ArcVirtualKeysMeta.md +14 -0
- data/docs/ArcVirtualKeysResponse.md +11 -0
- data/docs/AutomationToken.md +6 -2
- data/docs/AutomationTokenCreateRequest.md +10 -1
- data/docs/AutomationTokenCreateResponse.md +6 -2
- data/docs/AutomationTokenResponse.md +5 -1
- data/docs/AutomationTokenRole.md +11 -0
- data/docs/AutomationTokenUnversionedError.md +11 -0
- data/docs/AutomationTokenUnversionedErrorResponse.md +10 -0
- data/docs/AutomationTokenWorkspace.md +11 -0
- data/docs/AutomationTokenWorkspacesMeta.md +12 -0
- data/docs/AutomationTokenWorkspacesResponse.md +12 -0
- data/docs/AutomationTokensApi.md +43 -1
- data/docs/BotManagementAction.md +10 -0
- data/docs/BotManagementApi.md +433 -0
- data/docs/BotManagementBot.md +10 -0
- data/docs/BotManagementBotAction.md +10 -0
- data/docs/BotManagementBotResponse.md +12 -0
- data/docs/BotManagementBotResponseExtra.md +11 -0
- data/docs/BotManagementBotsResponse.md +11 -0
- data/docs/BotManagementCategoriesResponse.md +11 -0
- data/docs/BotManagementCategory.md +10 -0
- data/docs/BotManagementCategoryResponse.md +13 -0
- data/docs/BotManagementCategoryResponseExtra.md +12 -0
- data/docs/BotManagementError.md +12 -0
- data/docs/BotManagementInvalidRequestError.md +12 -0
- data/docs/BotManagementInvalidRequestErrorExtra.md +12 -0
- data/docs/BotManagementMeta.md +12 -0
- data/docs/BotManagementNotAllowedError.md +12 -0
- data/docs/BotManagementNotAllowedErrorExtra.md +11 -0
- data/docs/BotManagementNotAuthenticatedError.md +12 -0
- data/docs/BotManagementNotAuthenticatedErrorExtra.md +11 -0
- data/docs/BotManagementNotFoundError.md +12 -0
- data/docs/BotManagementNotFoundErrorExtra.md +11 -0
- data/docs/BotManagementProtectionMode.md +9 -0
- data/docs/BotManagementRateLimitError.md +12 -0
- data/docs/BotManagementRateLimitErrorExtra.md +11 -0
- data/docs/BotManagementWorkspace.md +12 -0
- data/docs/BotManagementWorkspaceBotResponse.md +13 -0
- data/docs/BotManagementWorkspaceBotResponseExtra.md +10 -0
- data/docs/BotManagementWorkspaceBotsResponse.md +11 -0
- data/docs/BotManagementWorkspaceResponse.md +16 -0
- data/docs/BotManagementWorkspaceResponseExtra.md +13 -0
- data/docs/BotManagementWorkspacesResponse.md +11 -0
- data/docs/BotRequestMetricsDataItem.md +16 -0
- data/docs/BotRequestMetricsMetadata.md +14 -0
- data/docs/BotRequestMetricsResponse.md +11 -0
- data/docs/BotRequestsMetricsApi.md +77 -0
- data/docs/BulkUpdateDictionaryItem.md +1 -1
- data/docs/DdosProtectionRule.md +1 -1
- data/docs/DdosProtectionRuleAllOf.md +1 -1
- data/docs/DdosProtectionRulePatch.md +1 -1
- data/docs/DdosProtectionRuleWithStats.md +1 -1
- data/docs/DictionaryItem.md +1 -1
- data/docs/DictionaryItemApi.md +14 -14
- data/docs/DictionaryItemResponse.md +1 -1
- data/docs/MetricsPlatformApi.md +69 -13
- data/docs/NetworkProtectApi.md +789 -0
- data/docs/NetworkProtectConflict.md +13 -0
- data/docs/NetworkProtectConflictError.md +11 -0
- data/docs/NetworkProtectEndpoint.md +11 -0
- data/docs/NetworkProtectEndpointCreate.md +11 -0
- data/docs/NetworkProtectEndpointPolicy.md +11 -0
- data/docs/NetworkProtectEndpointResponse.md +14 -0
- data/docs/NetworkProtectEndpointResponseFields.md +12 -0
- data/docs/NetworkProtectEndpointUpdate.md +10 -0
- data/docs/NetworkProtectEndpointsResponse.md +11 -0
- data/docs/NetworkProtectErrorDetail.md +11 -0
- data/docs/NetworkProtectInvalidRequest.md +13 -0
- data/docs/NetworkProtectListMeta.md +11 -0
- data/docs/NetworkProtectLoaStatus.md +9 -0
- data/docs/NetworkProtectNetwork.md +15 -0
- data/docs/NetworkProtectNetworkCreate.md +14 -0
- data/docs/NetworkProtectNetworkResponse.md +22 -0
- data/docs/NetworkProtectNetworkResponseFields.md +16 -0
- data/docs/NetworkProtectNetworkUpdate.md +14 -0
- data/docs/NetworkProtectNetworksResponse.md +11 -0
- data/docs/NetworkProtectPolicyEndpoint.md +13 -0
- data/docs/NetworkProtectPrefixList.md +12 -0
- data/docs/NetworkProtectPrefixListCreate.md +12 -0
- data/docs/NetworkProtectPrefixListFamily.md +9 -0
- data/docs/NetworkProtectPrefixListResponse.md +15 -0
- data/docs/NetworkProtectPrefixListResponseFields.md +12 -0
- data/docs/NetworkProtectPrefixListUpdate.md +11 -0
- data/docs/NetworkProtectPrefixListsResponse.md +11 -0
- data/docs/NetworkProtectRegion.md +9 -0
- data/docs/NetworkProtectRoaStatus.md +9 -0
- data/docs/NetworkProtectRule.md +16 -0
- data/docs/NetworkProtectRuleAction.md +9 -0
- data/docs/NetworkProtectRuleDestinationPorts.md +9 -0
- data/docs/NetworkProtectRuleIpProtocol.md +9 -0
- data/docs/NetworkProtectRuleMatchDestinationIp.md +10 -0
- data/docs/NetworkProtectRuleMatchDestinationPorts.md +10 -0
- data/docs/NetworkProtectRuleMatchIpProtocol.md +10 -0
- data/docs/NetworkProtectRuleMatchSourcePorts.md +10 -0
- data/docs/NetworkProtectRuleMatchSourcePrefixList.md +10 -0
- data/docs/NetworkProtectRuleResponse.md +16 -0
- data/docs/NetworkProtectRuleSet.md +11 -0
- data/docs/NetworkProtectRuleSetCreate.md +11 -0
- data/docs/NetworkProtectRuleSetDefaultAction.md +9 -0
- data/docs/NetworkProtectRuleSetResponse.md +14 -0
- data/docs/NetworkProtectRuleSetResponseFields.md +12 -0
- data/docs/NetworkProtectRuleSetUpdate.md +11 -0
- data/docs/NetworkProtectRuleSetsResponse.md +11 -0
- data/docs/NetworkProtectRuleSourcePorts.md +9 -0
- data/docs/NetworkProtectRuleTimestamps.md +11 -0
- data/docs/PlatformValues.md +359 -16
- data/docs/ProductAiRuntimeControlApi.md +115 -0
- data/docs/PurgeApi.md +6 -0
- data/docs/RealtimeEntryAggregated.md +16 -0
- data/docs/RealtimeEntryDatacenter.md +16 -0
- data/docs/RealtimeMeasurements.md +16 -0
- data/docs/Results.md +16 -0
- data/lib/fastly/api/ai_runtime_control_provider_connections_api.rb +355 -0
- data/lib/fastly/api/ai_runtime_control_providers_api.rb +195 -0
- data/lib/fastly/api/ai_runtime_control_sessions_api.rb +112 -0
- data/lib/fastly/api/ai_runtime_control_usage_metrics_api.rb +176 -0
- data/lib/fastly/api/ai_runtime_control_virtual_keys_api.rb +580 -0
- data/lib/fastly/api/automation_tokens_api.rb +78 -1
- data/lib/fastly/api/bot_management_api.rb +787 -0
- data/lib/fastly/api/bot_requests_metrics_api.rb +137 -0
- data/lib/fastly/api/dictionary_item_api.rb +14 -14
- data/lib/fastly/api/metrics_platform_api.rb +130 -23
- data/lib/fastly/api/network_protect_api.rb +1420 -0
- data/lib/fastly/api/product_ai_runtime_control_api.rb +186 -0
- data/lib/fastly/api/purge_api.rb +21 -0
- data/lib/fastly/configuration.rb +331 -1
- data/lib/fastly/models/ai_runtime_control_response_body_enable.rb +243 -0
- data/lib/fastly/models/ai_runtime_control_response_customer.rb +216 -0
- data/lib/fastly/models/ai_runtime_control_response_links.rb +216 -0
- data/lib/fastly/models/ai_runtime_control_response_links_links.rb +217 -0
- data/lib/fastly/models/ai_runtime_control_response_product.rb +216 -0
- data/lib/fastly/models/ai_runtime_control_response_product_product.rb +227 -0
- data/lib/fastly/models/arc_bedrock_setup_response.rb +237 -0
- data/lib/fastly/models/arc_create_virtual_key_response.rb +346 -0
- data/lib/fastly/models/arc_error.rb +238 -0
- data/lib/fastly/models/arc_failover_target.rb +223 -0
- data/lib/fastly/models/arc_get_provider_connection_response.rb +393 -0
- data/lib/fastly/models/arc_get_provider_connection_response_extra.rb +224 -0
- data/lib/fastly/models/arc_model.rb +253 -0
- data/lib/fastly/models/arc_models_meta.rb +217 -0
- data/lib/fastly/models/arc_models_response.rb +238 -0
- data/lib/fastly/models/arc_provider.rb +270 -0
- data/lib/fastly/models/arc_provider_connection_api_key.rb +335 -0
- data/lib/fastly/models/arc_provider_connection_aws_iam.rb +350 -0
- data/lib/fastly/models/arc_provider_connection_list_item_response.rb +386 -0
- data/lib/fastly/models/arc_provider_connection_list_item_response_extra.rb +217 -0
- data/lib/fastly/models/arc_provider_connection_request.rb +103 -0
- data/lib/fastly/models/arc_provider_connection_response.rb +369 -0
- data/lib/fastly/models/arc_provider_connections_meta.rb +228 -0
- data/lib/fastly/models/arc_provider_connections_response.rb +238 -0
- data/lib/fastly/models/arc_providers_meta.rb +217 -0
- data/lib/fastly/models/arc_providers_response.rb +238 -0
- data/lib/fastly/models/arc_rotate_virtual_key_request.rb +218 -0
- data/lib/fastly/models/arc_rotate_virtual_key_response.rb +324 -0
- data/lib/fastly/models/arc_session.rb +465 -0
- data/lib/fastly/models/arc_session_log_entry.rb +240 -0
- data/lib/fastly/models/arc_sessions_meta.rb +260 -0
- data/lib/fastly/models/arc_sessions_response.rb +238 -0
- data/lib/fastly/models/arc_update_provider_connection_request.rb +275 -0
- data/lib/fastly/models/arc_update_virtual_key_request.rb +345 -0
- data/lib/fastly/models/arc_update_virtual_key_response.rb +352 -0
- data/lib/fastly/models/arc_usage_metric.rb +347 -0
- data/lib/fastly/models/arc_usage_metrics_meta.rb +228 -0
- data/lib/fastly/models/arc_usage_metrics_response.rb +238 -0
- data/lib/fastly/models/arc_virtual_key.rb +342 -0
- data/lib/fastly/models/arc_virtual_key_failover_request.rb +255 -0
- data/lib/fastly/models/arc_virtual_key_failover_response.rb +270 -0
- data/lib/fastly/models/arc_virtual_key_list_item_response.rb +492 -0
- data/lib/fastly/models/arc_virtual_key_list_item_response_extra.rb +350 -0
- data/lib/fastly/models/arc_virtual_key_response.rb +477 -0
- data/lib/fastly/models/arc_virtual_key_response_extra.rb +335 -0
- data/lib/fastly/models/arc_virtual_keys_meta.rb +260 -0
- data/lib/fastly/models/arc_virtual_keys_response.rb +238 -0
- data/lib/fastly/models/automation_token.rb +49 -5
- data/lib/fastly/models/automation_token_create_request.rb +161 -7
- data/lib/fastly/models/automation_token_create_response.rb +49 -5
- data/lib/fastly/models/automation_token_error_response.rb +1 -0
- data/lib/fastly/models/automation_token_response.rb +46 -2
- data/lib/fastly/models/automation_token_role.rb +227 -0
- data/lib/fastly/models/automation_token_unversioned_error.rb +225 -0
- data/lib/fastly/models/automation_token_unversioned_error_response.rb +219 -0
- data/lib/fastly/models/automation_token_workspace.rb +237 -0
- data/lib/fastly/models/automation_token_workspaces_meta.rb +242 -0
- data/lib/fastly/models/automation_token_workspaces_response.rb +253 -0
- data/lib/fastly/models/bot_management_action.rb +257 -0
- data/lib/fastly/models/bot_management_bot.rb +222 -0
- data/lib/fastly/models/bot_management_bot_action.rb +257 -0
- data/lib/fastly/models/bot_management_bot_response.rb +259 -0
- data/lib/fastly/models/bot_management_bot_response_extra.rb +237 -0
- data/lib/fastly/models/bot_management_bots_response.rb +238 -0
- data/lib/fastly/models/bot_management_categories_response.rb +238 -0
- data/lib/fastly/models/bot_management_category.rb +222 -0
- data/lib/fastly/models/bot_management_category_response.rb +269 -0
- data/lib/fastly/models/bot_management_category_response_extra.rb +247 -0
- data/lib/fastly/models/bot_management_error.rb +248 -0
- data/lib/fastly/models/bot_management_invalid_request_error.rb +291 -0
- data/lib/fastly/models/bot_management_invalid_request_error_extra.rb +283 -0
- data/lib/fastly/models/bot_management_meta.rb +239 -0
- data/lib/fastly/models/bot_management_not_allowed_error.rb +287 -0
- data/lib/fastly/models/bot_management_not_allowed_error_extra.rb +259 -0
- data/lib/fastly/models/bot_management_not_authenticated_error.rb +287 -0
- data/lib/fastly/models/bot_management_not_authenticated_error_extra.rb +259 -0
- data/lib/fastly/models/bot_management_not_found_error.rb +287 -0
- data/lib/fastly/models/bot_management_not_found_error_extra.rb +259 -0
- data/lib/fastly/models/bot_management_protection_mode.rb +36 -0
- data/lib/fastly/models/bot_management_rate_limit_error.rb +287 -0
- data/lib/fastly/models/bot_management_rate_limit_error_extra.rb +259 -0
- data/lib/fastly/models/bot_management_workspace.rb +276 -0
- data/lib/fastly/models/bot_management_workspace_bot_response.rb +275 -0
- data/lib/fastly/models/bot_management_workspace_bot_response_extra.rb +222 -0
- data/lib/fastly/models/bot_management_workspace_bots_response.rb +238 -0
- data/lib/fastly/models/bot_management_workspace_response.rb +354 -0
- data/lib/fastly/models/bot_management_workspace_response_extra.rb +264 -0
- data/lib/fastly/models/bot_management_workspaces_response.rb +238 -0
- data/lib/fastly/models/bot_request_metrics_data_item.rb +278 -0
- data/lib/fastly/models/bot_request_metrics_metadata.rb +258 -0
- data/lib/fastly/models/bot_request_metrics_response.rb +228 -0
- data/lib/fastly/models/bulk_update_dictionary_item.rb +1 -1
- data/lib/fastly/models/ddos_protection_request_enable_mode.rb +2 -2
- data/lib/fastly/models/ddos_protection_request_update_configuration.rb +2 -2
- data/lib/fastly/models/ddos_protection_rule.rb +1 -1
- data/lib/fastly/models/ddos_protection_rule_all_of.rb +1 -1
- data/lib/fastly/models/ddos_protection_rule_patch.rb +1 -1
- data/lib/fastly/models/ddos_protection_rule_with_stats.rb +1 -1
- data/lib/fastly/models/dictionary_item.rb +1 -1
- data/lib/fastly/models/dictionary_item_response.rb +1 -1
- data/lib/fastly/models/event_attributes.rb +2 -2
- data/lib/fastly/models/network_protect_conflict.rb +299 -0
- data/lib/fastly/models/network_protect_conflict_error.rb +228 -0
- data/lib/fastly/models/network_protect_endpoint.rb +266 -0
- data/lib/fastly/models/network_protect_endpoint_create.rb +266 -0
- data/lib/fastly/models/network_protect_endpoint_policy.rb +255 -0
- data/lib/fastly/models/network_protect_endpoint_response.rb +340 -0
- data/lib/fastly/models/network_protect_endpoint_response_fields.rb +274 -0
- data/lib/fastly/models/network_protect_endpoint_update.rb +251 -0
- data/lib/fastly/models/network_protect_endpoints_response.rb +239 -0
- data/lib/fastly/models/network_protect_error_detail.rb +238 -0
- data/lib/fastly/models/{automation_token_create_request_attributes.rb → network_protect_invalid_request.rb} +63 -75
- data/lib/fastly/models/network_protect_list_meta.rb +263 -0
- data/lib/fastly/models/network_protect_loa_status.rb +36 -0
- data/lib/fastly/models/network_protect_network.rb +363 -0
- data/lib/fastly/models/network_protect_network_create.rb +340 -0
- data/lib/fastly/models/network_protect_network_response.rb +477 -0
- data/lib/fastly/models/network_protect_network_response_fields.rb +314 -0
- data/lib/fastly/models/network_protect_network_update.rb +329 -0
- data/lib/fastly/models/network_protect_networks_response.rb +239 -0
- data/lib/fastly/models/network_protect_policy_endpoint.rb +307 -0
- data/lib/fastly/models/network_protect_prefix_list.rb +282 -0
- data/lib/fastly/models/network_protect_prefix_list_create.rb +301 -0
- data/lib/fastly/models/network_protect_prefix_list_family.rb +35 -0
- data/lib/fastly/models/network_protect_prefix_list_response.rb +356 -0
- data/lib/fastly/models/network_protect_prefix_list_response_fields.rb +274 -0
- data/lib/fastly/models/network_protect_prefix_list_update.rb +269 -0
- data/lib/fastly/models/network_protect_prefix_lists_response.rb +239 -0
- data/lib/fastly/models/network_protect_region.rb +34 -0
- data/lib/fastly/models/network_protect_roa_status.rb +37 -0
- data/lib/fastly/models/network_protect_rule.rb +372 -0
- data/lib/fastly/models/network_protect_rule_action.rb +35 -0
- data/lib/fastly/models/network_protect_rule_destination_ports.rb +208 -0
- data/lib/fastly/models/network_protect_rule_ip_protocol.rb +37 -0
- data/lib/fastly/models/network_protect_rule_match_destination_ip.rb +223 -0
- data/lib/fastly/models/network_protect_rule_match_destination_ports.rb +222 -0
- data/lib/fastly/models/network_protect_rule_match_ip_protocol.rb +222 -0
- data/lib/fastly/models/network_protect_rule_match_source_ports.rb +222 -0
- data/lib/fastly/models/network_protect_rule_match_source_prefix_list.rb +244 -0
- data/lib/fastly/models/network_protect_rule_response.rb +329 -0
- data/lib/fastly/models/network_protect_rule_set.rb +258 -0
- data/lib/fastly/models/network_protect_rule_set_create.rb +249 -0
- data/lib/fastly/models/network_protect_rule_set_default_action.rb +35 -0
- data/lib/fastly/models/network_protect_rule_set_response.rb +332 -0
- data/lib/fastly/models/network_protect_rule_set_response_fields.rb +274 -0
- data/lib/fastly/models/network_protect_rule_set_update.rb +244 -0
- data/lib/fastly/models/network_protect_rule_sets_response.rb +239 -0
- data/lib/fastly/models/network_protect_rule_source_ports.rb +208 -0
- data/lib/fastly/models/network_protect_rule_timestamps.rb +228 -0
- data/lib/fastly/models/platform_values.rb +3568 -137
- data/lib/fastly/models/realtime_entry_aggregated.rb +164 -4
- data/lib/fastly/models/realtime_entry_datacenter.rb +164 -4
- data/lib/fastly/models/realtime_measurements.rb +164 -4
- data/lib/fastly/models/results.rb +161 -1
- data/lib/fastly/version.rb +1 -1
- data/lib/fastly.rb +143 -1
- data/sig.json +1 -1
- metadata +288 -4
- data/docs/AutomationTokenCreateRequestAttributes.md +0 -15
|
@@ -0,0 +1,1420 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Fastly API
|
|
3
|
+
|
|
4
|
+
#Via the Fastly API you can perform any of the operations that are possible within the management console, including creating services, domains, and backends, configuring rules or uploading your own application code, as well as account operations such as user administration and billing reports. The API is organized into collections of endpoints that allow manipulation of objects related to Fastly services and accounts. For the most accurate and up-to-date API reference content, visit our [Developer Hub](https://www.fastly.com/documentation/reference/api/)
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
Contact: oss@fastly.com
|
|
8
|
+
|
|
9
|
+
=end
|
|
10
|
+
|
|
11
|
+
require 'cgi'
|
|
12
|
+
|
|
13
|
+
module Fastly
|
|
14
|
+
class NetworkProtectApi
|
|
15
|
+
attr_accessor :api_client
|
|
16
|
+
|
|
17
|
+
def initialize(api_client = ApiClient.default)
|
|
18
|
+
@api_client = api_client
|
|
19
|
+
end
|
|
20
|
+
# Create a Network Protect endpoint
|
|
21
|
+
# Creates a GRE delivery destination. A new endpoint is not attached to a network until it is added to an endpoint policy.
|
|
22
|
+
# @option opts [NetworkProtectEndpointCreate] :network_protect_endpoint_create (required)
|
|
23
|
+
# @return [NetworkProtectEndpointResponse]
|
|
24
|
+
def create_network_protect_endpoint(opts = {})
|
|
25
|
+
data, _status_code, _headers = create_network_protect_endpoint_with_http_info(opts)
|
|
26
|
+
data
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
# Create a Network Protect endpoint
|
|
30
|
+
# Creates a GRE delivery destination. A new endpoint is not attached to a network until it is added to an endpoint policy.
|
|
31
|
+
# @option opts [NetworkProtectEndpointCreate] :network_protect_endpoint_create (required)
|
|
32
|
+
# @return [Array<(NetworkProtectEndpointResponse, Integer, Hash)>] NetworkProtectEndpointResponse data, response status code and response headers
|
|
33
|
+
def create_network_protect_endpoint_with_http_info(opts = {})
|
|
34
|
+
if @api_client.config.debugging
|
|
35
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.create_network_protect_endpoint ...'
|
|
36
|
+
end
|
|
37
|
+
# unbox the parameters from the hash
|
|
38
|
+
network_protect_endpoint_create = opts[:'network_protect_endpoint_create']
|
|
39
|
+
# verify the required parameter 'network_protect_endpoint_create' is set
|
|
40
|
+
if @api_client.config.client_side_validation && network_protect_endpoint_create.nil?
|
|
41
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_endpoint_create' when calling NetworkProtectApi.create_network_protect_endpoint"
|
|
42
|
+
end
|
|
43
|
+
# resource path
|
|
44
|
+
local_var_path = '/network-protect/v1/endpoints'
|
|
45
|
+
|
|
46
|
+
# query parameters
|
|
47
|
+
query_params = opts[:query_params] || {}
|
|
48
|
+
|
|
49
|
+
# header parameters
|
|
50
|
+
header_params = opts[:header_params] || {}
|
|
51
|
+
# HTTP header 'Accept' (if needed)
|
|
52
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
53
|
+
# HTTP header 'Content-Type'
|
|
54
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
55
|
+
if !content_type.nil?
|
|
56
|
+
header_params['Content-Type'] = content_type
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
# form parameters
|
|
60
|
+
form_params = opts[:form_params] || {}
|
|
61
|
+
|
|
62
|
+
# http body (model)
|
|
63
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_endpoint_create)
|
|
64
|
+
|
|
65
|
+
# return_type
|
|
66
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectEndpointResponse'
|
|
67
|
+
|
|
68
|
+
# auth_names
|
|
69
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
70
|
+
|
|
71
|
+
new_options = opts.merge(
|
|
72
|
+
:operation => :"NetworkProtectApi.create_network_protect_endpoint",
|
|
73
|
+
:header_params => header_params,
|
|
74
|
+
:query_params => query_params,
|
|
75
|
+
:form_params => form_params,
|
|
76
|
+
:body => post_body,
|
|
77
|
+
:auth_names => auth_names,
|
|
78
|
+
:return_type => return_type
|
|
79
|
+
)
|
|
80
|
+
|
|
81
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
82
|
+
if @api_client.config.debugging
|
|
83
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#create_network_protect_endpoint\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
84
|
+
end
|
|
85
|
+
return data, status_code, headers
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
# Create a Network Protect network
|
|
89
|
+
# Registers customer-owned IP space for protection. The network starts with advertisement disabled and Fastly does not announce its prefix. Turn advertisement on after LOA and ROA authorization are ready. The create request cannot include advertise; sending it returns a `400 Bad Request` error.
|
|
90
|
+
# @option opts [NetworkProtectNetworkCreate] :network_protect_network_create (required)
|
|
91
|
+
# @return [NetworkProtectNetworkResponse]
|
|
92
|
+
def create_network_protect_network(opts = {})
|
|
93
|
+
data, _status_code, _headers = create_network_protect_network_with_http_info(opts)
|
|
94
|
+
data
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
# Create a Network Protect network
|
|
98
|
+
# Registers customer-owned IP space for protection. The network starts with advertisement disabled and Fastly does not announce its prefix. Turn advertisement on after LOA and ROA authorization are ready. The create request cannot include advertise; sending it returns a `400 Bad Request` error.
|
|
99
|
+
# @option opts [NetworkProtectNetworkCreate] :network_protect_network_create (required)
|
|
100
|
+
# @return [Array<(NetworkProtectNetworkResponse, Integer, Hash)>] NetworkProtectNetworkResponse data, response status code and response headers
|
|
101
|
+
def create_network_protect_network_with_http_info(opts = {})
|
|
102
|
+
if @api_client.config.debugging
|
|
103
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.create_network_protect_network ...'
|
|
104
|
+
end
|
|
105
|
+
# unbox the parameters from the hash
|
|
106
|
+
network_protect_network_create = opts[:'network_protect_network_create']
|
|
107
|
+
# verify the required parameter 'network_protect_network_create' is set
|
|
108
|
+
if @api_client.config.client_side_validation && network_protect_network_create.nil?
|
|
109
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_network_create' when calling NetworkProtectApi.create_network_protect_network"
|
|
110
|
+
end
|
|
111
|
+
# resource path
|
|
112
|
+
local_var_path = '/network-protect/v1/networks'
|
|
113
|
+
|
|
114
|
+
# query parameters
|
|
115
|
+
query_params = opts[:query_params] || {}
|
|
116
|
+
|
|
117
|
+
# header parameters
|
|
118
|
+
header_params = opts[:header_params] || {}
|
|
119
|
+
# HTTP header 'Accept' (if needed)
|
|
120
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
121
|
+
# HTTP header 'Content-Type'
|
|
122
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
123
|
+
if !content_type.nil?
|
|
124
|
+
header_params['Content-Type'] = content_type
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
# form parameters
|
|
128
|
+
form_params = opts[:form_params] || {}
|
|
129
|
+
|
|
130
|
+
# http body (model)
|
|
131
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_network_create)
|
|
132
|
+
|
|
133
|
+
# return_type
|
|
134
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectNetworkResponse'
|
|
135
|
+
|
|
136
|
+
# auth_names
|
|
137
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
138
|
+
|
|
139
|
+
new_options = opts.merge(
|
|
140
|
+
:operation => :"NetworkProtectApi.create_network_protect_network",
|
|
141
|
+
:header_params => header_params,
|
|
142
|
+
:query_params => query_params,
|
|
143
|
+
:form_params => form_params,
|
|
144
|
+
:body => post_body,
|
|
145
|
+
:auth_names => auth_names,
|
|
146
|
+
:return_type => return_type
|
|
147
|
+
)
|
|
148
|
+
|
|
149
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
150
|
+
if @api_client.config.debugging
|
|
151
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#create_network_protect_network\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
152
|
+
end
|
|
153
|
+
return data, status_code, headers
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
# Create a Network Protect prefix list
|
|
157
|
+
# Creates a typed list of addresses that rules can reference. The family is required and cannot be changed. The addresses list may remain empty.
|
|
158
|
+
# @option opts [NetworkProtectPrefixListCreate] :network_protect_prefix_list_create (required)
|
|
159
|
+
# @return [NetworkProtectPrefixListResponse]
|
|
160
|
+
def create_network_protect_prefix_list(opts = {})
|
|
161
|
+
data, _status_code, _headers = create_network_protect_prefix_list_with_http_info(opts)
|
|
162
|
+
data
|
|
163
|
+
end
|
|
164
|
+
|
|
165
|
+
# Create a Network Protect prefix list
|
|
166
|
+
# Creates a typed list of addresses that rules can reference. The family is required and cannot be changed. The addresses list may remain empty.
|
|
167
|
+
# @option opts [NetworkProtectPrefixListCreate] :network_protect_prefix_list_create (required)
|
|
168
|
+
# @return [Array<(NetworkProtectPrefixListResponse, Integer, Hash)>] NetworkProtectPrefixListResponse data, response status code and response headers
|
|
169
|
+
def create_network_protect_prefix_list_with_http_info(opts = {})
|
|
170
|
+
if @api_client.config.debugging
|
|
171
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.create_network_protect_prefix_list ...'
|
|
172
|
+
end
|
|
173
|
+
# unbox the parameters from the hash
|
|
174
|
+
network_protect_prefix_list_create = opts[:'network_protect_prefix_list_create']
|
|
175
|
+
# verify the required parameter 'network_protect_prefix_list_create' is set
|
|
176
|
+
if @api_client.config.client_side_validation && network_protect_prefix_list_create.nil?
|
|
177
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_prefix_list_create' when calling NetworkProtectApi.create_network_protect_prefix_list"
|
|
178
|
+
end
|
|
179
|
+
# resource path
|
|
180
|
+
local_var_path = '/network-protect/v1/prefix-lists'
|
|
181
|
+
|
|
182
|
+
# query parameters
|
|
183
|
+
query_params = opts[:query_params] || {}
|
|
184
|
+
|
|
185
|
+
# header parameters
|
|
186
|
+
header_params = opts[:header_params] || {}
|
|
187
|
+
# HTTP header 'Accept' (if needed)
|
|
188
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
189
|
+
# HTTP header 'Content-Type'
|
|
190
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
191
|
+
if !content_type.nil?
|
|
192
|
+
header_params['Content-Type'] = content_type
|
|
193
|
+
end
|
|
194
|
+
|
|
195
|
+
# form parameters
|
|
196
|
+
form_params = opts[:form_params] || {}
|
|
197
|
+
|
|
198
|
+
# http body (model)
|
|
199
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_prefix_list_create)
|
|
200
|
+
|
|
201
|
+
# return_type
|
|
202
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectPrefixListResponse'
|
|
203
|
+
|
|
204
|
+
# auth_names
|
|
205
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
206
|
+
|
|
207
|
+
new_options = opts.merge(
|
|
208
|
+
:operation => :"NetworkProtectApi.create_network_protect_prefix_list",
|
|
209
|
+
:header_params => header_params,
|
|
210
|
+
:query_params => query_params,
|
|
211
|
+
:form_params => form_params,
|
|
212
|
+
:body => post_body,
|
|
213
|
+
:auth_names => auth_names,
|
|
214
|
+
:return_type => return_type
|
|
215
|
+
)
|
|
216
|
+
|
|
217
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
218
|
+
if @api_client.config.debugging
|
|
219
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#create_network_protect_prefix_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
220
|
+
end
|
|
221
|
+
return data, status_code, headers
|
|
222
|
+
end
|
|
223
|
+
|
|
224
|
+
# Create a Network Protect rule set
|
|
225
|
+
# Creates an ordered rule set and stores its filtering intent. A rule set has at most 64 rules and uses the default action when no rule matches. Custom attachment and detachment are restricted in this release.
|
|
226
|
+
# @option opts [NetworkProtectRuleSetCreate] :network_protect_rule_set_create (required)
|
|
227
|
+
# @return [NetworkProtectRuleSetResponse]
|
|
228
|
+
def create_network_protect_rule_set(opts = {})
|
|
229
|
+
data, _status_code, _headers = create_network_protect_rule_set_with_http_info(opts)
|
|
230
|
+
data
|
|
231
|
+
end
|
|
232
|
+
|
|
233
|
+
# Create a Network Protect rule set
|
|
234
|
+
# Creates an ordered rule set and stores its filtering intent. A rule set has at most 64 rules and uses the default action when no rule matches. Custom attachment and detachment are restricted in this release.
|
|
235
|
+
# @option opts [NetworkProtectRuleSetCreate] :network_protect_rule_set_create (required)
|
|
236
|
+
# @return [Array<(NetworkProtectRuleSetResponse, Integer, Hash)>] NetworkProtectRuleSetResponse data, response status code and response headers
|
|
237
|
+
def create_network_protect_rule_set_with_http_info(opts = {})
|
|
238
|
+
if @api_client.config.debugging
|
|
239
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.create_network_protect_rule_set ...'
|
|
240
|
+
end
|
|
241
|
+
# unbox the parameters from the hash
|
|
242
|
+
network_protect_rule_set_create = opts[:'network_protect_rule_set_create']
|
|
243
|
+
# verify the required parameter 'network_protect_rule_set_create' is set
|
|
244
|
+
if @api_client.config.client_side_validation && network_protect_rule_set_create.nil?
|
|
245
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_rule_set_create' when calling NetworkProtectApi.create_network_protect_rule_set"
|
|
246
|
+
end
|
|
247
|
+
# resource path
|
|
248
|
+
local_var_path = '/network-protect/v1/rule-sets'
|
|
249
|
+
|
|
250
|
+
# query parameters
|
|
251
|
+
query_params = opts[:query_params] || {}
|
|
252
|
+
|
|
253
|
+
# header parameters
|
|
254
|
+
header_params = opts[:header_params] || {}
|
|
255
|
+
# HTTP header 'Accept' (if needed)
|
|
256
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
257
|
+
# HTTP header 'Content-Type'
|
|
258
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
259
|
+
if !content_type.nil?
|
|
260
|
+
header_params['Content-Type'] = content_type
|
|
261
|
+
end
|
|
262
|
+
|
|
263
|
+
# form parameters
|
|
264
|
+
form_params = opts[:form_params] || {}
|
|
265
|
+
|
|
266
|
+
# http body (model)
|
|
267
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_rule_set_create)
|
|
268
|
+
|
|
269
|
+
# return_type
|
|
270
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectRuleSetResponse'
|
|
271
|
+
|
|
272
|
+
# auth_names
|
|
273
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
274
|
+
|
|
275
|
+
new_options = opts.merge(
|
|
276
|
+
:operation => :"NetworkProtectApi.create_network_protect_rule_set",
|
|
277
|
+
:header_params => header_params,
|
|
278
|
+
:query_params => query_params,
|
|
279
|
+
:form_params => form_params,
|
|
280
|
+
:body => post_body,
|
|
281
|
+
:auth_names => auth_names,
|
|
282
|
+
:return_type => return_type
|
|
283
|
+
)
|
|
284
|
+
|
|
285
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
286
|
+
if @api_client.config.debugging
|
|
287
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#create_network_protect_rule_set\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
288
|
+
end
|
|
289
|
+
return data, status_code, headers
|
|
290
|
+
end
|
|
291
|
+
|
|
292
|
+
# Delete a Network Protect endpoint
|
|
293
|
+
# Deletes an endpoint. The endpoint must first be removed from every network policy; active references return a `409 Conflict` error.
|
|
294
|
+
# @option opts [String] :endpoint_id Unique identifier of the Network Protect endpoint. (required)
|
|
295
|
+
# @return [nil]
|
|
296
|
+
def delete_network_protect_endpoint(opts = {})
|
|
297
|
+
delete_network_protect_endpoint_with_http_info(opts)
|
|
298
|
+
nil
|
|
299
|
+
end
|
|
300
|
+
|
|
301
|
+
# Delete a Network Protect endpoint
|
|
302
|
+
# Deletes an endpoint. The endpoint must first be removed from every network policy; active references return a `409 Conflict` error.
|
|
303
|
+
# @option opts [String] :endpoint_id Unique identifier of the Network Protect endpoint. (required)
|
|
304
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
305
|
+
def delete_network_protect_endpoint_with_http_info(opts = {})
|
|
306
|
+
if @api_client.config.debugging
|
|
307
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.delete_network_protect_endpoint ...'
|
|
308
|
+
end
|
|
309
|
+
# unbox the parameters from the hash
|
|
310
|
+
endpoint_id = opts[:'endpoint_id']
|
|
311
|
+
# verify the required parameter 'endpoint_id' is set
|
|
312
|
+
if @api_client.config.client_side_validation && endpoint_id.nil?
|
|
313
|
+
fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling NetworkProtectApi.delete_network_protect_endpoint"
|
|
314
|
+
end
|
|
315
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
316
|
+
if @api_client.config.client_side_validation && endpoint_id !~ pattern
|
|
317
|
+
fail ArgumentError, "invalid value for 'endpoint_id' when calling NetworkProtectApi.delete_network_protect_endpoint, must conform to the pattern #{pattern}."
|
|
318
|
+
end
|
|
319
|
+
|
|
320
|
+
# resource path
|
|
321
|
+
local_var_path = '/network-protect/v1/endpoints/{endpoint_id}'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
|
|
322
|
+
|
|
323
|
+
# query parameters
|
|
324
|
+
query_params = opts[:query_params] || {}
|
|
325
|
+
|
|
326
|
+
# header parameters
|
|
327
|
+
header_params = opts[:header_params] || {}
|
|
328
|
+
# HTTP header 'Accept' (if needed)
|
|
329
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/problem+json'])
|
|
330
|
+
|
|
331
|
+
# form parameters
|
|
332
|
+
form_params = opts[:form_params] || {}
|
|
333
|
+
|
|
334
|
+
# http body (model)
|
|
335
|
+
post_body = opts[:debug_body]
|
|
336
|
+
|
|
337
|
+
# return_type
|
|
338
|
+
return_type = opts[:debug_return_type]
|
|
339
|
+
|
|
340
|
+
# auth_names
|
|
341
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
342
|
+
|
|
343
|
+
new_options = opts.merge(
|
|
344
|
+
:operation => :"NetworkProtectApi.delete_network_protect_endpoint",
|
|
345
|
+
:header_params => header_params,
|
|
346
|
+
:query_params => query_params,
|
|
347
|
+
:form_params => form_params,
|
|
348
|
+
:body => post_body,
|
|
349
|
+
:auth_names => auth_names,
|
|
350
|
+
:return_type => return_type
|
|
351
|
+
)
|
|
352
|
+
|
|
353
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
354
|
+
if @api_client.config.debugging
|
|
355
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#delete_network_protect_endpoint\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
356
|
+
end
|
|
357
|
+
return data, status_code, headers
|
|
358
|
+
end
|
|
359
|
+
|
|
360
|
+
# Delete a Network Protect network
|
|
361
|
+
# Deletes a network and stops its advertisement and filtering. Endpoints and rule sets used by the network are not deleted.
|
|
362
|
+
# @option opts [String] :network_id Unique identifier of the Network Protect network. (required)
|
|
363
|
+
# @return [nil]
|
|
364
|
+
def delete_network_protect_network(opts = {})
|
|
365
|
+
delete_network_protect_network_with_http_info(opts)
|
|
366
|
+
nil
|
|
367
|
+
end
|
|
368
|
+
|
|
369
|
+
# Delete a Network Protect network
|
|
370
|
+
# Deletes a network and stops its advertisement and filtering. Endpoints and rule sets used by the network are not deleted.
|
|
371
|
+
# @option opts [String] :network_id Unique identifier of the Network Protect network. (required)
|
|
372
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
373
|
+
def delete_network_protect_network_with_http_info(opts = {})
|
|
374
|
+
if @api_client.config.debugging
|
|
375
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.delete_network_protect_network ...'
|
|
376
|
+
end
|
|
377
|
+
# unbox the parameters from the hash
|
|
378
|
+
network_id = opts[:'network_id']
|
|
379
|
+
# verify the required parameter 'network_id' is set
|
|
380
|
+
if @api_client.config.client_side_validation && network_id.nil?
|
|
381
|
+
fail ArgumentError, "Missing the required parameter 'network_id' when calling NetworkProtectApi.delete_network_protect_network"
|
|
382
|
+
end
|
|
383
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
384
|
+
if @api_client.config.client_side_validation && network_id !~ pattern
|
|
385
|
+
fail ArgumentError, "invalid value for 'network_id' when calling NetworkProtectApi.delete_network_protect_network, must conform to the pattern #{pattern}."
|
|
386
|
+
end
|
|
387
|
+
|
|
388
|
+
# resource path
|
|
389
|
+
local_var_path = '/network-protect/v1/networks/{network_id}'.sub('{' + 'network_id' + '}', CGI.escape(network_id.to_s))
|
|
390
|
+
|
|
391
|
+
# query parameters
|
|
392
|
+
query_params = opts[:query_params] || {}
|
|
393
|
+
|
|
394
|
+
# header parameters
|
|
395
|
+
header_params = opts[:header_params] || {}
|
|
396
|
+
# HTTP header 'Accept' (if needed)
|
|
397
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/problem+json'])
|
|
398
|
+
|
|
399
|
+
# form parameters
|
|
400
|
+
form_params = opts[:form_params] || {}
|
|
401
|
+
|
|
402
|
+
# http body (model)
|
|
403
|
+
post_body = opts[:debug_body]
|
|
404
|
+
|
|
405
|
+
# return_type
|
|
406
|
+
return_type = opts[:debug_return_type]
|
|
407
|
+
|
|
408
|
+
# auth_names
|
|
409
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
410
|
+
|
|
411
|
+
new_options = opts.merge(
|
|
412
|
+
:operation => :"NetworkProtectApi.delete_network_protect_network",
|
|
413
|
+
:header_params => header_params,
|
|
414
|
+
:query_params => query_params,
|
|
415
|
+
:form_params => form_params,
|
|
416
|
+
:body => post_body,
|
|
417
|
+
:auth_names => auth_names,
|
|
418
|
+
:return_type => return_type
|
|
419
|
+
)
|
|
420
|
+
|
|
421
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
422
|
+
if @api_client.config.debugging
|
|
423
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#delete_network_protect_network\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
424
|
+
end
|
|
425
|
+
return data, status_code, headers
|
|
426
|
+
end
|
|
427
|
+
|
|
428
|
+
# Delete a Network Protect prefix list
|
|
429
|
+
# Deletes a prefix list. Active rule references must be removed first; referenced lists return a `409 Conflict` error. Unknown and foreign IDs are indistinguishable and return a `404 Not Found` error.
|
|
430
|
+
# @option opts [String] :prefix_list_id Unique identifier of the Network Protect prefix list. (required)
|
|
431
|
+
# @return [nil]
|
|
432
|
+
def delete_network_protect_prefix_list(opts = {})
|
|
433
|
+
delete_network_protect_prefix_list_with_http_info(opts)
|
|
434
|
+
nil
|
|
435
|
+
end
|
|
436
|
+
|
|
437
|
+
# Delete a Network Protect prefix list
|
|
438
|
+
# Deletes a prefix list. Active rule references must be removed first; referenced lists return a `409 Conflict` error. Unknown and foreign IDs are indistinguishable and return a `404 Not Found` error.
|
|
439
|
+
# @option opts [String] :prefix_list_id Unique identifier of the Network Protect prefix list. (required)
|
|
440
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
441
|
+
def delete_network_protect_prefix_list_with_http_info(opts = {})
|
|
442
|
+
if @api_client.config.debugging
|
|
443
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.delete_network_protect_prefix_list ...'
|
|
444
|
+
end
|
|
445
|
+
# unbox the parameters from the hash
|
|
446
|
+
prefix_list_id = opts[:'prefix_list_id']
|
|
447
|
+
# verify the required parameter 'prefix_list_id' is set
|
|
448
|
+
if @api_client.config.client_side_validation && prefix_list_id.nil?
|
|
449
|
+
fail ArgumentError, "Missing the required parameter 'prefix_list_id' when calling NetworkProtectApi.delete_network_protect_prefix_list"
|
|
450
|
+
end
|
|
451
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
452
|
+
if @api_client.config.client_side_validation && prefix_list_id !~ pattern
|
|
453
|
+
fail ArgumentError, "invalid value for 'prefix_list_id' when calling NetworkProtectApi.delete_network_protect_prefix_list, must conform to the pattern #{pattern}."
|
|
454
|
+
end
|
|
455
|
+
|
|
456
|
+
# resource path
|
|
457
|
+
local_var_path = '/network-protect/v1/prefix-lists/{prefix_list_id}'.sub('{' + 'prefix_list_id' + '}', CGI.escape(prefix_list_id.to_s))
|
|
458
|
+
|
|
459
|
+
# query parameters
|
|
460
|
+
query_params = opts[:query_params] || {}
|
|
461
|
+
|
|
462
|
+
# header parameters
|
|
463
|
+
header_params = opts[:header_params] || {}
|
|
464
|
+
# HTTP header 'Accept' (if needed)
|
|
465
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/problem+json'])
|
|
466
|
+
|
|
467
|
+
# form parameters
|
|
468
|
+
form_params = opts[:form_params] || {}
|
|
469
|
+
|
|
470
|
+
# http body (model)
|
|
471
|
+
post_body = opts[:debug_body]
|
|
472
|
+
|
|
473
|
+
# return_type
|
|
474
|
+
return_type = opts[:debug_return_type]
|
|
475
|
+
|
|
476
|
+
# auth_names
|
|
477
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
478
|
+
|
|
479
|
+
new_options = opts.merge(
|
|
480
|
+
:operation => :"NetworkProtectApi.delete_network_protect_prefix_list",
|
|
481
|
+
:header_params => header_params,
|
|
482
|
+
:query_params => query_params,
|
|
483
|
+
:form_params => form_params,
|
|
484
|
+
:body => post_body,
|
|
485
|
+
:auth_names => auth_names,
|
|
486
|
+
:return_type => return_type
|
|
487
|
+
)
|
|
488
|
+
|
|
489
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
490
|
+
if @api_client.config.debugging
|
|
491
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#delete_network_protect_prefix_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
492
|
+
end
|
|
493
|
+
return data, status_code, headers
|
|
494
|
+
end
|
|
495
|
+
|
|
496
|
+
# Delete a Network Protect rule set
|
|
497
|
+
# Deletes a rule set. Attached rule sets cannot be deleted and return a `409 Conflict` error until their references are removed.
|
|
498
|
+
# @option opts [String] :rule_set_id Unique identifier of the Network Protect rule set. (required)
|
|
499
|
+
# @return [nil]
|
|
500
|
+
def delete_network_protect_rule_set(opts = {})
|
|
501
|
+
delete_network_protect_rule_set_with_http_info(opts)
|
|
502
|
+
nil
|
|
503
|
+
end
|
|
504
|
+
|
|
505
|
+
# Delete a Network Protect rule set
|
|
506
|
+
# Deletes a rule set. Attached rule sets cannot be deleted and return a `409 Conflict` error until their references are removed.
|
|
507
|
+
# @option opts [String] :rule_set_id Unique identifier of the Network Protect rule set. (required)
|
|
508
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
509
|
+
def delete_network_protect_rule_set_with_http_info(opts = {})
|
|
510
|
+
if @api_client.config.debugging
|
|
511
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.delete_network_protect_rule_set ...'
|
|
512
|
+
end
|
|
513
|
+
# unbox the parameters from the hash
|
|
514
|
+
rule_set_id = opts[:'rule_set_id']
|
|
515
|
+
# verify the required parameter 'rule_set_id' is set
|
|
516
|
+
if @api_client.config.client_side_validation && rule_set_id.nil?
|
|
517
|
+
fail ArgumentError, "Missing the required parameter 'rule_set_id' when calling NetworkProtectApi.delete_network_protect_rule_set"
|
|
518
|
+
end
|
|
519
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
520
|
+
if @api_client.config.client_side_validation && rule_set_id !~ pattern
|
|
521
|
+
fail ArgumentError, "invalid value for 'rule_set_id' when calling NetworkProtectApi.delete_network_protect_rule_set, must conform to the pattern #{pattern}."
|
|
522
|
+
end
|
|
523
|
+
|
|
524
|
+
# resource path
|
|
525
|
+
local_var_path = '/network-protect/v1/rule-sets/{rule_set_id}'.sub('{' + 'rule_set_id' + '}', CGI.escape(rule_set_id.to_s))
|
|
526
|
+
|
|
527
|
+
# query parameters
|
|
528
|
+
query_params = opts[:query_params] || {}
|
|
529
|
+
|
|
530
|
+
# header parameters
|
|
531
|
+
header_params = opts[:header_params] || {}
|
|
532
|
+
# HTTP header 'Accept' (if needed)
|
|
533
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/problem+json'])
|
|
534
|
+
|
|
535
|
+
# form parameters
|
|
536
|
+
form_params = opts[:form_params] || {}
|
|
537
|
+
|
|
538
|
+
# http body (model)
|
|
539
|
+
post_body = opts[:debug_body]
|
|
540
|
+
|
|
541
|
+
# return_type
|
|
542
|
+
return_type = opts[:debug_return_type]
|
|
543
|
+
|
|
544
|
+
# auth_names
|
|
545
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
546
|
+
|
|
547
|
+
new_options = opts.merge(
|
|
548
|
+
:operation => :"NetworkProtectApi.delete_network_protect_rule_set",
|
|
549
|
+
:header_params => header_params,
|
|
550
|
+
:query_params => query_params,
|
|
551
|
+
:form_params => form_params,
|
|
552
|
+
:body => post_body,
|
|
553
|
+
:auth_names => auth_names,
|
|
554
|
+
:return_type => return_type
|
|
555
|
+
)
|
|
556
|
+
|
|
557
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
558
|
+
if @api_client.config.debugging
|
|
559
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#delete_network_protect_rule_set\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
560
|
+
end
|
|
561
|
+
return data, status_code, headers
|
|
562
|
+
end
|
|
563
|
+
|
|
564
|
+
# Get a Network Protect endpoint
|
|
565
|
+
# Retrieves a single endpoint by its identifier.
|
|
566
|
+
# @option opts [String] :endpoint_id Unique identifier of the Network Protect endpoint. (required)
|
|
567
|
+
# @return [NetworkProtectEndpointResponse]
|
|
568
|
+
def get_network_protect_endpoint(opts = {})
|
|
569
|
+
data, _status_code, _headers = get_network_protect_endpoint_with_http_info(opts)
|
|
570
|
+
data
|
|
571
|
+
end
|
|
572
|
+
|
|
573
|
+
# Get a Network Protect endpoint
|
|
574
|
+
# Retrieves a single endpoint by its identifier.
|
|
575
|
+
# @option opts [String] :endpoint_id Unique identifier of the Network Protect endpoint. (required)
|
|
576
|
+
# @return [Array<(NetworkProtectEndpointResponse, Integer, Hash)>] NetworkProtectEndpointResponse data, response status code and response headers
|
|
577
|
+
def get_network_protect_endpoint_with_http_info(opts = {})
|
|
578
|
+
if @api_client.config.debugging
|
|
579
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.get_network_protect_endpoint ...'
|
|
580
|
+
end
|
|
581
|
+
# unbox the parameters from the hash
|
|
582
|
+
endpoint_id = opts[:'endpoint_id']
|
|
583
|
+
# verify the required parameter 'endpoint_id' is set
|
|
584
|
+
if @api_client.config.client_side_validation && endpoint_id.nil?
|
|
585
|
+
fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling NetworkProtectApi.get_network_protect_endpoint"
|
|
586
|
+
end
|
|
587
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
588
|
+
if @api_client.config.client_side_validation && endpoint_id !~ pattern
|
|
589
|
+
fail ArgumentError, "invalid value for 'endpoint_id' when calling NetworkProtectApi.get_network_protect_endpoint, must conform to the pattern #{pattern}."
|
|
590
|
+
end
|
|
591
|
+
|
|
592
|
+
# resource path
|
|
593
|
+
local_var_path = '/network-protect/v1/endpoints/{endpoint_id}'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
|
|
594
|
+
|
|
595
|
+
# query parameters
|
|
596
|
+
query_params = opts[:query_params] || {}
|
|
597
|
+
|
|
598
|
+
# header parameters
|
|
599
|
+
header_params = opts[:header_params] || {}
|
|
600
|
+
# HTTP header 'Accept' (if needed)
|
|
601
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
602
|
+
|
|
603
|
+
# form parameters
|
|
604
|
+
form_params = opts[:form_params] || {}
|
|
605
|
+
|
|
606
|
+
# http body (model)
|
|
607
|
+
post_body = opts[:debug_body]
|
|
608
|
+
|
|
609
|
+
# return_type
|
|
610
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectEndpointResponse'
|
|
611
|
+
|
|
612
|
+
# auth_names
|
|
613
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
614
|
+
|
|
615
|
+
new_options = opts.merge(
|
|
616
|
+
:operation => :"NetworkProtectApi.get_network_protect_endpoint",
|
|
617
|
+
:header_params => header_params,
|
|
618
|
+
:query_params => query_params,
|
|
619
|
+
:form_params => form_params,
|
|
620
|
+
:body => post_body,
|
|
621
|
+
:auth_names => auth_names,
|
|
622
|
+
:return_type => return_type
|
|
623
|
+
)
|
|
624
|
+
|
|
625
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
626
|
+
if @api_client.config.debugging
|
|
627
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#get_network_protect_endpoint\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
628
|
+
end
|
|
629
|
+
return data, status_code, headers
|
|
630
|
+
end
|
|
631
|
+
|
|
632
|
+
# Get a Network Protect network
|
|
633
|
+
# Retrieves a single network by its identifier.
|
|
634
|
+
# @option opts [String] :network_id Unique identifier of the Network Protect network. (required)
|
|
635
|
+
# @return [NetworkProtectNetworkResponse]
|
|
636
|
+
def get_network_protect_network(opts = {})
|
|
637
|
+
data, _status_code, _headers = get_network_protect_network_with_http_info(opts)
|
|
638
|
+
data
|
|
639
|
+
end
|
|
640
|
+
|
|
641
|
+
# Get a Network Protect network
|
|
642
|
+
# Retrieves a single network by its identifier.
|
|
643
|
+
# @option opts [String] :network_id Unique identifier of the Network Protect network. (required)
|
|
644
|
+
# @return [Array<(NetworkProtectNetworkResponse, Integer, Hash)>] NetworkProtectNetworkResponse data, response status code and response headers
|
|
645
|
+
def get_network_protect_network_with_http_info(opts = {})
|
|
646
|
+
if @api_client.config.debugging
|
|
647
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.get_network_protect_network ...'
|
|
648
|
+
end
|
|
649
|
+
# unbox the parameters from the hash
|
|
650
|
+
network_id = opts[:'network_id']
|
|
651
|
+
# verify the required parameter 'network_id' is set
|
|
652
|
+
if @api_client.config.client_side_validation && network_id.nil?
|
|
653
|
+
fail ArgumentError, "Missing the required parameter 'network_id' when calling NetworkProtectApi.get_network_protect_network"
|
|
654
|
+
end
|
|
655
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
656
|
+
if @api_client.config.client_side_validation && network_id !~ pattern
|
|
657
|
+
fail ArgumentError, "invalid value for 'network_id' when calling NetworkProtectApi.get_network_protect_network, must conform to the pattern #{pattern}."
|
|
658
|
+
end
|
|
659
|
+
|
|
660
|
+
# resource path
|
|
661
|
+
local_var_path = '/network-protect/v1/networks/{network_id}'.sub('{' + 'network_id' + '}', CGI.escape(network_id.to_s))
|
|
662
|
+
|
|
663
|
+
# query parameters
|
|
664
|
+
query_params = opts[:query_params] || {}
|
|
665
|
+
|
|
666
|
+
# header parameters
|
|
667
|
+
header_params = opts[:header_params] || {}
|
|
668
|
+
# HTTP header 'Accept' (if needed)
|
|
669
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
670
|
+
|
|
671
|
+
# form parameters
|
|
672
|
+
form_params = opts[:form_params] || {}
|
|
673
|
+
|
|
674
|
+
# http body (model)
|
|
675
|
+
post_body = opts[:debug_body]
|
|
676
|
+
|
|
677
|
+
# return_type
|
|
678
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectNetworkResponse'
|
|
679
|
+
|
|
680
|
+
# auth_names
|
|
681
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
682
|
+
|
|
683
|
+
new_options = opts.merge(
|
|
684
|
+
:operation => :"NetworkProtectApi.get_network_protect_network",
|
|
685
|
+
:header_params => header_params,
|
|
686
|
+
:query_params => query_params,
|
|
687
|
+
:form_params => form_params,
|
|
688
|
+
:body => post_body,
|
|
689
|
+
:auth_names => auth_names,
|
|
690
|
+
:return_type => return_type
|
|
691
|
+
)
|
|
692
|
+
|
|
693
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
694
|
+
if @api_client.config.debugging
|
|
695
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#get_network_protect_network\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
696
|
+
end
|
|
697
|
+
return data, status_code, headers
|
|
698
|
+
end
|
|
699
|
+
|
|
700
|
+
# Get a Network Protect prefix list
|
|
701
|
+
# Retrieves a single prefix list by its identifier. Unknown and foreign IDs are indistinguishable and return a `404 Not Found` error.
|
|
702
|
+
# @option opts [String] :prefix_list_id Unique identifier of the Network Protect prefix list. (required)
|
|
703
|
+
# @return [NetworkProtectPrefixListResponse]
|
|
704
|
+
def get_network_protect_prefix_list(opts = {})
|
|
705
|
+
data, _status_code, _headers = get_network_protect_prefix_list_with_http_info(opts)
|
|
706
|
+
data
|
|
707
|
+
end
|
|
708
|
+
|
|
709
|
+
# Get a Network Protect prefix list
|
|
710
|
+
# Retrieves a single prefix list by its identifier. Unknown and foreign IDs are indistinguishable and return a `404 Not Found` error.
|
|
711
|
+
# @option opts [String] :prefix_list_id Unique identifier of the Network Protect prefix list. (required)
|
|
712
|
+
# @return [Array<(NetworkProtectPrefixListResponse, Integer, Hash)>] NetworkProtectPrefixListResponse data, response status code and response headers
|
|
713
|
+
def get_network_protect_prefix_list_with_http_info(opts = {})
|
|
714
|
+
if @api_client.config.debugging
|
|
715
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.get_network_protect_prefix_list ...'
|
|
716
|
+
end
|
|
717
|
+
# unbox the parameters from the hash
|
|
718
|
+
prefix_list_id = opts[:'prefix_list_id']
|
|
719
|
+
# verify the required parameter 'prefix_list_id' is set
|
|
720
|
+
if @api_client.config.client_side_validation && prefix_list_id.nil?
|
|
721
|
+
fail ArgumentError, "Missing the required parameter 'prefix_list_id' when calling NetworkProtectApi.get_network_protect_prefix_list"
|
|
722
|
+
end
|
|
723
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
724
|
+
if @api_client.config.client_side_validation && prefix_list_id !~ pattern
|
|
725
|
+
fail ArgumentError, "invalid value for 'prefix_list_id' when calling NetworkProtectApi.get_network_protect_prefix_list, must conform to the pattern #{pattern}."
|
|
726
|
+
end
|
|
727
|
+
|
|
728
|
+
# resource path
|
|
729
|
+
local_var_path = '/network-protect/v1/prefix-lists/{prefix_list_id}'.sub('{' + 'prefix_list_id' + '}', CGI.escape(prefix_list_id.to_s))
|
|
730
|
+
|
|
731
|
+
# query parameters
|
|
732
|
+
query_params = opts[:query_params] || {}
|
|
733
|
+
|
|
734
|
+
# header parameters
|
|
735
|
+
header_params = opts[:header_params] || {}
|
|
736
|
+
# HTTP header 'Accept' (if needed)
|
|
737
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
738
|
+
|
|
739
|
+
# form parameters
|
|
740
|
+
form_params = opts[:form_params] || {}
|
|
741
|
+
|
|
742
|
+
# http body (model)
|
|
743
|
+
post_body = opts[:debug_body]
|
|
744
|
+
|
|
745
|
+
# return_type
|
|
746
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectPrefixListResponse'
|
|
747
|
+
|
|
748
|
+
# auth_names
|
|
749
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
750
|
+
|
|
751
|
+
new_options = opts.merge(
|
|
752
|
+
:operation => :"NetworkProtectApi.get_network_protect_prefix_list",
|
|
753
|
+
:header_params => header_params,
|
|
754
|
+
:query_params => query_params,
|
|
755
|
+
:form_params => form_params,
|
|
756
|
+
:body => post_body,
|
|
757
|
+
:auth_names => auth_names,
|
|
758
|
+
:return_type => return_type
|
|
759
|
+
)
|
|
760
|
+
|
|
761
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
762
|
+
if @api_client.config.debugging
|
|
763
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#get_network_protect_prefix_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
764
|
+
end
|
|
765
|
+
return data, status_code, headers
|
|
766
|
+
end
|
|
767
|
+
|
|
768
|
+
# Get a Network Protect rule set
|
|
769
|
+
# Retrieves a single rule set with rules in evaluation order.
|
|
770
|
+
# @option opts [String] :rule_set_id Unique identifier of the Network Protect rule set. (required)
|
|
771
|
+
# @return [NetworkProtectRuleSetResponse]
|
|
772
|
+
def get_network_protect_rule_set(opts = {})
|
|
773
|
+
data, _status_code, _headers = get_network_protect_rule_set_with_http_info(opts)
|
|
774
|
+
data
|
|
775
|
+
end
|
|
776
|
+
|
|
777
|
+
# Get a Network Protect rule set
|
|
778
|
+
# Retrieves a single rule set with rules in evaluation order.
|
|
779
|
+
# @option opts [String] :rule_set_id Unique identifier of the Network Protect rule set. (required)
|
|
780
|
+
# @return [Array<(NetworkProtectRuleSetResponse, Integer, Hash)>] NetworkProtectRuleSetResponse data, response status code and response headers
|
|
781
|
+
def get_network_protect_rule_set_with_http_info(opts = {})
|
|
782
|
+
if @api_client.config.debugging
|
|
783
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.get_network_protect_rule_set ...'
|
|
784
|
+
end
|
|
785
|
+
# unbox the parameters from the hash
|
|
786
|
+
rule_set_id = opts[:'rule_set_id']
|
|
787
|
+
# verify the required parameter 'rule_set_id' is set
|
|
788
|
+
if @api_client.config.client_side_validation && rule_set_id.nil?
|
|
789
|
+
fail ArgumentError, "Missing the required parameter 'rule_set_id' when calling NetworkProtectApi.get_network_protect_rule_set"
|
|
790
|
+
end
|
|
791
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
792
|
+
if @api_client.config.client_side_validation && rule_set_id !~ pattern
|
|
793
|
+
fail ArgumentError, "invalid value for 'rule_set_id' when calling NetworkProtectApi.get_network_protect_rule_set, must conform to the pattern #{pattern}."
|
|
794
|
+
end
|
|
795
|
+
|
|
796
|
+
# resource path
|
|
797
|
+
local_var_path = '/network-protect/v1/rule-sets/{rule_set_id}'.sub('{' + 'rule_set_id' + '}', CGI.escape(rule_set_id.to_s))
|
|
798
|
+
|
|
799
|
+
# query parameters
|
|
800
|
+
query_params = opts[:query_params] || {}
|
|
801
|
+
|
|
802
|
+
# header parameters
|
|
803
|
+
header_params = opts[:header_params] || {}
|
|
804
|
+
# HTTP header 'Accept' (if needed)
|
|
805
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
806
|
+
|
|
807
|
+
# form parameters
|
|
808
|
+
form_params = opts[:form_params] || {}
|
|
809
|
+
|
|
810
|
+
# http body (model)
|
|
811
|
+
post_body = opts[:debug_body]
|
|
812
|
+
|
|
813
|
+
# return_type
|
|
814
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectRuleSetResponse'
|
|
815
|
+
|
|
816
|
+
# auth_names
|
|
817
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
818
|
+
|
|
819
|
+
new_options = opts.merge(
|
|
820
|
+
:operation => :"NetworkProtectApi.get_network_protect_rule_set",
|
|
821
|
+
:header_params => header_params,
|
|
822
|
+
:query_params => query_params,
|
|
823
|
+
:form_params => form_params,
|
|
824
|
+
:body => post_body,
|
|
825
|
+
:auth_names => auth_names,
|
|
826
|
+
:return_type => return_type
|
|
827
|
+
)
|
|
828
|
+
|
|
829
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
830
|
+
if @api_client.config.debugging
|
|
831
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#get_network_protect_rule_set\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
832
|
+
end
|
|
833
|
+
return data, status_code, headers
|
|
834
|
+
end
|
|
835
|
+
|
|
836
|
+
# List Network Protect endpoints
|
|
837
|
+
# Lists the customer's GRE delivery endpoints in ascending ID order. The response is cursor-paginated and includes the effective page limit.
|
|
838
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
839
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
840
|
+
# @return [NetworkProtectEndpointsResponse]
|
|
841
|
+
def list_network_protect_endpoints(opts = {})
|
|
842
|
+
data, _status_code, _headers = list_network_protect_endpoints_with_http_info(opts)
|
|
843
|
+
data
|
|
844
|
+
end
|
|
845
|
+
|
|
846
|
+
# List Network Protect endpoints
|
|
847
|
+
# Lists the customer's GRE delivery endpoints in ascending ID order. The response is cursor-paginated and includes the effective page limit.
|
|
848
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
849
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
850
|
+
# @return [Array<(NetworkProtectEndpointsResponse, Integer, Hash)>] NetworkProtectEndpointsResponse data, response status code and response headers
|
|
851
|
+
def list_network_protect_endpoints_with_http_info(opts = {})
|
|
852
|
+
if @api_client.config.debugging
|
|
853
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.list_network_protect_endpoints ...'
|
|
854
|
+
end
|
|
855
|
+
# unbox the parameters from the hash
|
|
856
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
857
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling NetworkProtectApi.list_network_protect_endpoints, must be greater than or equal to 1.'
|
|
858
|
+
end
|
|
859
|
+
|
|
860
|
+
# resource path
|
|
861
|
+
local_var_path = '/network-protect/v1/endpoints'
|
|
862
|
+
|
|
863
|
+
# query parameters
|
|
864
|
+
query_params = opts[:query_params] || {}
|
|
865
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
866
|
+
query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
|
|
867
|
+
|
|
868
|
+
# header parameters
|
|
869
|
+
header_params = opts[:header_params] || {}
|
|
870
|
+
# HTTP header 'Accept' (if needed)
|
|
871
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
872
|
+
|
|
873
|
+
# form parameters
|
|
874
|
+
form_params = opts[:form_params] || {}
|
|
875
|
+
|
|
876
|
+
# http body (model)
|
|
877
|
+
post_body = opts[:debug_body]
|
|
878
|
+
|
|
879
|
+
# return_type
|
|
880
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectEndpointsResponse'
|
|
881
|
+
|
|
882
|
+
# auth_names
|
|
883
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
884
|
+
|
|
885
|
+
new_options = opts.merge(
|
|
886
|
+
:operation => :"NetworkProtectApi.list_network_protect_endpoints",
|
|
887
|
+
:header_params => header_params,
|
|
888
|
+
:query_params => query_params,
|
|
889
|
+
:form_params => form_params,
|
|
890
|
+
:body => post_body,
|
|
891
|
+
:auth_names => auth_names,
|
|
892
|
+
:return_type => return_type
|
|
893
|
+
)
|
|
894
|
+
|
|
895
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
896
|
+
if @api_client.config.debugging
|
|
897
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#list_network_protect_endpoints\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
898
|
+
end
|
|
899
|
+
return data, status_code, headers
|
|
900
|
+
end
|
|
901
|
+
|
|
902
|
+
# List Network Protect networks
|
|
903
|
+
# Lists the customer's networks in ascending ID order. The response is cursor-paginated and includes the effective page limit.
|
|
904
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
905
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
906
|
+
# @return [NetworkProtectNetworksResponse]
|
|
907
|
+
def list_network_protect_networks(opts = {})
|
|
908
|
+
data, _status_code, _headers = list_network_protect_networks_with_http_info(opts)
|
|
909
|
+
data
|
|
910
|
+
end
|
|
911
|
+
|
|
912
|
+
# List Network Protect networks
|
|
913
|
+
# Lists the customer's networks in ascending ID order. The response is cursor-paginated and includes the effective page limit.
|
|
914
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
915
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
916
|
+
# @return [Array<(NetworkProtectNetworksResponse, Integer, Hash)>] NetworkProtectNetworksResponse data, response status code and response headers
|
|
917
|
+
def list_network_protect_networks_with_http_info(opts = {})
|
|
918
|
+
if @api_client.config.debugging
|
|
919
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.list_network_protect_networks ...'
|
|
920
|
+
end
|
|
921
|
+
# unbox the parameters from the hash
|
|
922
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
923
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling NetworkProtectApi.list_network_protect_networks, must be greater than or equal to 1.'
|
|
924
|
+
end
|
|
925
|
+
|
|
926
|
+
# resource path
|
|
927
|
+
local_var_path = '/network-protect/v1/networks'
|
|
928
|
+
|
|
929
|
+
# query parameters
|
|
930
|
+
query_params = opts[:query_params] || {}
|
|
931
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
932
|
+
query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
|
|
933
|
+
|
|
934
|
+
# header parameters
|
|
935
|
+
header_params = opts[:header_params] || {}
|
|
936
|
+
# HTTP header 'Accept' (if needed)
|
|
937
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
938
|
+
|
|
939
|
+
# form parameters
|
|
940
|
+
form_params = opts[:form_params] || {}
|
|
941
|
+
|
|
942
|
+
# http body (model)
|
|
943
|
+
post_body = opts[:debug_body]
|
|
944
|
+
|
|
945
|
+
# return_type
|
|
946
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectNetworksResponse'
|
|
947
|
+
|
|
948
|
+
# auth_names
|
|
949
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
950
|
+
|
|
951
|
+
new_options = opts.merge(
|
|
952
|
+
:operation => :"NetworkProtectApi.list_network_protect_networks",
|
|
953
|
+
:header_params => header_params,
|
|
954
|
+
:query_params => query_params,
|
|
955
|
+
:form_params => form_params,
|
|
956
|
+
:body => post_body,
|
|
957
|
+
:auth_names => auth_names,
|
|
958
|
+
:return_type => return_type
|
|
959
|
+
)
|
|
960
|
+
|
|
961
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
962
|
+
if @api_client.config.debugging
|
|
963
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#list_network_protect_networks\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
964
|
+
end
|
|
965
|
+
return data, status_code, headers
|
|
966
|
+
end
|
|
967
|
+
|
|
968
|
+
# List Network Protect prefix lists
|
|
969
|
+
# Lists prefix lists in ascending ID order. Positive limits above 1000 are accepted and clamped to 1000. Invalid limits return a `400 Bad Request` error.
|
|
970
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
971
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
972
|
+
# @return [NetworkProtectPrefixListsResponse]
|
|
973
|
+
def list_network_protect_prefix_lists(opts = {})
|
|
974
|
+
data, _status_code, _headers = list_network_protect_prefix_lists_with_http_info(opts)
|
|
975
|
+
data
|
|
976
|
+
end
|
|
977
|
+
|
|
978
|
+
# List Network Protect prefix lists
|
|
979
|
+
# Lists prefix lists in ascending ID order. Positive limits above 1000 are accepted and clamped to 1000. Invalid limits return a `400 Bad Request` error.
|
|
980
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
981
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
982
|
+
# @return [Array<(NetworkProtectPrefixListsResponse, Integer, Hash)>] NetworkProtectPrefixListsResponse data, response status code and response headers
|
|
983
|
+
def list_network_protect_prefix_lists_with_http_info(opts = {})
|
|
984
|
+
if @api_client.config.debugging
|
|
985
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.list_network_protect_prefix_lists ...'
|
|
986
|
+
end
|
|
987
|
+
# unbox the parameters from the hash
|
|
988
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
989
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling NetworkProtectApi.list_network_protect_prefix_lists, must be greater than or equal to 1.'
|
|
990
|
+
end
|
|
991
|
+
|
|
992
|
+
# resource path
|
|
993
|
+
local_var_path = '/network-protect/v1/prefix-lists'
|
|
994
|
+
|
|
995
|
+
# query parameters
|
|
996
|
+
query_params = opts[:query_params] || {}
|
|
997
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
998
|
+
query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
|
|
999
|
+
|
|
1000
|
+
# header parameters
|
|
1001
|
+
header_params = opts[:header_params] || {}
|
|
1002
|
+
# HTTP header 'Accept' (if needed)
|
|
1003
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
1004
|
+
|
|
1005
|
+
# form parameters
|
|
1006
|
+
form_params = opts[:form_params] || {}
|
|
1007
|
+
|
|
1008
|
+
# http body (model)
|
|
1009
|
+
post_body = opts[:debug_body]
|
|
1010
|
+
|
|
1011
|
+
# return_type
|
|
1012
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectPrefixListsResponse'
|
|
1013
|
+
|
|
1014
|
+
# auth_names
|
|
1015
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
1016
|
+
|
|
1017
|
+
new_options = opts.merge(
|
|
1018
|
+
:operation => :"NetworkProtectApi.list_network_protect_prefix_lists",
|
|
1019
|
+
:header_params => header_params,
|
|
1020
|
+
:query_params => query_params,
|
|
1021
|
+
:form_params => form_params,
|
|
1022
|
+
:body => post_body,
|
|
1023
|
+
:auth_names => auth_names,
|
|
1024
|
+
:return_type => return_type
|
|
1025
|
+
)
|
|
1026
|
+
|
|
1027
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1028
|
+
if @api_client.config.debugging
|
|
1029
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#list_network_protect_prefix_lists\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1030
|
+
end
|
|
1031
|
+
return data, status_code, headers
|
|
1032
|
+
end
|
|
1033
|
+
|
|
1034
|
+
# List Network Protect rule sets
|
|
1035
|
+
# Lists rule sets in ascending ID order. Positive limits above 1000 are accepted and clamped to 1000; invalid limits return a `400 Bad Request` error.
|
|
1036
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
1037
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
1038
|
+
# @return [NetworkProtectRuleSetsResponse]
|
|
1039
|
+
def list_network_protect_rule_sets(opts = {})
|
|
1040
|
+
data, _status_code, _headers = list_network_protect_rule_sets_with_http_info(opts)
|
|
1041
|
+
data
|
|
1042
|
+
end
|
|
1043
|
+
|
|
1044
|
+
# List Network Protect rule sets
|
|
1045
|
+
# Lists rule sets in ascending ID order. Positive limits above 1000 are accepted and clamped to 1000; invalid limits return a `400 Bad Request` error.
|
|
1046
|
+
# @option opts [Integer] :limit Maximum resources to return. Defaults to 100. Positive values above 1000 are accepted and clamped to 1000; the effective value is reported in meta.limit. Zero, negative, and non-integer values return a `400 Bad Request` error. (default to 100)
|
|
1047
|
+
# @option opts [String] :cursor Continuation value from a previous response's meta.next_cursor. Omit this parameter to request the first page.
|
|
1048
|
+
# @return [Array<(NetworkProtectRuleSetsResponse, Integer, Hash)>] NetworkProtectRuleSetsResponse data, response status code and response headers
|
|
1049
|
+
def list_network_protect_rule_sets_with_http_info(opts = {})
|
|
1050
|
+
if @api_client.config.debugging
|
|
1051
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.list_network_protect_rule_sets ...'
|
|
1052
|
+
end
|
|
1053
|
+
# unbox the parameters from the hash
|
|
1054
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
1055
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling NetworkProtectApi.list_network_protect_rule_sets, must be greater than or equal to 1.'
|
|
1056
|
+
end
|
|
1057
|
+
|
|
1058
|
+
# resource path
|
|
1059
|
+
local_var_path = '/network-protect/v1/rule-sets'
|
|
1060
|
+
|
|
1061
|
+
# query parameters
|
|
1062
|
+
query_params = opts[:query_params] || {}
|
|
1063
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
1064
|
+
query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
|
|
1065
|
+
|
|
1066
|
+
# header parameters
|
|
1067
|
+
header_params = opts[:header_params] || {}
|
|
1068
|
+
# HTTP header 'Accept' (if needed)
|
|
1069
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
1070
|
+
|
|
1071
|
+
# form parameters
|
|
1072
|
+
form_params = opts[:form_params] || {}
|
|
1073
|
+
|
|
1074
|
+
# http body (model)
|
|
1075
|
+
post_body = opts[:debug_body]
|
|
1076
|
+
|
|
1077
|
+
# return_type
|
|
1078
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectRuleSetsResponse'
|
|
1079
|
+
|
|
1080
|
+
# auth_names
|
|
1081
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
1082
|
+
|
|
1083
|
+
new_options = opts.merge(
|
|
1084
|
+
:operation => :"NetworkProtectApi.list_network_protect_rule_sets",
|
|
1085
|
+
:header_params => header_params,
|
|
1086
|
+
:query_params => query_params,
|
|
1087
|
+
:form_params => form_params,
|
|
1088
|
+
:body => post_body,
|
|
1089
|
+
:auth_names => auth_names,
|
|
1090
|
+
:return_type => return_type
|
|
1091
|
+
)
|
|
1092
|
+
|
|
1093
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1094
|
+
if @api_client.config.debugging
|
|
1095
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#list_network_protect_rule_sets\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1096
|
+
end
|
|
1097
|
+
return data, status_code, headers
|
|
1098
|
+
end
|
|
1099
|
+
|
|
1100
|
+
# Update a Network Protect endpoint
|
|
1101
|
+
# Updates an endpoint. Omitted fields remain unchanged. The IP address cannot be changed; create a new endpoint if the destination changes.
|
|
1102
|
+
# @option opts [String] :endpoint_id Unique identifier of the Network Protect endpoint. (required)
|
|
1103
|
+
# @option opts [NetworkProtectEndpointUpdate] :network_protect_endpoint_update (required)
|
|
1104
|
+
# @return [NetworkProtectEndpointResponse]
|
|
1105
|
+
def update_network_protect_endpoint(opts = {})
|
|
1106
|
+
data, _status_code, _headers = update_network_protect_endpoint_with_http_info(opts)
|
|
1107
|
+
data
|
|
1108
|
+
end
|
|
1109
|
+
|
|
1110
|
+
# Update a Network Protect endpoint
|
|
1111
|
+
# Updates an endpoint. Omitted fields remain unchanged. The IP address cannot be changed; create a new endpoint if the destination changes.
|
|
1112
|
+
# @option opts [String] :endpoint_id Unique identifier of the Network Protect endpoint. (required)
|
|
1113
|
+
# @option opts [NetworkProtectEndpointUpdate] :network_protect_endpoint_update (required)
|
|
1114
|
+
# @return [Array<(NetworkProtectEndpointResponse, Integer, Hash)>] NetworkProtectEndpointResponse data, response status code and response headers
|
|
1115
|
+
def update_network_protect_endpoint_with_http_info(opts = {})
|
|
1116
|
+
if @api_client.config.debugging
|
|
1117
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.update_network_protect_endpoint ...'
|
|
1118
|
+
end
|
|
1119
|
+
# unbox the parameters from the hash
|
|
1120
|
+
endpoint_id = opts[:'endpoint_id']
|
|
1121
|
+
network_protect_endpoint_update = opts[:'network_protect_endpoint_update']
|
|
1122
|
+
# verify the required parameter 'endpoint_id' is set
|
|
1123
|
+
if @api_client.config.client_side_validation && endpoint_id.nil?
|
|
1124
|
+
fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling NetworkProtectApi.update_network_protect_endpoint"
|
|
1125
|
+
end
|
|
1126
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
1127
|
+
if @api_client.config.client_side_validation && endpoint_id !~ pattern
|
|
1128
|
+
fail ArgumentError, "invalid value for 'endpoint_id' when calling NetworkProtectApi.update_network_protect_endpoint, must conform to the pattern #{pattern}."
|
|
1129
|
+
end
|
|
1130
|
+
|
|
1131
|
+
# verify the required parameter 'network_protect_endpoint_update' is set
|
|
1132
|
+
if @api_client.config.client_side_validation && network_protect_endpoint_update.nil?
|
|
1133
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_endpoint_update' when calling NetworkProtectApi.update_network_protect_endpoint"
|
|
1134
|
+
end
|
|
1135
|
+
# resource path
|
|
1136
|
+
local_var_path = '/network-protect/v1/endpoints/{endpoint_id}'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
|
|
1137
|
+
|
|
1138
|
+
# query parameters
|
|
1139
|
+
query_params = opts[:query_params] || {}
|
|
1140
|
+
|
|
1141
|
+
# header parameters
|
|
1142
|
+
header_params = opts[:header_params] || {}
|
|
1143
|
+
# HTTP header 'Accept' (if needed)
|
|
1144
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
1145
|
+
# HTTP header 'Content-Type'
|
|
1146
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1147
|
+
if !content_type.nil?
|
|
1148
|
+
header_params['Content-Type'] = content_type
|
|
1149
|
+
end
|
|
1150
|
+
|
|
1151
|
+
# form parameters
|
|
1152
|
+
form_params = opts[:form_params] || {}
|
|
1153
|
+
|
|
1154
|
+
# http body (model)
|
|
1155
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_endpoint_update)
|
|
1156
|
+
|
|
1157
|
+
# return_type
|
|
1158
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectEndpointResponse'
|
|
1159
|
+
|
|
1160
|
+
# auth_names
|
|
1161
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
1162
|
+
|
|
1163
|
+
new_options = opts.merge(
|
|
1164
|
+
:operation => :"NetworkProtectApi.update_network_protect_endpoint",
|
|
1165
|
+
:header_params => header_params,
|
|
1166
|
+
:query_params => query_params,
|
|
1167
|
+
:form_params => form_params,
|
|
1168
|
+
:body => post_body,
|
|
1169
|
+
:auth_names => auth_names,
|
|
1170
|
+
:return_type => return_type
|
|
1171
|
+
)
|
|
1172
|
+
|
|
1173
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
1174
|
+
if @api_client.config.debugging
|
|
1175
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#update_network_protect_endpoint\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1176
|
+
end
|
|
1177
|
+
return data, status_code, headers
|
|
1178
|
+
end
|
|
1179
|
+
|
|
1180
|
+
# Update a Network Protect network
|
|
1181
|
+
# Updates a network. Omitted fields remain unchanged. The prefix cannot be changed. Sending `endpoint_policies` replaces the complete policy list; an empty array removes every policy. Advertisement is desired state. Enabling it requires an approved LOA, a valid ROA, and a ready default-region delivery policy. A readiness failure returns a `409 Conflict` error.
|
|
1182
|
+
# @option opts [String] :network_id Unique identifier of the Network Protect network. (required)
|
|
1183
|
+
# @option opts [NetworkProtectNetworkUpdate] :network_protect_network_update (required)
|
|
1184
|
+
# @return [NetworkProtectNetworkResponse]
|
|
1185
|
+
def update_network_protect_network(opts = {})
|
|
1186
|
+
data, _status_code, _headers = update_network_protect_network_with_http_info(opts)
|
|
1187
|
+
data
|
|
1188
|
+
end
|
|
1189
|
+
|
|
1190
|
+
# Update a Network Protect network
|
|
1191
|
+
# Updates a network. Omitted fields remain unchanged. The prefix cannot be changed. Sending `endpoint_policies` replaces the complete policy list; an empty array removes every policy. Advertisement is desired state. Enabling it requires an approved LOA, a valid ROA, and a ready default-region delivery policy. A readiness failure returns a `409 Conflict` error.
|
|
1192
|
+
# @option opts [String] :network_id Unique identifier of the Network Protect network. (required)
|
|
1193
|
+
# @option opts [NetworkProtectNetworkUpdate] :network_protect_network_update (required)
|
|
1194
|
+
# @return [Array<(NetworkProtectNetworkResponse, Integer, Hash)>] NetworkProtectNetworkResponse data, response status code and response headers
|
|
1195
|
+
def update_network_protect_network_with_http_info(opts = {})
|
|
1196
|
+
if @api_client.config.debugging
|
|
1197
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.update_network_protect_network ...'
|
|
1198
|
+
end
|
|
1199
|
+
# unbox the parameters from the hash
|
|
1200
|
+
network_id = opts[:'network_id']
|
|
1201
|
+
network_protect_network_update = opts[:'network_protect_network_update']
|
|
1202
|
+
# verify the required parameter 'network_id' is set
|
|
1203
|
+
if @api_client.config.client_side_validation && network_id.nil?
|
|
1204
|
+
fail ArgumentError, "Missing the required parameter 'network_id' when calling NetworkProtectApi.update_network_protect_network"
|
|
1205
|
+
end
|
|
1206
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
1207
|
+
if @api_client.config.client_side_validation && network_id !~ pattern
|
|
1208
|
+
fail ArgumentError, "invalid value for 'network_id' when calling NetworkProtectApi.update_network_protect_network, must conform to the pattern #{pattern}."
|
|
1209
|
+
end
|
|
1210
|
+
|
|
1211
|
+
# verify the required parameter 'network_protect_network_update' is set
|
|
1212
|
+
if @api_client.config.client_side_validation && network_protect_network_update.nil?
|
|
1213
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_network_update' when calling NetworkProtectApi.update_network_protect_network"
|
|
1214
|
+
end
|
|
1215
|
+
# resource path
|
|
1216
|
+
local_var_path = '/network-protect/v1/networks/{network_id}'.sub('{' + 'network_id' + '}', CGI.escape(network_id.to_s))
|
|
1217
|
+
|
|
1218
|
+
# query parameters
|
|
1219
|
+
query_params = opts[:query_params] || {}
|
|
1220
|
+
|
|
1221
|
+
# header parameters
|
|
1222
|
+
header_params = opts[:header_params] || {}
|
|
1223
|
+
# HTTP header 'Accept' (if needed)
|
|
1224
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
1225
|
+
# HTTP header 'Content-Type'
|
|
1226
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1227
|
+
if !content_type.nil?
|
|
1228
|
+
header_params['Content-Type'] = content_type
|
|
1229
|
+
end
|
|
1230
|
+
|
|
1231
|
+
# form parameters
|
|
1232
|
+
form_params = opts[:form_params] || {}
|
|
1233
|
+
|
|
1234
|
+
# http body (model)
|
|
1235
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_network_update)
|
|
1236
|
+
|
|
1237
|
+
# return_type
|
|
1238
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectNetworkResponse'
|
|
1239
|
+
|
|
1240
|
+
# auth_names
|
|
1241
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
1242
|
+
|
|
1243
|
+
new_options = opts.merge(
|
|
1244
|
+
:operation => :"NetworkProtectApi.update_network_protect_network",
|
|
1245
|
+
:header_params => header_params,
|
|
1246
|
+
:query_params => query_params,
|
|
1247
|
+
:form_params => form_params,
|
|
1248
|
+
:body => post_body,
|
|
1249
|
+
:auth_names => auth_names,
|
|
1250
|
+
:return_type => return_type
|
|
1251
|
+
)
|
|
1252
|
+
|
|
1253
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
1254
|
+
if @api_client.config.debugging
|
|
1255
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#update_network_protect_network\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1256
|
+
end
|
|
1257
|
+
return data, status_code, headers
|
|
1258
|
+
end
|
|
1259
|
+
|
|
1260
|
+
# Update a Network Protect prefix list
|
|
1261
|
+
# Updates a prefix list. The family cannot be changed. Sending addresses replaces the complete list; an empty array clears it when no active source-list restriction applies. Addresses are canonicalized, deduplicated, and sorted by the backend.
|
|
1262
|
+
# @option opts [String] :prefix_list_id Unique identifier of the Network Protect prefix list. (required)
|
|
1263
|
+
# @option opts [NetworkProtectPrefixListUpdate] :network_protect_prefix_list_update (required)
|
|
1264
|
+
# @return [NetworkProtectPrefixListResponse]
|
|
1265
|
+
def update_network_protect_prefix_list(opts = {})
|
|
1266
|
+
data, _status_code, _headers = update_network_protect_prefix_list_with_http_info(opts)
|
|
1267
|
+
data
|
|
1268
|
+
end
|
|
1269
|
+
|
|
1270
|
+
# Update a Network Protect prefix list
|
|
1271
|
+
# Updates a prefix list. The family cannot be changed. Sending addresses replaces the complete list; an empty array clears it when no active source-list restriction applies. Addresses are canonicalized, deduplicated, and sorted by the backend.
|
|
1272
|
+
# @option opts [String] :prefix_list_id Unique identifier of the Network Protect prefix list. (required)
|
|
1273
|
+
# @option opts [NetworkProtectPrefixListUpdate] :network_protect_prefix_list_update (required)
|
|
1274
|
+
# @return [Array<(NetworkProtectPrefixListResponse, Integer, Hash)>] NetworkProtectPrefixListResponse data, response status code and response headers
|
|
1275
|
+
def update_network_protect_prefix_list_with_http_info(opts = {})
|
|
1276
|
+
if @api_client.config.debugging
|
|
1277
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.update_network_protect_prefix_list ...'
|
|
1278
|
+
end
|
|
1279
|
+
# unbox the parameters from the hash
|
|
1280
|
+
prefix_list_id = opts[:'prefix_list_id']
|
|
1281
|
+
network_protect_prefix_list_update = opts[:'network_protect_prefix_list_update']
|
|
1282
|
+
# verify the required parameter 'prefix_list_id' is set
|
|
1283
|
+
if @api_client.config.client_side_validation && prefix_list_id.nil?
|
|
1284
|
+
fail ArgumentError, "Missing the required parameter 'prefix_list_id' when calling NetworkProtectApi.update_network_protect_prefix_list"
|
|
1285
|
+
end
|
|
1286
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
1287
|
+
if @api_client.config.client_side_validation && prefix_list_id !~ pattern
|
|
1288
|
+
fail ArgumentError, "invalid value for 'prefix_list_id' when calling NetworkProtectApi.update_network_protect_prefix_list, must conform to the pattern #{pattern}."
|
|
1289
|
+
end
|
|
1290
|
+
|
|
1291
|
+
# verify the required parameter 'network_protect_prefix_list_update' is set
|
|
1292
|
+
if @api_client.config.client_side_validation && network_protect_prefix_list_update.nil?
|
|
1293
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_prefix_list_update' when calling NetworkProtectApi.update_network_protect_prefix_list"
|
|
1294
|
+
end
|
|
1295
|
+
# resource path
|
|
1296
|
+
local_var_path = '/network-protect/v1/prefix-lists/{prefix_list_id}'.sub('{' + 'prefix_list_id' + '}', CGI.escape(prefix_list_id.to_s))
|
|
1297
|
+
|
|
1298
|
+
# query parameters
|
|
1299
|
+
query_params = opts[:query_params] || {}
|
|
1300
|
+
|
|
1301
|
+
# header parameters
|
|
1302
|
+
header_params = opts[:header_params] || {}
|
|
1303
|
+
# HTTP header 'Accept' (if needed)
|
|
1304
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
1305
|
+
# HTTP header 'Content-Type'
|
|
1306
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1307
|
+
if !content_type.nil?
|
|
1308
|
+
header_params['Content-Type'] = content_type
|
|
1309
|
+
end
|
|
1310
|
+
|
|
1311
|
+
# form parameters
|
|
1312
|
+
form_params = opts[:form_params] || {}
|
|
1313
|
+
|
|
1314
|
+
# http body (model)
|
|
1315
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_prefix_list_update)
|
|
1316
|
+
|
|
1317
|
+
# return_type
|
|
1318
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectPrefixListResponse'
|
|
1319
|
+
|
|
1320
|
+
# auth_names
|
|
1321
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
1322
|
+
|
|
1323
|
+
new_options = opts.merge(
|
|
1324
|
+
:operation => :"NetworkProtectApi.update_network_protect_prefix_list",
|
|
1325
|
+
:header_params => header_params,
|
|
1326
|
+
:query_params => query_params,
|
|
1327
|
+
:form_params => form_params,
|
|
1328
|
+
:body => post_body,
|
|
1329
|
+
:auth_names => auth_names,
|
|
1330
|
+
:return_type => return_type
|
|
1331
|
+
)
|
|
1332
|
+
|
|
1333
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
1334
|
+
if @api_client.config.debugging
|
|
1335
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#update_network_protect_prefix_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1336
|
+
end
|
|
1337
|
+
return data, status_code, headers
|
|
1338
|
+
end
|
|
1339
|
+
|
|
1340
|
+
# Update a Network Protect rule set
|
|
1341
|
+
# Updates a rule set. Omitted fields remain unchanged. Sending rules replaces the complete ordered list; an empty array removes every rule. Custom attachment and detachment remain restricted in this release.
|
|
1342
|
+
# @option opts [String] :rule_set_id Unique identifier of the Network Protect rule set. (required)
|
|
1343
|
+
# @option opts [NetworkProtectRuleSetUpdate] :network_protect_rule_set_update (required)
|
|
1344
|
+
# @return [NetworkProtectRuleSetResponse]
|
|
1345
|
+
def update_network_protect_rule_set(opts = {})
|
|
1346
|
+
data, _status_code, _headers = update_network_protect_rule_set_with_http_info(opts)
|
|
1347
|
+
data
|
|
1348
|
+
end
|
|
1349
|
+
|
|
1350
|
+
# Update a Network Protect rule set
|
|
1351
|
+
# Updates a rule set. Omitted fields remain unchanged. Sending rules replaces the complete ordered list; an empty array removes every rule. Custom attachment and detachment remain restricted in this release.
|
|
1352
|
+
# @option opts [String] :rule_set_id Unique identifier of the Network Protect rule set. (required)
|
|
1353
|
+
# @option opts [NetworkProtectRuleSetUpdate] :network_protect_rule_set_update (required)
|
|
1354
|
+
# @return [Array<(NetworkProtectRuleSetResponse, Integer, Hash)>] NetworkProtectRuleSetResponse data, response status code and response headers
|
|
1355
|
+
def update_network_protect_rule_set_with_http_info(opts = {})
|
|
1356
|
+
if @api_client.config.debugging
|
|
1357
|
+
@api_client.config.logger.debug 'Calling API: NetworkProtectApi.update_network_protect_rule_set ...'
|
|
1358
|
+
end
|
|
1359
|
+
# unbox the parameters from the hash
|
|
1360
|
+
rule_set_id = opts[:'rule_set_id']
|
|
1361
|
+
network_protect_rule_set_update = opts[:'network_protect_rule_set_update']
|
|
1362
|
+
# verify the required parameter 'rule_set_id' is set
|
|
1363
|
+
if @api_client.config.client_side_validation && rule_set_id.nil?
|
|
1364
|
+
fail ArgumentError, "Missing the required parameter 'rule_set_id' when calling NetworkProtectApi.update_network_protect_rule_set"
|
|
1365
|
+
end
|
|
1366
|
+
pattern = Regexp.new(/^[A-Za-z0-9]{19,22}$/)
|
|
1367
|
+
if @api_client.config.client_side_validation && rule_set_id !~ pattern
|
|
1368
|
+
fail ArgumentError, "invalid value for 'rule_set_id' when calling NetworkProtectApi.update_network_protect_rule_set, must conform to the pattern #{pattern}."
|
|
1369
|
+
end
|
|
1370
|
+
|
|
1371
|
+
# verify the required parameter 'network_protect_rule_set_update' is set
|
|
1372
|
+
if @api_client.config.client_side_validation && network_protect_rule_set_update.nil?
|
|
1373
|
+
fail ArgumentError, "Missing the required parameter 'network_protect_rule_set_update' when calling NetworkProtectApi.update_network_protect_rule_set"
|
|
1374
|
+
end
|
|
1375
|
+
# resource path
|
|
1376
|
+
local_var_path = '/network-protect/v1/rule-sets/{rule_set_id}'.sub('{' + 'rule_set_id' + '}', CGI.escape(rule_set_id.to_s))
|
|
1377
|
+
|
|
1378
|
+
# query parameters
|
|
1379
|
+
query_params = opts[:query_params] || {}
|
|
1380
|
+
|
|
1381
|
+
# header parameters
|
|
1382
|
+
header_params = opts[:header_params] || {}
|
|
1383
|
+
# HTTP header 'Accept' (if needed)
|
|
1384
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
1385
|
+
# HTTP header 'Content-Type'
|
|
1386
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1387
|
+
if !content_type.nil?
|
|
1388
|
+
header_params['Content-Type'] = content_type
|
|
1389
|
+
end
|
|
1390
|
+
|
|
1391
|
+
# form parameters
|
|
1392
|
+
form_params = opts[:form_params] || {}
|
|
1393
|
+
|
|
1394
|
+
# http body (model)
|
|
1395
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(network_protect_rule_set_update)
|
|
1396
|
+
|
|
1397
|
+
# return_type
|
|
1398
|
+
return_type = opts[:debug_return_type] || 'NetworkProtectRuleSetResponse'
|
|
1399
|
+
|
|
1400
|
+
# auth_names
|
|
1401
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
1402
|
+
|
|
1403
|
+
new_options = opts.merge(
|
|
1404
|
+
:operation => :"NetworkProtectApi.update_network_protect_rule_set",
|
|
1405
|
+
:header_params => header_params,
|
|
1406
|
+
:query_params => query_params,
|
|
1407
|
+
:form_params => form_params,
|
|
1408
|
+
:body => post_body,
|
|
1409
|
+
:auth_names => auth_names,
|
|
1410
|
+
:return_type => return_type
|
|
1411
|
+
)
|
|
1412
|
+
|
|
1413
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
1414
|
+
if @api_client.config.debugging
|
|
1415
|
+
@api_client.config.logger.debug "API called: NetworkProtectApi#update_network_protect_rule_set\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1416
|
+
end
|
|
1417
|
+
return data, status_code, headers
|
|
1418
|
+
end
|
|
1419
|
+
end
|
|
1420
|
+
end
|