diff --git a/mmv1/third_party/terraform/provider/provider_mmv1_resources.go.erb b/mmv1/third_party/terraform/provider/provider_mmv1_resources.go.erb
index f58f2b57e660..f828b8c13ff2 100644
--- a/mmv1/third_party/terraform/provider/provider_mmv1_resources.go.erb
+++ b/mmv1/third_party/terraform/provider/provider_mmv1_resources.go.erb
@@ -53,6 +53,7 @@ var handwrittenDatasources = map[string]*schema.Resource{
"google_cloud_identity_group_memberships": cloudidentity.DataSourceGoogleCloudIdentityGroupMemberships(),
"google_cloud_identity_group_lookup": cloudidentity.DataSourceGoogleCloudIdentityGroupLookup(),
"google_cloud_quotas_quota_info": cloudquotas.DataSourceGoogleCloudQuotasQuotaInfo(),
+ "google_cloud_quotas_quota_infos": cloudquotas.DataSourceGoogleCloudQuotasQuotaInfos(),
"google_cloud_run_locations": cloudrun.DataSourceGoogleCloudRunLocations(),
"google_cloud_run_service": cloudrun.DataSourceGoogleCloudRunService(),
"google_cloud_run_v2_job": cloudrunv2.DataSourceGoogleCloudRunV2Job(),
diff --git a/mmv1/third_party/terraform/services/cloudquotas/data_source_google_cloud_quotas_quota_infos.go b/mmv1/third_party/terraform/services/cloudquotas/data_source_google_cloud_quotas_quota_infos.go
new file mode 100644
index 000000000000..5b0c90afd9f8
--- /dev/null
+++ b/mmv1/third_party/terraform/services/cloudquotas/data_source_google_cloud_quotas_quota_infos.go
@@ -0,0 +1,215 @@
+package cloudquotas
+
+import (
+ "fmt"
+
+ "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
+ "github.com/hashicorp/terraform-provider-google/google/tpgresource"
+ transport_tpg "github.com/hashicorp/terraform-provider-google/google/transport"
+)
+
+func DataSourceGoogleCloudQuotasQuotaInfos() *schema.Resource {
+ return &schema.Resource{
+ Read: dataSourceGoogleCloudQuotasQuotaInfosRead,
+
+ Schema: map[string]*schema.Schema{
+ "parent": {
+ Type: schema.TypeString,
+ Required: true,
+ },
+ "service": {
+ Type: schema.TypeString,
+ Required: true,
+ },
+ "quota_infos": {
+ Type: schema.TypeList,
+ Computed: true,
+ Elem: &schema.Resource{
+ Schema: map[string]*schema.Schema{
+ "service": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "quota_id": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "name": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "metric": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "is_precise": {
+ Type: schema.TypeBool,
+ Computed: true,
+ },
+ "refresh_interval": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "container_type": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "dimensions": {
+ Type: schema.TypeList,
+ Computed: true,
+ Elem: &schema.Schema{Type: schema.TypeString},
+ },
+ "metric_display_name": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "quota_display_name": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "metric_unit": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ "quota_increase_eligibility": {
+ Type: schema.TypeList,
+ Computed: true,
+ Elem: &schema.Resource{
+ Schema: map[string]*schema.Schema{
+ "is_eligible": {
+ Type: schema.TypeBool,
+ Computed: true,
+ },
+ "ineligibility_reason": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ },
+ },
+ },
+ "is_fixed": {
+ Type: schema.TypeBool,
+ Computed: true,
+ },
+ "dimensions_infos": {
+ Type: schema.TypeList,
+ Computed: true,
+ Elem: &schema.Resource{
+ Schema: map[string]*schema.Schema{
+ "dimensions": {
+ Type: schema.TypeMap,
+ Computed: true,
+ },
+ "details": {
+ Type: schema.TypeList,
+ Computed: true,
+ Elem: &schema.Resource{
+ Schema: map[string]*schema.Schema{
+ "value": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ },
+ },
+ },
+ "applicable_locations": {
+ Type: schema.TypeList,
+ Computed: true,
+ Elem: &schema.Schema{Type: schema.TypeString},
+ },
+ },
+ },
+ },
+ "is_concurrent": {
+ Type: schema.TypeBool,
+ Computed: true,
+ },
+ "service_request_quota_uri": {
+ Type: schema.TypeString,
+ Computed: true,
+ },
+ },
+ },
+ },
+ },
+ UseJSONNumber: true,
+ }
+}
+
+func dataSourceGoogleCloudQuotasQuotaInfosRead(d *schema.ResourceData, meta interface{}) error {
+ config := meta.(*transport_tpg.Config)
+ userAgent, err := tpgresource.GenerateUserAgentString(d, config.UserAgent)
+ if err != nil {
+ return err
+ }
+
+ url, err := tpgresource.ReplaceVars(d, config, "{{CloudQuotasBasePath}}{{parent}}/locations/global/services/{{service}}/quotaInfos")
+ if err != nil {
+ return fmt.Errorf("error setting api endpoint")
+ }
+
+ res, err := transport_tpg.SendRequest(transport_tpg.SendRequestOptions{
+ Config: config,
+ Method: "GET",
+ RawURL: url,
+ UserAgent: userAgent,
+ })
+ if err != nil {
+ return transport_tpg.HandleNotFoundError(err, d, fmt.Sprintf("CloudQuotasQuotaInfo %q", d.Id()))
+ }
+
+ var quotaInfos []map[string]interface{}
+ for {
+ fetchedQuotaInfos := res["quotaInfos"].([]interface{})
+ for _, rawQuotaInfo := range fetchedQuotaInfos {
+ quotaInfos = append(quotaInfos, flattenCloudQuotasQuotaInfo(rawQuotaInfo.(map[string]interface{}), d, config))
+ }
+
+ if res["nextPageToken"] == nil || res["nextPageToken"].(string) == "" {
+ break
+ }
+ url, err = tpgresource.ReplaceVars(d, config, "{{CloudQuotasBasePath}}{{parent}}/locations/global/services/{{service}}/quotaInfos?pageToken="+res["nextPageToken"].(string))
+ if err != nil {
+ return fmt.Errorf("error setting api endpoint")
+ }
+ res, err = transport_tpg.SendRequest(transport_tpg.SendRequestOptions{
+ Config: config,
+ Method: "GET",
+ RawURL: url,
+ UserAgent: userAgent,
+ })
+ if err != nil {
+ return transport_tpg.HandleDataSourceNotFoundError(err, d, fmt.Sprintf("CloudQuotasQuotaInfo %q", d.Id()), url)
+ }
+ }
+
+ if err := d.Set("quota_infos", quotaInfos); err != nil {
+ return fmt.Errorf("error reading quota infos : %s", err)
+ }
+
+ d.SetId(url)
+ return nil
+}
+
+func flattenCloudQuotasQuotaInfo(rawQuotaInfo map[string]interface{}, d *schema.ResourceData, config *transport_tpg.Config) map[string]interface{} {
+ quotaInfo := make(map[string]interface{})
+
+ quotaInfo["name"] = rawQuotaInfo["name"]
+ quotaInfo["quota_id"] = rawQuotaInfo["quotaId"]
+ quotaInfo["metric"] = rawQuotaInfo["metric"]
+ quotaInfo["service"] = rawQuotaInfo["service"]
+ quotaInfo["is_precise"] = rawQuotaInfo["isPrecise"]
+ quotaInfo["refresh_interval"] = rawQuotaInfo["refreshInterval"]
+ quotaInfo["container_type"] = rawQuotaInfo["containerType"]
+ quotaInfo["dimensions"] = rawQuotaInfo["dimensions"]
+ quotaInfo["metric_display_name"] = rawQuotaInfo["metricDisplayName"]
+ quotaInfo["quota_display_name"] = rawQuotaInfo["quotaDisplayName"]
+ quotaInfo["metric_unit"] = rawQuotaInfo["metricUnit"]
+ quotaInfo["quota_increase_eligibility"] = flattenCloudQuotasQuotaInfoQuotaIncreaseEligibility(rawQuotaInfo["quotaIncreaseEligibility"], d, config)
+ quotaInfo["is_fixed"] = rawQuotaInfo["isFixed"]
+ quotaInfo["dimensions_infos"] = flattenCloudQuotasQuotaInfoDimensionsInfos(rawQuotaInfo["dimensionsInfos"], d, config)
+ quotaInfo["is_concurrent"] = rawQuotaInfo["isConcurrent"]
+ quotaInfo["service_request_quota_uri"] = rawQuotaInfo["serviceRequestQuotaUri"]
+
+ return quotaInfo
+}
diff --git a/mmv1/third_party/terraform/services/cloudquotas/data_source_google_cloud_quotas_quota_infos_test.go b/mmv1/third_party/terraform/services/cloudquotas/data_source_google_cloud_quotas_quota_infos_test.go
new file mode 100644
index 000000000000..99db75f58074
--- /dev/null
+++ b/mmv1/third_party/terraform/services/cloudquotas/data_source_google_cloud_quotas_quota_infos_test.go
@@ -0,0 +1,51 @@
+package cloudquotas_test
+
+import (
+ "testing"
+
+ "github.com/hashicorp/terraform-plugin-sdk/v2/helper/resource"
+ "github.com/hashicorp/terraform-provider-google/google/acctest"
+ "github.com/hashicorp/terraform-provider-google/google/envvar"
+)
+
+func TestAccDataSourceGoogleQuotaInfos_basic(t *testing.T) {
+ t.Parallel()
+
+ resourceName := "data.google_cloud_quotas_quota_infos.my_quota_infos"
+ service := "compute.googleapis.com"
+
+ context := map[string]interface{}{
+ "project": envvar.GetTestProjectFromEnv(),
+ "service": service,
+ }
+
+ acctest.VcrTest(t, resource.TestCase{
+ PreCheck: func() { acctest.AccTestPreCheck(t) },
+ ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories(t),
+ Steps: []resource.TestStep{
+ {
+ Config: testAccDataSourceGoogleQuotaInfos_basic(context),
+ Check: resource.ComposeTestCheckFunc(
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.name"),
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.quota_id"),
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.metric"),
+ resource.TestCheckResourceAttr(resourceName, "quota_infos.0.service", service),
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.is_precise"),
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.container_type"),
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.quota_increase_eligibility.0.is_eligible"),
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.dimensions_infos.0.details.0.value"),
+ resource.TestCheckResourceAttrSet(resourceName, "quota_infos.0.dimensions_infos.0.applicable_locations.0"),
+ ),
+ },
+ },
+ })
+}
+
+func testAccDataSourceGoogleQuotaInfos_basic(context map[string]interface{}) string {
+ return acctest.Nprintf(`
+ data "google_cloud_quotas_quota_infos" "my_quota_infos" {
+ parent = "projects/%{project}"
+ service = "%{service}"
+ }
+ `, context)
+}
diff --git a/mmv1/third_party/terraform/website/docs/d/cloud_quotas_quota_info.html.markdown b/mmv1/third_party/terraform/website/docs/d/cloud_quotas_quota_info.html.markdown
index 77e97d36489c..2f88f3c3abdc 100644
--- a/mmv1/third_party/terraform/website/docs/d/cloud_quotas_quota_info.html.markdown
+++ b/mmv1/third_party/terraform/website/docs/d/cloud_quotas_quota_info.html.markdown
@@ -53,7 +53,6 @@ The following attributes are exported:
The `dimensions_infos` block supports:
* `dimensions` - The map of dimensions for this dimensions info. The key of a map entry is "region", "zone" or the name of a service specific dimension, and the value of a map entry is the value of the dimension. If a dimension does not appear in the map of dimensions, the dimensions info applies to all the dimension values except for those that have another DimenisonInfo instance configured for the specific value. Example: {"provider" : "Foo Inc"} where "provider" is a service specific dimension of a quota.
- An object containing a list of "key": value pairs, for example: `{ "name": "wrench", "mass": "1.3kg", "count": "3" }`.
* `details` - The quota details for a map of dimensions.
* `applicable_locations` - The applicable regions or zones of this dimensions info. The field will be set to `['global']` for quotas that are not per region or per zone. Otherwise, it will be set to the list of locations this dimension info is applicable to.
diff --git a/mmv1/third_party/terraform/website/docs/d/cloud_quotas_quota_infos.html.markdown b/mmv1/third_party/terraform/website/docs/d/cloud_quotas_quota_infos.html.markdown
new file mode 100644
index 000000000000..b160791ce1ca
--- /dev/null
+++ b/mmv1/third_party/terraform/website/docs/d/cloud_quotas_quota_infos.html.markdown
@@ -0,0 +1,62 @@
+---
+subcategory: "Cloud Quotas"
+---
+
+# google\_cloud\_quotas\_quota\_infos
+
+Provides information about all quotas for a given project, folder or organization.
+
+## Example Usage
+
+```hcl
+data "google_cloud_quotas_quota_infos" "my_quota_infos" {
+ parent = "projects/my-project"
+ service = "compute.googleapis.com"
+}
+```
+
+## Argument Reference
+
+The following arguments are supported:
+
+* `parent` - (Required) Parent value of QuotaInfo resources. Listing across different resource containers (such as 'projects/-') is not allowed. Allowed parents are "projects/[project-id / number]" or "folders/[folder-id / number]" or "organizations/[org-id / number].
+
+* `service` - (Required) The name of the service in which the quotas are defined.
+
+
+## Attributes Reference
+
+The following attributes are exported:
+
+* `quota_infos` - (Output) The list of QuotaInfo.
+
+ The `quota_infos` block supports:
+
+* `name` - (Output) Resource name of this QuotaInfo, for example: `projects/123/locations/global/services/compute.googleapis.com/quotaInfos/CpusPerProjectPerRegion`.
+* `metric` - (Output) The metric of the quota. It specifies the resources consumption the quota is defined for, for example: `compute.googleapis.com/cpus`.
+* `is_precise` - (Output) Whether this is a precise quota. A precise quota is tracked with absolute precision. In contrast, an imprecise quota is not tracked with precision.
+* `refresh_interval` - (Output) The reset time interval for the quota. Refresh interval applies to rate quota only. Example: "minute" for per minute, "day" for per day, or "10 seconds" for every 10 seconds.
+* `container_type` - (Output) The container type of the QuotaInfo.
+* `dimensions` - (Output) The dimensions the quota is defined on.
+* `metric_display_name` - (Output) The display name of the quota metric.
+* `quota_display_name` - (Output) The display name of the quota.
+* `metric_unit` - (Output) The unit in which the metric value is reported, e.g., `MByte`.
+* `quota_increase_eligibility` - (Output) Whether it is eligible to request a higher quota value for this quota.
+* `is_fixed` - (Output) Whether the quota value is fixed or adjustable.
+* `dimensions_infos` - (Output) The collection of dimensions info ordered by their dimensions from more specific ones to less specific ones.
+* `is_concurrent` - (Output) Whether the quota is a concurrent quota. Concurrent quotas are enforced on the total number of concurrent operations in flight at any given time.
+* `service_request_quota_uri` - (Output) URI to the page where users can request more quota for the cloud service, for example: `https://console.cloud.google.com/iam-admin/quotas`.
+
+ The `quota_increase_eligibility` block supports:
+
+* `is_eligible` - Whether a higher quota value can be requested for the quota.
+* `ineligibility_reason` - The enumeration of reasons when it is ineligible to request increase adjustment.
+
+ The `dimensions_infos` block supports:
+* `dimensions` - The map of dimensions for this dimensions info. The key of a map entry is "region", "zone" or the name of a service specific dimension, and the value of a map entry is the value of the dimension. If a dimension does not appear in the map of dimensions, the dimensions info applies to all the dimension values except for those that have another DimenisonInfo instance configured for the specific value. Example: {"provider" : "Foo Inc"} where "provider" is a service specific dimension of a quota.
+
+* `details` - The quota details for a map of dimensions.
+* `applicable_locations` - The applicable regions or zones of this dimensions info. The field will be set to `['global']` for quotas that are not per region or per zone. Otherwise, it will be set to the list of locations this dimension info is applicable to.
+
+ The `details` block supports:
+* `value` - The value currently in effect and being enforced.