From 4b27b85786e6fc921223a02416a13f15a0b65757 Mon Sep 17 00:00:00 2001 From: "ci.datadog-api-spec" Date: Fri, 22 May 2026 17:02:38 +0000 Subject: [PATCH] Regenerate client from commit 8e38215 of spec repo --- .generator/schemas/v2/openapi.yaml | 86 ++--------- .../v2/org-groups/CreateOrgGroupPolicy.rb | 2 +- .../v2/org-groups/UpdateOrgGroupPolicy.rb | 2 +- features/scenarios_model_mapping.rb | 1 - features/v2/org_groups.feature | 12 +- lib/datadog_api_client/inflector.rb | 4 - .../v2/api/org_groups_api.rb | 2 - .../v2/models/org_group_data.rb | 12 +- .../v2/models/org_group_include_option.rb | 26 ---- .../v2/models/org_group_list_response.rb | 14 +- .../org_group_membership_relationship_data.rb | 144 ------------------ .../org_group_memberships_relationship.rb | 125 --------------- .../v2/models/org_group_policy_attributes.rb | 2 +- .../org_group_policy_create_attributes.rb | 2 +- .../org_group_policy_enforcement_tier.rb | 6 +- .../org_group_policy_update_attributes.rb | 2 +- .../v2/models/org_group_relationships.rb | 105 ------------- 17 files changed, 29 insertions(+), 518 deletions(-) delete mode 100644 lib/datadog_api_client/v2/models/org_group_include_option.rb delete mode 100644 lib/datadog_api_client/v2/models/org_group_membership_relationship_data.rb delete mode 100644 lib/datadog_api_client/v2/models/org_group_memberships_relationship.rb delete mode 100644 lib/datadog_api_client/v2/models/org_group_relationships.rb diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 22fc24351728..ae382a0be9a4 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -1051,20 +1051,6 @@ components: example: "a1b2c3d4-e5f6-7890-abcd-ef0123456789" format: uuid type: string - OrgGroupInclude: - description: >- - List of related resources to include. - explode: false - in: query - name: include - required: false - schema: - example: - - memberships - items: - $ref: "#/components/schemas/OrgGroupIncludeOption" - type: array - style: form OrgGroupMembershipFilterOrgGroupId: description: Filter memberships by org group ID. Required when `filter[org_uuid]` is not provided. in: query @@ -59225,8 +59211,6 @@ components: example: "a1b2c3d4-e5f6-7890-abcd-ef0123456789" format: uuid type: string - relationships: - $ref: "#/components/schemas/OrgGroupRelationships" type: $ref: "#/components/schemas/OrgGroupType" required: @@ -59234,13 +59218,6 @@ components: - type - attributes type: object - OrgGroupIncludeOption: - description: Allowed include options for org group endpoints. - enum: - - memberships - type: string - x-enum-varnames: - - MEMBERSHIPS OrgGroupListResponse: description: Response containing a list of org groups. properties: @@ -59249,11 +59226,6 @@ components: items: $ref: "#/components/schemas/OrgGroupData" type: array - included: - description: Related resources included in the response when requested with the `include` parameter. - items: - $ref: "#/components/schemas/OrgGroupMembershipData" - type: array links: $ref: "#/components/schemas/OrgGroupPaginationLinks" meta: @@ -59380,20 +59352,6 @@ components: required: - data type: object - OrgGroupMembershipRelationshipData: - description: A reference to an org group membership. - properties: - id: - description: The ID of the membership. - example: "f1e2d3c4-b5a6-7890-1234-567890abcdef" - format: uuid - type: string - type: - $ref: "#/components/schemas/OrgGroupMembershipType" - required: - - id - - type - type: object OrgGroupMembershipRelationships: description: Relationships of an org group membership. properties: @@ -59464,17 +59422,6 @@ components: required: - data type: object - OrgGroupMembershipsRelationship: - description: Relationship to org group memberships. - properties: - data: - description: An array of membership relationship references. - items: - $ref: "#/components/schemas/OrgGroupMembershipRelationshipData" - type: array - required: - - data - type: object OrgGroupPaginationLinks: description: Pagination links for navigating between pages of an org group list response. properties: @@ -59708,18 +59655,18 @@ components: - attributes type: object OrgGroupPolicyEnforcementTier: - default: DEFAULT + default: OVERRIDE_ALLOWED description: >- - The enforcement tier of the policy. `DEFAULT` means the policy is set but member orgs may mutate it. `ENFORCE` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. + The enforcement tier of the policy. `OVERRIDE_ALLOWED` means the policy is set but member orgs may mutate it. `GROUP_MANAGED` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. enum: - - DEFAULT - - ENFORCE + - OVERRIDE_ALLOWED + - GROUP_MANAGED - DELEGATE - example: DEFAULT + example: OVERRIDE_ALLOWED type: string x-enum-varnames: - - DEFAULT - - ENFORCE + - OVERRIDE_ALLOWED + - GROUP_MANAGED - DELEGATE OrgGroupPolicyListResponse: description: Response containing a list of org group policies. @@ -60060,12 +60007,6 @@ components: - id - type type: object - OrgGroupRelationships: - description: Relationships of an org group. - properties: - memberships: - $ref: "#/components/schemas/OrgGroupMembershipsRelationship" - type: object OrgGroupResponse: description: Response containing a single org group. properties: @@ -133887,7 +133828,7 @@ paths: - attributes: content: value: "UTC" - enforcement_tier: "DEFAULT" + enforcement_tier: "OVERRIDE_ALLOWED" modified_at: "2024-01-15T10:30:00Z" policy_name: "monitor_timezone" policy_type: "org_config" @@ -133959,7 +133900,7 @@ paths: attributes: content: value: "UTC" - enforcement_tier: "DEFAULT" + enforcement_tier: "OVERRIDE_ALLOWED" policy_name: "monitor_timezone" policy_type: "org_config" relationships: @@ -133982,7 +133923,7 @@ paths: attributes: content: value: "UTC" - enforcement_tier: "DEFAULT" + enforcement_tier: "OVERRIDE_ALLOWED" modified_at: "2024-01-15T10:30:00Z" policy_name: "monitor_timezone" policy_type: "org_config" @@ -134091,7 +134032,7 @@ paths: attributes: content: value: "UTC" - enforcement_tier: "DEFAULT" + enforcement_tier: "OVERRIDE_ALLOWED" modified_at: "2024-01-15T10:30:00Z" policy_name: "monitor_timezone" policy_type: "org_config" @@ -134155,7 +134096,7 @@ paths: attributes: content: value: "US/Eastern" - enforcement_tier: "ENFORCE" + enforcement_tier: "GROUP_MANAGED" id: "1a2b3c4d-5e6f-7890-abcd-ef0123456789" type: org_group_policies schema: @@ -134172,7 +134113,7 @@ paths: attributes: content: value: "US/Eastern" - enforcement_tier: "ENFORCE" + enforcement_tier: "GROUP_MANAGED" modified_at: "2024-01-16T14:00:00Z" policy_name: "monitor_timezone" policy_type: "org_config" @@ -134639,7 +134580,6 @@ paths: - $ref: "#/components/parameters/OrgGroupPageNumber" - $ref: "#/components/parameters/OrgGroupPageSize" - $ref: "#/components/parameters/OrgGroupSort" - - $ref: "#/components/parameters/OrgGroupInclude" responses: "200": content: diff --git a/examples/v2/org-groups/CreateOrgGroupPolicy.rb b/examples/v2/org-groups/CreateOrgGroupPolicy.rb index f39901d82005..095a7f55df13 100644 --- a/examples/v2/org-groups/CreateOrgGroupPolicy.rb +++ b/examples/v2/org-groups/CreateOrgGroupPolicy.rb @@ -12,7 +12,7 @@ content: { "value": "UTC", }, - enforcement_tier: DatadogAPIClient::V2::OrgGroupPolicyEnforcementTier::DEFAULT, + enforcement_tier: DatadogAPIClient::V2::OrgGroupPolicyEnforcementTier::OVERRIDE_ALLOWED, policy_name: "monitor_timezone", policy_type: DatadogAPIClient::V2::OrgGroupPolicyPolicyType::ORG_CONFIG, }), diff --git a/examples/v2/org-groups/UpdateOrgGroupPolicy.rb b/examples/v2/org-groups/UpdateOrgGroupPolicy.rb index 12c658ee0b7f..c2e69cd07832 100644 --- a/examples/v2/org-groups/UpdateOrgGroupPolicy.rb +++ b/examples/v2/org-groups/UpdateOrgGroupPolicy.rb @@ -12,7 +12,7 @@ content: { "value": "UTC", }, - enforcement_tier: DatadogAPIClient::V2::OrgGroupPolicyEnforcementTier::DEFAULT, + enforcement_tier: DatadogAPIClient::V2::OrgGroupPolicyEnforcementTier::OVERRIDE_ALLOWED, }), id: "1a2b3c4d-5e6f-7890-abcd-ef0123456789", type: DatadogAPIClient::V2::OrgGroupPolicyType::ORG_GROUP_POLICIES, diff --git a/features/scenarios_model_mapping.rb b/features/scenarios_model_mapping.rb index 67ed43751475..89ac9711f850 100644 --- a/features/scenarios_model_mapping.rb +++ b/features/scenarios_model_mapping.rb @@ -4008,7 +4008,6 @@ "page_number" => "Integer", "page_size" => "Integer", "sort" => "OrgGroupSortOption", - "include" => "Array", }, "v2.CreateOrgGroup" => { "body" => "OrgGroupCreateRequest", diff --git a/features/v2/org_groups.feature b/features/v2/org_groups.feature index b8c5fe1b61d1..58065ea87fc7 100644 --- a/features/v2/org_groups.feature +++ b/features/v2/org_groups.feature @@ -60,7 +60,7 @@ Feature: Org Groups Scenario: Create an org group policy returns "Bad Request" response Given operation "CreateOrgGroupPolicy" enabled And new "CreateOrgGroupPolicy" request - And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "DEFAULT", "policy_name": "monitor_timezone", "policy_type": "org_config"}, "relationships": {"org_group": {"data": {"id": "a1b2c3d4-e5f6-7890-abcd-ef0123456789", "type": "org_groups"}}}, "type": "org_group_policies"}} + And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "OVERRIDE_ALLOWED", "policy_name": "monitor_timezone", "policy_type": "org_config"}, "relationships": {"org_group": {"data": {"id": "a1b2c3d4-e5f6-7890-abcd-ef0123456789", "type": "org_groups"}}}, "type": "org_group_policies"}} When the request is sent Then the response status is 400 Bad Request @@ -68,7 +68,7 @@ Feature: Org Groups Scenario: Create an org group policy returns "Conflict" response Given operation "CreateOrgGroupPolicy" enabled And new "CreateOrgGroupPolicy" request - And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "DEFAULT", "policy_name": "monitor_timezone", "policy_type": "org_config"}, "relationships": {"org_group": {"data": {"id": "a1b2c3d4-e5f6-7890-abcd-ef0123456789", "type": "org_groups"}}}, "type": "org_group_policies"}} + And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "OVERRIDE_ALLOWED", "policy_name": "monitor_timezone", "policy_type": "org_config"}, "relationships": {"org_group": {"data": {"id": "a1b2c3d4-e5f6-7890-abcd-ef0123456789", "type": "org_groups"}}}, "type": "org_group_policies"}} When the request is sent Then the response status is 409 Conflict @@ -76,7 +76,7 @@ Feature: Org Groups Scenario: Create an org group policy returns "Created" response Given operation "CreateOrgGroupPolicy" enabled And new "CreateOrgGroupPolicy" request - And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "DEFAULT", "policy_name": "monitor_timezone", "policy_type": "org_config"}, "relationships": {"org_group": {"data": {"id": "a1b2c3d4-e5f6-7890-abcd-ef0123456789", "type": "org_groups"}}}, "type": "org_group_policies"}} + And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "OVERRIDE_ALLOWED", "policy_name": "monitor_timezone", "policy_type": "org_config"}, "relationships": {"org_group": {"data": {"id": "a1b2c3d4-e5f6-7890-abcd-ef0123456789", "type": "org_groups"}}}, "type": "org_group_policies"}} When the request is sent Then the response status is 201 Created @@ -398,7 +398,7 @@ Feature: Org Groups Given operation "UpdateOrgGroupPolicy" enabled And new "UpdateOrgGroupPolicy" request And request contains "org_group_policy_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "DEFAULT"}, "id": "1a2b3c4d-5e6f-7890-abcd-ef0123456789", "type": "org_group_policies"}} + And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "OVERRIDE_ALLOWED"}, "id": "1a2b3c4d-5e6f-7890-abcd-ef0123456789", "type": "org_group_policies"}} When the request is sent Then the response status is 400 Bad Request @@ -407,7 +407,7 @@ Feature: Org Groups Given operation "UpdateOrgGroupPolicy" enabled And new "UpdateOrgGroupPolicy" request And request contains "org_group_policy_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "DEFAULT"}, "id": "1a2b3c4d-5e6f-7890-abcd-ef0123456789", "type": "org_group_policies"}} + And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "OVERRIDE_ALLOWED"}, "id": "1a2b3c4d-5e6f-7890-abcd-ef0123456789", "type": "org_group_policies"}} When the request is sent Then the response status is 404 Not Found @@ -416,7 +416,7 @@ Feature: Org Groups Given operation "UpdateOrgGroupPolicy" enabled And new "UpdateOrgGroupPolicy" request And request contains "org_group_policy_id" parameter from "REPLACE.ME" - And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "DEFAULT"}, "id": "1a2b3c4d-5e6f-7890-abcd-ef0123456789", "type": "org_group_policies"}} + And body with value {"data": {"attributes": {"content": {"value": "UTC"}, "enforcement_tier": "OVERRIDE_ALLOWED"}, "id": "1a2b3c4d-5e6f-7890-abcd-ef0123456789", "type": "org_group_policies"}} When the request is sent Then the response status is 200 OK diff --git a/lib/datadog_api_client/inflector.rb b/lib/datadog_api_client/inflector.rb index 187627b2d0a6..4c2366f9397d 100644 --- a/lib/datadog_api_client/inflector.rb +++ b/lib/datadog_api_client/inflector.rb @@ -4736,7 +4736,6 @@ def overrides "v2.org_group_create_data" => "OrgGroupCreateData", "v2.org_group_create_request" => "OrgGroupCreateRequest", "v2.org_group_data" => "OrgGroupData", - "v2.org_group_include_option" => "OrgGroupIncludeOption", "v2.org_group_list_response" => "OrgGroupListResponse", "v2.org_group_membership_attributes" => "OrgGroupMembershipAttributes", "v2.org_group_membership_bulk_update_attributes" => "OrgGroupMembershipBulkUpdateAttributes", @@ -4746,11 +4745,9 @@ def overrides "v2.org_group_membership_bulk_update_type" => "OrgGroupMembershipBulkUpdateType", "v2.org_group_membership_data" => "OrgGroupMembershipData", "v2.org_group_membership_list_response" => "OrgGroupMembershipListResponse", - "v2.org_group_membership_relationship_data" => "OrgGroupMembershipRelationshipData", "v2.org_group_membership_relationships" => "OrgGroupMembershipRelationships", "v2.org_group_membership_response" => "OrgGroupMembershipResponse", "v2.org_group_membership_sort_option" => "OrgGroupMembershipSortOption", - "v2.org_group_memberships_relationship" => "OrgGroupMembershipsRelationship", "v2.org_group_membership_type" => "OrgGroupMembershipType", "v2.org_group_membership_update_data" => "OrgGroupMembershipUpdateData", "v2.org_group_membership_update_relationships" => "OrgGroupMembershipUpdateRelationships", @@ -4794,7 +4791,6 @@ def overrides "v2.org_group_policy_update_attributes" => "OrgGroupPolicyUpdateAttributes", "v2.org_group_policy_update_data" => "OrgGroupPolicyUpdateData", "v2.org_group_policy_update_request" => "OrgGroupPolicyUpdateRequest", - "v2.org_group_relationships" => "OrgGroupRelationships", "v2.org_group_relationship_to_one" => "OrgGroupRelationshipToOne", "v2.org_group_relationship_to_one_data" => "OrgGroupRelationshipToOneData", "v2.org_group_response" => "OrgGroupResponse", diff --git a/lib/datadog_api_client/v2/api/org_groups_api.rb b/lib/datadog_api_client/v2/api/org_groups_api.rb index b413a33ecf84..9e2eb61ee9fa 100644 --- a/lib/datadog_api_client/v2/api/org_groups_api.rb +++ b/lib/datadog_api_client/v2/api/org_groups_api.rb @@ -1169,7 +1169,6 @@ def list_org_groups(opts = {}) # @option opts [Integer] :page_number The page number to return. # @option opts [Integer] :page_size The number of items per page. Maximum is 1000. # @option opts [OrgGroupSortOption] :sort Field to sort org groups by. Supported values: `name`, `uuid`, `-name`, `-uuid`. Defaults to `uuid`. - # @option opts [Array] :include List of related resources to include. # @return [Array<(OrgGroupListResponse, Integer, Hash)>] OrgGroupListResponse data, response status code and response headers def list_org_groups_with_http_info(opts = {}) unstable_enabled = @api_client.config.unstable_operations["v2.list_org_groups".to_sym] @@ -1203,7 +1202,6 @@ def list_org_groups_with_http_info(opts = {}) query_params[:'page[number]'] = opts[:'page_number'] if !opts[:'page_number'].nil? query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil? query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil? - query_params[:'include'] = @api_client.build_collection_param(opts[:'include'], :csv) if !opts[:'include'].nil? # header parameters header_params = opts[:header_params] || {} diff --git a/lib/datadog_api_client/v2/models/org_group_data.rb b/lib/datadog_api_client/v2/models/org_group_data.rb index 433f78988a82..92f436426ced 100644 --- a/lib/datadog_api_client/v2/models/org_group_data.rb +++ b/lib/datadog_api_client/v2/models/org_group_data.rb @@ -27,9 +27,6 @@ class OrgGroupData # The ID of the org group. attr_reader :id - # Relationships of an org group. - attr_accessor :relationships - # Org groups resource type. attr_reader :type @@ -41,7 +38,6 @@ def self.attribute_map { :'attributes' => :'attributes', :'id' => :'id', - :'relationships' => :'relationships', :'type' => :'type' } end @@ -52,7 +48,6 @@ def self.openapi_types { :'attributes' => :'OrgGroupAttributes', :'id' => :'UUID', - :'relationships' => :'OrgGroupRelationships', :'type' => :'OrgGroupType' } end @@ -83,10 +78,6 @@ def initialize(attributes = {}) self.id = attributes[:'id'] end - if attributes.key?(:'relationships') - self.relationships = attributes[:'relationships'] - end - if attributes.key?(:'type') self.type = attributes[:'type'] end @@ -160,7 +151,6 @@ def ==(o) self.class == o.class && attributes == o.attributes && id == o.id && - relationships == o.relationships && type == o.type && additional_properties == o.additional_properties end @@ -169,7 +159,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [attributes, id, relationships, type, additional_properties].hash + [attributes, id, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/org_group_include_option.rb b/lib/datadog_api_client/v2/models/org_group_include_option.rb deleted file mode 100644 index 520bd1864b4f..000000000000 --- a/lib/datadog_api_client/v2/models/org_group_include_option.rb +++ /dev/null @@ -1,26 +0,0 @@ -=begin -#Datadog API V2 Collection - -#Collection of all Datadog Public endpoints. - -The version of the OpenAPI document: 1.0 -Contact: support@datadoghq.com -Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator - - Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. - This product includes software developed at Datadog (https://www.datadoghq.com/). - Copyright 2020-Present Datadog, Inc. - -=end - -require 'date' -require 'time' - -module DatadogAPIClient::V2 - # Allowed include options for org group endpoints. - class OrgGroupIncludeOption - include BaseEnumModel - - MEMBERSHIPS = "memberships".freeze - end -end diff --git a/lib/datadog_api_client/v2/models/org_group_list_response.rb b/lib/datadog_api_client/v2/models/org_group_list_response.rb index ca97b20718df..3b2621ba3456 100644 --- a/lib/datadog_api_client/v2/models/org_group_list_response.rb +++ b/lib/datadog_api_client/v2/models/org_group_list_response.rb @@ -24,9 +24,6 @@ class OrgGroupListResponse # An array of org groups. attr_reader :data - # Related resources included in the response when requested with the `include` parameter. - attr_accessor :included - # Pagination links for navigating between pages of an org group list response. attr_accessor :links @@ -40,7 +37,6 @@ class OrgGroupListResponse def self.attribute_map { :'data' => :'data', - :'included' => :'included', :'links' => :'links', :'meta' => :'meta' } @@ -51,7 +47,6 @@ def self.attribute_map def self.openapi_types { :'data' => :'Array', - :'included' => :'Array', :'links' => :'OrgGroupPaginationLinks', :'meta' => :'OrgGroupPaginationMeta' } @@ -81,12 +76,6 @@ def initialize(attributes = {}) end end - if attributes.key?(:'included') - if (value = attributes[:'included']).is_a?(Array) - self.included = value - end - end - if attributes.key?(:'links') self.links = attributes[:'links'] end @@ -141,7 +130,6 @@ def ==(o) return true if self.equal?(o) self.class == o.class && data == o.data && - included == o.included && links == o.links && meta == o.meta && additional_properties == o.additional_properties @@ -151,7 +139,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [data, included, links, meta, additional_properties].hash + [data, links, meta, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/org_group_membership_relationship_data.rb b/lib/datadog_api_client/v2/models/org_group_membership_relationship_data.rb deleted file mode 100644 index 1c8d8829412a..000000000000 --- a/lib/datadog_api_client/v2/models/org_group_membership_relationship_data.rb +++ /dev/null @@ -1,144 +0,0 @@ -=begin -#Datadog API V2 Collection - -#Collection of all Datadog Public endpoints. - -The version of the OpenAPI document: 1.0 -Contact: support@datadoghq.com -Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator - - Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. - This product includes software developed at Datadog (https://www.datadoghq.com/). - Copyright 2020-Present Datadog, Inc. - -=end - -require 'date' -require 'time' - -module DatadogAPIClient::V2 - # A reference to an org group membership. - class OrgGroupMembershipRelationshipData - include BaseGenericModel - - # The ID of the membership. - attr_reader :id - - # Org group memberships resource type. - attr_reader :type - - attr_accessor :additional_properties - - # Attribute mapping from ruby-style variable name to JSON key. - # @!visibility private - def self.attribute_map - { - :'id' => :'id', - :'type' => :'type' - } - end - - # Attribute type mapping. - # @!visibility private - def self.openapi_types - { - :'id' => :'UUID', - :'type' => :'OrgGroupMembershipType' - } - end - - # Initializes the object - # @param attributes [Hash] Model attributes in the form of hash - # @!visibility private - def initialize(attributes = {}) - if (!attributes.is_a?(Hash)) - fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::OrgGroupMembershipRelationshipData` initialize method" - end - - self.additional_properties = {} - # check to see if the attribute exists and convert string to symbol for hash key - attributes = attributes.each_with_object({}) { |(k, v), h| - if (!self.class.attribute_map.key?(k.to_sym)) - self.additional_properties[k.to_sym] = v - else - h[k.to_sym] = v - end - } - - if attributes.key?(:'id') - self.id = attributes[:'id'] - end - - if attributes.key?(:'type') - self.type = attributes[:'type'] - end - end - - # Check to see if the all the properties in the model are valid - # @return true if the model is valid - # @!visibility private - def valid? - return false if @id.nil? - return false if @type.nil? - true - end - - # Custom attribute writer method with validation - # @param id [Object] Object to be assigned - # @!visibility private - def id=(id) - if id.nil? - fail ArgumentError, 'invalid value for "id", id cannot be nil.' - end - @id = id - end - - # Custom attribute writer method with validation - # @param type [Object] Object to be assigned - # @!visibility private - def type=(type) - if type.nil? - fail ArgumentError, 'invalid value for "type", type cannot be nil.' - end - @type = type - end - - # Returns the object in the form of hash, with additionalProperties support. - # @return [Hash] Returns the object in the form of hash - # @!visibility private - def to_hash - hash = {} - self.class.attribute_map.each_pair do |attr, param| - value = self.send(attr) - if value.nil? - is_nullable = self.class.openapi_nullable.include?(attr) - next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) - end - - hash[param] = _to_hash(value) - end - self.additional_properties.each_pair do |attr, value| - hash[attr] = value - end - hash - end - - # Checks equality by comparing each attribute. - # @param o [Object] Object to be compared - # @!visibility private - def ==(o) - return true if self.equal?(o) - self.class == o.class && - id == o.id && - type == o.type && - additional_properties == o.additional_properties - end - - # Calculates hash code according to all attributes. - # @return [Integer] Hash code - # @!visibility private - def hash - [id, type, additional_properties].hash - end - end -end diff --git a/lib/datadog_api_client/v2/models/org_group_memberships_relationship.rb b/lib/datadog_api_client/v2/models/org_group_memberships_relationship.rb deleted file mode 100644 index 12ac8d57568d..000000000000 --- a/lib/datadog_api_client/v2/models/org_group_memberships_relationship.rb +++ /dev/null @@ -1,125 +0,0 @@ -=begin -#Datadog API V2 Collection - -#Collection of all Datadog Public endpoints. - -The version of the OpenAPI document: 1.0 -Contact: support@datadoghq.com -Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator - - Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. - This product includes software developed at Datadog (https://www.datadoghq.com/). - Copyright 2020-Present Datadog, Inc. - -=end - -require 'date' -require 'time' - -module DatadogAPIClient::V2 - # Relationship to org group memberships. - class OrgGroupMembershipsRelationship - include BaseGenericModel - - # An array of membership relationship references. - attr_reader :data - - attr_accessor :additional_properties - - # Attribute mapping from ruby-style variable name to JSON key. - # @!visibility private - def self.attribute_map - { - :'data' => :'data' - } - end - - # Attribute type mapping. - # @!visibility private - def self.openapi_types - { - :'data' => :'Array' - } - end - - # Initializes the object - # @param attributes [Hash] Model attributes in the form of hash - # @!visibility private - def initialize(attributes = {}) - if (!attributes.is_a?(Hash)) - fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::OrgGroupMembershipsRelationship` initialize method" - end - - self.additional_properties = {} - # check to see if the attribute exists and convert string to symbol for hash key - attributes = attributes.each_with_object({}) { |(k, v), h| - if (!self.class.attribute_map.key?(k.to_sym)) - self.additional_properties[k.to_sym] = v - else - h[k.to_sym] = v - end - } - - if attributes.key?(:'data') - if (value = attributes[:'data']).is_a?(Array) - self.data = value - end - end - end - - # Check to see if the all the properties in the model are valid - # @return true if the model is valid - # @!visibility private - def valid? - return false if @data.nil? - true - end - - # Custom attribute writer method with validation - # @param data [Object] Object to be assigned - # @!visibility private - def data=(data) - if data.nil? - fail ArgumentError, 'invalid value for "data", data cannot be nil.' - end - @data = data - end - - # Returns the object in the form of hash, with additionalProperties support. - # @return [Hash] Returns the object in the form of hash - # @!visibility private - def to_hash - hash = {} - self.class.attribute_map.each_pair do |attr, param| - value = self.send(attr) - if value.nil? - is_nullable = self.class.openapi_nullable.include?(attr) - next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) - end - - hash[param] = _to_hash(value) - end - self.additional_properties.each_pair do |attr, value| - hash[attr] = value - end - hash - end - - # Checks equality by comparing each attribute. - # @param o [Object] Object to be compared - # @!visibility private - def ==(o) - return true if self.equal?(o) - self.class == o.class && - data == o.data && - additional_properties == o.additional_properties - end - - # Calculates hash code according to all attributes. - # @return [Integer] Hash code - # @!visibility private - def hash - [data, additional_properties].hash - end - end -end diff --git a/lib/datadog_api_client/v2/models/org_group_policy_attributes.rb b/lib/datadog_api_client/v2/models/org_group_policy_attributes.rb index 5e2e80bc59ae..546b80b5c8c2 100644 --- a/lib/datadog_api_client/v2/models/org_group_policy_attributes.rb +++ b/lib/datadog_api_client/v2/models/org_group_policy_attributes.rb @@ -24,7 +24,7 @@ class OrgGroupPolicyAttributes # The policy content as key-value pairs. attr_accessor :content - # The enforcement tier of the policy. `DEFAULT` means the policy is set but member orgs may mutate it. `ENFORCE` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. + # The enforcement tier of the policy. `OVERRIDE_ALLOWED` means the policy is set but member orgs may mutate it. `GROUP_MANAGED` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. attr_reader :enforcement_tier # Timestamp when the policy was last modified. diff --git a/lib/datadog_api_client/v2/models/org_group_policy_create_attributes.rb b/lib/datadog_api_client/v2/models/org_group_policy_create_attributes.rb index 67ed3baa68df..fa344aec210e 100644 --- a/lib/datadog_api_client/v2/models/org_group_policy_create_attributes.rb +++ b/lib/datadog_api_client/v2/models/org_group_policy_create_attributes.rb @@ -24,7 +24,7 @@ class OrgGroupPolicyCreateAttributes # The policy content as key-value pairs. attr_reader :content - # The enforcement tier of the policy. `DEFAULT` means the policy is set but member orgs may mutate it. `ENFORCE` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. + # The enforcement tier of the policy. `OVERRIDE_ALLOWED` means the policy is set but member orgs may mutate it. `GROUP_MANAGED` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. attr_accessor :enforcement_tier # The name of the policy. diff --git a/lib/datadog_api_client/v2/models/org_group_policy_enforcement_tier.rb b/lib/datadog_api_client/v2/models/org_group_policy_enforcement_tier.rb index b9bdbc49997e..4ae4778978d6 100644 --- a/lib/datadog_api_client/v2/models/org_group_policy_enforcement_tier.rb +++ b/lib/datadog_api_client/v2/models/org_group_policy_enforcement_tier.rb @@ -17,12 +17,12 @@ require 'time' module DatadogAPIClient::V2 - # The enforcement tier of the policy. `DEFAULT` means the policy is set but member orgs may mutate it. `ENFORCE` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. + # The enforcement tier of the policy. `OVERRIDE_ALLOWED` means the policy is set but member orgs may mutate it. `GROUP_MANAGED` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. class OrgGroupPolicyEnforcementTier include BaseEnumModel - DEFAULT = "DEFAULT".freeze - ENFORCE = "ENFORCE".freeze + OVERRIDE_ALLOWED = "OVERRIDE_ALLOWED".freeze + GROUP_MANAGED = "GROUP_MANAGED".freeze DELEGATE = "DELEGATE".freeze end end diff --git a/lib/datadog_api_client/v2/models/org_group_policy_update_attributes.rb b/lib/datadog_api_client/v2/models/org_group_policy_update_attributes.rb index 9ec9b8cc9b3e..17f68d52e33b 100644 --- a/lib/datadog_api_client/v2/models/org_group_policy_update_attributes.rb +++ b/lib/datadog_api_client/v2/models/org_group_policy_update_attributes.rb @@ -24,7 +24,7 @@ class OrgGroupPolicyUpdateAttributes # The policy content as key-value pairs. attr_accessor :content - # The enforcement tier of the policy. `DEFAULT` means the policy is set but member orgs may mutate it. `ENFORCE` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. + # The enforcement tier of the policy. `OVERRIDE_ALLOWED` means the policy is set but member orgs may mutate it. `GROUP_MANAGED` means the policy is strictly controlled and mutations are blocked for affected orgs. `DELEGATE` means each member org controls its own value. attr_accessor :enforcement_tier attr_accessor :additional_properties diff --git a/lib/datadog_api_client/v2/models/org_group_relationships.rb b/lib/datadog_api_client/v2/models/org_group_relationships.rb deleted file mode 100644 index cc8619a0d245..000000000000 --- a/lib/datadog_api_client/v2/models/org_group_relationships.rb +++ /dev/null @@ -1,105 +0,0 @@ -=begin -#Datadog API V2 Collection - -#Collection of all Datadog Public endpoints. - -The version of the OpenAPI document: 1.0 -Contact: support@datadoghq.com -Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator - - Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. - This product includes software developed at Datadog (https://www.datadoghq.com/). - Copyright 2020-Present Datadog, Inc. - -=end - -require 'date' -require 'time' - -module DatadogAPIClient::V2 - # Relationships of an org group. - class OrgGroupRelationships - include BaseGenericModel - - # Relationship to org group memberships. - attr_accessor :memberships - - attr_accessor :additional_properties - - # Attribute mapping from ruby-style variable name to JSON key. - # @!visibility private - def self.attribute_map - { - :'memberships' => :'memberships' - } - end - - # Attribute type mapping. - # @!visibility private - def self.openapi_types - { - :'memberships' => :'OrgGroupMembershipsRelationship' - } - end - - # Initializes the object - # @param attributes [Hash] Model attributes in the form of hash - # @!visibility private - def initialize(attributes = {}) - if (!attributes.is_a?(Hash)) - fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::OrgGroupRelationships` initialize method" - end - - self.additional_properties = {} - # check to see if the attribute exists and convert string to symbol for hash key - attributes = attributes.each_with_object({}) { |(k, v), h| - if (!self.class.attribute_map.key?(k.to_sym)) - self.additional_properties[k.to_sym] = v - else - h[k.to_sym] = v - end - } - - if attributes.key?(:'memberships') - self.memberships = attributes[:'memberships'] - end - end - - # Returns the object in the form of hash, with additionalProperties support. - # @return [Hash] Returns the object in the form of hash - # @!visibility private - def to_hash - hash = {} - self.class.attribute_map.each_pair do |attr, param| - value = self.send(attr) - if value.nil? - is_nullable = self.class.openapi_nullable.include?(attr) - next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) - end - - hash[param] = _to_hash(value) - end - self.additional_properties.each_pair do |attr, value| - hash[attr] = value - end - hash - end - - # Checks equality by comparing each attribute. - # @param o [Object] Object to be compared - # @!visibility private - def ==(o) - return true if self.equal?(o) - self.class == o.class && - memberships == o.memberships && - additional_properties == o.additional_properties - end - - # Calculates hash code according to all attributes. - # @return [Integer] Hash code - # @!visibility private - def hash - [memberships, additional_properties].hash - end - end -end