diff --git a/.apigentools-info b/.apigentools-info index 570e7f1467d6..2a0ed52148f7 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.6.6", - "regenerated": "2024-07-17 14:52:48.536491", - "spec_repo_commit": "3bf67773" + "regenerated": "2024-07-17 20:47:00.852804", + "spec_repo_commit": "786a1731" }, "v2": { "apigentools_version": "1.6.6", - "regenerated": "2024-07-17 14:52:48.553866", - "spec_repo_commit": "3bf67773" + "regenerated": "2024-07-17 20:47:00.870774", + "spec_repo_commit": "786a1731" } } } \ No newline at end of file diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 1231b5a840da..270084c334ad 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -8741,6 +8741,12 @@ components: description: Attributes of hourly usage for a product family for an org for a time period. properties: + account_name: + description: The account name. + type: string + account_public_id: + description: The account public ID. + type: string measurements: description: List of the measured usage values for the product family for the org for the time period. @@ -36770,6 +36776,15 @@ paths: schema: default: false type: boolean + - description: Boolean to specify whether to include accounts connected to the + current account as partner customers in the Datadog partner network program. + Defaults to false. + in: query + name: filter[include_connected_accounts] + required: false + schema: + default: false + type: boolean - description: Include breakdown of usage by subcategories where applicable (for product family logs only). Defaults to false. in: query diff --git a/features/scenarios_model_mapping.rb b/features/scenarios_model_mapping.rb index 0d7dd60a8e4d..0a88c4fecbb6 100644 --- a/features/scenarios_model_mapping.rb +++ b/features/scenarios_model_mapping.rb @@ -1109,6 +1109,7 @@ "filter_timestamp_end" => "Time", "filter_product_families" => "String", "filter_include_descendants" => "Boolean", + "filter_include_connected_accounts" => "Boolean", "filter_include_breakdown" => "Boolean", "filter_versions" => "String", "page_limit" => "Integer", diff --git a/lib/datadog_api_client/v2/api/usage_metering_api.rb b/lib/datadog_api_client/v2/api/usage_metering_api.rb index b757c0bd2793..0691b1ec1929 100644 --- a/lib/datadog_api_client/v2/api/usage_metering_api.rb +++ b/lib/datadog_api_client/v2/api/usage_metering_api.rb @@ -333,6 +333,7 @@ def get_hourly_usage(filter_timestamp_start, filter_product_families, opts = {}) # @param opts [Hash] the optional parameters # @option opts [Time] :filter_timestamp_end Datetime in ISO-8601 format, UTC, precise to hour: [YYYY-MM-DDThh] for usage ending **before** this hour. # @option opts [Boolean] :filter_include_descendants Include child org usage in the response. Defaults to false. + # @option opts [Boolean] :filter_include_connected_accounts Boolean to specify whether to include accounts connected to the current account as partner customers in the Datadog partner network program. Defaults to false. # @option opts [Boolean] :filter_include_breakdown Include breakdown of usage by subcategories where applicable (for product family logs only). Defaults to false. # @option opts [String] :filter_versions Comma separated list of product family versions to use in the format `product_family:version`. For example, `infra_hosts:1.0.0`. If this parameter is not used, the API will use the latest version of each requested product family. Currently all families have one version `1.0.0`. # @option opts [Integer] :page_limit Maximum number of results to return (between 1 and 500) - defaults to 500 if limit not specified. @@ -366,6 +367,7 @@ def get_hourly_usage_with_http_info(filter_timestamp_start, filter_product_famil query_params[:'filter[product_families]'] = filter_product_families query_params[:'filter[timestamp][end]'] = opts[:'filter_timestamp_end'] if !opts[:'filter_timestamp_end'].nil? query_params[:'filter[include_descendants]'] = opts[:'filter_include_descendants'] if !opts[:'filter_include_descendants'].nil? + query_params[:'filter[include_connected_accounts]'] = opts[:'filter_include_connected_accounts'] if !opts[:'filter_include_connected_accounts'].nil? query_params[:'filter[include_breakdown]'] = opts[:'filter_include_breakdown'] if !opts[:'filter_include_breakdown'].nil? query_params[:'filter[versions]'] = opts[:'filter_versions'] if !opts[:'filter_versions'].nil? query_params[:'page[limit]'] = opts[:'page_limit'] if !opts[:'page_limit'].nil? diff --git a/lib/datadog_api_client/v2/models/hourly_usage_attributes.rb b/lib/datadog_api_client/v2/models/hourly_usage_attributes.rb index 73a2dd8b9b77..f2562cf9c9c5 100644 --- a/lib/datadog_api_client/v2/models/hourly_usage_attributes.rb +++ b/lib/datadog_api_client/v2/models/hourly_usage_attributes.rb @@ -21,6 +21,12 @@ module DatadogAPIClient::V2 class HourlyUsageAttributes include BaseGenericModel + # The account name. + attr_accessor :account_name + + # The account public ID. + attr_accessor :account_public_id + # List of the measured usage values for the product family for the org for the time period. attr_accessor :measurements @@ -43,6 +49,8 @@ class HourlyUsageAttributes # @!visibility private def self.attribute_map { + :'account_name' => :'account_name', + :'account_public_id' => :'account_public_id', :'measurements' => :'measurements', :'org_name' => :'org_name', :'product_family' => :'product_family', @@ -56,6 +64,8 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'account_name' => :'String', + :'account_public_id' => :'String', :'measurements' => :'Array', :'org_name' => :'String', :'product_family' => :'String', @@ -81,6 +91,14 @@ def initialize(attributes = {}) h[k.to_sym] = v } + if attributes.key?(:'account_name') + self.account_name = attributes[:'account_name'] + end + + if attributes.key?(:'account_public_id') + self.account_public_id = attributes[:'account_public_id'] + end + if attributes.key?(:'measurements') if (value = attributes[:'measurements']).is_a?(Array) self.measurements = value @@ -114,6 +132,8 @@ def initialize(attributes = {}) def ==(o) return true if self.equal?(o) self.class == o.class && + account_name == o.account_name && + account_public_id == o.account_public_id && measurements == o.measurements && org_name == o.org_name && product_family == o.product_family && @@ -126,7 +146,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [measurements, org_name, product_family, public_id, region, timestamp].hash + [account_name, account_public_id, measurements, org_name, product_family, public_id, region, timestamp].hash end end end