fastly 5.3.1 → 6.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +63 -0
- data/Gemfile.lock +1 -1
- data/README.md +85 -63
- data/docs/AclEntry.md +1 -1
- data/docs/AclEntryApi.md +176 -0
- data/docs/AclEntryResponse.md +1 -1
- data/docs/ApexRedirectApi.md +56 -0
- data/docs/{BillingEstimateResponseAllOfLines.md → BillingEstimateLines.md} +2 -2
- data/docs/{BillingEstimateResponseAllOfLine.md → BillingEstimateLinesLineItems.md} +1 -1
- data/docs/BillingEstimateResponse.md +1 -1
- data/docs/{BillingResponseAllOf.md → BillingResponseItemItemsData.md} +1 -1
- data/docs/BillingResponseLineItem.md +1 -1
- data/docs/BillingStatus.md +1 -1
- data/docs/BulkUpdateAclEntry.md +1 -1
- data/docs/ClientKey.md +12 -0
- data/docs/ContactApi.md +50 -0
- data/docs/Content.md +2 -2
- data/docs/ContentApi.md +52 -0
- data/docs/DirectorApi.md +42 -0
- data/docs/DomainInspector.md +12 -0
- data/docs/DomainInspectorEntry.md +11 -0
- data/docs/DomainInspectorEntryDimensions.md +12 -0
- data/docs/DomainInspectorHistoricalApi.md +72 -0
- data/docs/DomainInspectorMeasurements.md +71 -0
- data/docs/DomainInspectorRealtimeApi.md +132 -0
- data/docs/DomainInspectorRealtimeEntry.md +12 -0
- data/docs/EventAttributes.md +1 -1
- data/docs/{EventsResponseAllOf.md → EventData.md} +1 -1
- data/docs/HistoricalDomains.md +13 -0
- data/docs/HistoricalDomainsData.md +11 -0
- data/docs/HistoricalDomainsMeta.md +18 -0
- data/docs/HistoricalDomainsMetaFilters.md +12 -0
- data/docs/HistoricalDomainsResponse.md +13 -0
- data/docs/HistoricalDomainsResponseAllOf.md +10 -0
- data/docs/{HistoricalFieldResultsAttributesAllOf.md → HistoricalFieldResultsAttributesAdditional.md} +1 -1
- data/docs/HistoricalOriginsResponse.md +13 -0
- data/docs/HistoricalOriginsResponseAllOf.md +10 -0
- data/docs/IamRolesApi.md +157 -0
- data/docs/IamServiceGroupsApi.md +157 -0
- data/docs/IamUserGroupsApi.md +315 -0
- data/docs/InlineResponse2005.md +11 -0
- data/docs/InlineResponse2006.md +11 -0
- data/docs/{BillingEstimateResponseAllOf.md → InlineResponse2007.md} +2 -2
- data/docs/InlineResponse400.md +10 -0
- data/docs/LegacyWafConfigurationSet.md +11 -0
- data/docs/LegacyWafConfigurationSetsApi.md +125 -0
- data/docs/LegacyWafFirewall.md +18 -0
- data/docs/LegacyWafFirewallApi.md +352 -0
- data/docs/LegacyWafOwasp.md +38 -0
- data/docs/LegacyWafOwaspApi.md +138 -0
- data/docs/LegacyWafRule.md +14 -0
- data/docs/LegacyWafRuleApi.md +184 -0
- data/docs/LegacyWafRuleStatus.md +12 -0
- data/docs/LegacyWafRuleStatusApi.md +202 -0
- data/docs/LegacyWafRuleset.md +11 -0
- data/docs/LegacyWafRulesetApi.md +136 -0
- data/docs/LegacyWafTag.md +10 -0
- data/docs/LegacyWafTagApi.md +58 -0
- data/docs/LegacyWafUpdateStatus.md +15 -0
- data/docs/LegacyWafUpdateStatusApi.md +102 -0
- data/docs/{BillingResponseLineItemAllOf.md → LineItemData.md} +2 -2
- data/docs/LineItemDataReadOnlyInvoiceId.md +9 -0
- data/docs/LoggingKafkaApi.md +42 -0
- data/docs/LoggingKinesisApi.md +42 -0
- data/docs/OriginInspector.md +12 -0
- data/docs/OriginInspectorDimensions.md +12 -0
- data/docs/OriginInspectorEntry.md +11 -0
- data/docs/OriginInspectorHistorical.md +13 -0
- data/docs/OriginInspectorHistoricalApi.md +72 -0
- data/docs/OriginInspectorHistoricalData.md +11 -0
- data/docs/OriginInspectorHistoricalMeta.md +18 -0
- data/docs/OriginInspectorHistoricalMetaFilters.md +12 -0
- data/docs/OriginInspectorMeasurements.md +161 -0
- data/docs/OriginInspectorRealtimeApi.md +132 -0
- data/docs/OriginInspectorRealtimeEntry.md +12 -0
- data/docs/OriginInspectorRealtimeEntryRecorded.md +9 -0
- data/docs/OriginInspectorSubsequentRequestTimestamp.md +9 -0
- data/docs/OriginInspectorValues.md +161 -0
- data/docs/PaginationCursorMeta.md +11 -0
- data/docs/ReadOnlyServiceId.md +9 -0
- data/docs/ReadOnlyVersion.md +9 -0
- data/docs/RealtimeEntry.md +2 -2
- data/docs/RealtimeEntryAggregated.md +227 -0
- data/docs/RealtimeEntryRecorded.md +9 -0
- data/docs/RealtimeMeasurements.md +1 -1
- data/docs/RecordedTimestamp.md +9 -0
- data/docs/RequestSettingsApi.md +40 -0
- data/docs/ResponseObjectApi.md +82 -0
- data/docs/SchemasUserResponseReadOnly.md +12 -0
- data/docs/Secret.md +12 -0
- data/docs/SecretResponse.md +13 -0
- data/docs/SecretStore.md +10 -0
- data/docs/SecretStoreApi.md +233 -0
- data/docs/SecretStoreItemApi.md +255 -0
- data/docs/SecretStoreResponse.md +12 -0
- data/docs/ServiceAuthorizationsApi.md +76 -0
- data/docs/SigningKey.md +10 -0
- data/docs/SnippetApi.md +42 -0
- data/docs/SubsequentRequestTimestamp.md +9 -0
- data/docs/SudoApi.md +52 -0
- data/docs/SudoGenericTokenError.md +10 -0
- data/docs/SudoRequest.md +12 -0
- data/docs/SudoResponse.md +10 -0
- data/docs/TokensApi.md +70 -0
- data/docs/{UserResponseAllOf.md → UserResponseReadOnly.md} +1 -1
- data/docs/Values.md +71 -0
- data/docs/WafActiveRulesApi.md +41 -0
- data/lib/fastly/api/acl_entry_api.rb +332 -0
- data/lib/fastly/api/apex_redirect_api.rb +111 -0
- data/lib/fastly/api/contact_api.rb +90 -0
- data/lib/fastly/api/content_api.rb +79 -0
- data/lib/fastly/api/director_api.rb +82 -0
- data/lib/fastly/api/domain_inspector_historical_api.rb +125 -0
- data/lib/fastly/api/domain_inspector_realtime_api.rb +223 -0
- data/lib/fastly/api/iam_roles_api.rb +271 -0
- data/lib/fastly/api/iam_service_groups_api.rb +271 -0
- data/lib/fastly/api/iam_user_groups_api.rb +547 -0
- data/lib/fastly/api/legacy_waf_configuration_sets_api.rb +209 -0
- data/lib/fastly/api/legacy_waf_firewall_api.rb +627 -0
- data/lib/fastly/api/legacy_waf_owasp_api.rb +244 -0
- data/lib/fastly/api/legacy_waf_rule_api.rb +307 -0
- data/lib/fastly/api/legacy_waf_rule_status_api.rb +366 -0
- data/lib/fastly/api/legacy_waf_ruleset_api.rb +237 -0
- data/lib/fastly/api/legacy_waf_tag_api.rb +96 -0
- data/lib/fastly/api/legacy_waf_update_status_api.rb +184 -0
- data/lib/fastly/api/logging_kafka_api.rb +82 -0
- data/lib/fastly/api/logging_kinesis_api.rb +82 -0
- data/lib/fastly/api/origin_inspector_historical_api.rb +125 -0
- data/lib/fastly/api/origin_inspector_realtime_api.rb +223 -0
- data/lib/fastly/api/request_settings_api.rb +75 -0
- data/lib/fastly/api/response_object_api.rb +157 -0
- data/lib/fastly/api/secret_store_api.rb +381 -0
- data/lib/fastly/api/secret_store_item_api.rb +437 -0
- data/lib/fastly/api/service_authorizations_api.rb +126 -0
- data/lib/fastly/api/snippet_api.rb +82 -0
- data/lib/fastly/api/sudo_api.rb +83 -0
- data/lib/fastly/api/tokens_api.rb +122 -0
- data/lib/fastly/api/waf_active_rules_api.rb +75 -0
- data/lib/fastly/configuration.rb +504 -0
- data/lib/fastly/models/acl_entry.rb +1 -1
- data/lib/fastly/models/acl_entry_response.rb +1 -1
- data/lib/fastly/models/{billing_response_all_of.rb → billing_estimate_lines.rb} +4 -4
- data/lib/fastly/models/{billing_estimate_response_all_of_line.rb → billing_estimate_lines_line_items.rb} +3 -3
- data/lib/fastly/models/billing_estimate_response.rb +9 -9
- data/lib/fastly/models/billing_response.rb +1 -1
- data/lib/fastly/models/{billing_estimate_response_all_of.rb → billing_response_item_items_data.rb} +11 -11
- data/lib/fastly/models/billing_response_line_item.rb +2 -2
- data/lib/fastly/models/billing_status.rb +2 -0
- data/lib/fastly/models/bulk_update_acl_entry.rb +1 -1
- data/lib/fastly/models/client_key.rb +239 -0
- data/lib/fastly/models/content.rb +8 -4
- data/lib/fastly/models/domain.rb +1 -0
- data/lib/fastly/models/domain_inspector.rb +238 -0
- data/lib/fastly/models/domain_inspector_entry.rb +228 -0
- data/lib/fastly/models/domain_inspector_entry_dimensions.rb +238 -0
- data/lib/fastly/models/domain_inspector_measurements.rb +828 -0
- data/lib/fastly/models/domain_inspector_realtime_entry.rb +241 -0
- data/lib/fastly/models/event_attributes.rb +4 -2
- data/lib/fastly/models/{events_response_all_of.rb → event_data.rb} +3 -3
- data/lib/fastly/models/events_response.rb +1 -1
- data/lib/fastly/models/historical_domains.rb +249 -0
- data/lib/fastly/models/historical_domains_data.rb +228 -0
- data/lib/fastly/models/historical_domains_meta.rb +297 -0
- data/lib/fastly/models/historical_domains_meta_filters.rb +235 -0
- data/lib/fastly/models/historical_domains_response.rb +257 -0
- data/lib/fastly/models/historical_domains_response_all_of.rb +219 -0
- data/lib/fastly/models/historical_field_results_attributes.rb +1 -1
- data/lib/fastly/models/{historical_field_results_attributes_all_of.rb → historical_field_results_attributes_additional.rb} +3 -3
- data/lib/fastly/models/historical_origins_response.rb +257 -0
- data/lib/fastly/models/historical_origins_response_all_of.rb +219 -0
- data/lib/fastly/models/inline_response2005.rb +227 -0
- data/lib/fastly/models/inline_response2006.rb +227 -0
- data/lib/fastly/models/inline_response2007.rb +218 -0
- data/lib/fastly/models/inline_response400.rb +250 -0
- data/lib/fastly/models/legacy_waf_configuration_set.rb +227 -0
- data/lib/fastly/models/legacy_waf_firewall.rb +297 -0
- data/lib/fastly/models/legacy_waf_owasp.rb +527 -0
- data/lib/fastly/models/legacy_waf_rule.rb +257 -0
- data/lib/fastly/models/legacy_waf_rule_status.rb +237 -0
- data/lib/fastly/models/legacy_waf_ruleset.rb +227 -0
- data/lib/fastly/models/{billing_estimate_response_all_of_lines.rb → legacy_waf_tag.rb} +11 -10
- data/lib/fastly/models/legacy_waf_update_status.rb +267 -0
- data/lib/fastly/models/{billing_response_line_item_all_of.rb → line_item_data.rb} +4 -4
- data/lib/fastly/models/line_item_data_read_only_invoice_id.rb +207 -0
- data/lib/fastly/models/origin_inspector.rb +238 -0
- data/lib/fastly/models/origin_inspector_dimensions.rb +238 -0
- data/lib/fastly/models/origin_inspector_entry.rb +228 -0
- data/lib/fastly/models/origin_inspector_historical.rb +249 -0
- data/lib/fastly/models/origin_inspector_historical_data.rb +225 -0
- data/lib/fastly/models/origin_inspector_historical_meta.rb +297 -0
- data/lib/fastly/models/origin_inspector_historical_meta_filters.rb +235 -0
- data/lib/fastly/models/origin_inspector_measurements.rb +1728 -0
- data/lib/fastly/models/origin_inspector_realtime_entry.rb +241 -0
- data/lib/fastly/models/origin_inspector_realtime_entry_recorded.rb +208 -0
- data/lib/fastly/models/origin_inspector_subsequent_request_timestamp.rb +208 -0
- data/lib/fastly/models/origin_inspector_values.rb +1728 -0
- data/lib/fastly/models/pagination_cursor_meta.rb +227 -0
- data/lib/fastly/models/read_only_service_id.rb +207 -0
- data/lib/fastly/models/read_only_version.rb +207 -0
- data/lib/fastly/models/realtime_entry.rb +2 -7
- data/lib/fastly/models/realtime_entry_aggregated.rb +2397 -0
- data/lib/fastly/models/realtime_entry_recorded.rb +208 -0
- data/lib/fastly/models/realtime_measurements.rb +4 -2
- data/lib/fastly/models/recorded_timestamp.rb +208 -0
- data/lib/fastly/models/schemas_user_response.rb +5 -2
- data/lib/fastly/models/schemas_user_response_read_only.rb +235 -0
- data/lib/fastly/models/secret.rb +238 -0
- data/lib/fastly/models/secret_response.rb +249 -0
- data/lib/fastly/models/secret_store.rb +217 -0
- data/lib/fastly/models/secret_store_response.rb +238 -0
- data/lib/fastly/models/signing_key.rb +218 -0
- data/lib/fastly/models/subsequent_request_timestamp.rb +208 -0
- data/lib/fastly/models/sudo_generic_token_error.rb +216 -0
- data/lib/fastly/models/sudo_request.rb +244 -0
- data/lib/fastly/models/sudo_response.rb +217 -0
- data/lib/fastly/models/user.rb +3 -0
- data/lib/fastly/models/user_response.rb +4 -1
- data/lib/fastly/models/{user_response_all_of.rb → user_response_read_only.rb} +3 -3
- data/lib/fastly/models/values.rb +828 -0
- data/lib/fastly/version.rb +1 -1
- data/lib/fastly.rb +79 -8
- data/sig.json +1 -1
- metadata +160 -18
@@ -0,0 +1,223 @@
|
|
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://developer.fastly.com/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 DomainInspectorRealtimeApi
|
15
|
+
attr_accessor :api_client
|
16
|
+
|
17
|
+
def initialize(api_client = ApiClient.default)
|
18
|
+
@api_client = api_client
|
19
|
+
end
|
20
|
+
# Get real-time domain data for the last 120 seconds
|
21
|
+
# Get data for the 120 seconds preceding the latest timestamp available for a service.
|
22
|
+
# @option opts [String] :service_id Alphanumeric string identifying the service. (required)
|
23
|
+
# @return [DomainInspector]
|
24
|
+
def get_domain_inspector_last120_seconds(opts = {})
|
25
|
+
data, _status_code, _headers = get_domain_inspector_last120_seconds_with_http_info(opts)
|
26
|
+
data
|
27
|
+
end
|
28
|
+
|
29
|
+
# Get real-time domain data for the last 120 seconds
|
30
|
+
# Get data for the 120 seconds preceding the latest timestamp available for a service.
|
31
|
+
# @option opts [String] :service_id Alphanumeric string identifying the service. (required)
|
32
|
+
# @return [Array<(DomainInspector, Integer, Hash)>] DomainInspector data, response status code and response headers
|
33
|
+
def get_domain_inspector_last120_seconds_with_http_info(opts = {})
|
34
|
+
if @api_client.config.debugging
|
35
|
+
@api_client.config.logger.debug 'Calling API: DomainInspectorRealtimeApi.get_domain_inspector_last120_seconds ...'
|
36
|
+
end
|
37
|
+
# unbox the parameters from the hash
|
38
|
+
service_id = opts[:'service_id']
|
39
|
+
# verify the required parameter 'service_id' is set
|
40
|
+
if @api_client.config.client_side_validation && service_id.nil?
|
41
|
+
fail ArgumentError, "Missing the required parameter 'service_id' when calling DomainInspectorRealtimeApi.get_domain_inspector_last120_seconds"
|
42
|
+
end
|
43
|
+
# resource path
|
44
|
+
local_var_path = '/v1/domains/{service_id}/ts/h'.sub('{' + 'service_id' + '}', CGI.escape(service_id.to_s))
|
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'])
|
53
|
+
|
54
|
+
# form parameters
|
55
|
+
form_params = opts[:form_params] || {}
|
56
|
+
|
57
|
+
# http body (model)
|
58
|
+
post_body = opts[:debug_body]
|
59
|
+
|
60
|
+
# return_type
|
61
|
+
return_type = opts[:debug_return_type] || 'DomainInspector'
|
62
|
+
|
63
|
+
# auth_names
|
64
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
65
|
+
|
66
|
+
new_options = opts.merge(
|
67
|
+
:operation => :"DomainInspectorRealtimeApi.get_domain_inspector_last120_seconds",
|
68
|
+
:header_params => header_params,
|
69
|
+
:query_params => query_params,
|
70
|
+
:form_params => form_params,
|
71
|
+
:body => post_body,
|
72
|
+
:auth_names => auth_names,
|
73
|
+
:return_type => return_type
|
74
|
+
)
|
75
|
+
|
76
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
77
|
+
if @api_client.config.debugging
|
78
|
+
@api_client.config.logger.debug "API called: DomainInspectorRealtimeApi#get_domain_inspector_last120_seconds\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
79
|
+
end
|
80
|
+
return data, status_code, headers
|
81
|
+
end
|
82
|
+
|
83
|
+
# Get a limited number of real-time domain data entries
|
84
|
+
# Get data for the `max_entries` seconds preceding the latest timestamp available for a service, up to a maximum of 120 entries.
|
85
|
+
# @option opts [String] :service_id Alphanumeric string identifying the service. (required)
|
86
|
+
# @option opts [Integer] :max_entries Maximum number of results to show. (required)
|
87
|
+
# @return [DomainInspector]
|
88
|
+
def get_domain_inspector_last_max_entries(opts = {})
|
89
|
+
data, _status_code, _headers = get_domain_inspector_last_max_entries_with_http_info(opts)
|
90
|
+
data
|
91
|
+
end
|
92
|
+
|
93
|
+
# Get a limited number of real-time domain data entries
|
94
|
+
# Get data for the `max_entries` seconds preceding the latest timestamp available for a service, up to a maximum of 120 entries.
|
95
|
+
# @option opts [String] :service_id Alphanumeric string identifying the service. (required)
|
96
|
+
# @option opts [Integer] :max_entries Maximum number of results to show. (required)
|
97
|
+
# @return [Array<(DomainInspector, Integer, Hash)>] DomainInspector data, response status code and response headers
|
98
|
+
def get_domain_inspector_last_max_entries_with_http_info(opts = {})
|
99
|
+
if @api_client.config.debugging
|
100
|
+
@api_client.config.logger.debug 'Calling API: DomainInspectorRealtimeApi.get_domain_inspector_last_max_entries ...'
|
101
|
+
end
|
102
|
+
# unbox the parameters from the hash
|
103
|
+
service_id = opts[:'service_id']
|
104
|
+
max_entries = opts[:'max_entries']
|
105
|
+
# verify the required parameter 'service_id' is set
|
106
|
+
if @api_client.config.client_side_validation && service_id.nil?
|
107
|
+
fail ArgumentError, "Missing the required parameter 'service_id' when calling DomainInspectorRealtimeApi.get_domain_inspector_last_max_entries"
|
108
|
+
end
|
109
|
+
# verify the required parameter 'max_entries' is set
|
110
|
+
if @api_client.config.client_side_validation && max_entries.nil?
|
111
|
+
fail ArgumentError, "Missing the required parameter 'max_entries' when calling DomainInspectorRealtimeApi.get_domain_inspector_last_max_entries"
|
112
|
+
end
|
113
|
+
# resource path
|
114
|
+
local_var_path = '/v1/domains/{service_id}/ts/h/limit/{max_entries}'.sub('{' + 'service_id' + '}', CGI.escape(service_id.to_s)).sub('{' + 'max_entries' + '}', CGI.escape(max_entries.to_s))
|
115
|
+
|
116
|
+
# query parameters
|
117
|
+
query_params = opts[:query_params] || {}
|
118
|
+
|
119
|
+
# header parameters
|
120
|
+
header_params = opts[:header_params] || {}
|
121
|
+
# HTTP header 'Accept' (if needed)
|
122
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
123
|
+
|
124
|
+
# form parameters
|
125
|
+
form_params = opts[:form_params] || {}
|
126
|
+
|
127
|
+
# http body (model)
|
128
|
+
post_body = opts[:debug_body]
|
129
|
+
|
130
|
+
# return_type
|
131
|
+
return_type = opts[:debug_return_type] || 'DomainInspector'
|
132
|
+
|
133
|
+
# auth_names
|
134
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
135
|
+
|
136
|
+
new_options = opts.merge(
|
137
|
+
:operation => :"DomainInspectorRealtimeApi.get_domain_inspector_last_max_entries",
|
138
|
+
:header_params => header_params,
|
139
|
+
:query_params => query_params,
|
140
|
+
:form_params => form_params,
|
141
|
+
:body => post_body,
|
142
|
+
:auth_names => auth_names,
|
143
|
+
:return_type => return_type
|
144
|
+
)
|
145
|
+
|
146
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
147
|
+
if @api_client.config.debugging
|
148
|
+
@api_client.config.logger.debug "API called: DomainInspectorRealtimeApi#get_domain_inspector_last_max_entries\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
149
|
+
end
|
150
|
+
return data, status_code, headers
|
151
|
+
end
|
152
|
+
|
153
|
+
# Get real-time domain data from a specified time
|
154
|
+
# Get real-time domain data for the specified reporting period. Specify `0` to get a single entry for the last complete second. The `Timestamp` field included in the response provides the time index of the latest entry in the dataset and can be provided as the `start_timestamp` of the next request for a seamless continuation of the dataset from one request to the next. Due to processing latency, the earliest entry in the response dataset may be earlier than `start_timestamp` by the value of `AggregateDelay`.
|
155
|
+
# @option opts [String] :service_id Alphanumeric string identifying the service. (required)
|
156
|
+
# @option opts [Integer] :start_timestamp Timestamp in seconds (Unix epoch time). (required)
|
157
|
+
# @return [DomainInspector]
|
158
|
+
def get_domain_inspector_last_second(opts = {})
|
159
|
+
data, _status_code, _headers = get_domain_inspector_last_second_with_http_info(opts)
|
160
|
+
data
|
161
|
+
end
|
162
|
+
|
163
|
+
# Get real-time domain data from a specified time
|
164
|
+
# Get real-time domain data for the specified reporting period. Specify `0` to get a single entry for the last complete second. The `Timestamp` field included in the response provides the time index of the latest entry in the dataset and can be provided as the `start_timestamp` of the next request for a seamless continuation of the dataset from one request to the next. Due to processing latency, the earliest entry in the response dataset may be earlier than `start_timestamp` by the value of `AggregateDelay`.
|
165
|
+
# @option opts [String] :service_id Alphanumeric string identifying the service. (required)
|
166
|
+
# @option opts [Integer] :start_timestamp Timestamp in seconds (Unix epoch time). (required)
|
167
|
+
# @return [Array<(DomainInspector, Integer, Hash)>] DomainInspector data, response status code and response headers
|
168
|
+
def get_domain_inspector_last_second_with_http_info(opts = {})
|
169
|
+
if @api_client.config.debugging
|
170
|
+
@api_client.config.logger.debug 'Calling API: DomainInspectorRealtimeApi.get_domain_inspector_last_second ...'
|
171
|
+
end
|
172
|
+
# unbox the parameters from the hash
|
173
|
+
service_id = opts[:'service_id']
|
174
|
+
start_timestamp = opts[:'start_timestamp']
|
175
|
+
# verify the required parameter 'service_id' is set
|
176
|
+
if @api_client.config.client_side_validation && service_id.nil?
|
177
|
+
fail ArgumentError, "Missing the required parameter 'service_id' when calling DomainInspectorRealtimeApi.get_domain_inspector_last_second"
|
178
|
+
end
|
179
|
+
# verify the required parameter 'start_timestamp' is set
|
180
|
+
if @api_client.config.client_side_validation && start_timestamp.nil?
|
181
|
+
fail ArgumentError, "Missing the required parameter 'start_timestamp' when calling DomainInspectorRealtimeApi.get_domain_inspector_last_second"
|
182
|
+
end
|
183
|
+
# resource path
|
184
|
+
local_var_path = '/v1/domains/{service_id}/ts/{start_timestamp}'.sub('{' + 'service_id' + '}', CGI.escape(service_id.to_s)).sub('{' + 'start_timestamp' + '}', CGI.escape(start_timestamp.to_s))
|
185
|
+
|
186
|
+
# query parameters
|
187
|
+
query_params = opts[:query_params] || {}
|
188
|
+
|
189
|
+
# header parameters
|
190
|
+
header_params = opts[:header_params] || {}
|
191
|
+
# HTTP header 'Accept' (if needed)
|
192
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
193
|
+
|
194
|
+
# form parameters
|
195
|
+
form_params = opts[:form_params] || {}
|
196
|
+
|
197
|
+
# http body (model)
|
198
|
+
post_body = opts[:debug_body]
|
199
|
+
|
200
|
+
# return_type
|
201
|
+
return_type = opts[:debug_return_type] || 'DomainInspector'
|
202
|
+
|
203
|
+
# auth_names
|
204
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
205
|
+
|
206
|
+
new_options = opts.merge(
|
207
|
+
:operation => :"DomainInspectorRealtimeApi.get_domain_inspector_last_second",
|
208
|
+
:header_params => header_params,
|
209
|
+
:query_params => query_params,
|
210
|
+
:form_params => form_params,
|
211
|
+
:body => post_body,
|
212
|
+
:auth_names => auth_names,
|
213
|
+
:return_type => return_type
|
214
|
+
)
|
215
|
+
|
216
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
217
|
+
if @api_client.config.debugging
|
218
|
+
@api_client.config.logger.debug "API called: DomainInspectorRealtimeApi#get_domain_inspector_last_second\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
219
|
+
end
|
220
|
+
return data, status_code, headers
|
221
|
+
end
|
222
|
+
end
|
223
|
+
end
|
@@ -17,6 +17,139 @@ module Fastly
|
|
17
17
|
def initialize(api_client = ApiClient.default)
|
18
18
|
@api_client = api_client
|
19
19
|
end
|
20
|
+
# Add permissions to a role
|
21
|
+
# Add permissions to a role.
|
22
|
+
# @option opts [String] :role_id Alphanumeric string identifying the role. (required)
|
23
|
+
# @option opts [Hash<String, Object>] :request_body
|
24
|
+
# @return [Object]
|
25
|
+
def add_role_permissions(opts = {})
|
26
|
+
data, _status_code, _headers = add_role_permissions_with_http_info(opts)
|
27
|
+
data
|
28
|
+
end
|
29
|
+
|
30
|
+
# Add permissions to a role
|
31
|
+
# Add permissions to a role.
|
32
|
+
# @option opts [String] :role_id Alphanumeric string identifying the role. (required)
|
33
|
+
# @option opts [Hash<String, Object>] :request_body
|
34
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
35
|
+
def add_role_permissions_with_http_info(opts = {})
|
36
|
+
if @api_client.config.debugging
|
37
|
+
@api_client.config.logger.debug 'Calling API: IamRolesApi.add_role_permissions ...'
|
38
|
+
end
|
39
|
+
# unbox the parameters from the hash
|
40
|
+
role_id = opts[:'role_id']
|
41
|
+
# verify the required parameter 'role_id' is set
|
42
|
+
if @api_client.config.client_side_validation && role_id.nil?
|
43
|
+
fail ArgumentError, "Missing the required parameter 'role_id' when calling IamRolesApi.add_role_permissions"
|
44
|
+
end
|
45
|
+
# resource path
|
46
|
+
local_var_path = '/roles/{role_id}/permissions'.sub('{' + 'role_id' + '}', CGI.escape(role_id.to_s))
|
47
|
+
|
48
|
+
# query parameters
|
49
|
+
query_params = opts[:query_params] || {}
|
50
|
+
|
51
|
+
# header parameters
|
52
|
+
header_params = opts[:header_params] || {}
|
53
|
+
# HTTP header 'Accept' (if needed)
|
54
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
55
|
+
# HTTP header 'Content-Type'
|
56
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
57
|
+
if !content_type.nil?
|
58
|
+
header_params['Content-Type'] = content_type
|
59
|
+
end
|
60
|
+
|
61
|
+
# form parameters
|
62
|
+
form_params = opts[:form_params] || {}
|
63
|
+
|
64
|
+
# http body (model)
|
65
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'request_body'])
|
66
|
+
|
67
|
+
# return_type
|
68
|
+
return_type = opts[:debug_return_type] || 'Object'
|
69
|
+
|
70
|
+
# auth_names
|
71
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
72
|
+
|
73
|
+
new_options = opts.merge(
|
74
|
+
:operation => :"IamRolesApi.add_role_permissions",
|
75
|
+
:header_params => header_params,
|
76
|
+
:query_params => query_params,
|
77
|
+
:form_params => form_params,
|
78
|
+
:body => post_body,
|
79
|
+
:auth_names => auth_names,
|
80
|
+
:return_type => return_type
|
81
|
+
)
|
82
|
+
|
83
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
84
|
+
if @api_client.config.debugging
|
85
|
+
@api_client.config.logger.debug "API called: IamRolesApi#add_role_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
86
|
+
end
|
87
|
+
return data, status_code, headers
|
88
|
+
end
|
89
|
+
|
90
|
+
# Create a role
|
91
|
+
# Create a role.
|
92
|
+
# @option opts [Hash<String, Object>] :request_body
|
93
|
+
# @return [Object]
|
94
|
+
def create_a_role(opts = {})
|
95
|
+
data, _status_code, _headers = create_a_role_with_http_info(opts)
|
96
|
+
data
|
97
|
+
end
|
98
|
+
|
99
|
+
# Create a role
|
100
|
+
# Create a role.
|
101
|
+
# @option opts [Hash<String, Object>] :request_body
|
102
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
103
|
+
def create_a_role_with_http_info(opts = {})
|
104
|
+
if @api_client.config.debugging
|
105
|
+
@api_client.config.logger.debug 'Calling API: IamRolesApi.create_a_role ...'
|
106
|
+
end
|
107
|
+
# unbox the parameters from the hash
|
108
|
+
# resource path
|
109
|
+
local_var_path = '/roles'
|
110
|
+
|
111
|
+
# query parameters
|
112
|
+
query_params = opts[:query_params] || {}
|
113
|
+
|
114
|
+
# header parameters
|
115
|
+
header_params = opts[:header_params] || {}
|
116
|
+
# HTTP header 'Accept' (if needed)
|
117
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
118
|
+
# HTTP header 'Content-Type'
|
119
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
120
|
+
if !content_type.nil?
|
121
|
+
header_params['Content-Type'] = content_type
|
122
|
+
end
|
123
|
+
|
124
|
+
# form parameters
|
125
|
+
form_params = opts[:form_params] || {}
|
126
|
+
|
127
|
+
# http body (model)
|
128
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'request_body'])
|
129
|
+
|
130
|
+
# return_type
|
131
|
+
return_type = opts[:debug_return_type] || 'Object'
|
132
|
+
|
133
|
+
# auth_names
|
134
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
135
|
+
|
136
|
+
new_options = opts.merge(
|
137
|
+
:operation => :"IamRolesApi.create_a_role",
|
138
|
+
:header_params => header_params,
|
139
|
+
:query_params => query_params,
|
140
|
+
:form_params => form_params,
|
141
|
+
:body => post_body,
|
142
|
+
:auth_names => auth_names,
|
143
|
+
:return_type => return_type
|
144
|
+
)
|
145
|
+
|
146
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
147
|
+
if @api_client.config.debugging
|
148
|
+
@api_client.config.logger.debug "API called: IamRolesApi#create_a_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
149
|
+
end
|
150
|
+
return data, status_code, headers
|
151
|
+
end
|
152
|
+
|
20
153
|
# Delete a role
|
21
154
|
# Delete a role.
|
22
155
|
# @option opts [String] :role_id Alphanumeric string identifying the role. (required)
|
@@ -273,5 +406,143 @@ module Fastly
|
|
273
406
|
end
|
274
407
|
return data, status_code, headers
|
275
408
|
end
|
409
|
+
|
410
|
+
# Remove permissions from a role
|
411
|
+
# Remove permissions from a role.
|
412
|
+
# @option opts [String] :role_id Alphanumeric string identifying the role. (required)
|
413
|
+
# @option opts [Hash<String, Object>] :request_body
|
414
|
+
# @return [nil]
|
415
|
+
def remove_role_permissions(opts = {})
|
416
|
+
remove_role_permissions_with_http_info(opts)
|
417
|
+
nil
|
418
|
+
end
|
419
|
+
|
420
|
+
# Remove permissions from a role
|
421
|
+
# Remove permissions from a role.
|
422
|
+
# @option opts [String] :role_id Alphanumeric string identifying the role. (required)
|
423
|
+
# @option opts [Hash<String, Object>] :request_body
|
424
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
425
|
+
def remove_role_permissions_with_http_info(opts = {})
|
426
|
+
if @api_client.config.debugging
|
427
|
+
@api_client.config.logger.debug 'Calling API: IamRolesApi.remove_role_permissions ...'
|
428
|
+
end
|
429
|
+
# unbox the parameters from the hash
|
430
|
+
role_id = opts[:'role_id']
|
431
|
+
# verify the required parameter 'role_id' is set
|
432
|
+
if @api_client.config.client_side_validation && role_id.nil?
|
433
|
+
fail ArgumentError, "Missing the required parameter 'role_id' when calling IamRolesApi.remove_role_permissions"
|
434
|
+
end
|
435
|
+
# resource path
|
436
|
+
local_var_path = '/roles/{role_id}/permissions'.sub('{' + 'role_id' + '}', CGI.escape(role_id.to_s))
|
437
|
+
|
438
|
+
# query parameters
|
439
|
+
query_params = opts[:query_params] || {}
|
440
|
+
|
441
|
+
# header parameters
|
442
|
+
header_params = opts[:header_params] || {}
|
443
|
+
# HTTP header 'Content-Type'
|
444
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
445
|
+
if !content_type.nil?
|
446
|
+
header_params['Content-Type'] = content_type
|
447
|
+
end
|
448
|
+
|
449
|
+
# form parameters
|
450
|
+
form_params = opts[:form_params] || {}
|
451
|
+
|
452
|
+
# http body (model)
|
453
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'request_body'])
|
454
|
+
|
455
|
+
# return_type
|
456
|
+
return_type = opts[:debug_return_type]
|
457
|
+
|
458
|
+
# auth_names
|
459
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
460
|
+
|
461
|
+
new_options = opts.merge(
|
462
|
+
:operation => :"IamRolesApi.remove_role_permissions",
|
463
|
+
:header_params => header_params,
|
464
|
+
:query_params => query_params,
|
465
|
+
:form_params => form_params,
|
466
|
+
:body => post_body,
|
467
|
+
:auth_names => auth_names,
|
468
|
+
:return_type => return_type
|
469
|
+
)
|
470
|
+
|
471
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
472
|
+
if @api_client.config.debugging
|
473
|
+
@api_client.config.logger.debug "API called: IamRolesApi#remove_role_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
474
|
+
end
|
475
|
+
return data, status_code, headers
|
476
|
+
end
|
477
|
+
|
478
|
+
# Update a role
|
479
|
+
# Update a role.
|
480
|
+
# @option opts [String] :role_id Alphanumeric string identifying the role. (required)
|
481
|
+
# @option opts [Hash<String, Object>] :request_body
|
482
|
+
# @return [Object]
|
483
|
+
def update_a_role(opts = {})
|
484
|
+
data, _status_code, _headers = update_a_role_with_http_info(opts)
|
485
|
+
data
|
486
|
+
end
|
487
|
+
|
488
|
+
# Update a role
|
489
|
+
# Update a role.
|
490
|
+
# @option opts [String] :role_id Alphanumeric string identifying the role. (required)
|
491
|
+
# @option opts [Hash<String, Object>] :request_body
|
492
|
+
# @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
|
493
|
+
def update_a_role_with_http_info(opts = {})
|
494
|
+
if @api_client.config.debugging
|
495
|
+
@api_client.config.logger.debug 'Calling API: IamRolesApi.update_a_role ...'
|
496
|
+
end
|
497
|
+
# unbox the parameters from the hash
|
498
|
+
role_id = opts[:'role_id']
|
499
|
+
# verify the required parameter 'role_id' is set
|
500
|
+
if @api_client.config.client_side_validation && role_id.nil?
|
501
|
+
fail ArgumentError, "Missing the required parameter 'role_id' when calling IamRolesApi.update_a_role"
|
502
|
+
end
|
503
|
+
# resource path
|
504
|
+
local_var_path = '/roles/{role_id}'.sub('{' + 'role_id' + '}', CGI.escape(role_id.to_s))
|
505
|
+
|
506
|
+
# query parameters
|
507
|
+
query_params = opts[:query_params] || {}
|
508
|
+
|
509
|
+
# header parameters
|
510
|
+
header_params = opts[:header_params] || {}
|
511
|
+
# HTTP header 'Accept' (if needed)
|
512
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
513
|
+
# HTTP header 'Content-Type'
|
514
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
515
|
+
if !content_type.nil?
|
516
|
+
header_params['Content-Type'] = content_type
|
517
|
+
end
|
518
|
+
|
519
|
+
# form parameters
|
520
|
+
form_params = opts[:form_params] || {}
|
521
|
+
|
522
|
+
# http body (model)
|
523
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'request_body'])
|
524
|
+
|
525
|
+
# return_type
|
526
|
+
return_type = opts[:debug_return_type] || 'Object'
|
527
|
+
|
528
|
+
# auth_names
|
529
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
530
|
+
|
531
|
+
new_options = opts.merge(
|
532
|
+
:operation => :"IamRolesApi.update_a_role",
|
533
|
+
:header_params => header_params,
|
534
|
+
:query_params => query_params,
|
535
|
+
:form_params => form_params,
|
536
|
+
:body => post_body,
|
537
|
+
:auth_names => auth_names,
|
538
|
+
:return_type => return_type
|
539
|
+
)
|
540
|
+
|
541
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
542
|
+
if @api_client.config.debugging
|
543
|
+
@api_client.config.logger.debug "API called: IamRolesApi#update_a_role\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
544
|
+
end
|
545
|
+
return data, status_code, headers
|
546
|
+
end
|
276
547
|
end
|
277
548
|
end
|