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,580 @@
|
|
|
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 AiRuntimeControlVirtualKeysApi
|
|
15
|
+
attr_accessor :api_client
|
|
16
|
+
|
|
17
|
+
def initialize(api_client = ApiClient.default)
|
|
18
|
+
@api_client = api_client
|
|
19
|
+
end
|
|
20
|
+
# Create a virtual key
|
|
21
|
+
# Create a new virtual key for authenticating requests through the AI Runtime Control gateway.
|
|
22
|
+
# @option opts [ArcVirtualKey] :arc_virtual_key (required)
|
|
23
|
+
# @return [ArcCreateVirtualKeyResponse]
|
|
24
|
+
def arc_create_virtual_key(opts = {})
|
|
25
|
+
data, _status_code, _headers = arc_create_virtual_key_with_http_info(opts)
|
|
26
|
+
data
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
# Create a virtual key
|
|
30
|
+
# Create a new virtual key for authenticating requests through the AI Runtime Control gateway.
|
|
31
|
+
# @option opts [ArcVirtualKey] :arc_virtual_key (required)
|
|
32
|
+
# @return [Array<(ArcCreateVirtualKeyResponse, Integer, Hash)>] ArcCreateVirtualKeyResponse data, response status code and response headers
|
|
33
|
+
def arc_create_virtual_key_with_http_info(opts = {})
|
|
34
|
+
if @api_client.config.debugging
|
|
35
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_create_virtual_key ...'
|
|
36
|
+
end
|
|
37
|
+
# unbox the parameters from the hash
|
|
38
|
+
arc_virtual_key = opts[:'arc_virtual_key']
|
|
39
|
+
# verify the required parameter 'arc_virtual_key' is set
|
|
40
|
+
if @api_client.config.client_side_validation && arc_virtual_key.nil?
|
|
41
|
+
fail ArgumentError, "Missing the required parameter 'arc_virtual_key' when calling AiRuntimeControlVirtualKeysApi.arc_create_virtual_key"
|
|
42
|
+
end
|
|
43
|
+
# resource path
|
|
44
|
+
local_var_path = '/ai-runtime-control/v1/keys'
|
|
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(arc_virtual_key)
|
|
64
|
+
|
|
65
|
+
# return_type
|
|
66
|
+
return_type = opts[:debug_return_type] || 'ArcCreateVirtualKeyResponse'
|
|
67
|
+
|
|
68
|
+
# auth_names
|
|
69
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
70
|
+
|
|
71
|
+
new_options = opts.merge(
|
|
72
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_create_virtual_key",
|
|
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: AiRuntimeControlVirtualKeysApi#arc_create_virtual_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
84
|
+
end
|
|
85
|
+
return data, status_code, headers
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
# Delete a virtual key
|
|
89
|
+
# Delete a virtual key. This also deletes any security configuration associated with the key.
|
|
90
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
91
|
+
# @return [nil]
|
|
92
|
+
def arc_delete_virtual_key(opts = {})
|
|
93
|
+
arc_delete_virtual_key_with_http_info(opts)
|
|
94
|
+
nil
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
# Delete a virtual key
|
|
98
|
+
# Delete a virtual key. This also deletes any security configuration associated with the key.
|
|
99
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
100
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
101
|
+
def arc_delete_virtual_key_with_http_info(opts = {})
|
|
102
|
+
if @api_client.config.debugging
|
|
103
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_delete_virtual_key ...'
|
|
104
|
+
end
|
|
105
|
+
# unbox the parameters from the hash
|
|
106
|
+
key_id = opts[:'key_id']
|
|
107
|
+
# verify the required parameter 'key_id' is set
|
|
108
|
+
if @api_client.config.client_side_validation && key_id.nil?
|
|
109
|
+
fail ArgumentError, "Missing the required parameter 'key_id' when calling AiRuntimeControlVirtualKeysApi.arc_delete_virtual_key"
|
|
110
|
+
end
|
|
111
|
+
# resource path
|
|
112
|
+
local_var_path = '/ai-runtime-control/v1/keys/{key_id}'.sub('{' + 'key_id' + '}', CGI.escape(key_id.to_s))
|
|
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/problem+json'])
|
|
121
|
+
|
|
122
|
+
# form parameters
|
|
123
|
+
form_params = opts[:form_params] || {}
|
|
124
|
+
|
|
125
|
+
# http body (model)
|
|
126
|
+
post_body = opts[:debug_body]
|
|
127
|
+
|
|
128
|
+
# return_type
|
|
129
|
+
return_type = opts[:debug_return_type]
|
|
130
|
+
|
|
131
|
+
# auth_names
|
|
132
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
133
|
+
|
|
134
|
+
new_options = opts.merge(
|
|
135
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_delete_virtual_key",
|
|
136
|
+
:header_params => header_params,
|
|
137
|
+
:query_params => query_params,
|
|
138
|
+
:form_params => form_params,
|
|
139
|
+
:body => post_body,
|
|
140
|
+
:auth_names => auth_names,
|
|
141
|
+
:return_type => return_type
|
|
142
|
+
)
|
|
143
|
+
|
|
144
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
145
|
+
if @api_client.config.debugging
|
|
146
|
+
@api_client.config.logger.debug "API called: AiRuntimeControlVirtualKeysApi#arc_delete_virtual_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
147
|
+
end
|
|
148
|
+
return data, status_code, headers
|
|
149
|
+
end
|
|
150
|
+
|
|
151
|
+
# Get a virtual key
|
|
152
|
+
# Retrieve a single virtual key.
|
|
153
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
154
|
+
# @return [ArcVirtualKeyResponse]
|
|
155
|
+
def arc_get_virtual_key(opts = {})
|
|
156
|
+
data, _status_code, _headers = arc_get_virtual_key_with_http_info(opts)
|
|
157
|
+
data
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
# Get a virtual key
|
|
161
|
+
# Retrieve a single virtual key.
|
|
162
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
163
|
+
# @return [Array<(ArcVirtualKeyResponse, Integer, Hash)>] ArcVirtualKeyResponse data, response status code and response headers
|
|
164
|
+
def arc_get_virtual_key_with_http_info(opts = {})
|
|
165
|
+
if @api_client.config.debugging
|
|
166
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_get_virtual_key ...'
|
|
167
|
+
end
|
|
168
|
+
# unbox the parameters from the hash
|
|
169
|
+
key_id = opts[:'key_id']
|
|
170
|
+
# verify the required parameter 'key_id' is set
|
|
171
|
+
if @api_client.config.client_side_validation && key_id.nil?
|
|
172
|
+
fail ArgumentError, "Missing the required parameter 'key_id' when calling AiRuntimeControlVirtualKeysApi.arc_get_virtual_key"
|
|
173
|
+
end
|
|
174
|
+
# resource path
|
|
175
|
+
local_var_path = '/ai-runtime-control/v1/keys/{key_id}'.sub('{' + 'key_id' + '}', CGI.escape(key_id.to_s))
|
|
176
|
+
|
|
177
|
+
# query parameters
|
|
178
|
+
query_params = opts[:query_params] || {}
|
|
179
|
+
|
|
180
|
+
# header parameters
|
|
181
|
+
header_params = opts[:header_params] || {}
|
|
182
|
+
# HTTP header 'Accept' (if needed)
|
|
183
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
184
|
+
|
|
185
|
+
# form parameters
|
|
186
|
+
form_params = opts[:form_params] || {}
|
|
187
|
+
|
|
188
|
+
# http body (model)
|
|
189
|
+
post_body = opts[:debug_body]
|
|
190
|
+
|
|
191
|
+
# return_type
|
|
192
|
+
return_type = opts[:debug_return_type] || 'ArcVirtualKeyResponse'
|
|
193
|
+
|
|
194
|
+
# auth_names
|
|
195
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
196
|
+
|
|
197
|
+
new_options = opts.merge(
|
|
198
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_get_virtual_key",
|
|
199
|
+
:header_params => header_params,
|
|
200
|
+
:query_params => query_params,
|
|
201
|
+
:form_params => form_params,
|
|
202
|
+
:body => post_body,
|
|
203
|
+
:auth_names => auth_names,
|
|
204
|
+
:return_type => return_type
|
|
205
|
+
)
|
|
206
|
+
|
|
207
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
208
|
+
if @api_client.config.debugging
|
|
209
|
+
@api_client.config.logger.debug "API called: AiRuntimeControlVirtualKeysApi#arc_get_virtual_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
210
|
+
end
|
|
211
|
+
return data, status_code, headers
|
|
212
|
+
end
|
|
213
|
+
|
|
214
|
+
# Get a virtual key's failover policy
|
|
215
|
+
# Retrieve the failover policy for a virtual key. A failover policy lists alternate provider connections to retry a request against, and which error conditions trigger a retry. Failover is a per-account feature. If it isn't enabled on your account, this endpoint returns a 404 response.
|
|
216
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
217
|
+
# @return [ArcVirtualKeyFailoverResponse]
|
|
218
|
+
def arc_get_virtual_key_failover(opts = {})
|
|
219
|
+
data, _status_code, _headers = arc_get_virtual_key_failover_with_http_info(opts)
|
|
220
|
+
data
|
|
221
|
+
end
|
|
222
|
+
|
|
223
|
+
# Get a virtual key's failover policy
|
|
224
|
+
# Retrieve the failover policy for a virtual key. A failover policy lists alternate provider connections to retry a request against, and which error conditions trigger a retry. Failover is a per-account feature. If it isn't enabled on your account, this endpoint returns a 404 response.
|
|
225
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
226
|
+
# @return [Array<(ArcVirtualKeyFailoverResponse, Integer, Hash)>] ArcVirtualKeyFailoverResponse data, response status code and response headers
|
|
227
|
+
def arc_get_virtual_key_failover_with_http_info(opts = {})
|
|
228
|
+
if @api_client.config.debugging
|
|
229
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_get_virtual_key_failover ...'
|
|
230
|
+
end
|
|
231
|
+
# unbox the parameters from the hash
|
|
232
|
+
key_id = opts[:'key_id']
|
|
233
|
+
# verify the required parameter 'key_id' is set
|
|
234
|
+
if @api_client.config.client_side_validation && key_id.nil?
|
|
235
|
+
fail ArgumentError, "Missing the required parameter 'key_id' when calling AiRuntimeControlVirtualKeysApi.arc_get_virtual_key_failover"
|
|
236
|
+
end
|
|
237
|
+
# resource path
|
|
238
|
+
local_var_path = '/ai-runtime-control/v1/keys/{key_id}/failover'.sub('{' + 'key_id' + '}', CGI.escape(key_id.to_s))
|
|
239
|
+
|
|
240
|
+
# query parameters
|
|
241
|
+
query_params = opts[:query_params] || {}
|
|
242
|
+
|
|
243
|
+
# header parameters
|
|
244
|
+
header_params = opts[:header_params] || {}
|
|
245
|
+
# HTTP header 'Accept' (if needed)
|
|
246
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
247
|
+
|
|
248
|
+
# form parameters
|
|
249
|
+
form_params = opts[:form_params] || {}
|
|
250
|
+
|
|
251
|
+
# http body (model)
|
|
252
|
+
post_body = opts[:debug_body]
|
|
253
|
+
|
|
254
|
+
# return_type
|
|
255
|
+
return_type = opts[:debug_return_type] || 'ArcVirtualKeyFailoverResponse'
|
|
256
|
+
|
|
257
|
+
# auth_names
|
|
258
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
259
|
+
|
|
260
|
+
new_options = opts.merge(
|
|
261
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_get_virtual_key_failover",
|
|
262
|
+
:header_params => header_params,
|
|
263
|
+
:query_params => query_params,
|
|
264
|
+
:form_params => form_params,
|
|
265
|
+
:body => post_body,
|
|
266
|
+
:auth_names => auth_names,
|
|
267
|
+
:return_type => return_type
|
|
268
|
+
)
|
|
269
|
+
|
|
270
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
271
|
+
if @api_client.config.debugging
|
|
272
|
+
@api_client.config.logger.debug "API called: AiRuntimeControlVirtualKeysApi#arc_get_virtual_key_failover\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
273
|
+
end
|
|
274
|
+
return data, status_code, headers
|
|
275
|
+
end
|
|
276
|
+
|
|
277
|
+
# List virtual keys
|
|
278
|
+
# List the virtual keys belonging to your account.
|
|
279
|
+
# @option opts [Boolean] :include_deleted Include deleted virtual keys in the results. (default to false)
|
|
280
|
+
# @option opts [String] :search Filter results to virtual keys whose name contains this substring.
|
|
281
|
+
# @option opts [String] :cursor Cursor for pagination. Use the `next_cursor` value from a previous response to request the next page of results, or the `prev_cursor` value to request the previous page.
|
|
282
|
+
# @option opts [Integer] :limit Limit how many results are returned. (default to 10)
|
|
283
|
+
# @option opts [String] :sort Sort field. Prefix with `-` for descending order (e.g., `sort=-created_at`). (default to 'created_at')
|
|
284
|
+
# @return [ArcVirtualKeysResponse]
|
|
285
|
+
def arc_list_virtual_keys(opts = {})
|
|
286
|
+
data, _status_code, _headers = arc_list_virtual_keys_with_http_info(opts)
|
|
287
|
+
data
|
|
288
|
+
end
|
|
289
|
+
|
|
290
|
+
# List virtual keys
|
|
291
|
+
# List the virtual keys belonging to your account.
|
|
292
|
+
# @option opts [Boolean] :include_deleted Include deleted virtual keys in the results. (default to false)
|
|
293
|
+
# @option opts [String] :search Filter results to virtual keys whose name contains this substring.
|
|
294
|
+
# @option opts [String] :cursor Cursor for pagination. Use the `next_cursor` value from a previous response to request the next page of results, or the `prev_cursor` value to request the previous page.
|
|
295
|
+
# @option opts [Integer] :limit Limit how many results are returned. (default to 10)
|
|
296
|
+
# @option opts [String] :sort Sort field. Prefix with `-` for descending order (e.g., `sort=-created_at`). (default to 'created_at')
|
|
297
|
+
# @return [Array<(ArcVirtualKeysResponse, Integer, Hash)>] ArcVirtualKeysResponse data, response status code and response headers
|
|
298
|
+
def arc_list_virtual_keys_with_http_info(opts = {})
|
|
299
|
+
if @api_client.config.debugging
|
|
300
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_list_virtual_keys ...'
|
|
301
|
+
end
|
|
302
|
+
# unbox the parameters from the hash
|
|
303
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
304
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling AiRuntimeControlVirtualKeysApi.arc_list_virtual_keys, must be smaller than or equal to 100.'
|
|
305
|
+
end
|
|
306
|
+
|
|
307
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
308
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling AiRuntimeControlVirtualKeysApi.arc_list_virtual_keys, must be greater than or equal to 1.'
|
|
309
|
+
end
|
|
310
|
+
|
|
311
|
+
allowable_values = ["created_at", "-created_at", "updated_at", "-updated_at", "name", "-name", "expires_at", "-expires_at", "user_name", "-user_name", "last_used_at", "-last_used_at"]
|
|
312
|
+
if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort'])
|
|
313
|
+
fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}"
|
|
314
|
+
end
|
|
315
|
+
# resource path
|
|
316
|
+
local_var_path = '/ai-runtime-control/v1/keys'
|
|
317
|
+
|
|
318
|
+
# query parameters
|
|
319
|
+
query_params = opts[:query_params] || {}
|
|
320
|
+
query_params[:'include_deleted'] = opts[:'include_deleted'] if !opts[:'include_deleted'].nil?
|
|
321
|
+
query_params[:'search'] = opts[:'search'] if !opts[:'search'].nil?
|
|
322
|
+
query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
|
|
323
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
324
|
+
query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
|
|
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/json', '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] || 'ArcVirtualKeysResponse'
|
|
339
|
+
|
|
340
|
+
# auth_names
|
|
341
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
342
|
+
|
|
343
|
+
new_options = opts.merge(
|
|
344
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_list_virtual_keys",
|
|
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(:GET, local_var_path, new_options)
|
|
354
|
+
if @api_client.config.debugging
|
|
355
|
+
@api_client.config.logger.debug "API called: AiRuntimeControlVirtualKeysApi#arc_list_virtual_keys\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
356
|
+
end
|
|
357
|
+
return data, status_code, headers
|
|
358
|
+
end
|
|
359
|
+
|
|
360
|
+
# Rotate a virtual key
|
|
361
|
+
# Issue a new access token for a virtual key, invalidating the previous one.
|
|
362
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
363
|
+
# @option opts [ArcRotateVirtualKeyRequest] :arc_rotate_virtual_key_request
|
|
364
|
+
# @return [ArcRotateVirtualKeyResponse]
|
|
365
|
+
def arc_rotate_virtual_key(opts = {})
|
|
366
|
+
data, _status_code, _headers = arc_rotate_virtual_key_with_http_info(opts)
|
|
367
|
+
data
|
|
368
|
+
end
|
|
369
|
+
|
|
370
|
+
# Rotate a virtual key
|
|
371
|
+
# Issue a new access token for a virtual key, invalidating the previous one.
|
|
372
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
373
|
+
# @option opts [ArcRotateVirtualKeyRequest] :arc_rotate_virtual_key_request
|
|
374
|
+
# @return [Array<(ArcRotateVirtualKeyResponse, Integer, Hash)>] ArcRotateVirtualKeyResponse data, response status code and response headers
|
|
375
|
+
def arc_rotate_virtual_key_with_http_info(opts = {})
|
|
376
|
+
if @api_client.config.debugging
|
|
377
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_rotate_virtual_key ...'
|
|
378
|
+
end
|
|
379
|
+
# unbox the parameters from the hash
|
|
380
|
+
key_id = opts[:'key_id']
|
|
381
|
+
# verify the required parameter 'key_id' is set
|
|
382
|
+
if @api_client.config.client_side_validation && key_id.nil?
|
|
383
|
+
fail ArgumentError, "Missing the required parameter 'key_id' when calling AiRuntimeControlVirtualKeysApi.arc_rotate_virtual_key"
|
|
384
|
+
end
|
|
385
|
+
# resource path
|
|
386
|
+
local_var_path = '/ai-runtime-control/v1/keys/{key_id}/rotate'.sub('{' + 'key_id' + '}', CGI.escape(key_id.to_s))
|
|
387
|
+
|
|
388
|
+
# query parameters
|
|
389
|
+
query_params = opts[:query_params] || {}
|
|
390
|
+
|
|
391
|
+
# header parameters
|
|
392
|
+
header_params = opts[:header_params] || {}
|
|
393
|
+
# HTTP header 'Accept' (if needed)
|
|
394
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
395
|
+
# HTTP header 'Content-Type'
|
|
396
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
397
|
+
if !content_type.nil?
|
|
398
|
+
header_params['Content-Type'] = content_type
|
|
399
|
+
end
|
|
400
|
+
|
|
401
|
+
# form parameters
|
|
402
|
+
form_params = opts[:form_params] || {}
|
|
403
|
+
|
|
404
|
+
# http body (model)
|
|
405
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'arc_rotate_virtual_key_request'])
|
|
406
|
+
|
|
407
|
+
# return_type
|
|
408
|
+
return_type = opts[:debug_return_type] || 'ArcRotateVirtualKeyResponse'
|
|
409
|
+
|
|
410
|
+
# auth_names
|
|
411
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
412
|
+
|
|
413
|
+
new_options = opts.merge(
|
|
414
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_rotate_virtual_key",
|
|
415
|
+
:header_params => header_params,
|
|
416
|
+
:query_params => query_params,
|
|
417
|
+
:form_params => form_params,
|
|
418
|
+
:body => post_body,
|
|
419
|
+
:auth_names => auth_names,
|
|
420
|
+
:return_type => return_type
|
|
421
|
+
)
|
|
422
|
+
|
|
423
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
424
|
+
if @api_client.config.debugging
|
|
425
|
+
@api_client.config.logger.debug "API called: AiRuntimeControlVirtualKeysApi#arc_rotate_virtual_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
426
|
+
end
|
|
427
|
+
return data, status_code, headers
|
|
428
|
+
end
|
|
429
|
+
|
|
430
|
+
# Update a virtual key
|
|
431
|
+
# Update the attributes of a virtual key. Only the fields you include are changed.
|
|
432
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
433
|
+
# @option opts [ArcUpdateVirtualKeyRequest] :arc_update_virtual_key_request (required)
|
|
434
|
+
# @return [ArcUpdateVirtualKeyResponse]
|
|
435
|
+
def arc_update_virtual_key(opts = {})
|
|
436
|
+
data, _status_code, _headers = arc_update_virtual_key_with_http_info(opts)
|
|
437
|
+
data
|
|
438
|
+
end
|
|
439
|
+
|
|
440
|
+
# Update a virtual key
|
|
441
|
+
# Update the attributes of a virtual key. Only the fields you include are changed.
|
|
442
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
443
|
+
# @option opts [ArcUpdateVirtualKeyRequest] :arc_update_virtual_key_request (required)
|
|
444
|
+
# @return [Array<(ArcUpdateVirtualKeyResponse, Integer, Hash)>] ArcUpdateVirtualKeyResponse data, response status code and response headers
|
|
445
|
+
def arc_update_virtual_key_with_http_info(opts = {})
|
|
446
|
+
if @api_client.config.debugging
|
|
447
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_update_virtual_key ...'
|
|
448
|
+
end
|
|
449
|
+
# unbox the parameters from the hash
|
|
450
|
+
key_id = opts[:'key_id']
|
|
451
|
+
arc_update_virtual_key_request = opts[:'arc_update_virtual_key_request']
|
|
452
|
+
# verify the required parameter 'key_id' is set
|
|
453
|
+
if @api_client.config.client_side_validation && key_id.nil?
|
|
454
|
+
fail ArgumentError, "Missing the required parameter 'key_id' when calling AiRuntimeControlVirtualKeysApi.arc_update_virtual_key"
|
|
455
|
+
end
|
|
456
|
+
# verify the required parameter 'arc_update_virtual_key_request' is set
|
|
457
|
+
if @api_client.config.client_side_validation && arc_update_virtual_key_request.nil?
|
|
458
|
+
fail ArgumentError, "Missing the required parameter 'arc_update_virtual_key_request' when calling AiRuntimeControlVirtualKeysApi.arc_update_virtual_key"
|
|
459
|
+
end
|
|
460
|
+
# resource path
|
|
461
|
+
local_var_path = '/ai-runtime-control/v1/keys/{key_id}'.sub('{' + 'key_id' + '}', CGI.escape(key_id.to_s))
|
|
462
|
+
|
|
463
|
+
# query parameters
|
|
464
|
+
query_params = opts[:query_params] || {}
|
|
465
|
+
|
|
466
|
+
# header parameters
|
|
467
|
+
header_params = opts[:header_params] || {}
|
|
468
|
+
# HTTP header 'Accept' (if needed)
|
|
469
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
470
|
+
# HTTP header 'Content-Type'
|
|
471
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
472
|
+
if !content_type.nil?
|
|
473
|
+
header_params['Content-Type'] = content_type
|
|
474
|
+
end
|
|
475
|
+
|
|
476
|
+
# form parameters
|
|
477
|
+
form_params = opts[:form_params] || {}
|
|
478
|
+
|
|
479
|
+
# http body (model)
|
|
480
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(arc_update_virtual_key_request)
|
|
481
|
+
|
|
482
|
+
# return_type
|
|
483
|
+
return_type = opts[:debug_return_type] || 'ArcUpdateVirtualKeyResponse'
|
|
484
|
+
|
|
485
|
+
# auth_names
|
|
486
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
487
|
+
|
|
488
|
+
new_options = opts.merge(
|
|
489
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_update_virtual_key",
|
|
490
|
+
:header_params => header_params,
|
|
491
|
+
:query_params => query_params,
|
|
492
|
+
:form_params => form_params,
|
|
493
|
+
:body => post_body,
|
|
494
|
+
:auth_names => auth_names,
|
|
495
|
+
:return_type => return_type
|
|
496
|
+
)
|
|
497
|
+
|
|
498
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
|
499
|
+
if @api_client.config.debugging
|
|
500
|
+
@api_client.config.logger.debug "API called: AiRuntimeControlVirtualKeysApi#arc_update_virtual_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
501
|
+
end
|
|
502
|
+
return data, status_code, headers
|
|
503
|
+
end
|
|
504
|
+
|
|
505
|
+
# Update a virtual key's failover policy
|
|
506
|
+
# Replace the failover policy for a virtual key. Failover is a per-account feature. If it isn't enabled on your account, this endpoint returns a 404 response.
|
|
507
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
508
|
+
# @option opts [ArcVirtualKeyFailoverRequest] :arc_virtual_key_failover_request (required)
|
|
509
|
+
# @return [ArcVirtualKeyFailoverResponse]
|
|
510
|
+
def arc_update_virtual_key_failover(opts = {})
|
|
511
|
+
data, _status_code, _headers = arc_update_virtual_key_failover_with_http_info(opts)
|
|
512
|
+
data
|
|
513
|
+
end
|
|
514
|
+
|
|
515
|
+
# Update a virtual key's failover policy
|
|
516
|
+
# Replace the failover policy for a virtual key. Failover is a per-account feature. If it isn't enabled on your account, this endpoint returns a 404 response.
|
|
517
|
+
# @option opts [String] :key_id The ID of the virtual key. (required)
|
|
518
|
+
# @option opts [ArcVirtualKeyFailoverRequest] :arc_virtual_key_failover_request (required)
|
|
519
|
+
# @return [Array<(ArcVirtualKeyFailoverResponse, Integer, Hash)>] ArcVirtualKeyFailoverResponse data, response status code and response headers
|
|
520
|
+
def arc_update_virtual_key_failover_with_http_info(opts = {})
|
|
521
|
+
if @api_client.config.debugging
|
|
522
|
+
@api_client.config.logger.debug 'Calling API: AiRuntimeControlVirtualKeysApi.arc_update_virtual_key_failover ...'
|
|
523
|
+
end
|
|
524
|
+
# unbox the parameters from the hash
|
|
525
|
+
key_id = opts[:'key_id']
|
|
526
|
+
arc_virtual_key_failover_request = opts[:'arc_virtual_key_failover_request']
|
|
527
|
+
# verify the required parameter 'key_id' is set
|
|
528
|
+
if @api_client.config.client_side_validation && key_id.nil?
|
|
529
|
+
fail ArgumentError, "Missing the required parameter 'key_id' when calling AiRuntimeControlVirtualKeysApi.arc_update_virtual_key_failover"
|
|
530
|
+
end
|
|
531
|
+
# verify the required parameter 'arc_virtual_key_failover_request' is set
|
|
532
|
+
if @api_client.config.client_side_validation && arc_virtual_key_failover_request.nil?
|
|
533
|
+
fail ArgumentError, "Missing the required parameter 'arc_virtual_key_failover_request' when calling AiRuntimeControlVirtualKeysApi.arc_update_virtual_key_failover"
|
|
534
|
+
end
|
|
535
|
+
# resource path
|
|
536
|
+
local_var_path = '/ai-runtime-control/v1/keys/{key_id}/failover'.sub('{' + 'key_id' + '}', CGI.escape(key_id.to_s))
|
|
537
|
+
|
|
538
|
+
# query parameters
|
|
539
|
+
query_params = opts[:query_params] || {}
|
|
540
|
+
|
|
541
|
+
# header parameters
|
|
542
|
+
header_params = opts[:header_params] || {}
|
|
543
|
+
# HTTP header 'Accept' (if needed)
|
|
544
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
545
|
+
# HTTP header 'Content-Type'
|
|
546
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
547
|
+
if !content_type.nil?
|
|
548
|
+
header_params['Content-Type'] = content_type
|
|
549
|
+
end
|
|
550
|
+
|
|
551
|
+
# form parameters
|
|
552
|
+
form_params = opts[:form_params] || {}
|
|
553
|
+
|
|
554
|
+
# http body (model)
|
|
555
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(arc_virtual_key_failover_request)
|
|
556
|
+
|
|
557
|
+
# return_type
|
|
558
|
+
return_type = opts[:debug_return_type] || 'ArcVirtualKeyFailoverResponse'
|
|
559
|
+
|
|
560
|
+
# auth_names
|
|
561
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
562
|
+
|
|
563
|
+
new_options = opts.merge(
|
|
564
|
+
:operation => :"AiRuntimeControlVirtualKeysApi.arc_update_virtual_key_failover",
|
|
565
|
+
:header_params => header_params,
|
|
566
|
+
:query_params => query_params,
|
|
567
|
+
:form_params => form_params,
|
|
568
|
+
:body => post_body,
|
|
569
|
+
:auth_names => auth_names,
|
|
570
|
+
:return_type => return_type
|
|
571
|
+
)
|
|
572
|
+
|
|
573
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
|
574
|
+
if @api_client.config.debugging
|
|
575
|
+
@api_client.config.logger.debug "API called: AiRuntimeControlVirtualKeysApi#arc_update_virtual_key_failover\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
576
|
+
end
|
|
577
|
+
return data, status_code, headers
|
|
578
|
+
end
|
|
579
|
+
end
|
|
580
|
+
end
|
|
@@ -44,7 +44,7 @@ module Fastly
|
|
|
44
44
|
# header parameters
|
|
45
45
|
header_params = opts[:header_params] || {}
|
|
46
46
|
# HTTP header 'Accept' (if needed)
|
|
47
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
47
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
48
48
|
# HTTP header 'Content-Type'
|
|
49
49
|
content_type = @api_client.select_header_content_type(['application/json'])
|
|
50
50
|
if !content_type.nil?
|
|
@@ -212,6 +212,83 @@ module Fastly
|
|
|
212
212
|
return data, status_code, headers
|
|
213
213
|
end
|
|
214
214
|
|
|
215
|
+
# List Automation Token Workspaces
|
|
216
|
+
# Lists the Next-Gen WAF workspaces accessible by an automation token. Only applicable for tokens with roles that support workspace access (such as Next-Gen WAF roles).
|
|
217
|
+
# @option opts [String] :id The alphanumeric string identifying the automation token. (required)
|
|
218
|
+
# @option opts [Integer] :limit Maximum number of workspaces to return per page. (default to 20)
|
|
219
|
+
# @option opts [String] :cursor Pagination cursor from a previous response. Pass the `next_cursor` value to retrieve the next page, or `previous_cursor` to go back.
|
|
220
|
+
# @return [AutomationTokenWorkspacesResponse]
|
|
221
|
+
def get_automation_tokens_id_workspaces(opts = {})
|
|
222
|
+
data, _status_code, _headers = get_automation_tokens_id_workspaces_with_http_info(opts)
|
|
223
|
+
data
|
|
224
|
+
end
|
|
225
|
+
|
|
226
|
+
# List Automation Token Workspaces
|
|
227
|
+
# Lists the Next-Gen WAF workspaces accessible by an automation token. Only applicable for tokens with roles that support workspace access (such as Next-Gen WAF roles).
|
|
228
|
+
# @option opts [String] :id The alphanumeric string identifying the automation token. (required)
|
|
229
|
+
# @option opts [Integer] :limit Maximum number of workspaces to return per page. (default to 20)
|
|
230
|
+
# @option opts [String] :cursor Pagination cursor from a previous response. Pass the `next_cursor` value to retrieve the next page, or `previous_cursor` to go back.
|
|
231
|
+
# @return [Array<(AutomationTokenWorkspacesResponse, Integer, Hash)>] AutomationTokenWorkspacesResponse data, response status code and response headers
|
|
232
|
+
def get_automation_tokens_id_workspaces_with_http_info(opts = {})
|
|
233
|
+
if @api_client.config.debugging
|
|
234
|
+
@api_client.config.logger.debug 'Calling API: AutomationTokensApi.get_automation_tokens_id_workspaces ...'
|
|
235
|
+
end
|
|
236
|
+
# unbox the parameters from the hash
|
|
237
|
+
id = opts[:'id']
|
|
238
|
+
# verify the required parameter 'id' is set
|
|
239
|
+
if @api_client.config.client_side_validation && id.nil?
|
|
240
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling AutomationTokensApi.get_automation_tokens_id_workspaces"
|
|
241
|
+
end
|
|
242
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
243
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling AutomationTokensApi.get_automation_tokens_id_workspaces, must be smaller than or equal to 100.'
|
|
244
|
+
end
|
|
245
|
+
|
|
246
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
247
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling AutomationTokensApi.get_automation_tokens_id_workspaces, must be greater than or equal to 1.'
|
|
248
|
+
end
|
|
249
|
+
|
|
250
|
+
# resource path
|
|
251
|
+
local_var_path = '/automation-tokens/{id}/workspaces'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
|
252
|
+
|
|
253
|
+
# query parameters
|
|
254
|
+
query_params = opts[:query_params] || {}
|
|
255
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
256
|
+
query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
|
|
257
|
+
|
|
258
|
+
# header parameters
|
|
259
|
+
header_params = opts[:header_params] || {}
|
|
260
|
+
# HTTP header 'Accept' (if needed)
|
|
261
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
|
262
|
+
|
|
263
|
+
# form parameters
|
|
264
|
+
form_params = opts[:form_params] || {}
|
|
265
|
+
|
|
266
|
+
# http body (model)
|
|
267
|
+
post_body = opts[:debug_body]
|
|
268
|
+
|
|
269
|
+
# return_type
|
|
270
|
+
return_type = opts[:debug_return_type] || 'AutomationTokenWorkspacesResponse'
|
|
271
|
+
|
|
272
|
+
# auth_names
|
|
273
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
|
274
|
+
|
|
275
|
+
new_options = opts.merge(
|
|
276
|
+
:operation => :"AutomationTokensApi.get_automation_tokens_id_workspaces",
|
|
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(:GET, local_var_path, new_options)
|
|
286
|
+
if @api_client.config.debugging
|
|
287
|
+
@api_client.config.logger.debug "API called: AutomationTokensApi#get_automation_tokens_id_workspaces\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
288
|
+
end
|
|
289
|
+
return data, status_code, headers
|
|
290
|
+
end
|
|
291
|
+
|
|
215
292
|
# List Customer Automation Tokens
|
|
216
293
|
# Lists all automation tokens for a customer.
|
|
217
294
|
# @option opts [Integer] :per_page
|