fastly 8.5.0 → 8.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/Gemfile.lock +1 -1
- data/README.md +15 -2
- data/docs/{RelationshipTlsDnsRecord.md → AsyncResponse.md} +3 -2
- data/docs/BillingInvoicesApi.md +37 -4
- data/docs/BillingUsageMetricsApi.md +111 -0
- data/docs/CreateDashboardRequest.md +12 -0
- data/docs/Dashboard.md +17 -0
- data/docs/DashboardItem.md +15 -0
- data/docs/DashboardItemPropertyDataSource.md +11 -0
- data/docs/DashboardItemPropertyDataSourcePropertyConfig.md +10 -0
- data/docs/DashboardItemPropertyVisualization.md +11 -0
- data/docs/DashboardItemPropertyVisualizationPropertyConfig.md +12 -0
- data/docs/{RelationshipTlsDnsRecords.md → DashboardPropertyCreatedBy.md} +1 -2
- data/docs/{RelationshipTlsDnsRecordDnsRecord.md → DashboardPropertyUpdatedBy.md} +1 -2
- data/docs/DomainInspectorMeasurements.md +1 -1
- data/docs/{InvoiceResponse.md → EomInvoiceResponse.md} +1 -1
- data/docs/GetServiceLevelUsageResponse.md +10 -0
- data/docs/GetServiceLevelUsageTypesResponse.md +10 -0
- data/docs/IncludedWithTlsConfiguration.md +10 -0
- data/docs/IncludedWithTlsConfigurationItem.md +12 -0
- data/docs/ListDashboardsResponse.md +11 -0
- data/docs/{ListInvoicesResponse.md → ListEomInvoicesResponse.md} +1 -1
- data/docs/MtdInvoiceResponse.md +15 -0
- data/docs/Mtdinvoice.md +15 -0
- data/docs/Mtdlineitems.md +18 -0
- data/docs/ObservabilityCustomDashboardsApi.md +203 -0
- data/docs/RealtimeEntryAggregated.md +1 -0
- data/docs/RealtimeMeasurements.md +1 -0
- data/docs/RelationshipDefaultEcdsaTlsCertificate.md +10 -0
- data/docs/RelationshipDefaultEcdsaTlsCertificateDefaultEcdsaCertificate.md +10 -0
- data/docs/RelationshipDefaultEcdsaTlsCertificateDefaultEcdsaCertificateData.md +11 -0
- data/docs/RelationshipDefaultTlsCertificate.md +10 -0
- data/docs/RelationshipDefaultTlsCertificateDefaultCertificate.md +10 -0
- data/docs/RelationshipDefaultTlsCertificateDefaultCertificateData.md +11 -0
- data/docs/RelationshipTlsDnsRecordsRequest.md +10 -0
- data/docs/RelationshipTlsDnsRecordsRequestDnsRecords.md +10 -0
- data/docs/RelationshipTlsDnsRecordsRequestDnsRecordsData.md +11 -0
- data/docs/RelationshipTlsDnsRecordsResponse.md +10 -0
- data/docs/RelationshipTlsDnsRecordsResponseDnsRecords.md +10 -0
- data/docs/{RelationshipMemberTlsDnsRecord.md → RelationshipTlsDnsRecordsResponseDnsRecordsData.md} +1 -1
- data/docs/Results.md +1 -0
- data/docs/Serviceusagemetric.md +13 -0
- data/docs/Serviceusagemetrics.md +10 -0
- data/docs/ServiceusagemetricsData.md +16 -0
- data/docs/Serviceusagetype.md +11 -0
- data/docs/Serviceusagetypes.md +10 -0
- data/docs/TlsCertificateBlobResponse.md +10 -0
- data/docs/TlsCertificatesApi.md +38 -0
- data/docs/TlsDnsRecord.md +1 -2
- data/docs/UpdateDashboardRequest.md +12 -0
- data/docs/Values.md +1 -1
- data/lib/fastly/api/billing_invoices_api.rb +62 -6
- data/lib/fastly/api/billing_usage_metrics_api.rb +213 -0
- data/lib/fastly/api/observability_custom_dashboards_api.rb +333 -0
- data/lib/fastly/api/tls_certificates_api.rb +63 -0
- data/lib/fastly/configuration.rb +54 -0
- data/lib/fastly/models/async_response.rb +225 -0
- data/lib/fastly/models/create_dashboard_request.rb +245 -0
- data/lib/fastly/models/dashboard.rb +290 -0
- data/lib/fastly/models/dashboard_item.rb +368 -0
- data/lib/fastly/models/dashboard_item_property_data_source.rb +271 -0
- data/lib/fastly/models/dashboard_item_property_data_source_property_config.rb +244 -0
- data/lib/fastly/models/dashboard_item_property_visualization.rb +271 -0
- data/lib/fastly/models/dashboard_item_property_visualization_property_config.rb +303 -0
- data/lib/fastly/models/dashboard_property_created_by.rb +208 -0
- data/lib/fastly/models/dashboard_property_updated_by.rb +208 -0
- data/lib/fastly/models/domain_inspector_measurements.rb +1 -1
- data/lib/fastly/models/{invoice_response.rb → eom_invoice_response.rb} +3 -3
- data/lib/fastly/models/get_service_level_usage_response.rb +223 -0
- data/lib/fastly/models/get_service_level_usage_types_response.rb +225 -0
- data/lib/fastly/models/included_with_tls_configuration.rb +218 -0
- data/lib/fastly/models/included_with_tls_configuration_item.rb +237 -0
- data/lib/fastly/models/invoicelineitems.rb +5 -5
- data/lib/fastly/models/list_dashboards_response.rb +229 -0
- data/lib/fastly/models/{list_invoices_response.rb → list_eom_invoices_response.rb} +3 -3
- data/lib/fastly/models/mtd_invoice_response.rb +275 -0
- data/lib/fastly/models/mtdinvoice.rb +268 -0
- data/lib/fastly/models/mtdlineitems.rb +297 -0
- data/lib/fastly/models/realtime_entry_aggregated.rb +14 -4
- data/lib/fastly/models/realtime_measurements.rb +14 -4
- data/lib/fastly/models/relationship_default_ecdsa_tls_certificate.rb +216 -0
- data/lib/fastly/models/relationship_default_ecdsa_tls_certificate_default_ecdsa_certificate.rb +216 -0
- data/lib/fastly/models/relationship_default_ecdsa_tls_certificate_default_ecdsa_certificate_data.rb +228 -0
- data/lib/fastly/models/relationship_default_tls_certificate.rb +216 -0
- data/lib/fastly/models/relationship_default_tls_certificate_default_certificate.rb +216 -0
- data/lib/fastly/models/relationship_default_tls_certificate_default_certificate_data.rb +228 -0
- data/lib/fastly/models/{relationship_tls_dns_records.rb → relationship_tls_dns_records_request.rb} +4 -4
- data/lib/fastly/models/relationship_tls_dns_records_request_dns_records.rb +218 -0
- data/lib/fastly/models/{relationship_member_tls_dns_record.rb → relationship_tls_dns_records_request_dns_records_data.rb} +3 -3
- data/lib/fastly/models/relationship_tls_dns_records_response.rb +216 -0
- data/lib/fastly/models/relationship_tls_dns_records_response_dns_records.rb +218 -0
- data/lib/fastly/models/relationship_tls_dns_records_response_dns_records_data.rb +227 -0
- data/lib/fastly/models/relationships_for_tls_configuration.rb +1 -1
- data/lib/fastly/models/results.rb +11 -1
- data/lib/fastly/models/serviceusagemetric.rb +246 -0
- data/lib/fastly/models/{relationship_tls_dns_record.rb → serviceusagemetrics.rb} +10 -10
- data/lib/fastly/models/serviceusagemetrics_data.rb +276 -0
- data/lib/fastly/models/serviceusagetype.rb +227 -0
- data/lib/fastly/models/{relationship_tls_dns_record_dns_record.rb → serviceusagetypes.rb} +4 -4
- data/lib/fastly/models/tls_certificate_blob_response.rb +217 -0
- data/lib/fastly/models/tls_dns_record.rb +48 -12
- data/lib/fastly/models/update_dashboard_request.rb +240 -0
- data/lib/fastly/models/values.rb +1 -1
- data/lib/fastly/version.rb +1 -1
- data/lib/fastly.rb +41 -6
- data/sig.json +1 -1
- metadata +84 -14
@@ -0,0 +1,213 @@
|
|
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 BillingUsageMetricsApi
|
15
|
+
attr_accessor :api_client
|
16
|
+
|
17
|
+
def initialize(api_client = ApiClient.default)
|
18
|
+
@api_client = api_client
|
19
|
+
end
|
20
|
+
# Retrieve service-level usage metrics for a product.
|
21
|
+
# Returns product usage, broken down by service.
|
22
|
+
# @option opts [String] :customer_id Alphanumeric string identifying the customer. (required)
|
23
|
+
# @option opts [String] :product_id The product identifier for the metrics returned (e.g., `cdn_usage`). This field is not required for CSV requests. (required)
|
24
|
+
# @option opts [String] :usage_type_name The usage type name for the metrics returned (e.g., `North America Requests`). This field is not required for CSV requests. (required)
|
25
|
+
# @option opts [String] :time_granularity (required)
|
26
|
+
# @option opts [String] :start_date
|
27
|
+
# @option opts [String] :end_date
|
28
|
+
# @option opts [String] :start_month
|
29
|
+
# @option opts [String] :end_month
|
30
|
+
# @option opts [String] :limit Number of results per page. The maximum is 100. (default to '5')
|
31
|
+
# @option opts [String] :cursor Cursor value from the `next_cursor` field of a previous response, used to retrieve the next page. To request the first page, this should be empty.
|
32
|
+
# @return [Serviceusagemetrics]
|
33
|
+
def get_service_level_usage(opts = {})
|
34
|
+
data, _status_code, _headers = get_service_level_usage_with_http_info(opts)
|
35
|
+
data
|
36
|
+
end
|
37
|
+
|
38
|
+
# Retrieve service-level usage metrics for a product.
|
39
|
+
# Returns product usage, broken down by service.
|
40
|
+
# @option opts [String] :customer_id Alphanumeric string identifying the customer. (required)
|
41
|
+
# @option opts [String] :product_id The product identifier for the metrics returned (e.g., `cdn_usage`). This field is not required for CSV requests. (required)
|
42
|
+
# @option opts [String] :usage_type_name The usage type name for the metrics returned (e.g., `North America Requests`). This field is not required for CSV requests. (required)
|
43
|
+
# @option opts [String] :time_granularity (required)
|
44
|
+
# @option opts [String] :start_date
|
45
|
+
# @option opts [String] :end_date
|
46
|
+
# @option opts [String] :start_month
|
47
|
+
# @option opts [String] :end_month
|
48
|
+
# @option opts [String] :limit Number of results per page. The maximum is 100. (default to '5')
|
49
|
+
# @option opts [String] :cursor Cursor value from the `next_cursor` field of a previous response, used to retrieve the next page. To request the first page, this should be empty.
|
50
|
+
# @return [Array<(Serviceusagemetrics, Integer, Hash)>] Serviceusagemetrics data, response status code and response headers
|
51
|
+
def get_service_level_usage_with_http_info(opts = {})
|
52
|
+
if @api_client.config.debugging
|
53
|
+
@api_client.config.logger.debug 'Calling API: BillingUsageMetricsApi.get_service_level_usage ...'
|
54
|
+
end
|
55
|
+
# unbox the parameters from the hash
|
56
|
+
customer_id = opts[:'customer_id']
|
57
|
+
product_id = opts[:'product_id']
|
58
|
+
usage_type_name = opts[:'usage_type_name']
|
59
|
+
time_granularity = opts[:'time_granularity']
|
60
|
+
# verify the required parameter 'customer_id' is set
|
61
|
+
if @api_client.config.client_side_validation && customer_id.nil?
|
62
|
+
fail ArgumentError, "Missing the required parameter 'customer_id' when calling BillingUsageMetricsApi.get_service_level_usage"
|
63
|
+
end
|
64
|
+
# verify the required parameter 'product_id' is set
|
65
|
+
if @api_client.config.client_side_validation && product_id.nil?
|
66
|
+
fail ArgumentError, "Missing the required parameter 'product_id' when calling BillingUsageMetricsApi.get_service_level_usage"
|
67
|
+
end
|
68
|
+
# verify the required parameter 'usage_type_name' is set
|
69
|
+
if @api_client.config.client_side_validation && usage_type_name.nil?
|
70
|
+
fail ArgumentError, "Missing the required parameter 'usage_type_name' when calling BillingUsageMetricsApi.get_service_level_usage"
|
71
|
+
end
|
72
|
+
# verify the required parameter 'time_granularity' is set
|
73
|
+
if @api_client.config.client_side_validation && time_granularity.nil?
|
74
|
+
fail ArgumentError, "Missing the required parameter 'time_granularity' when calling BillingUsageMetricsApi.get_service_level_usage"
|
75
|
+
end
|
76
|
+
pattern = Regexp.new(/^day$|^month$/)
|
77
|
+
if @api_client.config.client_side_validation && time_granularity !~ pattern
|
78
|
+
fail ArgumentError, "invalid value for 'time_granularity' when calling BillingUsageMetricsApi.get_service_level_usage, must conform to the pattern #{pattern}."
|
79
|
+
end
|
80
|
+
|
81
|
+
pattern = Regexp.new(/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/)
|
82
|
+
if @api_client.config.client_side_validation && !opts[:'start_date'].nil? && opts[:'start_date'] !~ pattern
|
83
|
+
fail ArgumentError, "invalid value for 'opts[:\"start_date\"]' when calling BillingUsageMetricsApi.get_service_level_usage, must conform to the pattern #{pattern}."
|
84
|
+
end
|
85
|
+
|
86
|
+
pattern = Regexp.new(/^[0-9]{4}-[0-9]{2}-[0-9]{2}$/)
|
87
|
+
if @api_client.config.client_side_validation && !opts[:'end_date'].nil? && opts[:'end_date'] !~ pattern
|
88
|
+
fail ArgumentError, "invalid value for 'opts[:\"end_date\"]' when calling BillingUsageMetricsApi.get_service_level_usage, must conform to the pattern #{pattern}."
|
89
|
+
end
|
90
|
+
|
91
|
+
pattern = Regexp.new(/^[0-9]{4}-[0-9]{2}$/)
|
92
|
+
if @api_client.config.client_side_validation && !opts[:'start_month'].nil? && opts[:'start_month'] !~ pattern
|
93
|
+
fail ArgumentError, "invalid value for 'opts[:\"start_month\"]' when calling BillingUsageMetricsApi.get_service_level_usage, must conform to the pattern #{pattern}."
|
94
|
+
end
|
95
|
+
|
96
|
+
pattern = Regexp.new(/^[0-9]{4}-[0-9]{2}$/)
|
97
|
+
if @api_client.config.client_side_validation && !opts[:'end_month'].nil? && opts[:'end_month'] !~ pattern
|
98
|
+
fail ArgumentError, "invalid value for 'opts[:\"end_month\"]' when calling BillingUsageMetricsApi.get_service_level_usage, must conform to the pattern #{pattern}."
|
99
|
+
end
|
100
|
+
|
101
|
+
# resource path
|
102
|
+
local_var_path = '/billing/v2/account_customers/{customer_id}/service-usage-metrics'.sub('{' + 'customer_id' + '}', CGI.escape(customer_id.to_s))
|
103
|
+
|
104
|
+
# query parameters
|
105
|
+
query_params = opts[:query_params] || {}
|
106
|
+
query_params[:'product_id'] = product_id
|
107
|
+
query_params[:'usage_type_name'] = usage_type_name
|
108
|
+
query_params[:'time_granularity'] = time_granularity
|
109
|
+
query_params[:'start_date'] = opts[:'start_date'] if !opts[:'start_date'].nil?
|
110
|
+
query_params[:'end_date'] = opts[:'end_date'] if !opts[:'end_date'].nil?
|
111
|
+
query_params[:'start_month'] = opts[:'start_month'] if !opts[:'start_month'].nil?
|
112
|
+
query_params[:'end_month'] = opts[:'end_month'] if !opts[:'end_month'].nil?
|
113
|
+
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
114
|
+
query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
|
115
|
+
|
116
|
+
# header parameters
|
117
|
+
header_params = opts[:header_params] || {}
|
118
|
+
# HTTP header 'Accept' (if needed)
|
119
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
120
|
+
|
121
|
+
# form parameters
|
122
|
+
form_params = opts[:form_params] || {}
|
123
|
+
|
124
|
+
# http body (model)
|
125
|
+
post_body = opts[:debug_body]
|
126
|
+
|
127
|
+
# return_type
|
128
|
+
return_type = opts[:debug_return_type] || 'Serviceusagemetrics'
|
129
|
+
|
130
|
+
# auth_names
|
131
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
132
|
+
|
133
|
+
new_options = opts.merge(
|
134
|
+
:operation => :"BillingUsageMetricsApi.get_service_level_usage",
|
135
|
+
:header_params => header_params,
|
136
|
+
:query_params => query_params,
|
137
|
+
:form_params => form_params,
|
138
|
+
:body => post_body,
|
139
|
+
:auth_names => auth_names,
|
140
|
+
:return_type => return_type
|
141
|
+
)
|
142
|
+
|
143
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
144
|
+
if @api_client.config.debugging
|
145
|
+
@api_client.config.logger.debug "API called: BillingUsageMetricsApi#get_service_level_usage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
146
|
+
end
|
147
|
+
return data, status_code, headers
|
148
|
+
end
|
149
|
+
|
150
|
+
# Retrieve product usage types for a customer.
|
151
|
+
# Returns product usage types reported by the customer's services.
|
152
|
+
# @option opts [String] :customer_id Alphanumeric string identifying the customer. (required)
|
153
|
+
# @return [Serviceusagetypes]
|
154
|
+
def get_service_level_usage_types(opts = {})
|
155
|
+
data, _status_code, _headers = get_service_level_usage_types_with_http_info(opts)
|
156
|
+
data
|
157
|
+
end
|
158
|
+
|
159
|
+
# Retrieve product usage types for a customer.
|
160
|
+
# Returns product usage types reported by the customer's services.
|
161
|
+
# @option opts [String] :customer_id Alphanumeric string identifying the customer. (required)
|
162
|
+
# @return [Array<(Serviceusagetypes, Integer, Hash)>] Serviceusagetypes data, response status code and response headers
|
163
|
+
def get_service_level_usage_types_with_http_info(opts = {})
|
164
|
+
if @api_client.config.debugging
|
165
|
+
@api_client.config.logger.debug 'Calling API: BillingUsageMetricsApi.get_service_level_usage_types ...'
|
166
|
+
end
|
167
|
+
# unbox the parameters from the hash
|
168
|
+
customer_id = opts[:'customer_id']
|
169
|
+
# verify the required parameter 'customer_id' is set
|
170
|
+
if @api_client.config.client_side_validation && customer_id.nil?
|
171
|
+
fail ArgumentError, "Missing the required parameter 'customer_id' when calling BillingUsageMetricsApi.get_service_level_usage_types"
|
172
|
+
end
|
173
|
+
# resource path
|
174
|
+
local_var_path = '/billing/v2/account_customers/{customer_id}/service-usage-types'.sub('{' + 'customer_id' + '}', CGI.escape(customer_id.to_s))
|
175
|
+
|
176
|
+
# query parameters
|
177
|
+
query_params = opts[:query_params] || {}
|
178
|
+
|
179
|
+
# header parameters
|
180
|
+
header_params = opts[:header_params] || {}
|
181
|
+
# HTTP header 'Accept' (if needed)
|
182
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
183
|
+
|
184
|
+
# form parameters
|
185
|
+
form_params = opts[:form_params] || {}
|
186
|
+
|
187
|
+
# http body (model)
|
188
|
+
post_body = opts[:debug_body]
|
189
|
+
|
190
|
+
# return_type
|
191
|
+
return_type = opts[:debug_return_type] || 'Serviceusagetypes'
|
192
|
+
|
193
|
+
# auth_names
|
194
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
195
|
+
|
196
|
+
new_options = opts.merge(
|
197
|
+
:operation => :"BillingUsageMetricsApi.get_service_level_usage_types",
|
198
|
+
:header_params => header_params,
|
199
|
+
:query_params => query_params,
|
200
|
+
:form_params => form_params,
|
201
|
+
:body => post_body,
|
202
|
+
:auth_names => auth_names,
|
203
|
+
:return_type => return_type
|
204
|
+
)
|
205
|
+
|
206
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
207
|
+
if @api_client.config.debugging
|
208
|
+
@api_client.config.logger.debug "API called: BillingUsageMetricsApi#get_service_level_usage_types\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
209
|
+
end
|
210
|
+
return data, status_code, headers
|
211
|
+
end
|
212
|
+
end
|
213
|
+
end
|
@@ -0,0 +1,333 @@
|
|
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 ObservabilityCustomDashboardsApi
|
15
|
+
attr_accessor :api_client
|
16
|
+
|
17
|
+
def initialize(api_client = ApiClient.default)
|
18
|
+
@api_client = api_client
|
19
|
+
end
|
20
|
+
# Create a new dashboard
|
21
|
+
# Create a new dashboard
|
22
|
+
# @option opts [CreateDashboardRequest] :create_dashboard_request
|
23
|
+
# @return [Dashboard]
|
24
|
+
def create_dashboard(opts = {})
|
25
|
+
data, _status_code, _headers = create_dashboard_with_http_info(opts)
|
26
|
+
data
|
27
|
+
end
|
28
|
+
|
29
|
+
# Create a new dashboard
|
30
|
+
# Create a new dashboard
|
31
|
+
# @option opts [CreateDashboardRequest] :create_dashboard_request
|
32
|
+
# @return [Array<(Dashboard, Integer, Hash)>] Dashboard data, response status code and response headers
|
33
|
+
def create_dashboard_with_http_info(opts = {})
|
34
|
+
if @api_client.config.debugging
|
35
|
+
@api_client.config.logger.debug 'Calling API: ObservabilityCustomDashboardsApi.create_dashboard ...'
|
36
|
+
end
|
37
|
+
# unbox the parameters from the hash
|
38
|
+
# resource path
|
39
|
+
local_var_path = '/observability/dashboards'
|
40
|
+
|
41
|
+
# query parameters
|
42
|
+
query_params = opts[:query_params] || {}
|
43
|
+
|
44
|
+
# header parameters
|
45
|
+
header_params = opts[:header_params] || {}
|
46
|
+
# HTTP header 'Accept' (if needed)
|
47
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
48
|
+
# HTTP header 'Content-Type'
|
49
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
50
|
+
if !content_type.nil?
|
51
|
+
header_params['Content-Type'] = content_type
|
52
|
+
end
|
53
|
+
|
54
|
+
# form parameters
|
55
|
+
form_params = opts[:form_params] || {}
|
56
|
+
|
57
|
+
# http body (model)
|
58
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'create_dashboard_request'])
|
59
|
+
|
60
|
+
# return_type
|
61
|
+
return_type = opts[:debug_return_type] || 'Dashboard'
|
62
|
+
|
63
|
+
# auth_names
|
64
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
65
|
+
|
66
|
+
new_options = opts.merge(
|
67
|
+
:operation => :"ObservabilityCustomDashboardsApi.create_dashboard",
|
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(:POST, local_var_path, new_options)
|
77
|
+
if @api_client.config.debugging
|
78
|
+
@api_client.config.logger.debug "API called: ObservabilityCustomDashboardsApi#create_dashboard\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
79
|
+
end
|
80
|
+
return data, status_code, headers
|
81
|
+
end
|
82
|
+
|
83
|
+
# Delete an existing dashboard
|
84
|
+
# Delete an existing dashboard
|
85
|
+
# @option opts [String] :dashboard_id (required)
|
86
|
+
# @return [nil]
|
87
|
+
def delete_dashboard(opts = {})
|
88
|
+
delete_dashboard_with_http_info(opts)
|
89
|
+
nil
|
90
|
+
end
|
91
|
+
|
92
|
+
# Delete an existing dashboard
|
93
|
+
# Delete an existing dashboard
|
94
|
+
# @option opts [String] :dashboard_id (required)
|
95
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
96
|
+
def delete_dashboard_with_http_info(opts = {})
|
97
|
+
if @api_client.config.debugging
|
98
|
+
@api_client.config.logger.debug 'Calling API: ObservabilityCustomDashboardsApi.delete_dashboard ...'
|
99
|
+
end
|
100
|
+
# unbox the parameters from the hash
|
101
|
+
dashboard_id = opts[:'dashboard_id']
|
102
|
+
# verify the required parameter 'dashboard_id' is set
|
103
|
+
if @api_client.config.client_side_validation && dashboard_id.nil?
|
104
|
+
fail ArgumentError, "Missing the required parameter 'dashboard_id' when calling ObservabilityCustomDashboardsApi.delete_dashboard"
|
105
|
+
end
|
106
|
+
# resource path
|
107
|
+
local_var_path = '/observability/dashboards/{dashboard_id}'.sub('{' + 'dashboard_id' + '}', CGI.escape(dashboard_id.to_s))
|
108
|
+
|
109
|
+
# query parameters
|
110
|
+
query_params = opts[:query_params] || {}
|
111
|
+
|
112
|
+
# header parameters
|
113
|
+
header_params = opts[:header_params] || {}
|
114
|
+
|
115
|
+
# form parameters
|
116
|
+
form_params = opts[:form_params] || {}
|
117
|
+
|
118
|
+
# http body (model)
|
119
|
+
post_body = opts[:debug_body]
|
120
|
+
|
121
|
+
# return_type
|
122
|
+
return_type = opts[:debug_return_type]
|
123
|
+
|
124
|
+
# auth_names
|
125
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
126
|
+
|
127
|
+
new_options = opts.merge(
|
128
|
+
:operation => :"ObservabilityCustomDashboardsApi.delete_dashboard",
|
129
|
+
:header_params => header_params,
|
130
|
+
:query_params => query_params,
|
131
|
+
:form_params => form_params,
|
132
|
+
:body => post_body,
|
133
|
+
:auth_names => auth_names,
|
134
|
+
:return_type => return_type
|
135
|
+
)
|
136
|
+
|
137
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
138
|
+
if @api_client.config.debugging
|
139
|
+
@api_client.config.logger.debug "API called: ObservabilityCustomDashboardsApi#delete_dashboard\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
140
|
+
end
|
141
|
+
return data, status_code, headers
|
142
|
+
end
|
143
|
+
|
144
|
+
# Retrieve a dashboard by ID
|
145
|
+
# Retrieve a dashboard by ID
|
146
|
+
# @option opts [String] :dashboard_id (required)
|
147
|
+
# @return [Dashboard]
|
148
|
+
def get_dashboard(opts = {})
|
149
|
+
data, _status_code, _headers = get_dashboard_with_http_info(opts)
|
150
|
+
data
|
151
|
+
end
|
152
|
+
|
153
|
+
# Retrieve a dashboard by ID
|
154
|
+
# Retrieve a dashboard by ID
|
155
|
+
# @option opts [String] :dashboard_id (required)
|
156
|
+
# @return [Array<(Dashboard, Integer, Hash)>] Dashboard data, response status code and response headers
|
157
|
+
def get_dashboard_with_http_info(opts = {})
|
158
|
+
if @api_client.config.debugging
|
159
|
+
@api_client.config.logger.debug 'Calling API: ObservabilityCustomDashboardsApi.get_dashboard ...'
|
160
|
+
end
|
161
|
+
# unbox the parameters from the hash
|
162
|
+
dashboard_id = opts[:'dashboard_id']
|
163
|
+
# verify the required parameter 'dashboard_id' is set
|
164
|
+
if @api_client.config.client_side_validation && dashboard_id.nil?
|
165
|
+
fail ArgumentError, "Missing the required parameter 'dashboard_id' when calling ObservabilityCustomDashboardsApi.get_dashboard"
|
166
|
+
end
|
167
|
+
# resource path
|
168
|
+
local_var_path = '/observability/dashboards/{dashboard_id}'.sub('{' + 'dashboard_id' + '}', CGI.escape(dashboard_id.to_s))
|
169
|
+
|
170
|
+
# query parameters
|
171
|
+
query_params = opts[:query_params] || {}
|
172
|
+
|
173
|
+
# header parameters
|
174
|
+
header_params = opts[:header_params] || {}
|
175
|
+
# HTTP header 'Accept' (if needed)
|
176
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
177
|
+
|
178
|
+
# form parameters
|
179
|
+
form_params = opts[:form_params] || {}
|
180
|
+
|
181
|
+
# http body (model)
|
182
|
+
post_body = opts[:debug_body]
|
183
|
+
|
184
|
+
# return_type
|
185
|
+
return_type = opts[:debug_return_type] || 'Dashboard'
|
186
|
+
|
187
|
+
# auth_names
|
188
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
189
|
+
|
190
|
+
new_options = opts.merge(
|
191
|
+
:operation => :"ObservabilityCustomDashboardsApi.get_dashboard",
|
192
|
+
:header_params => header_params,
|
193
|
+
:query_params => query_params,
|
194
|
+
:form_params => form_params,
|
195
|
+
:body => post_body,
|
196
|
+
:auth_names => auth_names,
|
197
|
+
:return_type => return_type
|
198
|
+
)
|
199
|
+
|
200
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
201
|
+
if @api_client.config.debugging
|
202
|
+
@api_client.config.logger.debug "API called: ObservabilityCustomDashboardsApi#get_dashboard\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
203
|
+
end
|
204
|
+
return data, status_code, headers
|
205
|
+
end
|
206
|
+
|
207
|
+
# List all custom dashboards
|
208
|
+
# List all custom dashboards
|
209
|
+
# @return [ListDashboardsResponse]
|
210
|
+
def list_dashboards(opts = {})
|
211
|
+
data, _status_code, _headers = list_dashboards_with_http_info(opts)
|
212
|
+
data
|
213
|
+
end
|
214
|
+
|
215
|
+
# List all custom dashboards
|
216
|
+
# List all custom dashboards
|
217
|
+
# @return [Array<(ListDashboardsResponse, Integer, Hash)>] ListDashboardsResponse data, response status code and response headers
|
218
|
+
def list_dashboards_with_http_info(opts = {})
|
219
|
+
if @api_client.config.debugging
|
220
|
+
@api_client.config.logger.debug 'Calling API: ObservabilityCustomDashboardsApi.list_dashboards ...'
|
221
|
+
end
|
222
|
+
# unbox the parameters from the hash
|
223
|
+
# resource path
|
224
|
+
local_var_path = '/observability/dashboards'
|
225
|
+
|
226
|
+
# query parameters
|
227
|
+
query_params = opts[:query_params] || {}
|
228
|
+
|
229
|
+
# header parameters
|
230
|
+
header_params = opts[:header_params] || {}
|
231
|
+
# HTTP header 'Accept' (if needed)
|
232
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
233
|
+
|
234
|
+
# form parameters
|
235
|
+
form_params = opts[:form_params] || {}
|
236
|
+
|
237
|
+
# http body (model)
|
238
|
+
post_body = opts[:debug_body]
|
239
|
+
|
240
|
+
# return_type
|
241
|
+
return_type = opts[:debug_return_type] || 'ListDashboardsResponse'
|
242
|
+
|
243
|
+
# auth_names
|
244
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
245
|
+
|
246
|
+
new_options = opts.merge(
|
247
|
+
:operation => :"ObservabilityCustomDashboardsApi.list_dashboards",
|
248
|
+
:header_params => header_params,
|
249
|
+
:query_params => query_params,
|
250
|
+
:form_params => form_params,
|
251
|
+
:body => post_body,
|
252
|
+
:auth_names => auth_names,
|
253
|
+
:return_type => return_type
|
254
|
+
)
|
255
|
+
|
256
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
257
|
+
if @api_client.config.debugging
|
258
|
+
@api_client.config.logger.debug "API called: ObservabilityCustomDashboardsApi#list_dashboards\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
259
|
+
end
|
260
|
+
return data, status_code, headers
|
261
|
+
end
|
262
|
+
|
263
|
+
# Update an existing dashboard
|
264
|
+
# Update an existing dashboard
|
265
|
+
# @option opts [String] :dashboard_id (required)
|
266
|
+
# @option opts [UpdateDashboardRequest] :update_dashboard_request
|
267
|
+
# @return [Dashboard]
|
268
|
+
def update_dashboard(opts = {})
|
269
|
+
data, _status_code, _headers = update_dashboard_with_http_info(opts)
|
270
|
+
data
|
271
|
+
end
|
272
|
+
|
273
|
+
# Update an existing dashboard
|
274
|
+
# Update an existing dashboard
|
275
|
+
# @option opts [String] :dashboard_id (required)
|
276
|
+
# @option opts [UpdateDashboardRequest] :update_dashboard_request
|
277
|
+
# @return [Array<(Dashboard, Integer, Hash)>] Dashboard data, response status code and response headers
|
278
|
+
def update_dashboard_with_http_info(opts = {})
|
279
|
+
if @api_client.config.debugging
|
280
|
+
@api_client.config.logger.debug 'Calling API: ObservabilityCustomDashboardsApi.update_dashboard ...'
|
281
|
+
end
|
282
|
+
# unbox the parameters from the hash
|
283
|
+
dashboard_id = opts[:'dashboard_id']
|
284
|
+
# verify the required parameter 'dashboard_id' is set
|
285
|
+
if @api_client.config.client_side_validation && dashboard_id.nil?
|
286
|
+
fail ArgumentError, "Missing the required parameter 'dashboard_id' when calling ObservabilityCustomDashboardsApi.update_dashboard"
|
287
|
+
end
|
288
|
+
# resource path
|
289
|
+
local_var_path = '/observability/dashboards/{dashboard_id}'.sub('{' + 'dashboard_id' + '}', CGI.escape(dashboard_id.to_s))
|
290
|
+
|
291
|
+
# query parameters
|
292
|
+
query_params = opts[:query_params] || {}
|
293
|
+
|
294
|
+
# header parameters
|
295
|
+
header_params = opts[:header_params] || {}
|
296
|
+
# HTTP header 'Accept' (if needed)
|
297
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
298
|
+
# HTTP header 'Content-Type'
|
299
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
300
|
+
if !content_type.nil?
|
301
|
+
header_params['Content-Type'] = content_type
|
302
|
+
end
|
303
|
+
|
304
|
+
# form parameters
|
305
|
+
form_params = opts[:form_params] || {}
|
306
|
+
|
307
|
+
# http body (model)
|
308
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'update_dashboard_request'])
|
309
|
+
|
310
|
+
# return_type
|
311
|
+
return_type = opts[:debug_return_type] || 'Dashboard'
|
312
|
+
|
313
|
+
# auth_names
|
314
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
315
|
+
|
316
|
+
new_options = opts.merge(
|
317
|
+
:operation => :"ObservabilityCustomDashboardsApi.update_dashboard",
|
318
|
+
:header_params => header_params,
|
319
|
+
:query_params => query_params,
|
320
|
+
:form_params => form_params,
|
321
|
+
:body => post_body,
|
322
|
+
:auth_names => auth_names,
|
323
|
+
:return_type => return_type
|
324
|
+
)
|
325
|
+
|
326
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
327
|
+
if @api_client.config.debugging
|
328
|
+
@api_client.config.logger.debug "API called: ObservabilityCustomDashboardsApi#update_dashboard\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
329
|
+
end
|
330
|
+
return data, status_code, headers
|
331
|
+
end
|
332
|
+
end
|
333
|
+
end
|
@@ -204,6 +204,69 @@ module Fastly
|
|
204
204
|
return data, status_code, headers
|
205
205
|
end
|
206
206
|
|
207
|
+
# Get a TLS certificate blob (Limited Availability)
|
208
|
+
# Retrieve a TLS certificate blob. This feature is part of a [limited availability](https://docs.fastly.com/products/fastly-product-lifecycle#limited-availability) release.
|
209
|
+
# @option opts [String] :tls_certificate_id Alphanumeric string identifying a TLS certificate. (required)
|
210
|
+
# @return [TlsCertificateBlobResponse]
|
211
|
+
def get_tls_cert_blob(opts = {})
|
212
|
+
data, _status_code, _headers = get_tls_cert_blob_with_http_info(opts)
|
213
|
+
data
|
214
|
+
end
|
215
|
+
|
216
|
+
# Get a TLS certificate blob (Limited Availability)
|
217
|
+
# Retrieve a TLS certificate blob. This feature is part of a [limited availability](https://docs.fastly.com/products/fastly-product-lifecycle#limited-availability) release.
|
218
|
+
# @option opts [String] :tls_certificate_id Alphanumeric string identifying a TLS certificate. (required)
|
219
|
+
# @return [Array<(TlsCertificateBlobResponse, Integer, Hash)>] TlsCertificateBlobResponse data, response status code and response headers
|
220
|
+
def get_tls_cert_blob_with_http_info(opts = {})
|
221
|
+
if @api_client.config.debugging
|
222
|
+
@api_client.config.logger.debug 'Calling API: TlsCertificatesApi.get_tls_cert_blob ...'
|
223
|
+
end
|
224
|
+
# unbox the parameters from the hash
|
225
|
+
tls_certificate_id = opts[:'tls_certificate_id']
|
226
|
+
# verify the required parameter 'tls_certificate_id' is set
|
227
|
+
if @api_client.config.client_side_validation && tls_certificate_id.nil?
|
228
|
+
fail ArgumentError, "Missing the required parameter 'tls_certificate_id' when calling TlsCertificatesApi.get_tls_cert_blob"
|
229
|
+
end
|
230
|
+
# resource path
|
231
|
+
local_var_path = '/tls/certificates/{tls_certificate_id}/blob'.sub('{' + 'tls_certificate_id' + '}', CGI.escape(tls_certificate_id.to_s))
|
232
|
+
|
233
|
+
# query parameters
|
234
|
+
query_params = opts[:query_params] || {}
|
235
|
+
|
236
|
+
# header parameters
|
237
|
+
header_params = opts[:header_params] || {}
|
238
|
+
# HTTP header 'Accept' (if needed)
|
239
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
240
|
+
|
241
|
+
# form parameters
|
242
|
+
form_params = opts[:form_params] || {}
|
243
|
+
|
244
|
+
# http body (model)
|
245
|
+
post_body = opts[:debug_body]
|
246
|
+
|
247
|
+
# return_type
|
248
|
+
return_type = opts[:debug_return_type] || 'TlsCertificateBlobResponse'
|
249
|
+
|
250
|
+
# auth_names
|
251
|
+
auth_names = opts[:debug_auth_names] || ['token']
|
252
|
+
|
253
|
+
new_options = opts.merge(
|
254
|
+
:operation => :"TlsCertificatesApi.get_tls_cert_blob",
|
255
|
+
:header_params => header_params,
|
256
|
+
:query_params => query_params,
|
257
|
+
:form_params => form_params,
|
258
|
+
:body => post_body,
|
259
|
+
:auth_names => auth_names,
|
260
|
+
:return_type => return_type
|
261
|
+
)
|
262
|
+
|
263
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
264
|
+
if @api_client.config.debugging
|
265
|
+
@api_client.config.logger.debug "API called: TlsCertificatesApi#get_tls_cert_blob\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
266
|
+
end
|
267
|
+
return data, status_code, headers
|
268
|
+
end
|
269
|
+
|
207
270
|
# List TLS certificates
|
208
271
|
# List all TLS certificates.
|
209
272
|
# @option opts [String] :filter_in_use Optional. Limit the returned certificates to those currently using Fastly to terminate TLS (that is, certificates associated with an activation). Permitted values: true, false.
|