{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/google-cloud-platform/json-schema/google-cloud-platform-google-cloud-orgpolicy-v2-list-constraints-response-schema.json",
  "title": "GoogleCloudOrgpolicyV2ListConstraintsResponse",
  "description": "The response returned from the ListConstraints method.",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/google-cloud-platform-orgpolicy-folders-api-openapi.yml#/components/schemas/GoogleCloudOrgpolicyV2ListConstraintsResponse",
  "properties": {
    "nextPageToken": {
      "type": "string",
      "description": "Page token used to retrieve the next page. This is not used."
    },
    "constraints": {
      "description": "The collection of constraints that are available on the targeted resource.",
      "items": {
        "$ref": "#/$defs/GoogleCloudOrgpolicyV2Constraint"
      },
      "type": "array"
    }
  },
  "type": "object",
  "$defs": {
    "GoogleCloudOrgpolicyV2Constraint": {
      "description": "A constraint describes a way to restrict a resource's configuration. For example, you could enforce a constraint that controls which Google Cloud services can be activated across an organization, or whether a Compute Engine instance can have serial port connections established. Constraints can be configured by the organization policy administrator to fit the needs of the organization by setting a policy that includes constraints at different locations in the organization's resource hierarchy. Policies are inherited down the resource hierarchy from higher levels, but can also be overridden. For details about the inheritance rules, see `Policy`. Constraints have a default behavior determined by the `constraint_default` field, which is the enforcement behavior that is used in the absence of a policy being defined or inherited for the resource in question.",
      "properties": {
        "supportsSimulation": {
          "description": "Shows if simulation is supported for this constraint or not.",
          "type": "boolean"
        },
        "equivalentConstraint": {
          "description": "Defines the equivalent constraint name, if it exists. Managed constraints can have an equivalent legacy managed constraint, and legacy managed constraints can have an equivalent managed constraint. For example, \"constraints/iam.disableServiceAccountKeyUpload\" is equivalent to \"constraints/iam.managed.disableServiceAccountKeyUpload\".",
          "type": "string"
        },
        "name": {
          "type": "string",
          "description": "Immutable. The resource name of the constraint. Must be in one of the following forms: * `projects/{project_number}/constraints/{constraint_name}` * `folders/{folder_number}/constraints/{constraint_name}` * `organizations/{organization_number}/constraints/{constraint_name}` For example, \"/projects/123/constraints/compute.disableSerialPortAccess\"."
        },
        "listConstraint": {
          "$ref": "#/$defs/GoogleCloudOrgpolicyV2ConstraintListConstraint",
          "description": "Defines this constraint as being a list constraint."
        },
        "description": {
          "description": "Detailed description of what this constraint controls as well as how and where it is enforced. Mutable.",
          "type": "string"
        },
        "constraintDefault": {
          "enum": [
            "CONSTRAINT_DEFAULT_UNSPECIFIED",
            "ALLOW",
            "DENY"
          ],
          "description": "The evaluation behavior of this constraint in the absence of a policy.",
          "type": "string"
        },
        "supportsDryRun": {
          "type": "boolean",
          "description": "Shows if dry run is supported for this constraint or not."
        },
        "displayName": {
          "description": "The human readable name. Mutable.",
          "type": "string"
        },
        "booleanConstraint": {
          "$ref": "#/$defs/GoogleCloudOrgpolicyV2ConstraintBooleanConstraint",
          "description": "Defines this constraint as being a boolean constraint."
        }
      },
      "type": "object"
    },
    "GoogleCloudOrgpolicyV2ConstraintBooleanConstraint": {
      "type": "object",
      "description": "A constraint type is enforced or not enforced, which is configured in the `PolicyRule`. If `customConstraintDefinition` is defined, this constraint is a managed constraint.",
      "properties": {
        "customConstraintDefinition": {
          "$ref": "#/$defs/GoogleCloudOrgpolicyV2ConstraintCustomConstraintDefinition",
          "description": "Custom constraint definition. Defines this as a managed constraint."
        }
      }
    },
    "GoogleCloudOrgpolicyV2ConstraintCustomConstraintDefinition": {
      "description": "Custom constraint definition. Defines this as a managed constraint.",
      "properties": {
        "parameters": {
          "type": "object",
          "description": "Stores the structure of `Parameters` used by the constraint condition. The key of `map` represents the name of the parameter.",
          "additionalProperties": {
            "$ref": "#/$defs/GoogleCloudOrgpolicyV2ConstraintCustomConstraintDefinitionParameter"
          }
        },
        "methodTypes": {
          "description": "All the operations being applied for this constraint.",
          "items": {
            "type": "string",
            "enum": [
              "METHOD_TYPE_UNSPECIFIED",
              "CREATE",
              "UPDATE",
              "DELETE",
              "REMOVE_GRANT",
              "GOVERN_TAGS"
            ]
          },
          "type": "array"
        },
        "actionType": {
          "type": "string",
          "description": "Allow or deny type.",
          "enum": [
            "ACTION_TYPE_UNSPECIFIED",
            "ALLOW",
            "DENY"
          ]
        },
        "condition": {
          "description": "Org policy condition/expression. For example: `resource.instanceName.matches(\"(production|test)_(.+_)?[\\d]+\")` or, `resource.management.auto_upgrade == true` The max length of the condition is 1000 characters.",
          "type": "string"
        },
        "resourceTypes": {
          "description": "The resource instance type that this policy applies to, in the format `/`. Example: * `compute.googleapis.com/Instance`.",
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "type": "object"
    },
    "GoogleCloudOrgpolicyV2ConstraintCustomConstraintDefinitionParameter": {
      "description": "Defines a parameter structure.",
      "properties": {
        "type": {
          "type": "string",
          "description": "Type of the parameter.",
          "enum": [
            "TYPE_UNSPECIFIED",
            "LIST",
            "STRING",
            "BOOLEAN"
          ]
        },
        "metadata": {
          "$ref": "#/$defs/GoogleCloudOrgpolicyV2ConstraintCustomConstraintDefinitionParameterMetadata",
          "description": "Defines subproperties primarily used by the UI to display user-friendly information."
        },
        "validValuesExpr": {
          "description": "Provides a CEL expression to specify the acceptable parameter values during assignment. For example, parameterName in (\"parameterValue1\", \"parameterValue2\").",
          "type": "string"
        },
        "defaultValue": {
          "description": "Sets the value of the parameter in an assignment if no value is given."
        },
        "item": {
          "enum": [
            "TYPE_UNSPECIFIED",
            "LIST",
            "STRING",
            "BOOLEAN"
          ],
          "type": "string",
          "description": "Determines the parameter's value structure. For example, `LIST` can be specified by defining `type: LIST`, and `item: STRING`."
        }
      },
      "type": "object"
    },
    "GoogleCloudOrgpolicyV2ConstraintCustomConstraintDefinitionParameterMetadata": {
      "properties": {
        "description": {
          "type": "string",
          "description": "Detailed description of what this `parameter` is and its use. Mutable."
        }
      },
      "description": "Defines Metadata structure.",
      "type": "object"
    },
    "GoogleCloudOrgpolicyV2ConstraintListConstraint": {
      "description": "A constraint type that allows or disallows a list of string values, which are configured in the `PolicyRule`.",
      "properties": {
        "supportsIn": {
          "description": "Indicates whether values grouped into categories can be used in `Policy.allowed_values` and `Policy.denied_values`. For example, `\"in:Python\"` would match any value in the 'Python' group.",
          "type": "boolean"
        },
        "supportsUnder": {
          "description": "Indicates whether subtrees of the Resource Manager resource hierarchy can be used in `Policy.allowed_values` and `Policy.denied_values`. For example, `\"under:folders/123\"` would match any resource under the 'folders/123' folder.",
          "type": "boolean"
        }
      },
      "type": "object"
    }
  }
}