lib/fastly/api/historical_api.rb in fastly-7.2.2 vs lib/fastly/api/historical_api.rb in fastly-8.0.0

- old
+ new

@@ -21,11 +21,11 @@ # Fetches historical stats for each of your Fastly services and groups the results by service ID. # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [HistoricalResponse] + # @return [HistoricalStatsByServiceResponse] def get_hist_stats(opts = {}) data, _status_code, _headers = get_hist_stats_with_http_info(opts) data end @@ -33,11 +33,11 @@ # Fetches historical stats for each of your Fastly services and groups the results by service ID. # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [Array<(HistoricalResponse, Integer, Hash)>] HistoricalResponse data, response status code and response headers + # @return [Array<(HistoricalStatsByServiceResponse, Integer, Hash)>] HistoricalStatsByServiceResponse data, response status code and response headers def get_hist_stats_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: HistoricalApi.get_hist_stats ...' end # unbox the parameters from the hash @@ -69,11 +69,11 @@ # http body (model) post_body = opts[:debug_body] # return_type - return_type = opts[:debug_return_type] || 'HistoricalResponse' + return_type = opts[:debug_return_type] || 'HistoricalStatsByServiceResponse' # auth_names auth_names = opts[:debug_auth_names] || ['token'] new_options = opts.merge( @@ -97,11 +97,11 @@ # Fetches historical stats information aggregated across all of your Fastly services. # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [HistoricalAggregateResponse] + # @return [HistoricalStatsAggregatedResponse] def get_hist_stats_aggregated(opts = {}) data, _status_code, _headers = get_hist_stats_aggregated_with_http_info(opts) data end @@ -109,11 +109,11 @@ # Fetches historical stats information aggregated across all of your Fastly services. # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [Array<(HistoricalAggregateResponse, Integer, Hash)>] HistoricalAggregateResponse data, response status code and response headers + # @return [Array<(HistoricalStatsAggregatedResponse, Integer, Hash)>] HistoricalStatsAggregatedResponse data, response status code and response headers def get_hist_stats_aggregated_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: HistoricalApi.get_hist_stats_aggregated ...' end # unbox the parameters from the hash @@ -145,11 +145,11 @@ # http body (model) post_body = opts[:debug_body] # return_type - return_type = opts[:debug_return_type] || 'HistoricalAggregateResponse' + return_type = opts[:debug_return_type] || 'HistoricalStatsAggregatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['token'] new_options = opts.merge( @@ -174,11 +174,11 @@ # @option opts [String] :field Name of the stats field. (required) # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [HistoricalFieldResponse] + # @return [HistoricalStatsByServiceResponse] def get_hist_stats_field(opts = {}) data, _status_code, _headers = get_hist_stats_field_with_http_info(opts) data end @@ -187,11 +187,11 @@ # @option opts [String] :field Name of the stats field. (required) # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [Array<(HistoricalFieldResponse, Integer, Hash)>] HistoricalFieldResponse data, response status code and response headers + # @return [Array<(HistoricalStatsByServiceResponse, Integer, Hash)>] HistoricalStatsByServiceResponse data, response status code and response headers def get_hist_stats_field_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: HistoricalApi.get_hist_stats_field ...' end # unbox the parameters from the hash @@ -228,11 +228,11 @@ # http body (model) post_body = opts[:debug_body] # return_type - return_type = opts[:debug_return_type] || 'HistoricalFieldResponse' + return_type = opts[:debug_return_type] || 'HistoricalStatsByServiceResponse' # auth_names auth_names = opts[:debug_auth_names] || ['token'] new_options = opts.merge( @@ -257,11 +257,11 @@ # @option opts [String] :service_id Alphanumeric string identifying the service. (required) # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [HistoricalAggregateResponse] + # @return [HistoricalStatsAggregatedResponse] def get_hist_stats_service(opts = {}) data, _status_code, _headers = get_hist_stats_service_with_http_info(opts) data end @@ -270,11 +270,11 @@ # @option opts [String] :service_id Alphanumeric string identifying the service. (required) # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [Array<(HistoricalAggregateResponse, Integer, Hash)>] HistoricalAggregateResponse data, response status code and response headers + # @return [Array<(HistoricalStatsAggregatedResponse, Integer, Hash)>] HistoricalStatsAggregatedResponse data, response status code and response headers def get_hist_stats_service_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: HistoricalApi.get_hist_stats_service ...' end # unbox the parameters from the hash @@ -311,11 +311,11 @@ # http body (model) post_body = opts[:debug_body] # return_type - return_type = opts[:debug_return_type] || 'HistoricalAggregateResponse' + return_type = opts[:debug_return_type] || 'HistoricalStatsAggregatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['token'] new_options = opts.merge( @@ -341,11 +341,11 @@ # @option opts [String] :field Name of the stats field. (required) # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [HistoricalFieldAggregateResponse] + # @return [HistoricalStatsAggregatedResponse] def get_hist_stats_service_field(opts = {}) data, _status_code, _headers = get_hist_stats_service_field_with_http_info(opts) data end @@ -355,11 +355,11 @@ # @option opts [String] :field Name of the stats field. (required) # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') # @option opts [String] :by Duration of sample windows. One of: * &#x60;hour&#x60; - Group data by hour. * &#x60;minute&#x60; - Group data by minute. * &#x60;day&#x60; - Group data by day. (default to 'day') # @option opts [String] :region Limit query to a specific geographic region. One of: * &#x60;usa&#x60; - North America. * &#x60;europe&#x60; - Europe. * &#x60;anzac&#x60; - Australia and New Zealand. * &#x60;asia&#x60; - Asia. * &#x60;asia_india&#x60; - India. * &#x60;asia_southkorea&#x60; - South Korea. * &#x60;africa_std&#x60; - Africa. * &#x60;southamerica_std&#x60; - South America. - # @return [Array<(HistoricalFieldAggregateResponse, Integer, Hash)>] HistoricalFieldAggregateResponse data, response status code and response headers + # @return [Array<(HistoricalStatsAggregatedResponse, Integer, Hash)>] HistoricalStatsAggregatedResponse data, response status code and response headers def get_hist_stats_service_field_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: HistoricalApi.get_hist_stats_service_field ...' end # unbox the parameters from the hash @@ -401,11 +401,11 @@ # http body (model) post_body = opts[:debug_body] # return_type - return_type = opts[:debug_return_type] || 'HistoricalFieldAggregateResponse' + return_type = opts[:debug_return_type] || 'HistoricalStatsAggregatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['token'] new_options = opts.merge( @@ -483,21 +483,21 @@ # Get usage statistics # Returns usage information aggregated across all Fastly services and grouped by region. To aggregate across all Fastly services by time period, see [`/stats/aggregate`](#get-hist-stats-aggregated). # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') - # @return [HistoricalUsageAggregateResponse] + # @return [HistoricalUsageAggregatedResponse] def get_usage(opts = {}) data, _status_code, _headers = get_usage_with_http_info(opts) data end # Get usage statistics # Returns usage information aggregated across all Fastly services and grouped by region. To aggregate across all Fastly services by time period, see [&#x60;/stats/aggregate&#x60;](#get-hist-stats-aggregated). # @option opts [String] :from Timestamp that defines the start of the window for which to fetch statistics, including the timestamp itself. Accepts Unix timestamps, or any form of input parsable by the [Chronic Ruby library](https://github.com/mojombo/chronic), such as &#39;yesterday&#39;, or &#39;two weeks ago&#39;. Default varies based on the value of &#x60;by&#x60;. # @option opts [String] :to Timestamp that defines the end of the window for which to fetch statistics. Accepts the same formats as &#x60;from&#x60;. (default to 'now') - # @return [Array<(HistoricalUsageAggregateResponse, Integer, Hash)>] HistoricalUsageAggregateResponse data, response status code and response headers + # @return [Array<(HistoricalUsageAggregatedResponse, Integer, Hash)>] HistoricalUsageAggregatedResponse data, response status code and response headers def get_usage_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: HistoricalApi.get_usage ...' end # unbox the parameters from the hash @@ -519,10 +519,10 @@ # http body (model) post_body = opts[:debug_body] # return_type - return_type = opts[:debug_return_type] || 'HistoricalUsageAggregateResponse' + return_type = opts[:debug_return_type] || 'HistoricalUsageAggregatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['token'] new_options = opts.merge(