From dd818f50bab5faa505c8ffadc7688207965d7cc9 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Fri, 24 May 2024 07:12:28 +0000 Subject: [PATCH] feat(all): auto-regenerate discovery clients --- alloydb/v1/alloydb-api.json | 94 +- alloydb/v1/alloydb-gen.go | 105 +- alloydb/v1beta/alloydb-api.json | 106 +- alloydb/v1beta/alloydb-gen.go | 111 +- api-list.json | 15 + assuredworkloads/v1/assuredworkloads-api.json | 30 +- assuredworkloads/v1/assuredworkloads-gen.go | 36 +- .../v1beta1/assuredworkloads-api.json | 30 +- .../v1beta1/assuredworkloads-gen.go | 36 +- cloudbuild/v1/cloudbuild-api.json | 4 +- cloudbuild/v1/cloudbuild-gen.go | 2 +- cloudbuild/v2/cloudbuild-api.json | 36 +- cloudbuild/v2/cloudbuild-gen.go | 64 +- composer/v1/composer-api.json | 41 +- composer/v1/composer-gen.go | 144 + compute/v1/compute-api.json | 30 +- compute/v1/compute-gen.go | 33 +- compute/v1/compute3-gen.go | 8 +- container/v1/container-api.json | 10 +- container/v1/container-gen.go | 2 + developerconnect/v1/developerconnect-api.json | 1596 +++++++ developerconnect/v1/developerconnect-gen.go | 3886 +++++++++++++++++ dlp/v2/dlp-api.json | 6 +- dlp/v2/dlp-gen.go | 10 +- firestore/v1/firestore-api.json | 8 +- firestore/v1/firestore-gen.go | 9 +- gkebackup/v1/gkebackup-api.json | 181 +- gkebackup/v1/gkebackup-gen.go | 269 ++ migrationcenter/v1/migrationcenter-api.json | 4 +- migrationcenter/v1/migrationcenter-gen.go | 4 +- .../v1alpha1/migrationcenter-api.json | 4 +- .../v1alpha1/migrationcenter-gen.go | 4 +- .../v1/networkmanagement-api.json | 68 +- networkmanagement/v1/networkmanagement-gen.go | 65 +- .../v1beta1/networkmanagement-api.json | 68 +- .../v1beta1/networkmanagement-gen.go | 65 +- networkservices/v1/networkservices-api.json | 20 +- networkservices/v1/networkservices-gen.go | 16 +- sqladmin/v1/sqladmin-api.json | 51 +- sqladmin/v1/sqladmin-gen.go | 50 +- sqladmin/v1beta4/sqladmin-api.json | 55 +- sqladmin/v1beta4/sqladmin-gen.go | 55 +- vmmigration/v1alpha1/vmmigration-api.json | 4 +- vmmigration/v1alpha1/vmmigration-gen.go | 2 +- 44 files changed, 7204 insertions(+), 233 deletions(-) create mode 100644 developerconnect/v1/developerconnect-api.json create mode 100644 developerconnect/v1/developerconnect-gen.go diff --git a/alloydb/v1/alloydb-api.json b/alloydb/v1/alloydb-api.json index 28166a1007a..222f79bb270 100644 --- a/alloydb/v1/alloydb-api.json +++ b/alloydb/v1/alloydb-api.json @@ -1461,7 +1461,7 @@ } } }, - "revision": "20240424", + "revision": "20240517", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -3246,10 +3246,13 @@ ], "type": "string" }, - "recommendationSignalData": { - "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData", + "observabilityMetricData": { + "$ref": "StorageDatabasecenterPartnerapiV1mainObservabilityMetricData", "description": "More feed data would be added in subsequent CLs" }, + "recommendationSignalData": { + "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData" + }, "resourceHealthSignalData": { "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData" }, @@ -3423,7 +3426,11 @@ "SIGNAL_TYPE_CONNECTIONS_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TMP_TABLES_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TRANS_LOGS_PERFORMANCE_IMPACT", - "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" + "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES", + "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES", + "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS", + "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET", + "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" ], "enumDeprecated": [ false, @@ -3492,6 +3499,10 @@ false, false, false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -3561,7 +3572,11 @@ "Performance impact of connections settings", "Performance impact of temporary tables settings", "Performance impact of transaction logs settings", - "Performance impact of high joins without indexes" + "Performance impact of high joins without indexes", + "Detects events where a Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL users) writes to non-system tables.", + "Detects events where a database user or role has been granted all privileges to a database, or to all tables, procedures, or functions in a schema.", + "Detects if database instance data exported to a Cloud Storage bucket outside of the organization.", + "Detects if database instance data exported to a Cloud Storage bucket that is owned by the organization and is publicly accessible." ], "type": "string" }, @@ -3744,6 +3759,10 @@ "description": "The resource location. REQUIRED", "type": "string" }, + "machineConfiguration": { + "$ref": "StorageDatabasecenterPartnerapiV1mainMachineConfiguration", + "description": "Machine configuration for this resource." + }, "primaryResourceId": { "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceId", "description": "Identifier for this resource's immediate parent/primary resource if the current resource is a replica or derived form of another Database resource. Else it would be NULL. REQUIRED if the immediate parent exists when first time resource is getting ingested, otherwise optional." @@ -3902,7 +3921,11 @@ "SIGNAL_TYPE_CONNECTIONS_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TMP_TABLES_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TRANS_LOGS_PERFORMANCE_IMPACT", - "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" + "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES", + "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES", + "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS", + "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET", + "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" ], "enumDeprecated": [ false, @@ -3971,6 +3994,10 @@ false, false, false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -4040,7 +4067,11 @@ "Performance impact of connections settings", "Performance impact of temporary tables settings", "Performance impact of transaction logs settings", - "Performance impact of high joins without indexes" + "Performance impact of high joins without indexes", + "Detects events where a Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL users) writes to non-system tables.", + "Detects events where a database user or role has been granted all privileges to a database, or to all tables, procedures, or functions in a schema.", + "Detects if database instance data exported to a Cloud Storage bucket outside of the organization.", + "Detects if database instance data exported to a Cloud Storage bucket that is owned by the organization and is publicly accessible." ], "type": "string" } @@ -4080,6 +4111,55 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainMachineConfiguration": { + "description": "MachineConfiguration describes the configuration of a machine specific to Database Resource.", + "id": "StorageDatabasecenterPartnerapiV1mainMachineConfiguration", + "properties": { + "cpuCount": { + "description": "The number of CPUs.", + "format": "int32", + "type": "integer" + }, + "memorySizeInBytes": { + "description": "Memory size in bytes.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "StorageDatabasecenterPartnerapiV1mainObservabilityMetricData": { + "id": "StorageDatabasecenterPartnerapiV1mainObservabilityMetricData", + "properties": { + "metricTimestamp": { + "description": "Required. The timestamp of the metric value.", + "format": "google-datetime", + "type": "string" + }, + "metricType": { + "description": "Required. Type of metric like CPU, Memory, etc.", + "enum": [ + "METRIC_TYPE_UNSPECIFIED", + "INSTANCE_PEAK_CPU_UTILISATION" + ], + "enumDescriptions": [ + "", + "Peak CPU utilization for a DB instance as a fraction between 0.0 and 1.0 (may momentarily exceed 1.0 in some cases) List will keep increasing, e.g. PEAK_MEMORY_UTILISATION, NUMBER_OF_CONNECTIONS, SUCCESS_RATIO_FOR_QUERIES, etc." + ], + "type": "string" + }, + "resourceName": { + "description": "Required. Database resource name associated with the signal. Resource name to follow CAIS resource_name format as noted here go/condor-common-datamodel", + "type": "string" + }, + "value": { + "description": "Required. Value of the metric type.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainOperationError": { "description": "An error that occurred during a backup creation operation.", "id": "StorageDatabasecenterPartnerapiV1mainOperationError", diff --git a/alloydb/v1/alloydb-gen.go b/alloydb/v1/alloydb-gen.go index 5866ed2f206..4f4735d2344 100644 --- a/alloydb/v1/alloydb-gen.go +++ b/alloydb/v1/alloydb-gen.go @@ -2357,7 +2357,8 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // "RECOMMENDATION_SIGNAL_DATA" - Database resource recommendation signal // data FeedType string `json:"feedType,omitempty"` - // RecommendationSignalData: More feed data would be added in subsequent CLs + // ObservabilityMetricData: More feed data would be added in subsequent CLs + ObservabilityMetricData *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData `json:"observabilityMetricData,omitempty"` RecommendationSignalData *StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData `json:"recommendationSignalData,omitempty"` ResourceHealthSignalData *StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData `json:"resourceHealthSignalData,omitempty"` // ResourceId: Primary key associated with the Resource. resource_id is @@ -2607,6 +2608,18 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData struc // transaction logs settings // "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" - Performance impact of high // joins without indexes + // "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES" - Detects events where a + // Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL + // users) writes to non-system tables. + // "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS" - Detects events where a + // database user or role has been granted all privileges to a database, or to + // all tables, procedures, or functions in a schema. + // "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket outside of the + // organization. + // "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket that is owned by + // the organization and is publicly accessible. SignalType string `json:"signalType,omitempty"` // Possible values: // "STATE_UNSPECIFIED" - Unspecified state. @@ -2742,6 +2755,8 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { InstanceType string `json:"instanceType,omitempty"` // Location: The resource location. REQUIRED Location string `json:"location,omitempty"` + // MachineConfiguration: Machine configuration for this resource. + MachineConfiguration *StorageDatabasecenterPartnerapiV1mainMachineConfiguration `json:"machineConfiguration,omitempty"` // PrimaryResourceId: Identifier for this resource's immediate parent/primary // resource if the current resource is a replica or derived form of another // Database resource. Else it would be NULL. REQUIRED if the immediate parent @@ -2992,6 +3007,18 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalDa // transaction logs settings // "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" - Performance impact of high // joins without indexes + // "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES" - Detects events where a + // Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL + // users) writes to non-system tables. + // "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS" - Detects events where a + // database user or role has been granted all privileges to a database, or to + // all tables, procedures, or functions in a schema. + // "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket outside of the + // organization. + // "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket that is owned by + // the organization and is publicly accessible. SignalType string `json:"signalType,omitempty"` // ForceSendFields is a list of field names (e.g. "AdditionalMetadata") to // unconditionally include in API requests. By default, fields with empty or @@ -3049,6 +3076,82 @@ func (s *StorageDatabasecenterPartnerapiV1mainEntitlement) MarshalJSON() ([]byte return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainMachineConfiguration: +// MachineConfiguration describes the configuration of a machine specific to +// Database Resource. +type StorageDatabasecenterPartnerapiV1mainMachineConfiguration struct { + // CpuCount: The number of CPUs. + CpuCount int64 `json:"cpuCount,omitempty"` + // MemorySizeInBytes: Memory size in bytes. + MemorySizeInBytes int64 `json:"memorySizeInBytes,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "CpuCount") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CpuCount") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *StorageDatabasecenterPartnerapiV1mainMachineConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainMachineConfiguration + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +type StorageDatabasecenterPartnerapiV1mainObservabilityMetricData struct { + // MetricTimestamp: Required. The timestamp of the metric value. + MetricTimestamp string `json:"metricTimestamp,omitempty"` + // MetricType: Required. Type of metric like CPU, Memory, etc. + // + // Possible values: + // "METRIC_TYPE_UNSPECIFIED" + // "INSTANCE_PEAK_CPU_UTILISATION" - Peak CPU utilization for a DB instance + // as a fraction between 0.0 and 1.0 (may momentarily exceed 1.0 in some cases) + // List will keep increasing, e.g. PEAK_MEMORY_UTILISATION, + // NUMBER_OF_CONNECTIONS, SUCCESS_RATIO_FOR_QUERIES, etc. + MetricType string `json:"metricType,omitempty"` + // ResourceName: Required. Database resource name associated with the signal. + // Resource name to follow CAIS resource_name format as noted here + // go/condor-common-datamodel + ResourceName string `json:"resourceName,omitempty"` + // Value: Required. Value of the metric type. + Value float64 `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "MetricTimestamp") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "MetricTimestamp") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainObservabilityMetricData + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +func (s *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData) UnmarshalJSON(data []byte) error { + type NoMethod StorageDatabasecenterPartnerapiV1mainObservabilityMetricData + var s1 struct { + Value gensupport.JSONFloat64 `json:"value"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Value = float64(s1.Value) + return nil +} + // StorageDatabasecenterPartnerapiV1mainOperationError: An error that occurred // during a backup creation operation. type StorageDatabasecenterPartnerapiV1mainOperationError struct { diff --git a/alloydb/v1beta/alloydb-api.json b/alloydb/v1beta/alloydb-api.json index e3c5fc208d4..d512a77d77d 100644 --- a/alloydb/v1beta/alloydb-api.json +++ b/alloydb/v1beta/alloydb-api.json @@ -1458,7 +1458,7 @@ } } }, - "revision": "20240424", + "revision": "20240517", "rootUrl": "https://alloydb.googleapis.com/", "schemas": { "AuthorizedNetwork": { @@ -2386,6 +2386,14 @@ "$ref": "ObservabilityInstanceConfig", "description": "Configuration for observability." }, + "outboundPublicIpAddresses": { + "description": "Output only. All outbound public IP addresses configured for the instance.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, "pscInstanceConfig": { "$ref": "PscInstanceConfig", "description": "Optional. The configuration for Private Service Connect (PSC) for the instance." @@ -2474,6 +2482,10 @@ }, "type": "array" }, + "enableOutboundPublicIp": { + "description": "Optional. Enabling an outbound public IP address to support a database server sending requests out into the internet.", + "type": "boolean" + }, "enablePublicIp": { "description": "Optional. Enabling public ip for the instance.", "type": "boolean" @@ -3333,10 +3345,13 @@ ], "type": "string" }, - "recommendationSignalData": { - "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData", + "observabilityMetricData": { + "$ref": "StorageDatabasecenterPartnerapiV1mainObservabilityMetricData", "description": "More feed data would be added in subsequent CLs" }, + "recommendationSignalData": { + "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData" + }, "resourceHealthSignalData": { "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData" }, @@ -3510,7 +3525,11 @@ "SIGNAL_TYPE_CONNECTIONS_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TMP_TABLES_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TRANS_LOGS_PERFORMANCE_IMPACT", - "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" + "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES", + "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES", + "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS", + "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET", + "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" ], "enumDeprecated": [ false, @@ -3579,6 +3598,10 @@ false, false, false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -3648,7 +3671,11 @@ "Performance impact of connections settings", "Performance impact of temporary tables settings", "Performance impact of transaction logs settings", - "Performance impact of high joins without indexes" + "Performance impact of high joins without indexes", + "Detects events where a Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL users) writes to non-system tables.", + "Detects events where a database user or role has been granted all privileges to a database, or to all tables, procedures, or functions in a schema.", + "Detects if database instance data exported to a Cloud Storage bucket outside of the organization.", + "Detects if database instance data exported to a Cloud Storage bucket that is owned by the organization and is publicly accessible." ], "type": "string" }, @@ -3831,6 +3858,10 @@ "description": "The resource location. REQUIRED", "type": "string" }, + "machineConfiguration": { + "$ref": "StorageDatabasecenterPartnerapiV1mainMachineConfiguration", + "description": "Machine configuration for this resource." + }, "primaryResourceId": { "$ref": "StorageDatabasecenterPartnerapiV1mainDatabaseResourceId", "description": "Identifier for this resource's immediate parent/primary resource if the current resource is a replica or derived form of another Database resource. Else it would be NULL. REQUIRED if the immediate parent exists when first time resource is getting ingested, otherwise optional." @@ -3989,7 +4020,11 @@ "SIGNAL_TYPE_CONNECTIONS_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TMP_TABLES_PERFORMANCE_IMPACT", "SIGNAL_TYPE_TRANS_LOGS_PERFORMANCE_IMPACT", - "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" + "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES", + "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES", + "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS", + "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET", + "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" ], "enumDeprecated": [ false, @@ -4058,6 +4093,10 @@ false, false, false, + false, + false, + false, + false, false ], "enumDescriptions": [ @@ -4127,7 +4166,11 @@ "Performance impact of connections settings", "Performance impact of temporary tables settings", "Performance impact of transaction logs settings", - "Performance impact of high joins without indexes" + "Performance impact of high joins without indexes", + "Detects events where a Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL users) writes to non-system tables.", + "Detects events where a database user or role has been granted all privileges to a database, or to all tables, procedures, or functions in a schema.", + "Detects if database instance data exported to a Cloud Storage bucket outside of the organization.", + "Detects if database instance data exported to a Cloud Storage bucket that is owned by the organization and is publicly accessible." ], "type": "string" } @@ -4167,6 +4210,55 @@ }, "type": "object" }, + "StorageDatabasecenterPartnerapiV1mainMachineConfiguration": { + "description": "MachineConfiguration describes the configuration of a machine specific to Database Resource.", + "id": "StorageDatabasecenterPartnerapiV1mainMachineConfiguration", + "properties": { + "cpuCount": { + "description": "The number of CPUs.", + "format": "int32", + "type": "integer" + }, + "memorySizeInBytes": { + "description": "Memory size in bytes.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "StorageDatabasecenterPartnerapiV1mainObservabilityMetricData": { + "id": "StorageDatabasecenterPartnerapiV1mainObservabilityMetricData", + "properties": { + "metricTimestamp": { + "description": "Required. The timestamp of the metric value.", + "format": "google-datetime", + "type": "string" + }, + "metricType": { + "description": "Required. Type of metric like CPU, Memory, etc.", + "enum": [ + "METRIC_TYPE_UNSPECIFIED", + "INSTANCE_PEAK_CPU_UTILISATION" + ], + "enumDescriptions": [ + "", + "Peak CPU utilization for a DB instance as a fraction between 0.0 and 1.0 (may momentarily exceed 1.0 in some cases) List will keep increasing, e.g. PEAK_MEMORY_UTILISATION, NUMBER_OF_CONNECTIONS, SUCCESS_RATIO_FOR_QUERIES, etc." + ], + "type": "string" + }, + "resourceName": { + "description": "Required. Database resource name associated with the signal. Resource name to follow CAIS resource_name format as noted here go/condor-common-datamodel", + "type": "string" + }, + "value": { + "description": "Required. Value of the metric type.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, "StorageDatabasecenterPartnerapiV1mainOperationError": { "description": "An error that occurred during a backup creation operation.", "id": "StorageDatabasecenterPartnerapiV1mainOperationError", diff --git a/alloydb/v1beta/alloydb-gen.go b/alloydb/v1beta/alloydb-gen.go index e182d1d98c6..3300f6d8281 100644 --- a/alloydb/v1beta/alloydb-gen.go +++ b/alloydb/v1beta/alloydb-gen.go @@ -1212,6 +1212,9 @@ type Instance struct { Nodes []*Node `json:"nodes,omitempty"` // ObservabilityConfig: Configuration for observability. ObservabilityConfig *ObservabilityInstanceConfig `json:"observabilityConfig,omitempty"` + // OutboundPublicIpAddresses: Output only. All outbound public IP addresses + // configured for the instance. + OutboundPublicIpAddresses []string `json:"outboundPublicIpAddresses,omitempty"` // PscInstanceConfig: Optional. The configuration for Private Service Connect // (PSC) for the instance. PscInstanceConfig *PscInstanceConfig `json:"pscInstanceConfig,omitempty"` @@ -1293,6 +1296,9 @@ type InstanceNetworkConfig struct { // AuthorizedExternalNetworks: Optional. A list of external network authorized // to access this instance. AuthorizedExternalNetworks []*AuthorizedNetwork `json:"authorizedExternalNetworks,omitempty"` + // EnableOutboundPublicIp: Optional. Enabling an outbound public IP address to + // support a database server sending requests out into the internet. + EnableOutboundPublicIp bool `json:"enableOutboundPublicIp,omitempty"` // EnablePublicIp: Optional. Enabling public ip for the instance. EnablePublicIp bool `json:"enablePublicIp,omitempty"` // ForceSendFields is a list of field names (e.g. "AuthorizedExternalNetworks") @@ -2472,7 +2478,8 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceFeed struct { // "RECOMMENDATION_SIGNAL_DATA" - Database resource recommendation signal // data FeedType string `json:"feedType,omitempty"` - // RecommendationSignalData: More feed data would be added in subsequent CLs + // ObservabilityMetricData: More feed data would be added in subsequent CLs + ObservabilityMetricData *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData `json:"observabilityMetricData,omitempty"` RecommendationSignalData *StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalData `json:"recommendationSignalData,omitempty"` ResourceHealthSignalData *StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData `json:"resourceHealthSignalData,omitempty"` // ResourceId: Primary key associated with the Resource. resource_id is @@ -2722,6 +2729,18 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceHealthSignalData struc // transaction logs settings // "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" - Performance impact of high // joins without indexes + // "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES" - Detects events where a + // Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL + // users) writes to non-system tables. + // "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS" - Detects events where a + // database user or role has been granted all privileges to a database, or to + // all tables, procedures, or functions in a schema. + // "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket outside of the + // organization. + // "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket that is owned by + // the organization and is publicly accessible. SignalType string `json:"signalType,omitempty"` // Possible values: // "STATE_UNSPECIFIED" - Unspecified state. @@ -2857,6 +2876,8 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceMetadata struct { InstanceType string `json:"instanceType,omitempty"` // Location: The resource location. REQUIRED Location string `json:"location,omitempty"` + // MachineConfiguration: Machine configuration for this resource. + MachineConfiguration *StorageDatabasecenterPartnerapiV1mainMachineConfiguration `json:"machineConfiguration,omitempty"` // PrimaryResourceId: Identifier for this resource's immediate parent/primary // resource if the current resource is a replica or derived form of another // Database resource. Else it would be NULL. REQUIRED if the immediate parent @@ -3107,6 +3128,18 @@ type StorageDatabasecenterPartnerapiV1mainDatabaseResourceRecommendationSignalDa // transaction logs settings // "SIGNAL_TYPE_HIGH_JOINS_WITHOUT_INDEXES" - Performance impact of high // joins without indexes + // "SIGNAL_TYPE_SUPERUSER_WRITING_TO_USER_TABLES" - Detects events where a + // Cloud SQL superuser (postgres for PostgreSQL servers or root for MySQL + // users) writes to non-system tables. + // "SIGNAL_TYPE_USER_GRANTED_ALL_PERMISSIONS" - Detects events where a + // database user or role has been granted all privileges to a database, or to + // all tables, procedures, or functions in a schema. + // "SIGNAL_TYPE_DATA_EXPORT_TO_EXTERNAL_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket outside of the + // organization. + // "SIGNAL_TYPE_DATA_EXPORT_TO_PUBLIC_CLOUD_STORAGE_BUCKET" - Detects if + // database instance data exported to a Cloud Storage bucket that is owned by + // the organization and is publicly accessible. SignalType string `json:"signalType,omitempty"` // ForceSendFields is a list of field names (e.g. "AdditionalMetadata") to // unconditionally include in API requests. By default, fields with empty or @@ -3164,6 +3197,82 @@ func (s *StorageDatabasecenterPartnerapiV1mainEntitlement) MarshalJSON() ([]byte return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// StorageDatabasecenterPartnerapiV1mainMachineConfiguration: +// MachineConfiguration describes the configuration of a machine specific to +// Database Resource. +type StorageDatabasecenterPartnerapiV1mainMachineConfiguration struct { + // CpuCount: The number of CPUs. + CpuCount int64 `json:"cpuCount,omitempty"` + // MemorySizeInBytes: Memory size in bytes. + MemorySizeInBytes int64 `json:"memorySizeInBytes,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "CpuCount") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CpuCount") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *StorageDatabasecenterPartnerapiV1mainMachineConfiguration) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainMachineConfiguration + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +type StorageDatabasecenterPartnerapiV1mainObservabilityMetricData struct { + // MetricTimestamp: Required. The timestamp of the metric value. + MetricTimestamp string `json:"metricTimestamp,omitempty"` + // MetricType: Required. Type of metric like CPU, Memory, etc. + // + // Possible values: + // "METRIC_TYPE_UNSPECIFIED" + // "INSTANCE_PEAK_CPU_UTILISATION" - Peak CPU utilization for a DB instance + // as a fraction between 0.0 and 1.0 (may momentarily exceed 1.0 in some cases) + // List will keep increasing, e.g. PEAK_MEMORY_UTILISATION, + // NUMBER_OF_CONNECTIONS, SUCCESS_RATIO_FOR_QUERIES, etc. + MetricType string `json:"metricType,omitempty"` + // ResourceName: Required. Database resource name associated with the signal. + // Resource name to follow CAIS resource_name format as noted here + // go/condor-common-datamodel + ResourceName string `json:"resourceName,omitempty"` + // Value: Required. Value of the metric type. + Value float64 `json:"value,omitempty"` + // ForceSendFields is a list of field names (e.g. "MetricTimestamp") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "MetricTimestamp") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData) MarshalJSON() ([]byte, error) { + type NoMethod StorageDatabasecenterPartnerapiV1mainObservabilityMetricData + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +func (s *StorageDatabasecenterPartnerapiV1mainObservabilityMetricData) UnmarshalJSON(data []byte) error { + type NoMethod StorageDatabasecenterPartnerapiV1mainObservabilityMetricData + var s1 struct { + Value gensupport.JSONFloat64 `json:"value"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Value = float64(s1.Value) + return nil +} + // StorageDatabasecenterPartnerapiV1mainOperationError: An error that occurred // during a backup creation operation. type StorageDatabasecenterPartnerapiV1mainOperationError struct { diff --git a/api-list.json b/api-list.json index 4f136764905..ca0c4b1444a 100644 --- a/api-list.json +++ b/api-list.json @@ -2419,6 +2419,21 @@ "documentationLink": "https://cloud.google.com/deployment-manager", "preferred": true }, + { + "kind": "discovery#directoryItem", + "id": "developerconnect:v1", + "name": "developerconnect", + "version": "v1", + "title": "Developer Connect API", + "description": "Connect third-party source code management to Google", + "discoveryRestUrl": "https://developerconnect.googleapis.com/$discovery/rest?version=v1", + "icons": { + "x16": "https://www.gstatic.com/images/branding/product/1x/googleg_16dp.png", + "x32": "https://www.gstatic.com/images/branding/product/1x/googleg_32dp.png" + }, + "documentationLink": "http://cloud.google.com/developer-connect/docs/overview", + "preferred": true + }, { "kind": "discovery#directoryItem", "id": "dfareporting:v3.5", diff --git a/assuredworkloads/v1/assuredworkloads-api.json b/assuredworkloads/v1/assuredworkloads-api.json index 8c46ba8c5ec..1ed26651fc7 100644 --- a/assuredworkloads/v1/assuredworkloads-api.json +++ b/assuredworkloads/v1/assuredworkloads-api.json @@ -591,7 +591,7 @@ } } }, - "revision": "20240510", + "revision": "20240523", "rootUrl": "https://assuredworkloads.googleapis.com/", "schemas": { "GoogleCloudAssuredworkloadsV1AcknowledgeViolationRequest": { @@ -682,26 +682,26 @@ "CJIS", "FEDRAMP_HIGH", "FEDRAMP_MODERATE", - "REGIONAL_CONTROLS_PREMIUM_US", "US_REGIONAL_ACCESS", + "REGIONAL_CONTROLS_PREMIUM_US", "HIPAA", "HITRUST", - "REGIONAL_CONTROLS_PREMIUM_EU", "EU_REGIONS_AND_SUPPORT", - "REGIONAL_CONTROLS_PREMIUM_CA", + "REGIONAL_CONTROLS_PREMIUM_EU", "CA_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_CA", "ITAR", - "REGIONAL_CONTROLS_PREMIUM_AU", "AU_REGIONS_AND_US_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_AU", "ASSURED_WORKLOADS_FOR_PARTNERS", - "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS", + "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS_AND_SUPPORT", "CA_PROTECTED_B", "IL5", "IL2", - "REGIONAL_CONTROLS_PREMIUM_JP", "JP_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_JP", "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS", "REGIONAL_CONTROLS", "FREE_REGIONS" @@ -724,8 +724,8 @@ "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Partners;", - "Assured Workloads for Israel", "Assured Workloads for Israel Regions", + "Assured Workloads for Israel", "Assured Workloads for Israel Regions", "Assured Workloads for Canada Protected B regime", "Information protection as per DoD IL5 requirements.", @@ -1177,26 +1177,26 @@ "CJIS", "FEDRAMP_HIGH", "FEDRAMP_MODERATE", - "REGIONAL_CONTROLS_PREMIUM_US", "US_REGIONAL_ACCESS", + "REGIONAL_CONTROLS_PREMIUM_US", "HIPAA", "HITRUST", - "REGIONAL_CONTROLS_PREMIUM_EU", "EU_REGIONS_AND_SUPPORT", - "REGIONAL_CONTROLS_PREMIUM_CA", + "REGIONAL_CONTROLS_PREMIUM_EU", "CA_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_CA", "ITAR", - "REGIONAL_CONTROLS_PREMIUM_AU", "AU_REGIONS_AND_US_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_AU", "ASSURED_WORKLOADS_FOR_PARTNERS", - "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS", + "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS_AND_SUPPORT", "CA_PROTECTED_B", "IL5", "IL2", - "REGIONAL_CONTROLS_PREMIUM_JP", "JP_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_JP", "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS", "REGIONAL_CONTROLS", "FREE_REGIONS" @@ -1219,8 +1219,8 @@ "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Partners;", - "Assured Workloads for Israel", "Assured Workloads for Israel Regions", + "Assured Workloads for Israel", "Assured Workloads for Israel Regions", "Assured Workloads for Canada Protected B regime", "Information protection as per DoD IL5 requirements.", diff --git a/assuredworkloads/v1/assuredworkloads-gen.go b/assuredworkloads/v1/assuredworkloads-gen.go index 486baecbf01..37a6f040b30 100644 --- a/assuredworkloads/v1/assuredworkloads-gen.go +++ b/assuredworkloads/v1/assuredworkloads-gen.go @@ -328,34 +328,34 @@ type GoogleCloudAssuredworkloadsV1CreateWorkloadOperationMetadata struct { // "CJIS" - Criminal Justice Information Services (CJIS) Security policies. // "FEDRAMP_HIGH" - FedRAMP High data protection controls // "FEDRAMP_MODERATE" - FedRAMP Moderate data protection controls - // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data - // protection controls // "US_REGIONAL_ACCESS" - Assured Workloads For US Regions data protection // controls + // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data + // protection controls // "HIPAA" - Health Insurance Portability and Accountability Act controls // "HITRUST" - Health Information Trust Alliance controls - // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and - // Support controls // "EU_REGIONS_AND_SUPPORT" - Assured Workloads For EU Regions and Support // controls - // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and // Support controls // "CA_REGIONS_AND_SUPPORT" - Assured Workloads For Canada Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // Support controls // "ITAR" - International Traffic in Arms Regulations - // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions - // and Support controls // "AU_REGIONS_AND_US_SUPPORT" - Assured Workloads for Australia Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions + // and Support controls // "ASSURED_WORKLOADS_FOR_PARTNERS" - Assured Workloads for Partners; - // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS" - Assured Workloads for Israel Regions + // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS_AND_SUPPORT" - Assured Workloads for Israel Regions // "CA_PROTECTED_B" - Assured Workloads for Canada Protected B regime // "IL5" - Information protection as per DoD IL5 requirements. // "IL2" - Information protection as per DoD IL2 requirements. - // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "JP_REGIONS_AND_SUPPORT" - Assured Workloads for Japan Regions + // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS" - KSA R5 Controls. // "REGIONAL_CONTROLS" - Assured Workloads for Regional Controls/Free Regions // "FREE_REGIONS" - Assured Workloads for Regional Controls/Free Regions @@ -871,34 +871,34 @@ type GoogleCloudAssuredworkloadsV1Workload struct { // "CJIS" - Criminal Justice Information Services (CJIS) Security policies. // "FEDRAMP_HIGH" - FedRAMP High data protection controls // "FEDRAMP_MODERATE" - FedRAMP Moderate data protection controls - // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data - // protection controls // "US_REGIONAL_ACCESS" - Assured Workloads For US Regions data protection // controls + // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data + // protection controls // "HIPAA" - Health Insurance Portability and Accountability Act controls // "HITRUST" - Health Information Trust Alliance controls - // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and - // Support controls // "EU_REGIONS_AND_SUPPORT" - Assured Workloads For EU Regions and Support // controls - // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and // Support controls // "CA_REGIONS_AND_SUPPORT" - Assured Workloads For Canada Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // Support controls // "ITAR" - International Traffic in Arms Regulations - // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions - // and Support controls // "AU_REGIONS_AND_US_SUPPORT" - Assured Workloads for Australia Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions + // and Support controls // "ASSURED_WORKLOADS_FOR_PARTNERS" - Assured Workloads for Partners; - // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS" - Assured Workloads for Israel Regions + // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS_AND_SUPPORT" - Assured Workloads for Israel Regions // "CA_PROTECTED_B" - Assured Workloads for Canada Protected B regime // "IL5" - Information protection as per DoD IL5 requirements. // "IL2" - Information protection as per DoD IL2 requirements. - // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "JP_REGIONS_AND_SUPPORT" - Assured Workloads for Japan Regions + // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS" - KSA R5 Controls. // "REGIONAL_CONTROLS" - Assured Workloads for Regional Controls/Free Regions // "FREE_REGIONS" - Assured Workloads for Regional Controls/Free Regions diff --git a/assuredworkloads/v1beta1/assuredworkloads-api.json b/assuredworkloads/v1beta1/assuredworkloads-api.json index f09a5e65f1e..e999568d4a5 100644 --- a/assuredworkloads/v1beta1/assuredworkloads-api.json +++ b/assuredworkloads/v1beta1/assuredworkloads-api.json @@ -563,7 +563,7 @@ } } }, - "revision": "20240510", + "revision": "20240523", "rootUrl": "https://assuredworkloads.googleapis.com/", "schemas": { "GoogleCloudAssuredworkloadsV1beta1AcknowledgeViolationRequest": { @@ -654,26 +654,26 @@ "CJIS", "FEDRAMP_HIGH", "FEDRAMP_MODERATE", - "REGIONAL_CONTROLS_PREMIUM_US", "US_REGIONAL_ACCESS", + "REGIONAL_CONTROLS_PREMIUM_US", "HIPAA", "HITRUST", - "REGIONAL_CONTROLS_PREMIUM_EU", "EU_REGIONS_AND_SUPPORT", - "REGIONAL_CONTROLS_PREMIUM_CA", + "REGIONAL_CONTROLS_PREMIUM_EU", "CA_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_CA", "ITAR", - "REGIONAL_CONTROLS_PREMIUM_AU", "AU_REGIONS_AND_US_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_AU", "ASSURED_WORKLOADS_FOR_PARTNERS", - "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS", + "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS_AND_SUPPORT", "CA_PROTECTED_B", "IL5", "IL2", - "REGIONAL_CONTROLS_PREMIUM_JP", "JP_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_JP", "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS", "REGIONAL_CONTROLS", "FREE_REGIONS" @@ -696,8 +696,8 @@ "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Partners;", - "Assured Workloads for Israel", "Assured Workloads for Israel Regions", + "Assured Workloads for Israel", "Assured Workloads for Israel Regions", "Assured Workloads for Canada Protected B regime", "Information protection as per DoD IL5 requirements.", @@ -1141,26 +1141,26 @@ "CJIS", "FEDRAMP_HIGH", "FEDRAMP_MODERATE", - "REGIONAL_CONTROLS_PREMIUM_US", "US_REGIONAL_ACCESS", + "REGIONAL_CONTROLS_PREMIUM_US", "HIPAA", "HITRUST", - "REGIONAL_CONTROLS_PREMIUM_EU", "EU_REGIONS_AND_SUPPORT", - "REGIONAL_CONTROLS_PREMIUM_CA", + "REGIONAL_CONTROLS_PREMIUM_EU", "CA_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_CA", "ITAR", - "REGIONAL_CONTROLS_PREMIUM_AU", "AU_REGIONS_AND_US_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_AU", "ASSURED_WORKLOADS_FOR_PARTNERS", - "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS", + "REGIONAL_CONTROLS_PREMIUM_ISR", "ISR_REGIONS_AND_SUPPORT", "CA_PROTECTED_B", "IL5", "IL2", - "REGIONAL_CONTROLS_PREMIUM_JP", "JP_REGIONS_AND_SUPPORT", + "REGIONAL_CONTROLS_PREMIUM_JP", "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS", "REGIONAL_CONTROLS", "FREE_REGIONS" @@ -1183,8 +1183,8 @@ "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Australia Regions and Support controls", "Assured Workloads for Partners;", - "Assured Workloads for Israel", "Assured Workloads for Israel Regions", + "Assured Workloads for Israel", "Assured Workloads for Israel Regions", "Assured Workloads for Canada Protected B regime", "Information protection as per DoD IL5 requirements.", diff --git a/assuredworkloads/v1beta1/assuredworkloads-gen.go b/assuredworkloads/v1beta1/assuredworkloads-gen.go index 7a799a3bd4f..09b99e5897f 100644 --- a/assuredworkloads/v1beta1/assuredworkloads-gen.go +++ b/assuredworkloads/v1beta1/assuredworkloads-gen.go @@ -328,34 +328,34 @@ type GoogleCloudAssuredworkloadsV1beta1CreateWorkloadOperationMetadata struct { // "CJIS" - Criminal Justice Information Services (CJIS) Security policies. // "FEDRAMP_HIGH" - FedRAMP High data protection controls // "FEDRAMP_MODERATE" - FedRAMP Moderate data protection controls - // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data - // protection controls // "US_REGIONAL_ACCESS" - Assured Workloads For US Regions data protection // controls + // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data + // protection controls // "HIPAA" - Health Insurance Portability and Accountability Act controls // "HITRUST" - Health Information Trust Alliance controls - // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and - // Support controls // "EU_REGIONS_AND_SUPPORT" - Assured Workloads For EU Regions and Support // controls - // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and // Support controls // "CA_REGIONS_AND_SUPPORT" - Assured Workloads For Canada Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // Support controls // "ITAR" - International Traffic in Arms Regulations - // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions - // and Support controls // "AU_REGIONS_AND_US_SUPPORT" - Assured Workloads for Australia Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions + // and Support controls // "ASSURED_WORKLOADS_FOR_PARTNERS" - Assured Workloads for Partners; - // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS" - Assured Workloads for Israel Regions + // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS_AND_SUPPORT" - Assured Workloads for Israel Regions // "CA_PROTECTED_B" - Assured Workloads for Canada Protected B regime // "IL5" - Information protection as per DoD IL5 requirements. // "IL2" - Information protection as per DoD IL2 requirements. - // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "JP_REGIONS_AND_SUPPORT" - Assured Workloads for Japan Regions + // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS" - KSA R5 Controls. // "REGIONAL_CONTROLS" - Assured Workloads for Regional Controls/Free Regions // "FREE_REGIONS" - Assured Workloads for Regional Controls/Free Regions @@ -848,34 +848,34 @@ type GoogleCloudAssuredworkloadsV1beta1Workload struct { // "CJIS" - Criminal Justice Information Services (CJIS) Security policies. // "FEDRAMP_HIGH" - FedRAMP High data protection controls // "FEDRAMP_MODERATE" - FedRAMP Moderate data protection controls - // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data - // protection controls // "US_REGIONAL_ACCESS" - Assured Workloads For US Regions data protection // controls + // "REGIONAL_CONTROLS_PREMIUM_US" - Assured Workloads For US Regions data + // protection controls // "HIPAA" - Health Insurance Portability and Accountability Act controls // "HITRUST" - Health Information Trust Alliance controls - // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and - // Support controls // "EU_REGIONS_AND_SUPPORT" - Assured Workloads For EU Regions and Support // controls - // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // "REGIONAL_CONTROLS_PREMIUM_EU" - Assured Workloads For EU Regions and // Support controls // "CA_REGIONS_AND_SUPPORT" - Assured Workloads For Canada Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_CA" - Assured Workloads For Canada Regions and + // Support controls // "ITAR" - International Traffic in Arms Regulations - // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions - // and Support controls // "AU_REGIONS_AND_US_SUPPORT" - Assured Workloads for Australia Regions and // Support controls + // "REGIONAL_CONTROLS_PREMIUM_AU" - Assured Workloads for Australia Regions + // and Support controls // "ASSURED_WORKLOADS_FOR_PARTNERS" - Assured Workloads for Partners; - // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS" - Assured Workloads for Israel Regions + // "REGIONAL_CONTROLS_PREMIUM_ISR" - Assured Workloads for Israel // "ISR_REGIONS_AND_SUPPORT" - Assured Workloads for Israel Regions // "CA_PROTECTED_B" - Assured Workloads for Canada Protected B regime // "IL5" - Information protection as per DoD IL5 requirements. // "IL2" - Information protection as per DoD IL2 requirements. - // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "JP_REGIONS_AND_SUPPORT" - Assured Workloads for Japan Regions + // "REGIONAL_CONTROLS_PREMIUM_JP" - Assured Workloads for Japan Regions // "KSA_REGIONS_AND_SUPPORT_WITH_SOVEREIGNTY_CONTROLS" - KSA R5 Controls. // "REGIONAL_CONTROLS" - Assured Workloads for Regional Controls/Free Regions // "FREE_REGIONS" - Assured Workloads for Regional Controls/Free Regions diff --git a/cloudbuild/v1/cloudbuild-api.json b/cloudbuild/v1/cloudbuild-api.json index a5b8f302d23..91bc7aeb976 100644 --- a/cloudbuild/v1/cloudbuild-api.json +++ b/cloudbuild/v1/cloudbuild-api.json @@ -2346,7 +2346,7 @@ } } }, - "revision": "20240512", + "revision": "20240519", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "ApprovalConfig": { @@ -3026,7 +3026,7 @@ "type": "string" }, "diskSizeGb": { - "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.", + "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 4000GB; builds that request more than the maximum are rejected with an error.", "format": "int64", "type": "string" }, diff --git a/cloudbuild/v1/cloudbuild-gen.go b/cloudbuild/v1/cloudbuild-gen.go index dfd6c11dd3b..91aa7dafb7c 100644 --- a/cloudbuild/v1/cloudbuild-gen.go +++ b/cloudbuild/v1/cloudbuild-gen.go @@ -1190,7 +1190,7 @@ type BuildOptions struct { // this is *NOT* "disk free"; some of the space will be used by the operating // system and build utilities. Also note that this is the minimum disk size // that will be allocated for the build -- the build may run with a larger disk - // than requested. At present, the maximum disk size is 2000GB; builds that + // than requested. At present, the maximum disk size is 4000GB; builds that // request more than the maximum are rejected with an error. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` // DynamicSubstitutions: Option to specify whether or not to apply bash style diff --git a/cloudbuild/v2/cloudbuild-api.json b/cloudbuild/v2/cloudbuild-api.json index c7868b9127c..b3c26362e50 100644 --- a/cloudbuild/v2/cloudbuild-api.json +++ b/cloudbuild/v2/cloudbuild-api.json @@ -844,7 +844,7 @@ } } }, - "revision": "20240427", + "revision": "20240519", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "AuditConfig": { @@ -977,7 +977,7 @@ "description": "Required. A http access token with the `REPO_ADMIN` scope access." }, "hostUri": { - "description": "Required. The URI of the Bitbucket Data Center instance or cluster this connection is for.", + "description": "Optional. The URI of the Bitbucket Data Center instance or cluster this connection is for.", "type": "string" }, "readAuthorizerCredential": { @@ -1074,7 +1074,7 @@ "additionalProperties": { "type": "string" }, - "description": "Allows clients to store small amounts of arbitrary data.", + "description": "Optional. Allows clients to store small amounts of arbitrary data.", "type": "object" }, "bitbucketCloudConfig": { @@ -1092,7 +1092,7 @@ "type": "string" }, "disabled": { - "description": "If disabled is set to true, functionality is disabled for this connection. Repository based API methods and webhooks processing for repositories in this connection will be disabled.", + "description": "Optional. If disabled is set to true, functionality is disabled for this connection. Repository based API methods and webhooks processing for repositories in this connection will be disabled.", "type": "boolean" }, "etag": { @@ -1320,13 +1320,13 @@ "id": "GitHubConfig", "properties": { "appInstallationId": { - "description": "GitHub App installation id.", + "description": "Optional. GitHub App installation id.", "format": "int64", "type": "string" }, "authorizerCredential": { "$ref": "OAuthCredential", - "description": "OAuth credential of the account that authorized the Cloud Build GitHub App. It is recommended to use a robot account instead of a human user account. The OAuth token must be tied to the Cloud Build GitHub App." + "description": "Optional. OAuth credential of the account that authorized the Cloud Build GitHub App. It is recommended to use a robot account instead of a human user account. The OAuth token must be tied to the Cloud Build GitHub App." } }, "type": "object" @@ -1392,17 +1392,17 @@ "type": "string" }, "appId": { - "description": "Id of the GitHub App created from the manifest.", + "description": "Optional. Id of the GitHub App created from the manifest.", "format": "int64", "type": "string" }, "appInstallationId": { - "description": "ID of the installation of the GitHub App.", + "description": "Optional. ID of the installation of the GitHub App.", "format": "int64", "type": "string" }, "appSlug": { - "description": "The URL-friendly name of the GitHub App.", + "description": "Optional. The URL-friendly name of the GitHub App.", "type": "string" }, "hostUri": { @@ -1410,7 +1410,7 @@ "type": "string" }, "privateKeySecretVersion": { - "description": "SecretManager resource containing the private key of the GitHub App, formatted as `projects/*/secrets/*/versions/*`.", + "description": "Optional. SecretManager resource containing the private key of the GitHub App, formatted as `projects/*/secrets/*/versions/*`.", "type": "string" }, "serverVersion": { @@ -1420,14 +1420,14 @@ }, "serviceDirectoryConfig": { "$ref": "GoogleDevtoolsCloudbuildV2ServiceDirectoryConfig", - "description": "Configuration for using Service Directory to privately connect to a GitHub Enterprise server. This should only be set if the GitHub Enterprise server is hosted on-premises and not reachable by public internet. If this field is left empty, calls to the GitHub Enterprise server will be made over the public internet." + "description": "Optional. Configuration for using Service Directory to privately connect to a GitHub Enterprise server. This should only be set if the GitHub Enterprise server is hosted on-premises and not reachable by public internet. If this field is left empty, calls to the GitHub Enterprise server will be made over the public internet." }, "sslCa": { - "description": "SSL certificate to use for requests to GitHub Enterprise.", + "description": "Optional. SSL certificate to use for requests to GitHub Enterprise.", "type": "string" }, "webhookSecretSecretVersion": { - "description": "SecretManager resource containing the webhook secret of the GitHub App, formatted as `projects/*/secrets/*/versions/*`.", + "description": "Optional. SecretManager resource containing the webhook secret of the GitHub App, formatted as `projects/*/secrets/*/versions/*`.", "type": "string" } }, @@ -1442,7 +1442,7 @@ "description": "Required. A GitLab personal access token with the `api` scope access." }, "hostUri": { - "description": "The URI of the GitLab Enterprise host this connection is for. If not specified, the default value is https://gitlab.com.", + "description": "Optional. The URI of the GitLab Enterprise host this connection is for. If not specified, the default value is https://gitlab.com.", "type": "string" }, "readAuthorizerCredential": { @@ -1456,10 +1456,10 @@ }, "serviceDirectoryConfig": { "$ref": "GoogleDevtoolsCloudbuildV2ServiceDirectoryConfig", - "description": "Configuration for using Service Directory to privately connect to a GitLab Enterprise server. This should only be set if the GitLab Enterprise server is hosted on-premises and not reachable by public internet. If this field is left empty, calls to the GitLab Enterprise server will be made over the public internet." + "description": "Optional. Configuration for using Service Directory to privately connect to a GitLab Enterprise server. This should only be set if the GitLab Enterprise server is hosted on-premises and not reachable by public internet. If this field is left empty, calls to the GitLab Enterprise server will be made over the public internet." }, "sslCa": { - "description": "SSL certificate to use for requests to GitLab Enterprise.", + "description": "Optional. SSL certificate to use for requests to GitLab Enterprise.", "type": "string" }, "webhookSecretSecretVersion": { @@ -1680,7 +1680,7 @@ "id": "OAuthCredential", "properties": { "oauthTokenSecretVersion": { - "description": "A SecretManager resource containing the OAuth token that authorizes the Cloud Build connection. Format: `projects/*/secrets/*/versions/*`.", + "description": "Optional. A SecretManager resource containing the OAuth token that authorizes the Cloud Build connection. Format: `projects/*/secrets/*/versions/*`.", "type": "string" }, "username": { @@ -2370,7 +2370,7 @@ "additionalProperties": { "type": "string" }, - "description": "Allows clients to store small amounts of arbitrary data.", + "description": "Optional. Allows clients to store small amounts of arbitrary data.", "type": "object" }, "createTime": { diff --git a/cloudbuild/v2/cloudbuild-gen.go b/cloudbuild/v2/cloudbuild-gen.go index 4b1223af3e4..1a2696cb4c0 100644 --- a/cloudbuild/v2/cloudbuild-gen.go +++ b/cloudbuild/v2/cloudbuild-gen.go @@ -475,7 +475,7 @@ type BitbucketDataCenterConfig struct { // AuthorizerCredential: Required. A http access token with the `REPO_ADMIN` // scope access. AuthorizerCredential *UserCredential `json:"authorizerCredential,omitempty"` - // HostUri: Required. The URI of the Bitbucket Data Center instance or cluster + // HostUri: Optional. The URI of the Bitbucket Data Center instance or cluster // this connection is for. HostUri string `json:"hostUri,omitempty"` // ReadAuthorizerCredential: Required. A http access token with the `REPO_READ` @@ -582,7 +582,8 @@ func (s *ChildStatusReference) MarshalJSON() ([]byte, error) { // Connection: A connection to a SCM like GitHub, GitHub Enterprise, Bitbucket // Data Center, Bitbucket Cloud or GitLab. type Connection struct { - // Annotations: Allows clients to store small amounts of arbitrary data. + // Annotations: Optional. Allows clients to store small amounts of arbitrary + // data. Annotations map[string]string `json:"annotations,omitempty"` // BitbucketCloudConfig: Configuration for connections to Bitbucket Cloud. BitbucketCloudConfig *BitbucketCloudConfig `json:"bitbucketCloudConfig,omitempty"` @@ -592,9 +593,9 @@ type Connection struct { // CreateTime: Output only. Server assigned timestamp for when the connection // was created. CreateTime string `json:"createTime,omitempty"` - // Disabled: If disabled is set to true, functionality is disabled for this - // connection. Repository based API methods and webhooks processing for - // repositories in this connection will be disabled. + // Disabled: Optional. If disabled is set to true, functionality is disabled + // for this connection. Repository based API methods and webhooks processing + // for repositories in this connection will be disabled. Disabled bool `json:"disabled,omitempty"` // Etag: This checksum is computed by the server based on the value of other // fields, and may be sent on update and delete requests to ensure the client @@ -930,12 +931,12 @@ func (s *FetchReadWriteTokenResponse) MarshalJSON() ([]byte, error) { // GitHubConfig: Configuration for connections to github.com. type GitHubConfig struct { - // AppInstallationId: GitHub App installation id. + // AppInstallationId: Optional. GitHub App installation id. AppInstallationId int64 `json:"appInstallationId,omitempty,string"` - // AuthorizerCredential: OAuth credential of the account that authorized the - // Cloud Build GitHub App. It is recommended to use a robot account instead of - // a human user account. The OAuth token must be tied to the Cloud Build GitHub - // App. + // AuthorizerCredential: Optional. OAuth credential of the account that + // authorized the Cloud Build GitHub App. It is recommended to use a robot + // account instead of a human user account. The OAuth token must be tied to the + // Cloud Build GitHub App. AuthorizerCredential *OAuthCredential `json:"authorizerCredential,omitempty"` // ForceSendFields is a list of field names (e.g. "AppInstallationId") to // unconditionally include in API requests. By default, fields with empty or @@ -1004,31 +1005,33 @@ func (s *GoogleDevtoolsCloudbuildV2Condition) MarshalJSON() ([]byte, error) { type GoogleDevtoolsCloudbuildV2GitHubEnterpriseConfig struct { // ApiKey: Required. API Key used for authentication of webhook events. ApiKey string `json:"apiKey,omitempty"` - // AppId: Id of the GitHub App created from the manifest. + // AppId: Optional. Id of the GitHub App created from the manifest. AppId int64 `json:"appId,omitempty,string"` - // AppInstallationId: ID of the installation of the GitHub App. + // AppInstallationId: Optional. ID of the installation of the GitHub App. AppInstallationId int64 `json:"appInstallationId,omitempty,string"` - // AppSlug: The URL-friendly name of the GitHub App. + // AppSlug: Optional. The URL-friendly name of the GitHub App. AppSlug string `json:"appSlug,omitempty"` // HostUri: Required. The URI of the GitHub Enterprise host this connection is // for. HostUri string `json:"hostUri,omitempty"` - // PrivateKeySecretVersion: SecretManager resource containing the private key - // of the GitHub App, formatted as `projects/*/secrets/*/versions/*`. + // PrivateKeySecretVersion: Optional. SecretManager resource containing the + // private key of the GitHub App, formatted as + // `projects/*/secrets/*/versions/*`. PrivateKeySecretVersion string `json:"privateKeySecretVersion,omitempty"` // ServerVersion: Output only. GitHub Enterprise version installed at the // host_uri. ServerVersion string `json:"serverVersion,omitempty"` - // ServiceDirectoryConfig: Configuration for using Service Directory to - // privately connect to a GitHub Enterprise server. This should only be set if - // the GitHub Enterprise server is hosted on-premises and not reachable by + // ServiceDirectoryConfig: Optional. Configuration for using Service Directory + // to privately connect to a GitHub Enterprise server. This should only be set + // if the GitHub Enterprise server is hosted on-premises and not reachable by // public internet. If this field is left empty, calls to the GitHub Enterprise // server will be made over the public internet. ServiceDirectoryConfig *GoogleDevtoolsCloudbuildV2ServiceDirectoryConfig `json:"serviceDirectoryConfig,omitempty"` - // SslCa: SSL certificate to use for requests to GitHub Enterprise. + // SslCa: Optional. SSL certificate to use for requests to GitHub Enterprise. SslCa string `json:"sslCa,omitempty"` - // WebhookSecretSecretVersion: SecretManager resource containing the webhook - // secret of the GitHub App, formatted as `projects/*/secrets/*/versions/*`. + // WebhookSecretSecretVersion: Optional. SecretManager resource containing the + // webhook secret of the GitHub App, formatted as + // `projects/*/secrets/*/versions/*`. WebhookSecretSecretVersion string `json:"webhookSecretSecretVersion,omitempty"` // ForceSendFields is a list of field names (e.g. "ApiKey") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -1054,8 +1057,8 @@ type GoogleDevtoolsCloudbuildV2GitLabConfig struct { // AuthorizerCredential: Required. A GitLab personal access token with the // `api` scope access. AuthorizerCredential *UserCredential `json:"authorizerCredential,omitempty"` - // HostUri: The URI of the GitLab Enterprise host this connection is for. If - // not specified, the default value is https://gitlab.com. + // HostUri: Optional. The URI of the GitLab Enterprise host this connection is + // for. If not specified, the default value is https://gitlab.com. HostUri string `json:"hostUri,omitempty"` // ReadAuthorizerCredential: Required. A GitLab personal access token with the // minimum `read_api` scope access. @@ -1063,13 +1066,13 @@ type GoogleDevtoolsCloudbuildV2GitLabConfig struct { // ServerVersion: Output only. Version of the GitLab Enterprise server running // on the `host_uri`. ServerVersion string `json:"serverVersion,omitempty"` - // ServiceDirectoryConfig: Configuration for using Service Directory to - // privately connect to a GitLab Enterprise server. This should only be set if - // the GitLab Enterprise server is hosted on-premises and not reachable by + // ServiceDirectoryConfig: Optional. Configuration for using Service Directory + // to privately connect to a GitLab Enterprise server. This should only be set + // if the GitLab Enterprise server is hosted on-premises and not reachable by // public internet. If this field is left empty, calls to the GitLab Enterprise // server will be made over the public internet. ServiceDirectoryConfig *GoogleDevtoolsCloudbuildV2ServiceDirectoryConfig `json:"serviceDirectoryConfig,omitempty"` - // SslCa: SSL certificate to use for requests to GitLab Enterprise. + // SslCa: Optional. SSL certificate to use for requests to GitLab Enterprise. SslCa string `json:"sslCa,omitempty"` // WebhookSecretSecretVersion: Required. Immutable. SecretManager resource // containing the webhook secret of a GitLab Enterprise project, formatted as @@ -1367,8 +1370,8 @@ func (s *Location) MarshalJSON() ([]byte, error) { // OAuthCredential: Represents an OAuth token of the account that authorized // the Connection, and associated metadata. type OAuthCredential struct { - // OauthTokenSecretVersion: A SecretManager resource containing the OAuth token - // that authorizes the Cloud Build connection. Format: + // OauthTokenSecretVersion: Optional. A SecretManager resource containing the + // OAuth token that authorizes the Cloud Build connection. Format: // `projects/*/secrets/*/versions/*`. OauthTokenSecretVersion string `json:"oauthTokenSecretVersion,omitempty"` // Username: Output only. The username associated to this token. @@ -2068,7 +2071,8 @@ func (s *Provenance) MarshalJSON() ([]byte, error) { // Repository: A repository associated to a parent connection. type Repository struct { - // Annotations: Allows clients to store small amounts of arbitrary data. + // Annotations: Optional. Allows clients to store small amounts of arbitrary + // data. Annotations map[string]string `json:"annotations,omitempty"` // CreateTime: Output only. Server assigned timestamp for when the connection // was created. diff --git a/composer/v1/composer-api.json b/composer/v1/composer-api.json index a59dbed1f3c..4eebf7439c3 100644 --- a/composer/v1/composer-api.json +++ b/composer/v1/composer-api.json @@ -111,6 +111,34 @@ "resources": { "environments": { "methods": { + "checkUpgrade": { + "description": "Check if an upgrade operation on the environment will succeed. In case of problems detailed info can be found in the returned Operation.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/environments/{environmentsId}:checkUpgrade", + "httpMethod": "POST", + "id": "composer.projects.locations.environments.checkUpgrade", + "parameterOrder": [ + "environment" + ], + "parameters": { + "environment": { + "description": "Required. The resource name of the environment to check upgrade for, in the form: \"projects/{projectId}/locations/{locationId}/environments/{environmentId}\"", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/environments/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+environment}:checkUpgrade", + "request": { + "$ref": "CheckUpgradeRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "create": { "description": "Create a new environment.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/environments", @@ -938,7 +966,7 @@ } } }, - "revision": "20240317", + "revision": "20240520", "rootUrl": "https://composer.googleapis.com/", "schemas": { "AirflowMetadataRetentionPolicyConfig": { @@ -982,6 +1010,17 @@ }, "type": "object" }, + "CheckUpgradeRequest": { + "description": "Request to check whether image upgrade will succeed.", + "id": "CheckUpgradeRequest", + "properties": { + "imageVersion": { + "description": "Optional. The version of the software running in the environment. This encapsulates both the version of Cloud Composer functionality and the version of Apache Airflow. It must match the regular expression `composer-([0-9]+(\\.[0-9]+\\.[0-9]+(-preview\\.[0-9]+)?)?|latest)-airflow-([0-9]+(\\.[0-9]+(\\.[0-9]+)?)?)`. When used as input, the server also checks if the provided version is supported and denies the request for an unsupported version. The Cloud Composer portion of the image version is a full [semantic version](https://semver.org), or an alias in the form of major version number or `latest`. When an alias is provided, the server replaces it with the current Cloud Composer version that satisfies the alias. The Apache Airflow portion of the image version is a full semantic version that points to one of the supported Apache Airflow versions, or an alias in the form of only major or major.minor versions specified. When an alias is provided, the server replaces it with the latest Apache Airflow version that satisfies the alias and is supported in the given Cloud Composer version. In all cases, the resolved image version is stored in the same field. See also [version list](/composer/docs/concepts/versioning/composer-versions) and [versioning overview](/composer/docs/concepts/versioning/composer-versioning-overview).", + "type": "string" + } + }, + "type": "object" + }, "CheckUpgradeResponse": { "description": "Message containing information about the result of an upgrade check operation.", "id": "CheckUpgradeResponse", diff --git a/composer/v1/composer-gen.go b/composer/v1/composer-gen.go index dd975fee2ee..33976a0f389 100644 --- a/composer/v1/composer-gen.go +++ b/composer/v1/composer-gen.go @@ -308,6 +308,46 @@ func (s *AllowedIpRange) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// CheckUpgradeRequest: Request to check whether image upgrade will succeed. +type CheckUpgradeRequest struct { + // ImageVersion: Optional. The version of the software running in the + // environment. This encapsulates both the version of Cloud Composer + // functionality and the version of Apache Airflow. It must match the regular + // expression + // `composer-([0-9]+(\.[0-9]+\.[0-9]+(-preview\.[0-9]+)?)?|latest)-airflow-([0-9 + // ]+(\.[0-9]+(\.[0-9]+)?)?)`. When used as input, the server also checks if + // the provided version is supported and denies the request for an unsupported + // version. The Cloud Composer portion of the image version is a full semantic + // version (https://semver.org), or an alias in the form of major version + // number or `latest`. When an alias is provided, the server replaces it with + // the current Cloud Composer version that satisfies the alias. The Apache + // Airflow portion of the image version is a full semantic version that points + // to one of the supported Apache Airflow versions, or an alias in the form of + // only major or major.minor versions specified. When an alias is provided, the + // server replaces it with the latest Apache Airflow version that satisfies the + // alias and is supported in the given Cloud Composer version. In all cases, + // the resolved image version is stored in the same field. See also version + // list (/composer/docs/concepts/versioning/composer-versions) and versioning + // overview (/composer/docs/concepts/versioning/composer-versioning-overview). + ImageVersion string `json:"imageVersion,omitempty"` + // ForceSendFields is a list of field names (e.g. "ImageVersion") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ImageVersion") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *CheckUpgradeRequest) MarshalJSON() ([]byte, error) { + type NoMethod CheckUpgradeRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // CheckUpgradeResponse: Message containing information about the result of an // upgrade check operation. type CheckUpgradeResponse struct { @@ -2445,6 +2485,110 @@ func (s *WorkloadsConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +type ProjectsLocationsEnvironmentsCheckUpgradeCall struct { + s *Service + environment string + checkupgraderequest *CheckUpgradeRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// CheckUpgrade: Check if an upgrade operation on the environment will succeed. +// In case of problems detailed info can be found in the returned Operation. +// +// - environment: The resource name of the environment to check upgrade for, in +// the form: +// "projects/{projectId}/locations/{locationId}/environments/{environmentId}". +func (r *ProjectsLocationsEnvironmentsService) CheckUpgrade(environment string, checkupgraderequest *CheckUpgradeRequest) *ProjectsLocationsEnvironmentsCheckUpgradeCall { + c := &ProjectsLocationsEnvironmentsCheckUpgradeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.environment = environment + c.checkupgraderequest = checkupgraderequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsEnvironmentsCheckUpgradeCall) Fields(s ...googleapi.Field) *ProjectsLocationsEnvironmentsCheckUpgradeCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsEnvironmentsCheckUpgradeCall) Context(ctx context.Context) *ProjectsLocationsEnvironmentsCheckUpgradeCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsEnvironmentsCheckUpgradeCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsEnvironmentsCheckUpgradeCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.checkupgraderequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+environment}:checkUpgrade") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "environment": c.environment, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "composer.projects.locations.environments.checkUpgrade" call. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsEnvironmentsCheckUpgradeCall) Do(opts ...googleapi.CallOption) (*Operation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Operation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + type ProjectsLocationsEnvironmentsCreateCall struct { s *Service parent string diff --git a/compute/v1/compute-api.json b/compute/v1/compute-api.json index c31acb91571..4a6b808bf06 100644 --- a/compute/v1/compute-api.json +++ b/compute/v1/compute-api.json @@ -28015,7 +28015,7 @@ ] }, "list": { - "description": "Retrieves the list of region resources available to the specified project. To decrease latency for this method, you can optionally omit any unneeded information from the response by using a field mask. This practice is especially recommended for unused quota information (the `items.quotas` field). To exclude one or more fields, set your request's `fields` query parameter to only include the fields you need. For example, to only include the `id` and `selfLink` fields, add the query parameter `?fields=id,selfLink` to your request.", + "description": "Retrieves the list of region resources available to the specified project. To decrease latency for this method, you can optionally omit any unneeded information from the response by using a field mask. This practice is especially recommended for unused quota information (the `items.quotas` field). To exclude one or more fields, set your request's `fields` query parameter to only include the fields you need. For example, to only include the `id` and `selfLink` fields, add the query parameter `?fields=id,selfLink` to your request. This method fails if the quota information is unavailable for the region and if the organization policy constraint compute.requireBasicQuotaInResponse is enforced. This constraint, when enforced, disables the fail-open behaviour when quota information (the `items.quotas` field) is unavailable for the region. It is recommended to use the default setting for the constraint unless your application requires the fail-closed behaviour for this method.", "flatPath": "projects/{project}/regions", "httpMethod": "GET", "id": "compute.regions.list", @@ -37421,7 +37421,7 @@ } } }, - "revision": "20240507", + "revision": "20240519", "rootUrl": "https://compute.googleapis.com/", "schemas": { "AWSV4Signature": { @@ -38896,7 +38896,7 @@ }, "diskEncryptionKey": { "$ref": "CustomerEncryptionKey", - "description": "Encrypts or decrypts a disk using a customer-supplied encryption key. If you are creating a new disk, this field encrypts the new disk using an encryption key that you provide. If you are attaching an existing disk that is already encrypted, this field decrypts the disk using the customer-supplied encryption key. If you encrypt a disk using a customer-supplied key, you must provide the same key again when you attempt to use this resource at a later time. For example, you must provide the key when you create a snapshot or an image from the disk or when you attach the disk to a virtual machine instance. If you do not provide an encryption key, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the disk later. Instance templates do not store customer-supplied encryption keys, so you cannot use your own keys to encrypt disks in a managed instance group." + "description": "Encrypts or decrypts a disk using a customer-supplied encryption key. If you are creating a new disk, this field encrypts the new disk using an encryption key that you provide. If you are attaching an existing disk that is already encrypted, this field decrypts the disk using the customer-supplied encryption key. If you encrypt a disk using a customer-supplied key, you must provide the same key again when you attempt to use this resource at a later time. For example, you must provide the key when you create a snapshot or an image from the disk or when you attach the disk to a virtual machine instance. If you do not provide an encryption key, then the disk will be encrypted using an automatically generated key and you do not need to provide a key to use the disk later. Note: Instance templates do not store customer-supplied encryption keys, so you cannot use your own keys to encrypt disks in a managed instance group. You cannot create VMs that have disks with customer-supplied keys using the bulk insert method." }, "diskSizeGb": { "description": "The size of the disk in GB.", @@ -42988,6 +42988,20 @@ "description": "Represents a Persistent Disk resource. Google Compute Engine has two Disk resources: * [Zonal](/compute/docs/reference/rest/v1/disks) * [Regional](/compute/docs/reference/rest/v1/regionDisks) Persistent disks are required for running your VM instances. Create both boot and non-boot (data) persistent disks. For more information, read Persistent Disks. For more storage options, read Storage options. The disks resource represents a zonal persistent disk. For more information, read Zonal persistent disks. The regionDisks resource represents a regional persistent disk. For more information, read Regional resources.", "id": "Disk", "properties": { + "accessMode": { + "description": "The access mode of the disk. - READ_WRITE_SINGLE: The default AccessMode, means the disk can be attached to single instance in RW mode. - READ_WRITE_MANY: The AccessMode means the disk can be attached to multiple instances in RW mode. - READ_ONLY_MANY: The AccessMode means the disk can be attached to multiple instances in RO mode. The AccessMode is only valid for Hyperdisk disk types.", + "enum": [ + "READ_ONLY_MANY", + "READ_WRITE_MANY", + "READ_WRITE_SINGLE" + ], + "enumDescriptions": [ + "The AccessMode means the disk can be attached to multiple instances in RO mode.", + "The AccessMode means the disk can be attached to multiple instances in RW mode.", + "The default AccessMode, means the disk can be attached to single instance in RW mode." + ], + "type": "string" + }, "architecture": { "description": "The architecture of the disk. Valid values are ARM64 or X86_64.", "enum": [ @@ -52336,7 +52350,7 @@ "compute.instanceTemplates.insert" ] }, - "description": "The machine type to use for instances that are created from these properties.", + "description": "The machine type to use for instances that are created from these properties. This field only accept machine types name. e.g. n2-standard-4 and does not accept machine type full or partial url. e.g. projects/my-l7ilb-project/zones/us-central1-a/machineTypes/n2-standard-4 will throw INTERNAL_ERROR.", "type": "string" }, "metadata": { @@ -59831,11 +59845,13 @@ "description": "The type of vNIC to be used on this interface. This may be gVNIC or VirtioNet.", "enum": [ "GVNIC", + "IDPF", "UNSPECIFIED_NIC_TYPE", "VIRTIO_NET" ], "enumDescriptions": [ "GVNIC", + "IDPF", "No type specified.", "VIRTIO" ], @@ -82487,11 +82503,13 @@ "description": "The stack type for this VPN gateway to identify the IP protocols that are enabled. Possible values are: IPV4_ONLY, IPV4_IPV6. If not specified, IPV4_ONLY will be used.", "enum": [ "IPV4_IPV6", - "IPV4_ONLY" + "IPV4_ONLY", + "IPV6_ONLY" ], "enumDescriptions": [ "Enable VPN gateway with both IPv4 and IPv6 protocols.", - "Enable VPN gateway with only IPv4 protocol." + "Enable VPN gateway with only IPv4 protocol.", + "Enable VPN gateway with only IPv6 protocol." ], "type": "string" }, diff --git a/compute/v1/compute-gen.go b/compute/v1/compute-gen.go index 91bbf8a8720..5e70e4d6677 100644 --- a/compute/v1/compute-gen.go +++ b/compute/v1/compute-gen.go @@ -2990,9 +2990,10 @@ type AttachedDisk struct { // when you create a snapshot or an image from the disk or when you attach the // disk to a virtual machine instance. If you do not provide an encryption key, // then the disk will be encrypted using an automatically generated key and you - // do not need to provide a key to use the disk later. Instance templates do - // not store customer-supplied encryption keys, so you cannot use your own keys - // to encrypt disks in a managed instance group. + // do not need to provide a key to use the disk later. Note: Instance templates + // do not store customer-supplied encryption keys, so you cannot use your own + // keys to encrypt disks in a managed instance group. You cannot create VMs + // that have disks with customer-supplied keys using the bulk insert method. DiskEncryptionKey *CustomerEncryptionKey `json:"diskEncryptionKey,omitempty"` // DiskSizeGb: The size of the disk in GB. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` @@ -7939,6 +7940,21 @@ func (s *DeprecationStatus) MarshalJSON() ([]byte, error) { // regionDisks resource represents a regional persistent disk. For more // information, read Regional resources. type Disk struct { + // AccessMode: The access mode of the disk. - READ_WRITE_SINGLE: The default + // AccessMode, means the disk can be attached to single instance in RW mode. - + // READ_WRITE_MANY: The AccessMode means the disk can be attached to multiple + // instances in RW mode. - READ_ONLY_MANY: The AccessMode means the disk can be + // attached to multiple instances in RO mode. The AccessMode is only valid for + // Hyperdisk disk types. + // + // Possible values: + // "READ_ONLY_MANY" - The AccessMode means the disk can be attached to + // multiple instances in RO mode. + // "READ_WRITE_MANY" - The AccessMode means the disk can be attached to + // multiple instances in RW mode. + // "READ_WRITE_SINGLE" - The default AccessMode, means the disk can be + // attached to single instance in RW mode. + AccessMode string `json:"accessMode,omitempty"` // Architecture: The architecture of the disk. Valid values are ARM64 or // X86_64. // @@ -8190,13 +8206,13 @@ type Disk struct { // ServerResponse contains the HTTP response code and headers from the server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Architecture") to + // ForceSendFields is a list of field names (e.g. "AccessMode") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Architecture") to include in API + // NullFields is a list of field names (e.g. "AccessMode") to include in API // requests with the JSON null value. By default, fields with empty values are // omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. @@ -18814,7 +18830,10 @@ type InstanceProperties struct { // Labels: Labels to apply to instances that are created from these properties. Labels map[string]string `json:"labels,omitempty"` // MachineType: The machine type to use for instances that are created from - // these properties. + // these properties. This field only accept machine types name. e.g. + // n2-standard-4 and does not accept machine type full or partial url. e.g. + // projects/my-l7ilb-project/zones/us-central1-a/machineTypes/n2-standard-4 + // will throw INTERNAL_ERROR. MachineType string `json:"machineType,omitempty"` // Metadata: The metadata key/value pairs to assign to instances that are // created from these properties. These pairs can consist of custom metadata or @@ -27132,6 +27151,7 @@ type NetworkInterface struct { // // Possible values: // "GVNIC" - GVNIC + // "IDPF" - IDPF // "UNSPECIFIED_NIC_TYPE" - No type specified. // "VIRTIO_NET" - VIRTIO NicType string `json:"nicType,omitempty"` @@ -51603,6 +51623,7 @@ type VpnGateway struct { // Possible values: // "IPV4_IPV6" - Enable VPN gateway with both IPv4 and IPv6 protocols. // "IPV4_ONLY" - Enable VPN gateway with only IPv4 protocol. + // "IPV6_ONLY" - Enable VPN gateway with only IPv6 protocol. StackType string `json:"stackType,omitempty"` // VpnInterfaces: The list of VPN interfaces associated with this VPN gateway. VpnInterfaces []*VpnGatewayVpnGatewayInterface `json:"vpnInterfaces,omitempty"` diff --git a/compute/v1/compute3-gen.go b/compute/v1/compute3-gen.go index a78dcd5b5f9..254547bb0a6 100644 --- a/compute/v1/compute3-gen.go +++ b/compute/v1/compute3-gen.go @@ -21968,7 +21968,13 @@ type RegionsListCall struct { // field). To exclude one or more fields, set your request's `fields` query // parameter to only include the fields you need. For example, to only include // the `id` and `selfLink` fields, add the query parameter -// `?fields=id,selfLink` to your request. +// `?fields=id,selfLink` to your request. This method fails if the quota +// information is unavailable for the region and if the organization policy +// constraint compute.requireBasicQuotaInResponse is enforced. This constraint, +// when enforced, disables the fail-open behaviour when quota information (the +// `items.quotas` field) is unavailable for the region. It is recommended to +// use the default setting for the constraint unless your application requires +// the fail-closed behaviour for this method. // // - project: Project ID for this request. func (r *RegionsService) List(project string) *RegionsListCall { diff --git a/container/v1/container-api.json b/container/v1/container-api.json index ae43d91c406..79bf232105e 100644 --- a/container/v1/container-api.json +++ b/container/v1/container-api.json @@ -2540,7 +2540,7 @@ } } }, - "revision": "20240422", + "revision": "20240510", "rootUrl": "https://container.googleapis.com/", "schemas": { "AcceleratorConfig": { @@ -5038,7 +5038,9 @@ "POD", "DAEMONSET", "DEPLOYMENT", - "STATEFULSET" + "STATEFULSET", + "CADVISOR", + "KUBELET" ], "enumDescriptions": [ "Default value. This shouldn't be used.", @@ -5051,7 +5053,9 @@ "Pod", "DaemonSet", "Deployment", - "Statefulset" + "Statefulset", + "CADVISOR", + "KUBELET" ], "type": "string" }, diff --git a/container/v1/container-gen.go b/container/v1/container-gen.go index 84dc2d71c91..9cc6427b9ad 100644 --- a/container/v1/container-gen.go +++ b/container/v1/container-gen.go @@ -3541,6 +3541,8 @@ type MonitoringComponentConfig struct { // "DAEMONSET" - DaemonSet // "DEPLOYMENT" - Deployment // "STATEFULSET" - Statefulset + // "CADVISOR" - CADVISOR + // "KUBELET" - KUBELET EnableComponents []string `json:"enableComponents,omitempty"` // ForceSendFields is a list of field names (e.g. "EnableComponents") to // unconditionally include in API requests. By default, fields with empty or diff --git a/developerconnect/v1/developerconnect-api.json b/developerconnect/v1/developerconnect-api.json new file mode 100644 index 00000000000..01db6c41a5d --- /dev/null +++ b/developerconnect/v1/developerconnect-api.json @@ -0,0 +1,1596 @@ +{ + "auth": { + "oauth2": { + "scopes": { + "https://www.googleapis.com/auth/cloud-platform": { + "description": "See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account." + } + } + } + }, + "basePath": "", + "baseUrl": "https://developerconnect.googleapis.com/", + "batchPath": "batch", + "canonicalName": "Developer Connect", + "description": "Connect third-party source code management to Google", + "discoveryVersion": "v1", + "documentationLink": "http://cloud.google.com/developer-connect/docs/overview", + "fullyEncodeReservedExpansion": true, + "icons": { + "x16": "http://www.google.com/images/icons/product/search-16.gif", + "x32": "http://www.google.com/images/icons/product/search-32.gif" + }, + "id": "developerconnect:v1", + "kind": "discovery#restDescription", + "mtlsRootUrl": "https://developerconnect.mtls.googleapis.com/", + "name": "developerconnect", + "ownerDomain": "google.com", + "ownerName": "Google", + "parameters": { + "$.xgafv": { + "description": "V1 error format.", + "enum": [ + "1", + "2" + ], + "enumDescriptions": [ + "v1 error format", + "v2 error format" + ], + "location": "query", + "type": "string" + }, + "access_token": { + "description": "OAuth access token.", + "location": "query", + "type": "string" + }, + "alt": { + "default": "json", + "description": "Data format for response.", + "enum": [ + "json", + "media", + "proto" + ], + "enumDescriptions": [ + "Responses with Content-Type of application/json", + "Media download with context-dependent Content-Type", + "Responses with Content-Type of application/x-protobuf" + ], + "location": "query", + "type": "string" + }, + "callback": { + "description": "JSONP", + "location": "query", + "type": "string" + }, + "fields": { + "description": "Selector specifying which fields to include in a partial response.", + "location": "query", + "type": "string" + }, + "key": { + "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.", + "location": "query", + "type": "string" + }, + "oauth_token": { + "description": "OAuth 2.0 token for the current user.", + "location": "query", + "type": "string" + }, + "prettyPrint": { + "default": "true", + "description": "Returns response with indentations and line breaks.", + "location": "query", + "type": "boolean" + }, + "quotaUser": { + "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.", + "location": "query", + "type": "string" + }, + "uploadType": { + "description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\").", + "location": "query", + "type": "string" + }, + "upload_protocol": { + "description": "Upload protocol for media (e.g. \"raw\", \"multipart\").", + "location": "query", + "type": "string" + } + }, + "protocol": "rest", + "resources": { + "projects": { + "resources": { + "locations": { + "methods": { + "get": { + "description": "Gets information about a location.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Resource name for the location.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Location" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists information about the supported locations for this service.", + "flatPath": "v1/projects/{projectsId}/locations", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.list", + "parameterOrder": [ + "name" + ], + "parameters": { + "filter": { + "description": "A filter to narrow down results to a preferred subset. The filtering language accepts strings like `\"displayName=tokyo\"`, and is documented in more detail in [AIP-160](https://google.aip.dev/160).", + "location": "query", + "type": "string" + }, + "name": { + "description": "The resource that owns the locations collection, if applicable.", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "The maximum number of results to return. If not set, the service selects a default.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}/locations", + "response": { + "$ref": "ListLocationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "connections": { + "methods": { + "create": { + "description": "Creates a new Connection in a given project and location.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.connections.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "connectionId": { + "description": "Required. Id of the requesting object If auto-generating Id server-side, remove this field and connection_id from the method_signature of Create RPC", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Value for parent.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "validateOnly": { + "description": "Optional. If set, validate the request, but do not actually post it.", + "location": "query", + "type": "boolean" + } + }, + "path": "v1/{+parent}/connections", + "request": { + "$ref": "Connection" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a single Connection.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", + "httpMethod": "DELETE", + "id": "developerconnect.projects.locations.connections.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "etag": { + "description": "Optional. The current etag of the Connection. If an etag is provided and does not match the current etag of the Connection, deletion will be blocked and an ABORTED error will be returned.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. Name of the resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "validateOnly": { + "description": "Optional. If set, validate the request, but do not actually post it.", + "location": "query", + "type": "boolean" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "fetchGitHubInstallations": { + "description": "FetchGitHubInstallations returns the list of GitHub Installations that are available to be added to a Connection. For github.com, only installations accessible to the authorizer token are returned. For GitHub Enterprise, all installations are returned.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:fetchGitHubInstallations", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.connections.fetchGitHubInstallations", + "parameterOrder": [ + "connection" + ], + "parameters": { + "connection": { + "description": "Required. The resource name of the connection in the format `projects/*/locations/*/connections/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+connection}:fetchGitHubInstallations", + "response": { + "$ref": "FetchGitHubInstallationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "fetchLinkableGitRepositories": { + "description": "FetchLinkableGitRepositories returns a list of git repositories from an SCM that are available to be added to a Connection.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:fetchLinkableGitRepositories", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.connections.fetchLinkableGitRepositories", + "parameterOrder": [ + "connection" + ], + "parameters": { + "connection": { + "description": "Required. The name of the Connection. Format: `projects/*/locations/*/connections/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "Optional. Number of results to return in the list. Defaults to 20.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. Page start.", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+connection}:fetchLinkableGitRepositories", + "response": { + "$ref": "FetchLinkableGitRepositoriesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single Connection.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.connections.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Connection" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists Connections in a given project and location.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.connections.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Optional. Filtering results", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Optional. Hint for how to order the results", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A token identifying a page of results the server should return.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent value for ListConnectionsRequest", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/connections", + "response": { + "$ref": "ListConnectionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates the parameters of a single Connection.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", + "httpMethod": "PATCH", + "id": "developerconnect.projects.locations.connections.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "allowMissing": { + "description": "Optional. If set to true, and the connection is not found a new connection will be created. In this situation `update_mask` is ignored. The creation will succeed only if the input connection has all the necessary information (e.g a github_config with both user_oauth_token and installation_id properties).", + "location": "query", + "type": "boolean" + }, + "name": { + "description": "Identifier. The resource name of the connection, in the format `projects/{project}/locations/{location}/connections/{connection_id}`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "updateMask": { + "description": "Required. Field mask is used to specify the fields to be overwritten in the Connection resource by the update. The fields specified in the update_mask are relative to the resource, not the full request. A field will be overwritten if it is in the mask. If the user does not provide a mask then all fields will be overwritten.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + }, + "validateOnly": { + "description": "Optional. If set, validate the request, but do not actually post it.", + "location": "query", + "type": "boolean" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "Connection" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "processGitHubEnterpriseWebhook": { + "description": "ProcessGitHubEnterpriseWebhook is called by the external GitHub Enterprise instances for notifying events.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections:processGitHubEnterpriseWebhook", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.connections.processGitHubEnterpriseWebhook", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Project and location where the webhook will be received. Format: `projects/*/locations/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/connections:processGitHubEnterpriseWebhook", + "request": { + "$ref": "ProcessGitHubEnterpriseWebhookRequest" + }, + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "processGitLabEnterpriseWebhook": { + "description": "ProcessGitLabEnterpriseWebhook is called by the external GitLab Enterprise instances for notifying events.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections:processGitLabEnterpriseWebhook", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.connections.processGitLabEnterpriseWebhook", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Project and location where the webhook will be received. Format: `projects/*/locations/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/connections:processGitLabEnterpriseWebhook", + "request": { + "$ref": "ProcessGitLabEnterpriseWebhookRequest" + }, + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "processGitLabWebhook": { + "description": "ProcessGitLabWebhook is called by the GitLab.com for notifying events.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections:processGitLabWebhook", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.connections.processGitLabWebhook", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Project and location where the webhook will be received. Format: `projects/*/locations/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/connections:processGitLabWebhook", + "request": { + "$ref": "ProcessGitLabWebhookRequest" + }, + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "gitRepositoryLinks": { + "methods": { + "create": { + "description": "Creates a GitRepositoryLink. Upon linking a Git Repository, Developer Connect will configure the Git Repository to send webhook events to Developer Connect. Connections that use Firebase GitHub Application will have events forwarded to the Firebase service. All other Connections will have events forwarded to Cloud Build.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/gitRepositoryLinks", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.connections.gitRepositoryLinks.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "gitRepositoryLinkId": { + "description": "Required. The ID to use for the repository, which will become the final component of the repository's resource name. This ID should be unique in the connection. Allows alphanumeric characters and any of -._~%!$\u0026'()*+,;=@.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Value for parent.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "validateOnly": { + "description": "Optional. If set, validate the request, but do not actually post it.", + "location": "query", + "type": "boolean" + } + }, + "path": "v1/{+parent}/gitRepositoryLinks", + "request": { + "$ref": "GitRepositoryLink" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a single GitRepositoryLink.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/gitRepositoryLinks/{gitRepositoryLinksId}", + "httpMethod": "DELETE", + "id": "developerconnect.projects.locations.connections.gitRepositoryLinks.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "etag": { + "description": "Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. Name of the resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/gitRepositoryLinks/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "validateOnly": { + "description": "Optional. If set, validate the request, but do not actually post it.", + "location": "query", + "type": "boolean" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "fetchGitRefs": { + "description": "Fetch the list of branches or tags for a given repository.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/gitRepositoryLinks/{gitRepositoryLinksId}:fetchGitRefs", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.connections.gitRepositoryLinks.fetchGitRefs", + "parameterOrder": [ + "gitRepositoryLink" + ], + "parameters": { + "gitRepositoryLink": { + "description": "Required. The resource name of GitRepositoryLink in the format `projects/*/locations/*/connections/*/gitRepositoryLinks/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/gitRepositoryLinks/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "Optional. Number of results to return in the list. Default to 20.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. Page start.", + "location": "query", + "type": "string" + }, + "refType": { + "description": "Required. Type of refs to fetch.", + "enum": [ + "REF_TYPE_UNSPECIFIED", + "TAG", + "BRANCH" + ], + "enumDescriptions": [ + "No type specified.", + "To fetch tags.", + "To fetch branches." + ], + "location": "query", + "type": "string" + } + }, + "path": "v1/{+gitRepositoryLink}:fetchGitRefs", + "response": { + "$ref": "FetchGitRefsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "fetchReadToken": { + "description": "Fetches read token of a given gitRepositoryLink.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/gitRepositoryLinks/{gitRepositoryLinksId}:fetchReadToken", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.connections.gitRepositoryLinks.fetchReadToken", + "parameterOrder": [ + "gitRepositoryLink" + ], + "parameters": { + "gitRepositoryLink": { + "description": "Required. The resource name of the gitRepositoryLink in the format `projects/*/locations/*/connections/*/gitRepositoryLinks/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/gitRepositoryLinks/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+gitRepositoryLink}:fetchReadToken", + "request": { + "$ref": "FetchReadTokenRequest" + }, + "response": { + "$ref": "FetchReadTokenResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "fetchReadWriteToken": { + "description": "Fetches read/write token of a given gitRepositoryLink.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/gitRepositoryLinks/{gitRepositoryLinksId}:fetchReadWriteToken", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.connections.gitRepositoryLinks.fetchReadWriteToken", + "parameterOrder": [ + "gitRepositoryLink" + ], + "parameters": { + "gitRepositoryLink": { + "description": "Required. The resource name of the gitRepositoryLink in the format `projects/*/locations/*/connections/*/gitRepositoryLinks/*`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/gitRepositoryLinks/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+gitRepositoryLink}:fetchReadWriteToken", + "request": { + "$ref": "FetchReadWriteTokenRequest" + }, + "response": { + "$ref": "FetchReadWriteTokenResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single GitRepositoryLink.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/gitRepositoryLinks/{gitRepositoryLinksId}", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.connections.gitRepositoryLinks.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/gitRepositoryLinks/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "GitRepositoryLink" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists GitRepositoryLinks in a given project, location, and connection.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/gitRepositoryLinks", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.connections.gitRepositoryLinks.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Optional. Filtering results", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Optional. Hint for how to order the results", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Optional. Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A token identifying a page of results the server should return.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent value for ListGitRepositoryLinksRequest", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/gitRepositoryLinks", + "response": { + "$ref": "ListGitRepositoryLinksResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "operations": { + "methods": { + "cancel": { + "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", + "httpMethod": "POST", + "id": "developerconnect.projects.locations.operations.cancel", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource to be cancelled.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:cancel", + "request": { + "$ref": "CancelOperationRequest" + }, + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "DELETE", + "id": "developerconnect.projects.locations.operations.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource to be deleted.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations", + "httpMethod": "GET", + "id": "developerconnect.projects.locations.operations.list", + "parameterOrder": [ + "name" + ], + "parameters": { + "filter": { + "description": "The standard list filter.", + "location": "query", + "type": "string" + }, + "name": { + "description": "The name of the operation's parent resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "The standard list page size.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "The standard list page token.", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}/operations", + "response": { + "$ref": "ListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + } + } + } + }, + "revision": "20240515", + "rootUrl": "https://developerconnect.googleapis.com/", + "schemas": { + "CancelOperationRequest": { + "description": "The request message for Operations.CancelOperation.", + "id": "CancelOperationRequest", + "properties": {}, + "type": "object" + }, + "Connection": { + "description": "Message describing Connection object", + "id": "Connection", + "properties": { + "annotations": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Allows clients to store small amounts of arbitrary data.", + "type": "object" + }, + "createTime": { + "description": "Output only. [Output only] Create timestamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "deleteTime": { + "description": "Output only. [Output only] Delete timestamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "disabled": { + "description": "Optional. If disabled is set to true, functionality is disabled for this connection. Repository based API methods and webhooks processing for repositories in this connection will be disabled.", + "type": "boolean" + }, + "etag": { + "description": "Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.", + "type": "string" + }, + "githubConfig": { + "$ref": "GitHubConfig", + "description": "Configuration for connections to github.com." + }, + "installationState": { + "$ref": "InstallationState", + "description": "Output only. Installation state of the Connection.", + "readOnly": true + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels as key value pairs", + "type": "object" + }, + "name": { + "description": "Identifier. The resource name of the connection, in the format `projects/{project}/locations/{location}/connections/{connection_id}`.", + "type": "string" + }, + "reconciling": { + "description": "Output only. Set to true when the connection is being set up or updated in the background.", + "readOnly": true, + "type": "boolean" + }, + "uid": { + "description": "Output only. A system-assigned unique identifier for a the GitRepositoryLink.", + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. [Output only] Update timestamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "Empty": { + "description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }", + "id": "Empty", + "properties": {}, + "type": "object" + }, + "FetchGitHubInstallationsResponse": { + "description": "Response of fetching github installations.", + "id": "FetchGitHubInstallationsResponse", + "properties": { + "installations": { + "description": "List of installations available to the OAuth user (for github.com) or all the installations (for GitHub enterprise).", + "items": { + "$ref": "Installation" + }, + "type": "array" + } + }, + "type": "object" + }, + "FetchGitRefsResponse": { + "description": "Response for fetching git refs.", + "id": "FetchGitRefsResponse", + "properties": { + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + }, + "refNames": { + "description": "Name of the refs fetched.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "FetchLinkableGitRepositoriesResponse": { + "description": "Response message for FetchLinkableGitRepositories.", + "id": "FetchLinkableGitRepositoriesResponse", + "properties": { + "linkableGitRepositories": { + "description": "The git repositories that can be linked to the connection.", + "items": { + "$ref": "LinkableGitRepository" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + } + }, + "type": "object" + }, + "FetchReadTokenRequest": { + "description": "Message for fetching SCM read token.", + "id": "FetchReadTokenRequest", + "properties": {}, + "type": "object" + }, + "FetchReadTokenResponse": { + "description": "Message for responding to get read token.", + "id": "FetchReadTokenResponse", + "properties": { + "expirationTime": { + "description": "Expiration timestamp. Can be empty if unknown or non-expiring.", + "format": "google-datetime", + "type": "string" + }, + "gitUsername": { + "description": "The git_username to specify when making a git clone with the token. For example, for GitHub GitRepositoryLinks, this would be \"x-access-token\"", + "type": "string" + }, + "token": { + "description": "The token content.", + "type": "string" + } + }, + "type": "object" + }, + "FetchReadWriteTokenRequest": { + "description": "Message for fetching SCM read/write token.", + "id": "FetchReadWriteTokenRequest", + "properties": {}, + "type": "object" + }, + "FetchReadWriteTokenResponse": { + "description": "Message for responding to get read/write token.", + "id": "FetchReadWriteTokenResponse", + "properties": { + "expirationTime": { + "description": "Expiration timestamp. Can be empty if unknown or non-expiring.", + "format": "google-datetime", + "type": "string" + }, + "gitUsername": { + "description": "The git_username to specify when making a git clone with the token. For example, for GitHub GitRepositoryLinks, this would be \"x-access-token\"", + "type": "string" + }, + "token": { + "description": "The token content.", + "type": "string" + } + }, + "type": "object" + }, + "GitHubConfig": { + "description": "Configuration for connections to github.com.", + "id": "GitHubConfig", + "properties": { + "appInstallationId": { + "description": "Optional. GitHub App installation id.", + "format": "int64", + "type": "string" + }, + "authorizerCredential": { + "$ref": "OAuthCredential", + "description": "Optional. OAuth credential of the account that authorized the GitHub App. It is recommended to use a robot account instead of a human user account. The OAuth token must be tied to the GitHub App of this config." + }, + "githubApp": { + "description": "Required. Immutable. The GitHub Application that was installed to the GitHub user or organization.", + "enum": [ + "GIT_HUB_APP_UNSPECIFIED", + "DEVELOPER_CONNECT", + "FIREBASE" + ], + "enumDescriptions": [ + "GitHub App not specified.", + "The Developer Connect GitHub Application.", + "The Firebase GitHub Application." + ], + "type": "string" + }, + "installationUri": { + "description": "Output only. The URI to navigate to in order to manage the installation associated with this GitHubConfig.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GitRepositoryLink": { + "description": "Message describing the GitRepositoryLink object", + "id": "GitRepositoryLink", + "properties": { + "annotations": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Allows clients to store small amounts of arbitrary data.", + "type": "object" + }, + "cloneUri": { + "description": "Required. Git Clone URI.", + "type": "string" + }, + "createTime": { + "description": "Output only. [Output only] Create timestamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "deleteTime": { + "description": "Output only. [Output only] Delete timestamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "etag": { + "description": "Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.", + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels as key value pairs", + "type": "object" + }, + "name": { + "description": "Identifier. Resource name of the repository, in the format `projects/*/locations/*/connections/*/gitRepositoryLinks/*`.", + "type": "string" + }, + "reconciling": { + "description": "Output only. Set to true when the connection is being set up or updated in the background.", + "readOnly": true, + "type": "boolean" + }, + "uid": { + "description": "Output only. A system-assigned unique identifier for a the GitRepositoryLink.", + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. [Output only] Update timestamp", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "HttpBody": { + "description": "Message that represents an arbitrary HTTP body. It should only be used for payload formats that can't be represented as JSON, such as raw binary or an HTML page. This message can be used both in streaming and non-streaming API methods in the request as well as the response. It can be used as a top-level request field, which is convenient if one wants to extract parameters from either the URL or HTTP template into the request fields and also want access to the raw HTTP body. Example: message GetResourceRequest { // A unique request id. string request_id = 1; // The raw HTTP body is bound to this field. google.api.HttpBody http_body = 2; } service ResourceService { rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty); } Example with streaming methods: service CaldavService { rpc GetCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); rpc UpdateCalendar(stream google.api.HttpBody) returns (stream google.api.HttpBody); } Use of this type only changes how the request and response bodies are handled, all other features will continue to work unchanged.", + "id": "HttpBody", + "properties": { + "contentType": { + "description": "The HTTP Content-Type header value specifying the content type of the body.", + "type": "string" + }, + "data": { + "description": "The HTTP request/response body as raw binary.", + "format": "byte", + "type": "string" + }, + "extensions": { + "description": "Application specific response metadata. Must be set in the first response for streaming APIs.", + "items": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "type": "object" + }, + "type": "array" + } + }, + "type": "object" + }, + "Installation": { + "description": "Represents an installation of the GitHub App.", + "id": "Installation", + "properties": { + "id": { + "description": "ID of the installation in GitHub.", + "format": "int64", + "type": "string" + }, + "name": { + "description": "Name of the GitHub user or organization that owns this installation.", + "type": "string" + }, + "type": { + "description": "Either \"user\" or \"organization\".", + "type": "string" + } + }, + "type": "object" + }, + "InstallationState": { + "description": "Describes stage and necessary actions to be taken by the user to complete the installation. Used for GitHub and GitHub Enterprise based connections.", + "id": "InstallationState", + "properties": { + "actionUri": { + "description": "Output only. Link to follow for next action. Empty string if the installation is already complete.", + "readOnly": true, + "type": "string" + }, + "message": { + "description": "Output only. Message of what the user should do next to continue the installation. Empty string if the installation is already complete.", + "readOnly": true, + "type": "string" + }, + "stage": { + "description": "Output only. Current step of the installation process.", + "enum": [ + "STAGE_UNSPECIFIED", + "PENDING_CREATE_APP", + "PENDING_USER_OAUTH", + "PENDING_INSTALL_APP", + "COMPLETE" + ], + "enumDescriptions": [ + "No stage specified.", + "Only for GitHub Enterprise. An App creation has been requested. The user needs to confirm the creation in their GitHub enterprise host.", + "User needs to authorize the GitHub (or Enterprise) App via OAuth.", + "User needs to follow the link to install the GitHub (or Enterprise) App.", + "Installation process has been completed." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "LinkableGitRepository": { + "description": "LinkableGitRepository represents a git repository that can be linked to a connection.", + "id": "LinkableGitRepository", + "properties": { + "cloneUri": { + "description": "The clone uri of the repository.", + "type": "string" + } + }, + "type": "object" + }, + "ListConnectionsResponse": { + "description": "Message for response to listing Connections", + "id": "ListConnectionsResponse", + "properties": { + "connections": { + "description": "The list of Connection", + "items": { + "$ref": "Connection" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListGitRepositoryLinksResponse": { + "description": "Message for response to listing GitRepositoryLinks", + "id": "ListGitRepositoryLinksResponse", + "properties": { + "gitRepositoryLinks": { + "description": "The list of GitRepositoryLinks", + "items": { + "$ref": "GitRepositoryLink" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListLocationsResponse": { + "description": "The response message for Locations.ListLocations.", + "id": "ListLocationsResponse", + "properties": { + "locations": { + "description": "A list of locations that matches the specified filter in the request.", + "items": { + "$ref": "Location" + }, + "type": "array" + }, + "nextPageToken": { + "description": "The standard List next-page token.", + "type": "string" + } + }, + "type": "object" + }, + "ListOperationsResponse": { + "description": "The response message for Operations.ListOperations.", + "id": "ListOperationsResponse", + "properties": { + "nextPageToken": { + "description": "The standard List next-page token.", + "type": "string" + }, + "operations": { + "description": "A list of operations that matches the specified filter in the request.", + "items": { + "$ref": "Operation" + }, + "type": "array" + } + }, + "type": "object" + }, + "Location": { + "description": "A resource that represents a Google Cloud location.", + "id": "Location", + "properties": { + "displayName": { + "description": "The friendly name for this location, typically a nearby city name. For example, \"Tokyo\".", + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Cross-service attributes for the location. For example {\"cloud.googleapis.com/region\": \"us-east1\"}", + "type": "object" + }, + "locationId": { + "description": "The canonical id for this location. For example: `\"us-east1\"`.", + "type": "string" + }, + "metadata": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "description": "Service-specific metadata. For example the available capacity at the given location.", + "type": "object" + }, + "name": { + "description": "Resource name for the location, which may vary between implementations. For example: `\"projects/example-project/locations/us-east1\"`", + "type": "string" + } + }, + "type": "object" + }, + "OAuthCredential": { + "description": "Represents an OAuth token of the account that authorized the Connection, and associated metadata.", + "id": "OAuthCredential", + "properties": { + "oauthTokenSecretVersion": { + "description": "Required. A SecretManager resource containing the OAuth token that authorizes the connection. Format: `projects/*/secrets/*/versions/*`.", + "type": "string" + }, + "username": { + "description": "Output only. The username associated with this token.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "Operation": { + "description": "This resource represents a long-running operation that is the result of a network API call.", + "id": "Operation", + "properties": { + "done": { + "description": "If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.", + "type": "boolean" + }, + "error": { + "$ref": "Status", + "description": "The error result of the operation in case of failure or cancellation." + }, + "metadata": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "description": "Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.", + "type": "object" + }, + "name": { + "description": "The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.", + "type": "string" + }, + "response": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "description": "The normal, successful response of the operation. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.", + "type": "object" + } + }, + "type": "object" + }, + "OperationMetadata": { + "description": "Represents the metadata of the long-running operation.", + "id": "OperationMetadata", + "properties": { + "apiVersion": { + "description": "Output only. API version used to start the operation.", + "readOnly": true, + "type": "string" + }, + "createTime": { + "description": "Output only. The time the operation was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "endTime": { + "description": "Output only. The time the operation finished running.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "requestedCancellation": { + "description": "Output only. Identifies whether the user has requested cancellation of the operation. Operations that have been cancelled successfully have Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", + "readOnly": true, + "type": "boolean" + }, + "statusMessage": { + "description": "Output only. Human-readable status of the operation, if any.", + "readOnly": true, + "type": "string" + }, + "target": { + "description": "Output only. Server-defined resource path for the target of the operation.", + "readOnly": true, + "type": "string" + }, + "verb": { + "description": "Output only. Name of the verb executed by the operation.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "ProcessGitHubEnterpriseWebhookRequest": { + "description": "RPC request object accepted by the ProcessGitHubEnterpriseWebhook RPC method.", + "id": "ProcessGitHubEnterpriseWebhookRequest", + "properties": { + "body": { + "$ref": "HttpBody", + "description": "Required. HTTP request body." + }, + "webhookKey": { + "description": "Required. Arbitrary additional key to find the matching repository for a webhook event if needed.", + "type": "string" + } + }, + "type": "object" + }, + "ProcessGitLabEnterpriseWebhookRequest": { + "description": "RPC request object accepted by the ProcessGitLabEnterpriseWebhook RPC method.", + "id": "ProcessGitLabEnterpriseWebhookRequest", + "properties": { + "body": { + "$ref": "HttpBody", + "description": "Required. HTTP request body." + }, + "webhookKey": { + "description": "Required. Arbitrary additional key to find the matching repository for a webhook event if needed.", + "type": "string" + } + }, + "type": "object" + }, + "ProcessGitLabWebhookRequest": { + "description": "RPC request object accepted by the ProcessGitLabWebhook RPC method.", + "id": "ProcessGitLabWebhookRequest", + "properties": { + "body": { + "$ref": "HttpBody", + "description": "Required. HTTP request body." + }, + "webhookKey": { + "description": "Required. Arbitrary additional key to find the matching repository for a webhook event if needed.", + "type": "string" + } + }, + "type": "object" + }, + "Status": { + "description": "The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).", + "id": "Status", + "properties": { + "code": { + "description": "The status code, which should be an enum value of google.rpc.Code.", + "format": "int32", + "type": "integer" + }, + "details": { + "description": "A list of messages that carry the error details. There is a common set of message types for APIs to use.", + "items": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "type": "object" + }, + "type": "array" + }, + "message": { + "description": "A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.", + "type": "string" + } + }, + "type": "object" + } + }, + "servicePath": "", + "title": "Developer Connect API", + "version": "v1", + "version_module": true +} \ No newline at end of file diff --git a/developerconnect/v1/developerconnect-gen.go b/developerconnect/v1/developerconnect-gen.go new file mode 100644 index 00000000000..75ab3e5a57d --- /dev/null +++ b/developerconnect/v1/developerconnect-gen.go @@ -0,0 +1,3886 @@ +// Copyright 2024 Google LLC. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Code generated file. DO NOT EDIT. + +// Package developerconnect provides access to the Developer Connect API. +// +// For product documentation, see: http://cloud.google.com/developer-connect/docs/overview +// +// # Library status +// +// These client libraries are officially supported by Google. However, this +// library is considered complete and is in maintenance mode. This means +// that we will address critical bugs and security issues but will not add +// any new features. +// +// When possible, we recommend using our newer +// [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go) +// that are still actively being worked and iterated on. +// +// # Creating a client +// +// Usage example: +// +// import "google.golang.org/api/developerconnect/v1" +// ... +// ctx := context.Background() +// developerconnectService, err := developerconnect.NewService(ctx) +// +// In this example, Google Application Default Credentials are used for +// authentication. For information on how to create and obtain Application +// Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials. +// +// # Other authentication options +// +// To use an API key for authentication (note: some APIs do not support API +// keys), use [google.golang.org/api/option.WithAPIKey]: +// +// developerconnectService, err := developerconnect.NewService(ctx, option.WithAPIKey("AIza...")) +// +// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth +// flow, use [google.golang.org/api/option.WithTokenSource]: +// +// config := &oauth2.Config{...} +// // ... +// token, err := config.Exchange(ctx, ...) +// developerconnectService, err := developerconnect.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token))) +// +// See [google.golang.org/api/option.ClientOption] for details on options. +package developerconnect // import "google.golang.org/api/developerconnect/v1" + +import ( + "bytes" + "context" + "encoding/json" + "errors" + "fmt" + "io" + "net/http" + "net/url" + "strconv" + "strings" + + googleapi "google.golang.org/api/googleapi" + internal "google.golang.org/api/internal" + gensupport "google.golang.org/api/internal/gensupport" + option "google.golang.org/api/option" + internaloption "google.golang.org/api/option/internaloption" + htransport "google.golang.org/api/transport/http" +) + +// Always reference these packages, just in case the auto-generated code +// below doesn't. +var _ = bytes.NewBuffer +var _ = strconv.Itoa +var _ = fmt.Sprintf +var _ = json.NewDecoder +var _ = io.Copy +var _ = url.Parse +var _ = gensupport.MarshalJSON +var _ = googleapi.Version +var _ = errors.New +var _ = strings.Replace +var _ = context.Canceled +var _ = internaloption.WithDefaultEndpoint +var _ = internal.Version + +const apiId = "developerconnect:v1" +const apiName = "developerconnect" +const apiVersion = "v1" +const basePath = "https://developerconnect.googleapis.com/" +const basePathTemplate = "https://developerconnect.UNIVERSE_DOMAIN/" +const mtlsBasePath = "https://developerconnect.mtls.googleapis.com/" + +// OAuth2 scopes used by this API. +const ( + // See, edit, configure, and delete your Google Cloud data and see the email + // address for your Google Account. + CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" +) + +// NewService creates a new Service. +func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) { + scopesOption := internaloption.WithDefaultScopes( + "https://www.googleapis.com/auth/cloud-platform", + ) + // NOTE: prepend, so we don't override user-specified scopes. + opts = append([]option.ClientOption{scopesOption}, opts...) + opts = append(opts, internaloption.WithDefaultEndpoint(basePath)) + opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate)) + opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath)) + opts = append(opts, internaloption.EnableNewAuthLibrary()) + client, endpoint, err := htransport.NewClient(ctx, opts...) + if err != nil { + return nil, err + } + s, err := New(client) + if err != nil { + return nil, err + } + if endpoint != "" { + s.BasePath = endpoint + } + return s, nil +} + +// New creates a new Service. It uses the provided http.Client for requests. +// +// Deprecated: please use NewService instead. +// To provide a custom HTTP client, use option.WithHTTPClient. +// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. +func New(client *http.Client) (*Service, error) { + if client == nil { + return nil, errors.New("client is nil") + } + s := &Service{client: client, BasePath: basePath} + s.Projects = NewProjectsService(s) + return s, nil +} + +type Service struct { + client *http.Client + BasePath string // API endpoint base URL + UserAgent string // optional additional User-Agent fragment + + Projects *ProjectsService +} + +func (s *Service) userAgent() string { + if s.UserAgent == "" { + return googleapi.UserAgent + } + return googleapi.UserAgent + " " + s.UserAgent +} + +func NewProjectsService(s *Service) *ProjectsService { + rs := &ProjectsService{s: s} + rs.Locations = NewProjectsLocationsService(s) + return rs +} + +type ProjectsService struct { + s *Service + + Locations *ProjectsLocationsService +} + +func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { + rs := &ProjectsLocationsService{s: s} + rs.Connections = NewProjectsLocationsConnectionsService(s) + rs.Operations = NewProjectsLocationsOperationsService(s) + return rs +} + +type ProjectsLocationsService struct { + s *Service + + Connections *ProjectsLocationsConnectionsService + + Operations *ProjectsLocationsOperationsService +} + +func NewProjectsLocationsConnectionsService(s *Service) *ProjectsLocationsConnectionsService { + rs := &ProjectsLocationsConnectionsService{s: s} + rs.GitRepositoryLinks = NewProjectsLocationsConnectionsGitRepositoryLinksService(s) + return rs +} + +type ProjectsLocationsConnectionsService struct { + s *Service + + GitRepositoryLinks *ProjectsLocationsConnectionsGitRepositoryLinksService +} + +func NewProjectsLocationsConnectionsGitRepositoryLinksService(s *Service) *ProjectsLocationsConnectionsGitRepositoryLinksService { + rs := &ProjectsLocationsConnectionsGitRepositoryLinksService{s: s} + return rs +} + +type ProjectsLocationsConnectionsGitRepositoryLinksService struct { + s *Service +} + +func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService { + rs := &ProjectsLocationsOperationsService{s: s} + return rs +} + +type ProjectsLocationsOperationsService struct { + s *Service +} + +// CancelOperationRequest: The request message for Operations.CancelOperation. +type CancelOperationRequest struct { +} + +// Connection: Message describing Connection object +type Connection struct { + // Annotations: Optional. Allows clients to store small amounts of arbitrary + // data. + Annotations map[string]string `json:"annotations,omitempty"` + // CreateTime: Output only. [Output only] Create timestamp + CreateTime string `json:"createTime,omitempty"` + // DeleteTime: Output only. [Output only] Delete timestamp + DeleteTime string `json:"deleteTime,omitempty"` + // Disabled: Optional. If disabled is set to true, functionality is disabled + // for this connection. Repository based API methods and webhooks processing + // for repositories in this connection will be disabled. + Disabled bool `json:"disabled,omitempty"` + // Etag: Optional. This checksum is computed by the server based on the value + // of other fields, and may be sent on update and delete requests to ensure the + // client has an up-to-date value before proceeding. + Etag string `json:"etag,omitempty"` + // GithubConfig: Configuration for connections to github.com. + GithubConfig *GitHubConfig `json:"githubConfig,omitempty"` + // InstallationState: Output only. Installation state of the Connection. + InstallationState *InstallationState `json:"installationState,omitempty"` + // Labels: Optional. Labels as key value pairs + Labels map[string]string `json:"labels,omitempty"` + // Name: Identifier. The resource name of the connection, in the format + // `projects/{project}/locations/{location}/connections/{connection_id}`. + Name string `json:"name,omitempty"` + // Reconciling: Output only. Set to true when the connection is being set up or + // updated in the background. + Reconciling bool `json:"reconciling,omitempty"` + // Uid: Output only. A system-assigned unique identifier for a the + // GitRepositoryLink. + Uid string `json:"uid,omitempty"` + // UpdateTime: Output only. [Output only] Update timestamp + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Annotations") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Annotations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Connection) MarshalJSON() ([]byte, error) { + type NoMethod Connection + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Empty: A generic empty message that you can re-use to avoid defining +// duplicated empty messages in your APIs. A typical example is to use it as +// the request or the response type of an API method. For instance: service Foo +// { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } +type Empty struct { + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` +} + +// FetchGitHubInstallationsResponse: Response of fetching github installations. +type FetchGitHubInstallationsResponse struct { + // Installations: List of installations available to the OAuth user (for + // github.com) or all the installations (for GitHub enterprise). + Installations []*Installation `json:"installations,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Installations") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Installations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *FetchGitHubInstallationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod FetchGitHubInstallationsResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// FetchGitRefsResponse: Response for fetching git refs. +type FetchGitRefsResponse struct { + // NextPageToken: A token identifying a page of results the server should + // return. + NextPageToken string `json:"nextPageToken,omitempty"` + // RefNames: Name of the refs fetched. + RefNames []string `json:"refNames,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *FetchGitRefsResponse) MarshalJSON() ([]byte, error) { + type NoMethod FetchGitRefsResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// FetchLinkableGitRepositoriesResponse: Response message for +// FetchLinkableGitRepositories. +type FetchLinkableGitRepositoriesResponse struct { + // LinkableGitRepositories: The git repositories that can be linked to the + // connection. + LinkableGitRepositories []*LinkableGitRepository `json:"linkableGitRepositories,omitempty"` + // NextPageToken: A token identifying a page of results the server should + // return. + NextPageToken string `json:"nextPageToken,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "LinkableGitRepositories") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "LinkableGitRepositories") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *FetchLinkableGitRepositoriesResponse) MarshalJSON() ([]byte, error) { + type NoMethod FetchLinkableGitRepositoriesResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// FetchReadTokenRequest: Message for fetching SCM read token. +type FetchReadTokenRequest struct { +} + +// FetchReadTokenResponse: Message for responding to get read token. +type FetchReadTokenResponse struct { + // ExpirationTime: Expiration timestamp. Can be empty if unknown or + // non-expiring. + ExpirationTime string `json:"expirationTime,omitempty"` + // GitUsername: The git_username to specify when making a git clone with the + // token. For example, for GitHub GitRepositoryLinks, this would be + // "x-access-token" + GitUsername string `json:"gitUsername,omitempty"` + // Token: The token content. + Token string `json:"token,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "ExpirationTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ExpirationTime") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *FetchReadTokenResponse) MarshalJSON() ([]byte, error) { + type NoMethod FetchReadTokenResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// FetchReadWriteTokenRequest: Message for fetching SCM read/write token. +type FetchReadWriteTokenRequest struct { +} + +// FetchReadWriteTokenResponse: Message for responding to get read/write token. +type FetchReadWriteTokenResponse struct { + // ExpirationTime: Expiration timestamp. Can be empty if unknown or + // non-expiring. + ExpirationTime string `json:"expirationTime,omitempty"` + // GitUsername: The git_username to specify when making a git clone with the + // token. For example, for GitHub GitRepositoryLinks, this would be + // "x-access-token" + GitUsername string `json:"gitUsername,omitempty"` + // Token: The token content. + Token string `json:"token,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "ExpirationTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ExpirationTime") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *FetchReadWriteTokenResponse) MarshalJSON() ([]byte, error) { + type NoMethod FetchReadWriteTokenResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GitHubConfig: Configuration for connections to github.com. +type GitHubConfig struct { + // AppInstallationId: Optional. GitHub App installation id. + AppInstallationId int64 `json:"appInstallationId,omitempty,string"` + // AuthorizerCredential: Optional. OAuth credential of the account that + // authorized the GitHub App. It is recommended to use a robot account instead + // of a human user account. The OAuth token must be tied to the GitHub App of + // this config. + AuthorizerCredential *OAuthCredential `json:"authorizerCredential,omitempty"` + // GithubApp: Required. Immutable. The GitHub Application that was installed to + // the GitHub user or organization. + // + // Possible values: + // "GIT_HUB_APP_UNSPECIFIED" - GitHub App not specified. + // "DEVELOPER_CONNECT" - The Developer Connect GitHub Application. + // "FIREBASE" - The Firebase GitHub Application. + GithubApp string `json:"githubApp,omitempty"` + // InstallationUri: Output only. The URI to navigate to in order to manage the + // installation associated with this GitHubConfig. + InstallationUri string `json:"installationUri,omitempty"` + // ForceSendFields is a list of field names (e.g. "AppInstallationId") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "AppInstallationId") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GitHubConfig) MarshalJSON() ([]byte, error) { + type NoMethod GitHubConfig + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GitRepositoryLink: Message describing the GitRepositoryLink object +type GitRepositoryLink struct { + // Annotations: Optional. Allows clients to store small amounts of arbitrary + // data. + Annotations map[string]string `json:"annotations,omitempty"` + // CloneUri: Required. Git Clone URI. + CloneUri string `json:"cloneUri,omitempty"` + // CreateTime: Output only. [Output only] Create timestamp + CreateTime string `json:"createTime,omitempty"` + // DeleteTime: Output only. [Output only] Delete timestamp + DeleteTime string `json:"deleteTime,omitempty"` + // Etag: Optional. This checksum is computed by the server based on the value + // of other fields, and may be sent on update and delete requests to ensure the + // client has an up-to-date value before proceeding. + Etag string `json:"etag,omitempty"` + // Labels: Optional. Labels as key value pairs + Labels map[string]string `json:"labels,omitempty"` + // Name: Identifier. Resource name of the repository, in the format + // `projects/*/locations/*/connections/*/gitRepositoryLinks/*`. + Name string `json:"name,omitempty"` + // Reconciling: Output only. Set to true when the connection is being set up or + // updated in the background. + Reconciling bool `json:"reconciling,omitempty"` + // Uid: Output only. A system-assigned unique identifier for a the + // GitRepositoryLink. + Uid string `json:"uid,omitempty"` + // UpdateTime: Output only. [Output only] Update timestamp + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Annotations") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Annotations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GitRepositoryLink) MarshalJSON() ([]byte, error) { + type NoMethod GitRepositoryLink + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// HttpBody: Message that represents an arbitrary HTTP body. It should only be +// used for payload formats that can't be represented as JSON, such as raw +// binary or an HTML page. This message can be used both in streaming and +// non-streaming API methods in the request as well as the response. It can be +// used as a top-level request field, which is convenient if one wants to +// extract parameters from either the URL or HTTP template into the request +// fields and also want access to the raw HTTP body. Example: message +// GetResourceRequest { // A unique request id. string request_id = 1; // The +// raw HTTP body is bound to this field. google.api.HttpBody http_body = 2; } +// service ResourceService { rpc GetResource(GetResourceRequest) returns +// (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody) returns +// (google.protobuf.Empty); } Example with streaming methods: service +// CaldavService { rpc GetCalendar(stream google.api.HttpBody) returns (stream +// google.api.HttpBody); rpc UpdateCalendar(stream google.api.HttpBody) returns +// (stream google.api.HttpBody); } Use of this type only changes how the +// request and response bodies are handled, all other features will continue to +// work unchanged. +type HttpBody struct { + // ContentType: The HTTP Content-Type header value specifying the content type + // of the body. + ContentType string `json:"contentType,omitempty"` + // Data: The HTTP request/response body as raw binary. + Data string `json:"data,omitempty"` + // Extensions: Application specific response metadata. Must be set in the first + // response for streaming APIs. + Extensions []googleapi.RawMessage `json:"extensions,omitempty"` + // ForceSendFields is a list of field names (e.g. "ContentType") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ContentType") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *HttpBody) MarshalJSON() ([]byte, error) { + type NoMethod HttpBody + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Installation: Represents an installation of the GitHub App. +type Installation struct { + // Id: ID of the installation in GitHub. + Id int64 `json:"id,omitempty,string"` + // Name: Name of the GitHub user or organization that owns this installation. + Name string `json:"name,omitempty"` + // Type: Either "user" or "organization". + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Id") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Id") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Installation) MarshalJSON() ([]byte, error) { + type NoMethod Installation + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// InstallationState: Describes stage and necessary actions to be taken by the +// user to complete the installation. Used for GitHub and GitHub Enterprise +// based connections. +type InstallationState struct { + // ActionUri: Output only. Link to follow for next action. Empty string if the + // installation is already complete. + ActionUri string `json:"actionUri,omitempty"` + // Message: Output only. Message of what the user should do next to continue + // the installation. Empty string if the installation is already complete. + Message string `json:"message,omitempty"` + // Stage: Output only. Current step of the installation process. + // + // Possible values: + // "STAGE_UNSPECIFIED" - No stage specified. + // "PENDING_CREATE_APP" - Only for GitHub Enterprise. An App creation has + // been requested. The user needs to confirm the creation in their GitHub + // enterprise host. + // "PENDING_USER_OAUTH" - User needs to authorize the GitHub (or Enterprise) + // App via OAuth. + // "PENDING_INSTALL_APP" - User needs to follow the link to install the + // GitHub (or Enterprise) App. + // "COMPLETE" - Installation process has been completed. + Stage string `json:"stage,omitempty"` + // ForceSendFields is a list of field names (e.g. "ActionUri") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ActionUri") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *InstallationState) MarshalJSON() ([]byte, error) { + type NoMethod InstallationState + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// LinkableGitRepository: LinkableGitRepository represents a git repository +// that can be linked to a connection. +type LinkableGitRepository struct { + // CloneUri: The clone uri of the repository. + CloneUri string `json:"cloneUri,omitempty"` + // ForceSendFields is a list of field names (e.g. "CloneUri") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CloneUri") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *LinkableGitRepository) MarshalJSON() ([]byte, error) { + type NoMethod LinkableGitRepository + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// ListConnectionsResponse: Message for response to listing Connections +type ListConnectionsResponse struct { + // Connections: The list of Connection + Connections []*Connection `json:"connections,omitempty"` + // NextPageToken: A token identifying a page of results the server should + // return. + NextPageToken string `json:"nextPageToken,omitempty"` + // Unreachable: Locations that could not be reached. + Unreachable []string `json:"unreachable,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Connections") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Connections") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ListConnectionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListConnectionsResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// ListGitRepositoryLinksResponse: Message for response to listing +// GitRepositoryLinks +type ListGitRepositoryLinksResponse struct { + // GitRepositoryLinks: The list of GitRepositoryLinks + GitRepositoryLinks []*GitRepositoryLink `json:"gitRepositoryLinks,omitempty"` + // NextPageToken: A token identifying a page of results the server should + // return. + NextPageToken string `json:"nextPageToken,omitempty"` + // Unreachable: Locations that could not be reached. + Unreachable []string `json:"unreachable,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "GitRepositoryLinks") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GitRepositoryLinks") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ListGitRepositoryLinksResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListGitRepositoryLinksResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// ListLocationsResponse: The response message for Locations.ListLocations. +type ListLocationsResponse struct { + // Locations: A list of locations that matches the specified filter in the + // request. + Locations []*Location `json:"locations,omitempty"` + // NextPageToken: The standard List next-page token. + NextPageToken string `json:"nextPageToken,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Locations") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Locations") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ListLocationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListLocationsResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// ListOperationsResponse: The response message for Operations.ListOperations. +type ListOperationsResponse struct { + // NextPageToken: The standard List next-page token. + NextPageToken string `json:"nextPageToken,omitempty"` + // Operations: A list of operations that matches the specified filter in the + // request. + Operations []*Operation `json:"operations,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "NextPageToken") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListOperationsResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Location: A resource that represents a Google Cloud location. +type Location struct { + // DisplayName: The friendly name for this location, typically a nearby city + // name. For example, "Tokyo". + DisplayName string `json:"displayName,omitempty"` + // Labels: Cross-service attributes for the location. For example + // {"cloud.googleapis.com/region": "us-east1"} + Labels map[string]string `json:"labels,omitempty"` + // LocationId: The canonical id for this location. For example: "us-east1". + LocationId string `json:"locationId,omitempty"` + // Metadata: Service-specific metadata. For example the available capacity at + // the given location. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + // Name: Resource name for the location, which may vary between + // implementations. For example: + // "projects/example-project/locations/us-east1" + Name string `json:"name,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "DisplayName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DisplayName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Location) MarshalJSON() ([]byte, error) { + type NoMethod Location + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// OAuthCredential: Represents an OAuth token of the account that authorized +// the Connection, and associated metadata. +type OAuthCredential struct { + // OauthTokenSecretVersion: Required. A SecretManager resource containing the + // OAuth token that authorizes the connection. Format: + // `projects/*/secrets/*/versions/*`. + OauthTokenSecretVersion string `json:"oauthTokenSecretVersion,omitempty"` + // Username: Output only. The username associated with this token. + Username string `json:"username,omitempty"` + // ForceSendFields is a list of field names (e.g. "OauthTokenSecretVersion") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "OauthTokenSecretVersion") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *OAuthCredential) MarshalJSON() ([]byte, error) { + type NoMethod OAuthCredential + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Operation: This resource represents a long-running operation that is the +// result of a network API call. +type Operation struct { + // Done: If the value is `false`, it means the operation is still in progress. + // If `true`, the operation is completed, and either `error` or `response` is + // available. + Done bool `json:"done,omitempty"` + // Error: The error result of the operation in case of failure or cancellation. + Error *Status `json:"error,omitempty"` + // Metadata: Service-specific metadata associated with the operation. It + // typically contains progress information and common metadata such as create + // time. Some services might not provide such metadata. Any method that returns + // a long-running operation should document the metadata type, if any. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + // Name: The server-assigned name, which is only unique within the same service + // that originally returns it. If you use the default HTTP mapping, the `name` + // should be a resource name ending with `operations/{unique_id}`. + Name string `json:"name,omitempty"` + // Response: The normal, successful response of the operation. If the original + // method returns no data on success, such as `Delete`, the response is + // `google.protobuf.Empty`. If the original method is standard + // `Get`/`Create`/`Update`, the response should be the resource. For other + // methods, the response should have the type `XxxResponse`, where `Xxx` is the + // original method name. For example, if the original method name is + // `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`. + Response googleapi.RawMessage `json:"response,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Done") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Done") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Operation) MarshalJSON() ([]byte, error) { + type NoMethod Operation + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// OperationMetadata: Represents the metadata of the long-running operation. +type OperationMetadata struct { + // ApiVersion: Output only. API version used to start the operation. + ApiVersion string `json:"apiVersion,omitempty"` + // CreateTime: Output only. The time the operation was created. + CreateTime string `json:"createTime,omitempty"` + // EndTime: Output only. The time the operation finished running. + EndTime string `json:"endTime,omitempty"` + // RequestedCancellation: Output only. Identifies whether the user has + // requested cancellation of the operation. Operations that have been cancelled + // successfully have Operation.error value with a google.rpc.Status.code of 1, + // corresponding to `Code.CANCELLED`. + RequestedCancellation bool `json:"requestedCancellation,omitempty"` + // StatusMessage: Output only. Human-readable status of the operation, if any. + StatusMessage string `json:"statusMessage,omitempty"` + // Target: Output only. Server-defined resource path for the target of the + // operation. + Target string `json:"target,omitempty"` + // Verb: Output only. Name of the verb executed by the operation. + Verb string `json:"verb,omitempty"` + // ForceSendFields is a list of field names (e.g. "ApiVersion") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ApiVersion") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *OperationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod OperationMetadata + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// ProcessGitHubEnterpriseWebhookRequest: RPC request object accepted by the +// ProcessGitHubEnterpriseWebhook RPC method. +type ProcessGitHubEnterpriseWebhookRequest struct { + // Body: Required. HTTP request body. + Body *HttpBody `json:"body,omitempty"` + // WebhookKey: Required. Arbitrary additional key to find the matching + // repository for a webhook event if needed. + WebhookKey string `json:"webhookKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "Body") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Body") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ProcessGitHubEnterpriseWebhookRequest) MarshalJSON() ([]byte, error) { + type NoMethod ProcessGitHubEnterpriseWebhookRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// ProcessGitLabEnterpriseWebhookRequest: RPC request object accepted by the +// ProcessGitLabEnterpriseWebhook RPC method. +type ProcessGitLabEnterpriseWebhookRequest struct { + // Body: Required. HTTP request body. + Body *HttpBody `json:"body,omitempty"` + // WebhookKey: Required. Arbitrary additional key to find the matching + // repository for a webhook event if needed. + WebhookKey string `json:"webhookKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "Body") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Body") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ProcessGitLabEnterpriseWebhookRequest) MarshalJSON() ([]byte, error) { + type NoMethod ProcessGitLabEnterpriseWebhookRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// ProcessGitLabWebhookRequest: RPC request object accepted by the +// ProcessGitLabWebhook RPC method. +type ProcessGitLabWebhookRequest struct { + // Body: Required. HTTP request body. + Body *HttpBody `json:"body,omitempty"` + // WebhookKey: Required. Arbitrary additional key to find the matching + // repository for a webhook event if needed. + WebhookKey string `json:"webhookKey,omitempty"` + // ForceSendFields is a list of field names (e.g. "Body") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Body") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ProcessGitLabWebhookRequest) MarshalJSON() ([]byte, error) { + type NoMethod ProcessGitLabWebhookRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// Status: The `Status` type defines a logical error model that is suitable for +// different programming environments, including REST APIs and RPC APIs. It is +// used by gRPC (https://github.com/grpc). Each `Status` message contains three +// pieces of data: error code, error message, and error details. You can find +// out more about this error model and how to work with it in the API Design +// Guide (https://cloud.google.com/apis/design/errors). +type Status struct { + // Code: The status code, which should be an enum value of google.rpc.Code. + Code int64 `json:"code,omitempty"` + // Details: A list of messages that carry the error details. There is a common + // set of message types for APIs to use. + Details []googleapi.RawMessage `json:"details,omitempty"` + // Message: A developer-facing error message, which should be in English. Any + // user-facing error message should be localized and sent in the + // google.rpc.Status.details field, or localized by the client. + Message string `json:"message,omitempty"` + // ForceSendFields is a list of field names (e.g. "Code") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Code") to include in API requests + // with the JSON null value. By default, fields with empty values are omitted + // from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Status) MarshalJSON() ([]byte, error) { + type NoMethod Status + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +type ProjectsLocationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets information about a location. +// +// - name: Resource name for the location. +func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall { + c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGetCall) Context(ctx context.Context) *ProjectsLocationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *Location.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Location{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists information about the supported locations for this service. +// +// - name: The resource that owns the locations collection, if applicable. +func (r *ProjectsLocationsService) List(name string) *ProjectsLocationsListCall { + c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": A filter to narrow down results +// to a preferred subset. The filtering language accepts strings like +// "displayName=tokyo", and is documented in more detail in AIP-160 +// (https://google.aip.dev/160). +func (c *ProjectsLocationsListCall) Filter(filter string) *ProjectsLocationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number of +// results to return. If not set, the service selects a default. +func (c *ProjectsLocationsListCall) PageSize(pageSize int64) *ProjectsLocationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token received +// from the `next_page_token` field in the response. Send that page token to +// receive the subsequent page. +func (c *ProjectsLocationsListCall) PageToken(pageToken string) *ProjectsLocationsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/locations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListLocationsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &ListLocationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*ListLocationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsConnectionsCreateCall struct { + s *Service + parent string + connection *Connection + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new Connection in a given project and location. +// +// - parent: Value for parent. +func (r *ProjectsLocationsConnectionsService) Create(parent string, connection *Connection) *ProjectsLocationsConnectionsCreateCall { + c := &ProjectsLocationsConnectionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.connection = connection + return c +} + +// ConnectionId sets the optional parameter "connectionId": Required. Id of the +// requesting object If auto-generating Id server-side, remove this field and +// connection_id from the method_signature of Create RPC +func (c *ProjectsLocationsConnectionsCreateCall) ConnectionId(connectionId string) *ProjectsLocationsConnectionsCreateCall { + c.urlParams_.Set("connectionId", connectionId) + return c +} + +// RequestId sets the optional parameter "requestId": An optional request ID to +// identify requests. Specify a unique request ID so that if you must retry +// your request, the server will know to ignore the request if it has already +// been completed. The server will guarantee that for at least 60 minutes since +// the first request. For example, consider a situation where you make an +// initial request and the request times out. If you make the request again +// with the same request ID, the server can check if original operation with +// the same request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate commitments. The +// request ID must be a valid UUID with the exception that zero UUID is not +// supported (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsConnectionsCreateCall) RequestId(requestId string) *ProjectsLocationsConnectionsCreateCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": If set, validate +// the request, but do not actually post it. +func (c *ProjectsLocationsConnectionsCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsConnectionsCreateCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsCreateCall) Context(ctx context.Context) *ProjectsLocationsConnectionsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.connection) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connections") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Operation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single Connection. +// +// - name: Name of the resource. +func (r *ProjectsLocationsConnectionsService) Delete(name string) *ProjectsLocationsConnectionsDeleteCall { + c := &ProjectsLocationsConnectionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Etag sets the optional parameter "etag": The current etag of the Connection. +// If an etag is provided and does not match the current etag of the +// Connection, deletion will be blocked and an ABORTED error will be returned. +func (c *ProjectsLocationsConnectionsDeleteCall) Etag(etag string) *ProjectsLocationsConnectionsDeleteCall { + c.urlParams_.Set("etag", etag) + return c +} + +// RequestId sets the optional parameter "requestId": An optional request ID to +// identify requests. Specify a unique request ID so that if you must retry +// your request, the server will know to ignore the request if it has already +// been completed. The server will guarantee that for at least 60 minutes after +// the first request. For example, consider a situation where you make an +// initial request and the request times out. If you make the request again +// with the same request ID, the server can check if original operation with +// the same request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate commitments. The +// request ID must be a valid UUID with the exception that zero UUID is not +// supported (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsConnectionsDeleteCall) RequestId(requestId string) *ProjectsLocationsConnectionsDeleteCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": If set, validate +// the request, but do not actually post it. +func (c *ProjectsLocationsConnectionsDeleteCall) ValidateOnly(validateOnly bool) *ProjectsLocationsConnectionsDeleteCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsConnectionsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.delete" call. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Operation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsFetchGitHubInstallationsCall struct { + s *Service + connection string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// FetchGitHubInstallations: FetchGitHubInstallations returns the list of +// GitHub Installations that are available to be added to a Connection. For +// github.com, only installations accessible to the authorizer token are +// returned. For GitHub Enterprise, all installations are returned. +// +// - connection: The resource name of the connection in the format +// `projects/*/locations/*/connections/*`. +func (r *ProjectsLocationsConnectionsService) FetchGitHubInstallations(connection string) *ProjectsLocationsConnectionsFetchGitHubInstallationsCall { + c := &ProjectsLocationsConnectionsFetchGitHubInstallationsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.connection = connection + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsFetchGitHubInstallationsCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsFetchGitHubInstallationsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsConnectionsFetchGitHubInstallationsCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsFetchGitHubInstallationsCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsFetchGitHubInstallationsCall) Context(ctx context.Context) *ProjectsLocationsConnectionsFetchGitHubInstallationsCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsFetchGitHubInstallationsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsFetchGitHubInstallationsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+connection}:fetchGitHubInstallations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "connection": c.connection, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.fetchGitHubInstallations" call. +// Any non-2xx status code is an error. Response headers are in either +// *FetchGitHubInstallationsResponse.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsFetchGitHubInstallationsCall) Do(opts ...googleapi.CallOption) (*FetchGitHubInstallationsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &FetchGitHubInstallationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall struct { + s *Service + connection string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// FetchLinkableGitRepositories: FetchLinkableGitRepositories returns a list of +// git repositories from an SCM that are available to be added to a Connection. +// +// - connection: The name of the Connection. Format: +// `projects/*/locations/*/connections/*`. +func (r *ProjectsLocationsConnectionsService) FetchLinkableGitRepositories(connection string) *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall { + c := &ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.connection = connection + return c +} + +// PageSize sets the optional parameter "pageSize": Number of results to return +// in the list. Defaults to 20. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page start. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) PageToken(pageToken string) *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) Context(ctx context.Context) *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+connection}:fetchLinkableGitRepositories") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "connection": c.connection, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.fetchLinkableGitRepositories" call. +// Any non-2xx status code is an error. Response headers are in either +// *FetchLinkableGitRepositoriesResponse.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) Do(opts ...googleapi.CallOption) (*FetchLinkableGitRepositoriesResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &FetchLinkableGitRepositoriesResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsConnectionsFetchLinkableGitRepositoriesCall) Pages(ctx context.Context, f func(*FetchLinkableGitRepositoriesResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsConnectionsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single Connection. +// +// - name: Name of the resource. +func (r *ProjectsLocationsConnectionsService) Get(name string) *ProjectsLocationsConnectionsGetCall { + c := &ProjectsLocationsConnectionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsConnectionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGetCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *Connection.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsGetCall) Do(opts ...googleapi.CallOption) (*Connection, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Connection{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists Connections in a given project and location. +// +// - parent: Parent value for ListConnectionsRequest. +func (r *ProjectsLocationsConnectionsService) List(parent string) *ProjectsLocationsConnectionsListCall { + c := &ProjectsLocationsConnectionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results +func (c *ProjectsLocationsConnectionsListCall) Filter(filter string) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Hint for how to order the +// results +func (c *ProjectsLocationsConnectionsListCall) OrderBy(orderBy string) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Requested page size. Server +// may return fewer items than requested. If unspecified, server will pick an +// appropriate default. +func (c *ProjectsLocationsConnectionsListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A token identifying a +// page of results the server should return. +func (c *ProjectsLocationsConnectionsListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsConnectionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connections") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListConnectionsResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsListCall) Do(opts ...googleapi.CallOption) (*ListConnectionsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &ListConnectionsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsConnectionsListCall) Pages(ctx context.Context, f func(*ListConnectionsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsConnectionsPatchCall struct { + s *Service + name string + connection *Connection + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates the parameters of a single Connection. +// +// - name: Identifier. The resource name of the connection, in the format +// `projects/{project}/locations/{location}/connections/{connection_id}`. +func (r *ProjectsLocationsConnectionsService) Patch(name string, connection *Connection) *ProjectsLocationsConnectionsPatchCall { + c := &ProjectsLocationsConnectionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.connection = connection + return c +} + +// AllowMissing sets the optional parameter "allowMissing": If set to true, and +// the connection is not found a new connection will be created. In this +// situation `update_mask` is ignored. The creation will succeed only if the +// input connection has all the necessary information (e.g a github_config with +// both user_oauth_token and installation_id properties). +func (c *ProjectsLocationsConnectionsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsConnectionsPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) + return c +} + +// RequestId sets the optional parameter "requestId": An optional request ID to +// identify requests. Specify a unique request ID so that if you must retry +// your request, the server will know to ignore the request if it has already +// been completed. The server will guarantee that for at least 60 minutes since +// the first request. For example, consider a situation where you make an +// initial request and the request times out. If you make the request again +// with the same request ID, the server can check if original operation with +// the same request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate commitments. The +// request ID must be a valid UUID with the exception that zero UUID is not +// supported (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsConnectionsPatchCall) RequestId(requestId string) *ProjectsLocationsConnectionsPatchCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. Field mask is +// used to specify the fields to be overwritten in the Connection resource by +// the update. The fields specified in the update_mask are relative to the +// resource, not the full request. A field will be overwritten if it is in the +// mask. If the user does not provide a mask then all fields will be +// overwritten. +func (c *ProjectsLocationsConnectionsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConnectionsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": If set, validate +// the request, but do not actually post it. +func (c *ProjectsLocationsConnectionsPatchCall) ValidateOnly(validateOnly bool) *ProjectsLocationsConnectionsPatchCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsPatchCall) Context(ctx context.Context) *ProjectsLocationsConnectionsPatchCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.connection) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Operation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall struct { + s *Service + parent string + processgithubenterprisewebhookrequest *ProcessGitHubEnterpriseWebhookRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ProcessGitHubEnterpriseWebhook: ProcessGitHubEnterpriseWebhook is called by +// the external GitHub Enterprise instances for notifying events. +// +// - parent: Project and location where the webhook will be received. Format: +// `projects/*/locations/*`. +func (r *ProjectsLocationsConnectionsService) ProcessGitHubEnterpriseWebhook(parent string, processgithubenterprisewebhookrequest *ProcessGitHubEnterpriseWebhookRequest) *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall { + c := &ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.processgithubenterprisewebhookrequest = processgithubenterprisewebhookrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall) Context(ctx context.Context) *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.processgithubenterprisewebhookrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connections:processGitHubEnterpriseWebhook") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.processGitHubEnterpriseWebhook" call. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsProcessGitHubEnterpriseWebhookCall) Do(opts ...googleapi.CallOption) (*Empty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Empty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall struct { + s *Service + parent string + processgitlabenterprisewebhookrequest *ProcessGitLabEnterpriseWebhookRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ProcessGitLabEnterpriseWebhook: ProcessGitLabEnterpriseWebhook is called by +// the external GitLab Enterprise instances for notifying events. +// +// - parent: Project and location where the webhook will be received. Format: +// `projects/*/locations/*`. +func (r *ProjectsLocationsConnectionsService) ProcessGitLabEnterpriseWebhook(parent string, processgitlabenterprisewebhookrequest *ProcessGitLabEnterpriseWebhookRequest) *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall { + c := &ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.processgitlabenterprisewebhookrequest = processgitlabenterprisewebhookrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall) Context(ctx context.Context) *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.processgitlabenterprisewebhookrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connections:processGitLabEnterpriseWebhook") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.processGitLabEnterpriseWebhook" call. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsProcessGitLabEnterpriseWebhookCall) Do(opts ...googleapi.CallOption) (*Empty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Empty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsProcessGitLabWebhookCall struct { + s *Service + parent string + processgitlabwebhookrequest *ProcessGitLabWebhookRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ProcessGitLabWebhook: ProcessGitLabWebhook is called by the GitLab.com for +// notifying events. +// +// - parent: Project and location where the webhook will be received. Format: +// `projects/*/locations/*`. +func (r *ProjectsLocationsConnectionsService) ProcessGitLabWebhook(parent string, processgitlabwebhookrequest *ProcessGitLabWebhookRequest) *ProjectsLocationsConnectionsProcessGitLabWebhookCall { + c := &ProjectsLocationsConnectionsProcessGitLabWebhookCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.processgitlabwebhookrequest = processgitlabwebhookrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsProcessGitLabWebhookCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsProcessGitLabWebhookCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsProcessGitLabWebhookCall) Context(ctx context.Context) *ProjectsLocationsConnectionsProcessGitLabWebhookCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsProcessGitLabWebhookCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsProcessGitLabWebhookCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.processgitlabwebhookrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connections:processGitLabWebhook") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.processGitLabWebhook" call. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsProcessGitLabWebhookCall) Do(opts ...googleapi.CallOption) (*Empty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Empty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsGitRepositoryLinksCreateCall struct { + s *Service + parent string + gitrepositorylink *GitRepositoryLink + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a GitRepositoryLink. Upon linking a Git Repository, +// Developer Connect will configure the Git Repository to send webhook events +// to Developer Connect. Connections that use Firebase GitHub Application will +// have events forwarded to the Firebase service. All other Connections will +// have events forwarded to Cloud Build. +// +// - parent: Value for parent. +func (r *ProjectsLocationsConnectionsGitRepositoryLinksService) Create(parent string, gitrepositorylink *GitRepositoryLink) *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall { + c := &ProjectsLocationsConnectionsGitRepositoryLinksCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.gitrepositorylink = gitrepositorylink + return c +} + +// GitRepositoryLinkId sets the optional parameter "gitRepositoryLinkId": +// Required. The ID to use for the repository, which will become the final +// component of the repository's resource name. This ID should be unique in the +// connection. Allows alphanumeric characters and any of -._~%!$&'()*+,;=@. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) GitRepositoryLinkId(gitRepositoryLinkId string) *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall { + c.urlParams_.Set("gitRepositoryLinkId", gitRepositoryLinkId) + return c +} + +// RequestId sets the optional parameter "requestId": An optional request ID to +// identify requests. Specify a unique request ID so that if you must retry +// your request, the server will know to ignore the request if it has already +// been completed. The server will guarantee that for at least 60 minutes since +// the first request. For example, consider a situation where you make an +// initial request and the request times out. If you make the request again +// with the same request ID, the server can check if original operation with +// the same request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate commitments. The +// request ID must be a valid UUID with the exception that zero UUID is not +// supported (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) RequestId(requestId string) *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": If set, validate +// the request, but do not actually post it. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.gitrepositorylink) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/gitRepositoryLinks") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.gitRepositoryLinks.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Operation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single GitRepositoryLink. +// +// - name: Name of the resource. +func (r *ProjectsLocationsConnectionsGitRepositoryLinksService) Delete(name string) *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall { + c := &ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Etag sets the optional parameter "etag": This checksum is computed by the +// server based on the value of other fields, and may be sent on update and +// delete requests to ensure the client has an up-to-date value before +// proceeding. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) Etag(etag string) *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall { + c.urlParams_.Set("etag", etag) + return c +} + +// RequestId sets the optional parameter "requestId": An optional request ID to +// identify requests. Specify a unique request ID so that if you must retry +// your request, the server will know to ignore the request if it has already +// been completed. The server will guarantee that for at least 60 minutes after +// the first request. For example, consider a situation where you make an +// initial request and the request times out. If you make the request again +// with the same request ID, the server can check if original operation with +// the same request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate commitments. The +// request ID must be a valid UUID with the exception that zero UUID is not +// supported (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) RequestId(requestId string) *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": If set, validate +// the request, but do not actually post it. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) ValidateOnly(validateOnly bool) *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.gitRepositoryLinks.delete" call. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Operation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall struct { + s *Service + gitRepositoryLink string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// FetchGitRefs: Fetch the list of branches or tags for a given repository. +// +// - gitRepositoryLink: The resource name of GitRepositoryLink in the format +// `projects/*/locations/*/connections/*/gitRepositoryLinks/*`. +func (r *ProjectsLocationsConnectionsGitRepositoryLinksService) FetchGitRefs(gitRepositoryLink string) *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall { + c := &ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.gitRepositoryLink = gitRepositoryLink + return c +} + +// PageSize sets the optional parameter "pageSize": Number of results to return +// in the list. Default to 20. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page start. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) PageToken(pageToken string) *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// RefType sets the optional parameter "refType": Required. Type of refs to +// fetch. +// +// Possible values: +// +// "REF_TYPE_UNSPECIFIED" - No type specified. +// "TAG" - To fetch tags. +// "BRANCH" - To fetch branches. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) RefType(refType string) *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall { + c.urlParams_.Set("refType", refType) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+gitRepositoryLink}:fetchGitRefs") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "gitRepositoryLink": c.gitRepositoryLink, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.gitRepositoryLinks.fetchGitRefs" call. +// Any non-2xx status code is an error. Response headers are in either +// *FetchGitRefsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) Do(opts ...googleapi.CallOption) (*FetchGitRefsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &FetchGitRefsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchGitRefsCall) Pages(ctx context.Context, f func(*FetchGitRefsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall struct { + s *Service + gitRepositoryLink string + fetchreadtokenrequest *FetchReadTokenRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// FetchReadToken: Fetches read token of a given gitRepositoryLink. +// +// - gitRepositoryLink: The resource name of the gitRepositoryLink in the +// format `projects/*/locations/*/connections/*/gitRepositoryLinks/*`. +func (r *ProjectsLocationsConnectionsGitRepositoryLinksService) FetchReadToken(gitRepositoryLink string, fetchreadtokenrequest *FetchReadTokenRequest) *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall { + c := &ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.gitRepositoryLink = gitRepositoryLink + c.fetchreadtokenrequest = fetchreadtokenrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.fetchreadtokenrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+gitRepositoryLink}:fetchReadToken") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "gitRepositoryLink": c.gitRepositoryLink, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.gitRepositoryLinks.fetchReadToken" call. +// Any non-2xx status code is an error. Response headers are in either +// *FetchReadTokenResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadTokenCall) Do(opts ...googleapi.CallOption) (*FetchReadTokenResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &FetchReadTokenResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall struct { + s *Service + gitRepositoryLink string + fetchreadwritetokenrequest *FetchReadWriteTokenRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// FetchReadWriteToken: Fetches read/write token of a given gitRepositoryLink. +// +// - gitRepositoryLink: The resource name of the gitRepositoryLink in the +// format `projects/*/locations/*/connections/*/gitRepositoryLinks/*`. +func (r *ProjectsLocationsConnectionsGitRepositoryLinksService) FetchReadWriteToken(gitRepositoryLink string, fetchreadwritetokenrequest *FetchReadWriteTokenRequest) *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall { + c := &ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.gitRepositoryLink = gitRepositoryLink + c.fetchreadwritetokenrequest = fetchreadwritetokenrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.fetchreadwritetokenrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+gitRepositoryLink}:fetchReadWriteToken") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "gitRepositoryLink": c.gitRepositoryLink, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.gitRepositoryLinks.fetchReadWriteToken" call. +// Any non-2xx status code is an error. Response headers are in either +// *FetchReadWriteTokenResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksFetchReadWriteTokenCall) Do(opts ...googleapi.CallOption) (*FetchReadWriteTokenResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &FetchReadWriteTokenResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsGitRepositoryLinksGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single GitRepositoryLink. +// +// - name: Name of the resource. +func (r *ProjectsLocationsConnectionsGitRepositoryLinksService) Get(name string) *ProjectsLocationsConnectionsGitRepositoryLinksGetCall { + c := &ProjectsLocationsConnectionsGitRepositoryLinksGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGitRepositoryLinksGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGitRepositoryLinksGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksGetCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGitRepositoryLinksGetCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGitRepositoryLinksGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.gitRepositoryLinks.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *GitRepositoryLink.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksGetCall) Do(opts ...googleapi.CallOption) (*GitRepositoryLink, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GitRepositoryLink{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsConnectionsGitRepositoryLinksListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists GitRepositoryLinks in a given project, location, and connection. +// +// - parent: Parent value for ListGitRepositoryLinksRequest. +func (r *ProjectsLocationsConnectionsGitRepositoryLinksService) List(parent string) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c := &ProjectsLocationsConnectionsGitRepositoryLinksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) Filter(filter string) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Hint for how to order the +// results +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) OrderBy(orderBy string) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Requested page size. Server +// may return fewer items than requested. If unspecified, server will pick an +// appropriate default. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A token identifying a +// page of results the server should return. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGitRepositoryLinksListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/gitRepositoryLinks") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.connections.gitRepositoryLinks.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListGitRepositoryLinksResponse.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was because +// http.StatusNotModified was returned. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) Do(opts ...googleapi.CallOption) (*ListGitRepositoryLinksResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &ListGitRepositoryLinksResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsConnectionsGitRepositoryLinksListCall) Pages(ctx context.Context, f func(*ListGitRepositoryLinksResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsOperationsCancelCall struct { + s *Service + name string + canceloperationrequest *CancelOperationRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Cancel: Starts asynchronous cancellation on a long-running operation. The +// server makes a best effort to cancel the operation, but success is not +// guaranteed. If the server doesn't support this method, it returns +// `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or +// other methods to check whether the cancellation succeeded or whether the +// operation completed despite cancellation. On successful cancellation, the +// operation is not deleted; instead, it becomes an operation with an +// Operation.error value with a google.rpc.Status.code of 1, corresponding to +// `Code.CANCELLED`. +// +// - name: The name of the operation resource to be cancelled. +func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall { + c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.canceloperationrequest = canceloperationrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.operations.cancel" call. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Empty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsOperationsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a long-running operation. This method indicates that the +// client is no longer interested in the operation result. It does not cancel +// the operation. If the server doesn't support this method, it returns +// `google.rpc.Code.UNIMPLEMENTED`. +// +// - name: The name of the operation resource to be deleted. +func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall { + c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.operations.delete" call. +// Any non-2xx status code is an error. Response headers are in either +// *Empty.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Empty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can use this +// method to poll the operation result at intervals as recommended by the API +// service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall { + c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.operations.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *Operation.ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &Operation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the request. If +// the server doesn't support this method, it returns `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall { + c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list filter. +func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list page +// size. +func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list page +// token. +func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an optional parameter which makes the operation fail if the +// object's ETag matches the given value. This is useful for getting updates +// only after the object has changed since the last request. +func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "developerconnect.projects.locations.operations.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *ListOperationsResponse.ServerResponse.Header or (if a response was returned +// at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &ListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} diff --git a/dlp/v2/dlp-api.json b/dlp/v2/dlp-api.json index 4f4611664d7..a0d9387527a 100644 --- a/dlp/v2/dlp-api.json +++ b/dlp/v2/dlp-api.json @@ -4451,7 +4451,7 @@ } } }, - "revision": "20240512", + "revision": "20240519", "rootUrl": "https://dlp.googleapis.com/", "schemas": { "GooglePrivacyDlpV2Action": { @@ -6667,7 +6667,7 @@ "id": "GooglePrivacyDlpV2DiscoveryCloudSqlGenerationCadence", "properties": { "refreshFrequency": { - "description": "Data changes (non-schema changes) in Cloud SQL tables can't trigger reprofiling. If you set this field, profiles are refreshed at this frequency regardless of whether the underlying tables have changes. Defaults to never.", + "description": "Data changes (non-schema changes) in Cloud SQL tables can't trigger reprofiling. If you set this field, profiles are refreshed at this frequency regardless of whether the underlying tables have changed. Defaults to never.", "enum": [ "UPDATE_FREQUENCY_UNSPECIFIED", "UPDATE_FREQUENCY_NEVER", @@ -9818,7 +9818,7 @@ "type": "object" }, "GooglePrivacyDlpV2SecretsDiscoveryTarget": { - "description": "Discovery target for credentials and secrets in Cloud resource metadata. This target does not include any filtering or frequency controls. Cloud DLP will scan Cloud resource metadata for secrets daily. No inspect template should be included in the discovery config for a security benchmarks scan. Instead, the built-in list of Secrets and Credentials infoTypes will be used (see https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference#credentials_and_secrets). Credentials and secrets discovered will be reported as vulnerabilities to Security Command Center.", + "description": "Discovery target for credentials and secrets in cloud resource metadata. This target does not include any filtering or frequency controls. Cloud DLP will scan cloud resource metadata for secrets daily. No inspect template should be included in the discovery config for a security benchmarks scan. Instead, the built-in list of secrets and credentials infoTypes will be used (see https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference#credentials_and_secrets). Credentials and secrets discovered will be reported as vulnerabilities to Security Command Center.", "id": "GooglePrivacyDlpV2SecretsDiscoveryTarget", "properties": {}, "type": "object" diff --git a/dlp/v2/dlp-gen.go b/dlp/v2/dlp-gen.go index 7f9fdae4e6a..f87c55cdf80 100644 --- a/dlp/v2/dlp-gen.go +++ b/dlp/v2/dlp-gen.go @@ -3777,7 +3777,7 @@ func (s *GooglePrivacyDlpV2DiscoveryCloudSqlFilter) MarshalJSON() ([]byte, error type GooglePrivacyDlpV2DiscoveryCloudSqlGenerationCadence struct { // RefreshFrequency: Data changes (non-schema changes) in Cloud SQL tables // can't trigger reprofiling. If you set this field, profiles are refreshed at - // this frequency regardless of whether the underlying tables have changes. + // this frequency regardless of whether the underlying tables have changed. // Defaults to never. // // Possible values: @@ -8108,11 +8108,11 @@ func (s *GooglePrivacyDlpV2SecretManagerCredential) MarshalJSON() ([]byte, error } // GooglePrivacyDlpV2SecretsDiscoveryTarget: Discovery target for credentials -// and secrets in Cloud resource metadata. This target does not include any -// filtering or frequency controls. Cloud DLP will scan Cloud resource metadata +// and secrets in cloud resource metadata. This target does not include any +// filtering or frequency controls. Cloud DLP will scan cloud resource metadata // for secrets daily. No inspect template should be included in the discovery -// config for a security benchmarks scan. Instead, the built-in list of Secrets -// and Credentials infoTypes will be used (see +// config for a security benchmarks scan. Instead, the built-in list of secrets +// and credentials infoTypes will be used (see // https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference#credentials_and_secrets). // Credentials and secrets discovered will be reported as vulnerabilities to // Security Command Center. diff --git a/firestore/v1/firestore-api.json b/firestore/v1/firestore-api.json index fb708262e8f..94652016217 100644 --- a/firestore/v1/firestore-api.json +++ b/firestore/v1/firestore-api.json @@ -1677,7 +1677,7 @@ } } }, - "revision": "20240512", + "revision": "20240521", "rootUrl": "https://firestore.googleapis.com/", "schemas": { "Aggregation": { @@ -2582,7 +2582,7 @@ "type": "string" }, "deleteTime": { - "description": "Output only. The timestamp at which this database was soft deleted. Only set if the database has been soft deleted.", + "description": "Output only. The timestamp at which this database was deleted. Only set if the database has been deleted.", "format": "google-datetime", "readOnly": true, "type": "string" @@ -2762,7 +2762,7 @@ "id": "GoogleFirestoreAdminV1ExportDocumentsRequest", "properties": { "collectionIds": { - "description": "Which collection ids to export. Unspecified means all collections.", + "description": "Which collection ids to export. Unspecified means all collections. Each collection id in this list must be unique.", "items": { "type": "string" }, @@ -2959,7 +2959,7 @@ "id": "GoogleFirestoreAdminV1ImportDocumentsRequest", "properties": { "collectionIds": { - "description": "Which collection ids to import. Unspecified means all collections included in the import.", + "description": "Which collection ids to import. Unspecified means all collections included in the import. Each collection id in this list must be unique.", "items": { "type": "string" }, diff --git a/firestore/v1/firestore-gen.go b/firestore/v1/firestore-gen.go index 22c8a3a5aee..48f0f29390e 100644 --- a/firestore/v1/firestore-gen.go +++ b/firestore/v1/firestore-gen.go @@ -1606,8 +1606,8 @@ type GoogleFirestoreAdminV1Database struct { // "DELETE_PROTECTION_DISABLED" - Delete protection is disabled // "DELETE_PROTECTION_ENABLED" - Delete protection is enabled DeleteProtectionState string `json:"deleteProtectionState,omitempty"` - // DeleteTime: Output only. The timestamp at which this database was soft - // deleted. Only set if the database has been soft deleted. + // DeleteTime: Output only. The timestamp at which this database was deleted. + // Only set if the database has been deleted. DeleteTime string `json:"deleteTime,omitempty"` // EarliestVersionTime: Output only. The earliest timestamp at which older // versions of the data can be read from the database. See @@ -1784,7 +1784,7 @@ func (s *GoogleFirestoreAdminV1ExportDocumentsMetadata) MarshalJSON() ([]byte, e // FirestoreAdmin.ExportDocuments. type GoogleFirestoreAdminV1ExportDocumentsRequest struct { // CollectionIds: Which collection ids to export. Unspecified means all - // collections. + // collections. Each collection id in this list must be unique. CollectionIds []string `json:"collectionIds,omitempty"` // NamespaceIds: An empty list represents all namespaces. This is the preferred // usage for databases that don't use namespaces. An empty string element @@ -2017,7 +2017,8 @@ func (s *GoogleFirestoreAdminV1ImportDocumentsMetadata) MarshalJSON() ([]byte, e // FirestoreAdmin.ImportDocuments. type GoogleFirestoreAdminV1ImportDocumentsRequest struct { // CollectionIds: Which collection ids to import. Unspecified means all - // collections included in the import. + // collections included in the import. Each collection id in this list must be + // unique. CollectionIds []string `json:"collectionIds,omitempty"` // InputUriPrefix: Location of the exported files. This must match the // output_uri_prefix of an ExportDocumentsResponse from an export that has diff --git a/gkebackup/v1/gkebackup-api.json b/gkebackup/v1/gkebackup-api.json index ca85232d886..4576d933651 100644 --- a/gkebackup/v1/gkebackup-api.json +++ b/gkebackup/v1/gkebackup-api.json @@ -1713,7 +1713,7 @@ } } }, - "revision": "20240410", + "revision": "20240518", "rootUrl": "https://gkebackup.googleapis.com/", "schemas": { "AuditConfig": { @@ -1848,6 +1848,11 @@ "readOnly": true, "type": "string" }, + "permissiveMode": { + "description": "Output only. If false, Backup will fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore. Inherited from the parent BackupPlan's permissive_mode value.", + "readOnly": true, + "type": "boolean" + }, "podCount": { "description": "Output only. The total number of Kubernetes Pods contained in the Backup.", "format": "int32", @@ -1953,6 +1958,10 @@ "description": "Optional. This flag specifies whether volume data should be backed up when PVCs are included in the scope of a Backup. Default: False", "type": "boolean" }, + "permissiveMode": { + "description": "Optional. If false, Backups will fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore. Default: False", + "type": "boolean" + }, "selectedApplications": { "$ref": "NamespacedNames", "description": "If set, include just the resources referenced by the listed ProtectedApplications." @@ -2284,6 +2293,27 @@ }, "type": "object" }, + "Filter": { + "description": "Defines the filter for `Restore`. This filter can be used to further refine the resource selection of the `Restore` beyond the coarse-grained scope defined in the `RestorePlan`. `exclusion_filters` take precedence over `inclusion_filters`. If a resource matches both `inclusion_filters` and `exclusion_filters`, it will not be restored.", + "id": "Filter", + "properties": { + "exclusionFilters": { + "description": "Optional. Excludes resources from restoration. If specified, a resource will not be restored if it matches any `ResourceSelector` of the `exclusion_filters`.", + "items": { + "$ref": "ResourceSelector" + }, + "type": "array" + }, + "inclusionFilters": { + "description": "Optional. Selects resources for restoration. If specified, only resources which match `inclusion_filters` will be selected for restoration. A resource will be selected if it matches any `ResourceSelector` of the `inclusion_filters`.", + "items": { + "$ref": "ResourceSelector" + }, + "type": "array" + } + }, + "type": "object" + }, "GetBackupIndexDownloadUrlResponse": { "description": "Response message for GetBackupIndexDownloadUrl.", "id": "GetBackupIndexDownloadUrlResponse", @@ -2395,6 +2425,21 @@ }, "type": "object" }, + "GroupKindDependency": { + "description": "Defines a dependency between two group kinds.", + "id": "GroupKindDependency", + "properties": { + "requiring": { + "$ref": "GroupKind", + "description": "Required. The requiring group kind requires that the other group kind be restored first." + }, + "satisfying": { + "$ref": "GroupKind", + "description": "Required. The satisfying group kind must be restored first in order to satisfy the dependency." + } + }, + "type": "object" + }, "ListBackupPlansResponse": { "description": "Response message for ListBackupPlans.", "id": "ListBackupPlansResponse", @@ -2719,6 +2764,32 @@ }, "type": "object" }, + "ResourceSelector": { + "description": "Defines a selector to identify a single or a group of resources. Conditions in the selector are optional, but at least one field should be set to a non-empty value. If a condition is not specified, no restrictions will be applied on that dimension. If more than one condition is specified, a resource will be selected if and only if all conditions are met.", + "id": "ResourceSelector", + "properties": { + "groupKind": { + "$ref": "GroupKind", + "description": "Optional. Selects resources using their Kubernetes GroupKinds. If specified, only resources of provided GroupKind will be selected." + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Selects resources using Kubernetes [labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/). If specified, a resource will be selected if and only if the resource has all of the provided labels and all the label values match.", + "type": "object" + }, + "name": { + "description": "Optional. Selects resources using their resource names. If specified, only resources with the provided name will be selected.", + "type": "string" + }, + "namespace": { + "description": "Optional. Selects resources using their namespaces. This only applies to namespace scoped resources and cannot be used for selecting cluster scoped resources. If specified, only resources in the provided namespace will be selected. If not specified, the filter will apply to both cluster scoped and namespace scoped resources (e.g. name or label). The [Namespace](https://pkg.go.dev/k8s.io/api/core/v1#Namespace) resource itself will be restored if and only if any resources within the namespace are restored.", + "type": "string" + } + }, + "type": "object" + }, "Restore": { "description": "Represents both a request to Restore some portion of a Backup into a target GKE cluster and a record of the restore operation itself.", "id": "Restore", @@ -2753,6 +2824,10 @@ "readOnly": true, "type": "string" }, + "filter": { + "$ref": "Filter", + "description": "Optional. Immutable. Filters resources for `Restore`. If not specified, the scope of the restore will remain the same as defined in the `RestorePlan`. If this is specified, and no resources are matched by the `inclusion_filters` or everyting is excluded by the `exclusion_filters`, nothing will be restored. This filter can only be specified if the value of namespaced_resource_restore_mode is set to `MERGE_SKIP_ON_CONFLICT`, `MERGE_REPLACE_VOLUME_ON_CONFLICT` or `MERGE_REPLACE_ON_CONFLICT`." + }, "labels": { "additionalProperties": { "type": "string" @@ -2825,6 +2900,13 @@ "readOnly": true, "type": "string" }, + "volumeDataRestorePolicyOverrides": { + "description": "Optional. Immutable. Overrides the volume data restore policies selected in the Restore Config for override-scoped resources.", + "items": { + "$ref": "VolumeDataRestorePolicyOverride" + }, + "type": "array" + }, "volumesRestoredCount": { "description": "Output only. Number of volumes restored during the restore execution.", "format": "int32", @@ -2869,12 +2951,18 @@ "enum": [ "NAMESPACED_RESOURCE_RESTORE_MODE_UNSPECIFIED", "DELETE_AND_RESTORE", - "FAIL_ON_CONFLICT" + "FAIL_ON_CONFLICT", + "MERGE_SKIP_ON_CONFLICT", + "MERGE_REPLACE_VOLUME_ON_CONFLICT", + "MERGE_REPLACE_ON_CONFLICT" ], "enumDescriptions": [ "Unspecified (invalid).", "When conflicting top-level resources (either Namespaces or ProtectedApplications, depending upon the scope) are encountered, this will first trigger a delete of the conflicting resource AND ALL OF ITS REFERENCED RESOURCES (e.g., all resources in the Namespace or all resources referenced by the ProtectedApplication) before restoring the resources from the Backup. This mode should only be used when you are intending to revert some portion of a cluster to an earlier state.", - "If conflicting top-level resources (either Namespaces or ProtectedApplications, depending upon the scope) are encountered at the beginning of a restore process, the Restore will fail. If a conflict occurs during the restore process itself (e.g., because an out of band process creates conflicting resources), a conflict will be reported." + "If conflicting top-level resources (either Namespaces or ProtectedApplications, depending upon the scope) are encountered at the beginning of a restore process, the Restore will fail. If a conflict occurs during the restore process itself (e.g., because an out of band process creates conflicting resources), a conflict will be reported.", + "This mode merges the backup and the target cluster and skips the conflicting resources. If a single resource to restore exists in the cluster before restoration, the resource will be skipped, otherwise it will be restored.", + "This mode merges the backup and the target cluster and skips the conflicting resources except volume data. If a PVC to restore already exists, this mode will restore/reconnect the volume without overwriting the PVC. It is similar to MERGE_SKIP_ON_CONFLICT except that it will apply the volume data policy for the conflicting PVCs: - RESTORE_VOLUME_DATA_FROM_BACKUP: restore data only and respect the reclaim policy of the original PV; - REUSE_VOLUME_HANDLE_FROM_BACKUP: reconnect and respect the reclaim policy of the original PV; - NO_VOLUME_DATA_RESTORATION: new provision and respect the reclaim policy of the original PV. Note that this mode could cause data loss as the original PV can be retained or deleted depending on its reclaim policy.", + "This mode merges the backup and the target cluster and replaces the conflicting resources with the ones in the backup. If a single resource to restore exists in the cluster before restoration, the resource will be replaced with the one from the backup. To replace an existing resource, the first attempt is to update the resource to match the one from the backup; if the update fails, the second attempt is to delete the resource and restore it from the backup. Note that this mode could cause data loss as it replaces the existing resources in the target cluster, and the original PV can be retained or deleted depending on its reclaim policy." ], "type": "string" }, @@ -2882,6 +2970,10 @@ "description": "Do not restore any namespaced resources if set to \"True\". Specifying this field to \"False\" is not allowed.", "type": "boolean" }, + "restoreOrder": { + "$ref": "RestoreOrder", + "description": "Optional. RestoreOrder contains custom ordering to use on a Restore." + }, "selectedApplications": { "$ref": "NamespacedNames", "description": "A list of selected ProtectedApplications to restore. The listed ProtectedApplications and all the resources to which they refer will be restored." @@ -2919,6 +3011,27 @@ "For each PVC to be restored, create PVC without any particular action to restore data. In this case, the normal Kubernetes provisioning logic would kick in, and this would likely result in either dynamically provisioning blank PVs or binding to statically provisioned PVs." ], "type": "string" + }, + "volumeDataRestorePolicyBindings": { + "description": "Optional. A table that binds volumes by their scope to a restore policy. Bindings must have a unique scope. Any volumes not scoped in the bindings are subject to the policy defined in volume_data_restore_policy.", + "items": { + "$ref": "VolumeDataRestorePolicyBinding" + }, + "type": "array" + } + }, + "type": "object" + }, + "RestoreOrder": { + "description": "Allows customers to specify dependencies between resources that Backup for GKE can use to compute a resasonable restore order.", + "id": "RestoreOrder", + "properties": { + "groupKindDependencies": { + "description": "Optional. Contains a list of group kind dependency pairs provided by the customer, that is used by Backup for GKE to generate a group kind restore order.", + "items": { + "$ref": "GroupKindDependency" + }, + "type": "array" } }, "type": "object" @@ -3339,6 +3452,68 @@ }, "type": "object" }, + "VolumeDataRestorePolicyBinding": { + "description": "Binds resources in the scope to the given VolumeDataRestorePolicy.", + "id": "VolumeDataRestorePolicyBinding", + "properties": { + "policy": { + "description": "Required. The VolumeDataRestorePolicy to apply when restoring volumes in scope.", + "enum": [ + "VOLUME_DATA_RESTORE_POLICY_UNSPECIFIED", + "RESTORE_VOLUME_DATA_FROM_BACKUP", + "REUSE_VOLUME_HANDLE_FROM_BACKUP", + "NO_VOLUME_DATA_RESTORATION" + ], + "enumDescriptions": [ + "Unspecified (illegal).", + "For each PVC to be restored, create a new underlying volume and PV from the corresponding VolumeBackup contained within the Backup.", + "For each PVC to be restored, attempt to reuse the original PV contained in the Backup (with its original underlying volume). This option is likely only usable when restoring a workload to its original cluster.", + "For each PVC to be restored, create PVC without any particular action to restore data. In this case, the normal Kubernetes provisioning logic would kick in, and this would likely result in either dynamically provisioning blank PVs or binding to statically provisioned PVs." + ], + "type": "string" + }, + "volumeType": { + "description": "The volume type, as determined by the PVC's bound PV, to apply the policy to.", + "enum": [ + "VOLUME_TYPE_UNSPECIFIED", + "GCE_PERSISTENT_DISK" + ], + "enumDescriptions": [ + "Default", + "Compute Engine Persistent Disk volume" + ], + "type": "string" + } + }, + "type": "object" + }, + "VolumeDataRestorePolicyOverride": { + "description": "Defines an override to apply a VolumeDataRestorePolicy for scoped resources.", + "id": "VolumeDataRestorePolicyOverride", + "properties": { + "policy": { + "description": "Required. The VolumeDataRestorePolicy to apply when restoring volumes in scope.", + "enum": [ + "VOLUME_DATA_RESTORE_POLICY_UNSPECIFIED", + "RESTORE_VOLUME_DATA_FROM_BACKUP", + "REUSE_VOLUME_HANDLE_FROM_BACKUP", + "NO_VOLUME_DATA_RESTORATION" + ], + "enumDescriptions": [ + "Unspecified (illegal).", + "For each PVC to be restored, create a new underlying volume and PV from the corresponding VolumeBackup contained within the Backup.", + "For each PVC to be restored, attempt to reuse the original PV contained in the Backup (with its original underlying volume). This option is likely only usable when restoring a workload to its original cluster.", + "For each PVC to be restored, create PVC without any particular action to restore data. In this case, the normal Kubernetes provisioning logic would kick in, and this would likely result in either dynamically provisioning blank PVs or binding to statically provisioned PVs." + ], + "type": "string" + }, + "selectedPvcs": { + "$ref": "NamespacedNames", + "description": "A list of PVCs to apply the policy override to." + } + }, + "type": "object" + }, "VolumeRestore": { "description": "Represents the operation of restoring a volume from a VolumeBackup.", "id": "VolumeRestore", diff --git a/gkebackup/v1/gkebackup-gen.go b/gkebackup/v1/gkebackup-gen.go index 1174cda40f4..5edb571bfe2 100644 --- a/gkebackup/v1/gkebackup-gen.go +++ b/gkebackup/v1/gkebackup-gen.go @@ -395,6 +395,11 @@ type Backup struct { // Name: Output only. The fully qualified name of the Backup. // `projects/*/locations/*/backupPlans/*/backups/*` Name string `json:"name,omitempty"` + // PermissiveMode: Output only. If false, Backup will fail when Backup for GKE + // detects Kubernetes configuration that is non-standard or requires additional + // setup to restore. Inherited from the parent BackupPlan's permissive_mode + // value. + PermissiveMode bool `json:"permissiveMode,omitempty"` // PodCount: Output only. The total number of Kubernetes Pods contained in the // Backup. PodCount int64 `json:"podCount,omitempty"` @@ -483,6 +488,10 @@ type BackupConfig struct { // IncludeVolumeData: Optional. This flag specifies whether volume data should // be backed up when PVCs are included in the scope of a Backup. Default: False IncludeVolumeData bool `json:"includeVolumeData,omitempty"` + // PermissiveMode: Optional. If false, Backups will fail when Backup for GKE + // detects Kubernetes configuration that is non-standard or requires additional + // setup to restore. Default: False + PermissiveMode bool `json:"permissiveMode,omitempty"` // SelectedApplications: If set, include just the resources referenced by the // listed ProtectedApplications. SelectedApplications *NamespacedNames `json:"selectedApplications,omitempty"` @@ -974,6 +983,39 @@ func (s *Expr) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// Filter: Defines the filter for `Restore`. This filter can be used to further +// refine the resource selection of the `Restore` beyond the coarse-grained +// scope defined in the `RestorePlan`. `exclusion_filters` take precedence over +// `inclusion_filters`. If a resource matches both `inclusion_filters` and +// `exclusion_filters`, it will not be restored. +type Filter struct { + // ExclusionFilters: Optional. Excludes resources from restoration. If + // specified, a resource will not be restored if it matches any + // `ResourceSelector` of the `exclusion_filters`. + ExclusionFilters []*ResourceSelector `json:"exclusionFilters,omitempty"` + // InclusionFilters: Optional. Selects resources for restoration. If specified, + // only resources which match `inclusion_filters` will be selected for + // restoration. A resource will be selected if it matches any + // `ResourceSelector` of the `inclusion_filters`. + InclusionFilters []*ResourceSelector `json:"inclusionFilters,omitempty"` + // ForceSendFields is a list of field names (e.g. "ExclusionFilters") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ExclusionFilters") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *Filter) MarshalJSON() ([]byte, error) { + type NoMethod Filter + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GetBackupIndexDownloadUrlResponse: Response message for // GetBackupIndexDownloadUrl. type GetBackupIndexDownloadUrlResponse struct { @@ -1144,6 +1186,32 @@ func (s *GroupKind) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GroupKindDependency: Defines a dependency between two group kinds. +type GroupKindDependency struct { + // Requiring: Required. The requiring group kind requires that the other group + // kind be restored first. + Requiring *GroupKind `json:"requiring,omitempty"` + // Satisfying: Required. The satisfying group kind must be restored first in + // order to satisfy the dependency. + Satisfying *GroupKind `json:"satisfying,omitempty"` + // ForceSendFields is a list of field names (e.g. "Requiring") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Requiring") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GroupKindDependency) MarshalJSON() ([]byte, error) { + type NoMethod GroupKindDependency + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // ListBackupPlansResponse: Response message for ListBackupPlans. type ListBackupPlansResponse struct { // BackupPlans: The list of BackupPlans matching the given criteria. @@ -1628,6 +1696,51 @@ func (s *ResourceFilter) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// ResourceSelector: Defines a selector to identify a single or a group of +// resources. Conditions in the selector are optional, but at least one field +// should be set to a non-empty value. If a condition is not specified, no +// restrictions will be applied on that dimension. If more than one condition +// is specified, a resource will be selected if and only if all conditions are +// met. +type ResourceSelector struct { + // GroupKind: Optional. Selects resources using their Kubernetes GroupKinds. If + // specified, only resources of provided GroupKind will be selected. + GroupKind *GroupKind `json:"groupKind,omitempty"` + // Labels: Optional. Selects resources using Kubernetes labels + // (https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/). + // If specified, a resource will be selected if and only if the resource has + // all of the provided labels and all the label values match. + Labels map[string]string `json:"labels,omitempty"` + // Name: Optional. Selects resources using their resource names. If specified, + // only resources with the provided name will be selected. + Name string `json:"name,omitempty"` + // Namespace: Optional. Selects resources using their namespaces. This only + // applies to namespace scoped resources and cannot be used for selecting + // cluster scoped resources. If specified, only resources in the provided + // namespace will be selected. If not specified, the filter will apply to both + // cluster scoped and namespace scoped resources (e.g. name or label). The + // Namespace (https://pkg.go.dev/k8s.io/api/core/v1#Namespace) resource itself + // will be restored if and only if any resources within the namespace are + // restored. + Namespace string `json:"namespace,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroupKind") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GroupKind") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ResourceSelector) MarshalJSON() ([]byte, error) { + type NoMethod ResourceSelector + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // Restore: Represents both a request to Restore some portion of a Backup into // a target GKE cluster and a record of the restore operation itself. type Restore struct { @@ -1658,6 +1771,14 @@ type Restore struct { // `DeleteRestore` to ensure that their change will be applied to the same // version of the resource. Etag string `json:"etag,omitempty"` + // Filter: Optional. Immutable. Filters resources for `Restore`. If not + // specified, the scope of the restore will remain the same as defined in the + // `RestorePlan`. If this is specified, and no resources are matched by the + // `inclusion_filters` or everyting is excluded by the `exclusion_filters`, + // nothing will be restored. This filter can only be specified if the value of + // namespaced_resource_restore_mode is set to `MERGE_SKIP_ON_CONFLICT`, + // `MERGE_REPLACE_VOLUME_ON_CONFLICT` or `MERGE_REPLACE_ON_CONFLICT`. + Filter *Filter `json:"filter,omitempty"` // Labels: A set of custom labels supplied by user. Labels map[string]string `json:"labels,omitempty"` // Name: Output only. The full name of the Restore resource. Format: @@ -1698,6 +1819,10 @@ type Restore struct { // UpdateTime: Output only. The timestamp when this Restore resource was last // updated. UpdateTime string `json:"updateTime,omitempty"` + // VolumeDataRestorePolicyOverrides: Optional. Immutable. Overrides the volume + // data restore policies selected in the Restore Config for override-scoped + // resources. + VolumeDataRestorePolicyOverrides []*VolumeDataRestorePolicyOverride `json:"volumeDataRestorePolicyOverrides,omitempty"` // VolumesRestoredCount: Output only. Number of volumes restored during the // restore execution. VolumesRestoredCount int64 `json:"volumesRestoredCount,omitempty"` @@ -1769,10 +1894,37 @@ type RestoreConfig struct { // beginning of a restore process, the Restore will fail. If a conflict occurs // during the restore process itself (e.g., because an out of band process // creates conflicting resources), a conflict will be reported. + // "MERGE_SKIP_ON_CONFLICT" - This mode merges the backup and the target + // cluster and skips the conflicting resources. If a single resource to restore + // exists in the cluster before restoration, the resource will be skipped, + // otherwise it will be restored. + // "MERGE_REPLACE_VOLUME_ON_CONFLICT" - This mode merges the backup and the + // target cluster and skips the conflicting resources except volume data. If a + // PVC to restore already exists, this mode will restore/reconnect the volume + // without overwriting the PVC. It is similar to MERGE_SKIP_ON_CONFLICT except + // that it will apply the volume data policy for the conflicting PVCs: - + // RESTORE_VOLUME_DATA_FROM_BACKUP: restore data only and respect the reclaim + // policy of the original PV; - REUSE_VOLUME_HANDLE_FROM_BACKUP: reconnect and + // respect the reclaim policy of the original PV; - NO_VOLUME_DATA_RESTORATION: + // new provision and respect the reclaim policy of the original PV. Note that + // this mode could cause data loss as the original PV can be retained or + // deleted depending on its reclaim policy. + // "MERGE_REPLACE_ON_CONFLICT" - This mode merges the backup and the target + // cluster and replaces the conflicting resources with the ones in the backup. + // If a single resource to restore exists in the cluster before restoration, + // the resource will be replaced with the one from the backup. To replace an + // existing resource, the first attempt is to update the resource to match the + // one from the backup; if the update fails, the second attempt is to delete + // the resource and restore it from the backup. Note that this mode could cause + // data loss as it replaces the existing resources in the target cluster, and + // the original PV can be retained or deleted depending on its reclaim policy. NamespacedResourceRestoreMode string `json:"namespacedResourceRestoreMode,omitempty"` // NoNamespaces: Do not restore any namespaced resources if set to "True". // Specifying this field to "False" is not allowed. NoNamespaces bool `json:"noNamespaces,omitempty"` + // RestoreOrder: Optional. RestoreOrder contains custom ordering to use on a + // Restore. + RestoreOrder *RestoreOrder `json:"restoreOrder,omitempty"` // SelectedApplications: A list of selected ProtectedApplications to restore. // The listed ProtectedApplications and all the resources to which they refer // will be restored. @@ -1812,6 +1964,11 @@ type RestoreConfig struct { // either dynamically provisioning blank PVs or binding to statically // provisioned PVs. VolumeDataRestorePolicy string `json:"volumeDataRestorePolicy,omitempty"` + // VolumeDataRestorePolicyBindings: Optional. A table that binds volumes by + // their scope to a restore policy. Bindings must have a unique scope. Any + // volumes not scoped in the bindings are subject to the policy defined in + // volume_data_restore_policy. + VolumeDataRestorePolicyBindings []*VolumeDataRestorePolicyBinding `json:"volumeDataRestorePolicyBindings,omitempty"` // ForceSendFields is a list of field names (e.g. "AllNamespaces") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -1830,6 +1987,31 @@ func (s *RestoreConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// RestoreOrder: Allows customers to specify dependencies between resources +// that Backup for GKE can use to compute a resasonable restore order. +type RestoreOrder struct { + // GroupKindDependencies: Optional. Contains a list of group kind dependency + // pairs provided by the customer, that is used by Backup for GKE to generate a + // group kind restore order. + GroupKindDependencies []*GroupKindDependency `json:"groupKindDependencies,omitempty"` + // ForceSendFields is a list of field names (e.g. "GroupKindDependencies") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GroupKindDependencies") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *RestoreOrder) MarshalJSON() ([]byte, error) { + type NoMethod RestoreOrder + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // RestorePlan: The configuration of a potential series of Restore operations // to be performed against Backups belong to a particular BackupPlan. type RestorePlan struct { @@ -2378,6 +2560,93 @@ func (s *VolumeBackup) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// VolumeDataRestorePolicyBinding: Binds resources in the scope to the given +// VolumeDataRestorePolicy. +type VolumeDataRestorePolicyBinding struct { + // Policy: Required. The VolumeDataRestorePolicy to apply when restoring + // volumes in scope. + // + // Possible values: + // "VOLUME_DATA_RESTORE_POLICY_UNSPECIFIED" - Unspecified (illegal). + // "RESTORE_VOLUME_DATA_FROM_BACKUP" - For each PVC to be restored, create a + // new underlying volume and PV from the corresponding VolumeBackup contained + // within the Backup. + // "REUSE_VOLUME_HANDLE_FROM_BACKUP" - For each PVC to be restored, attempt + // to reuse the original PV contained in the Backup (with its original + // underlying volume). This option is likely only usable when restoring a + // workload to its original cluster. + // "NO_VOLUME_DATA_RESTORATION" - For each PVC to be restored, create PVC + // without any particular action to restore data. In this case, the normal + // Kubernetes provisioning logic would kick in, and this would likely result in + // either dynamically provisioning blank PVs or binding to statically + // provisioned PVs. + Policy string `json:"policy,omitempty"` + // VolumeType: The volume type, as determined by the PVC's bound PV, to apply + // the policy to. + // + // Possible values: + // "VOLUME_TYPE_UNSPECIFIED" - Default + // "GCE_PERSISTENT_DISK" - Compute Engine Persistent Disk volume + VolumeType string `json:"volumeType,omitempty"` + // ForceSendFields is a list of field names (e.g. "Policy") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Policy") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *VolumeDataRestorePolicyBinding) MarshalJSON() ([]byte, error) { + type NoMethod VolumeDataRestorePolicyBinding + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// VolumeDataRestorePolicyOverride: Defines an override to apply a +// VolumeDataRestorePolicy for scoped resources. +type VolumeDataRestorePolicyOverride struct { + // Policy: Required. The VolumeDataRestorePolicy to apply when restoring + // volumes in scope. + // + // Possible values: + // "VOLUME_DATA_RESTORE_POLICY_UNSPECIFIED" - Unspecified (illegal). + // "RESTORE_VOLUME_DATA_FROM_BACKUP" - For each PVC to be restored, create a + // new underlying volume and PV from the corresponding VolumeBackup contained + // within the Backup. + // "REUSE_VOLUME_HANDLE_FROM_BACKUP" - For each PVC to be restored, attempt + // to reuse the original PV contained in the Backup (with its original + // underlying volume). This option is likely only usable when restoring a + // workload to its original cluster. + // "NO_VOLUME_DATA_RESTORATION" - For each PVC to be restored, create PVC + // without any particular action to restore data. In this case, the normal + // Kubernetes provisioning logic would kick in, and this would likely result in + // either dynamically provisioning blank PVs or binding to statically + // provisioned PVs. + Policy string `json:"policy,omitempty"` + // SelectedPvcs: A list of PVCs to apply the policy override to. + SelectedPvcs *NamespacedNames `json:"selectedPvcs,omitempty"` + // ForceSendFields is a list of field names (e.g. "Policy") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Policy") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *VolumeDataRestorePolicyOverride) MarshalJSON() ([]byte, error) { + type NoMethod VolumeDataRestorePolicyOverride + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // VolumeRestore: Represents the operation of restoring a volume from a // VolumeBackup. type VolumeRestore struct { diff --git a/migrationcenter/v1/migrationcenter-api.json b/migrationcenter/v1/migrationcenter-api.json index ab7b4254cbb..47bb08eaa58 100644 --- a/migrationcenter/v1/migrationcenter-api.json +++ b/migrationcenter/v1/migrationcenter-api.json @@ -2309,7 +2309,7 @@ } } }, - "revision": "20240502", + "revision": "20240516", "rootUrl": "https://migrationcenter.googleapis.com/", "schemas": { "AddAssetsToGroupRequest": { @@ -2666,7 +2666,7 @@ "id": "AssetPerformanceData", "properties": { "dailyResourceUsageAggregations": { - "description": "Daily resource usage aggregations. Contains all of the data available for an asset, up to the last 40 days. Aggregations are sorted from oldest to most recent.", + "description": "Daily resource usage aggregations. Contains all of the data available for an asset, up to the last 420 days. Aggregations are sorted from oldest to most recent.", "items": { "$ref": "DailyResourceUsageAggregation" }, diff --git a/migrationcenter/v1/migrationcenter-gen.go b/migrationcenter/v1/migrationcenter-gen.go index 3890eef89bf..b4abd26d0ae 100644 --- a/migrationcenter/v1/migrationcenter-gen.go +++ b/migrationcenter/v1/migrationcenter-gen.go @@ -778,8 +778,8 @@ func (s *AssetList) MarshalJSON() ([]byte, error) { // AssetPerformanceData: Performance data for an asset. type AssetPerformanceData struct { // DailyResourceUsageAggregations: Daily resource usage aggregations. Contains - // all of the data available for an asset, up to the last 40 days. Aggregations - // are sorted from oldest to most recent. + // all of the data available for an asset, up to the last 420 days. + // Aggregations are sorted from oldest to most recent. DailyResourceUsageAggregations []*DailyResourceUsageAggregation `json:"dailyResourceUsageAggregations,omitempty"` // ForceSendFields is a list of field names (e.g. // "DailyResourceUsageAggregations") to unconditionally include in API diff --git a/migrationcenter/v1alpha1/migrationcenter-api.json b/migrationcenter/v1alpha1/migrationcenter-api.json index 2ca8274f3c9..873a98c5d56 100644 --- a/migrationcenter/v1alpha1/migrationcenter-api.json +++ b/migrationcenter/v1alpha1/migrationcenter-api.json @@ -2317,7 +2317,7 @@ } } }, - "revision": "20240509", + "revision": "20240516", "rootUrl": "https://migrationcenter.googleapis.com/", "schemas": { "AddAssetsToGroupRequest": { @@ -2715,7 +2715,7 @@ "id": "AssetPerformanceData", "properties": { "dailyResourceUsageAggregations": { - "description": "Daily resource usage aggregations. Contains all of the data available for an asset, up to the last 40 days. Aggregations are sorted from oldest to most recent.", + "description": "Daily resource usage aggregations. Contains all of the data available for an asset, up to the last 420 days. Aggregations are sorted from oldest to most recent.", "items": { "$ref": "DailyResourceUsageAggregation" }, diff --git a/migrationcenter/v1alpha1/migrationcenter-gen.go b/migrationcenter/v1alpha1/migrationcenter-gen.go index a2947da1d30..6751f8b242a 100644 --- a/migrationcenter/v1alpha1/migrationcenter-gen.go +++ b/migrationcenter/v1alpha1/migrationcenter-gen.go @@ -800,8 +800,8 @@ func (s *AssetList) MarshalJSON() ([]byte, error) { // AssetPerformanceData: Performance data for an asset. type AssetPerformanceData struct { // DailyResourceUsageAggregations: Daily resource usage aggregations. Contains - // all of the data available for an asset, up to the last 40 days. Aggregations - // are sorted from oldest to most recent. + // all of the data available for an asset, up to the last 420 days. + // Aggregations are sorted from oldest to most recent. DailyResourceUsageAggregations []*DailyResourceUsageAggregation `json:"dailyResourceUsageAggregations,omitempty"` // ForceSendFields is a list of field names (e.g. // "DailyResourceUsageAggregations") to unconditionally include in API diff --git a/networkmanagement/v1/networkmanagement-api.json b/networkmanagement/v1/networkmanagement-api.json index 147ced24ab7..787a1aaba96 100644 --- a/networkmanagement/v1/networkmanagement-api.json +++ b/networkmanagement/v1/networkmanagement-api.json @@ -591,7 +591,7 @@ } } }, - "revision": "20240424", + "revision": "20240515", "rootUrl": "https://networkmanagement.googleapis.com/", "schemas": { "AbortInfo": { @@ -1015,10 +1015,18 @@ "description": "IP address of the target (if applicable).", "type": "string" }, + "pscGoogleApiTarget": { + "description": "PSC Google API target the packet is delivered to (if applicable).", + "type": "string" + }, "resourceUri": { "description": "URI of the resource that the packet is delivered to.", "type": "string" }, + "storageBucket": { + "description": "Name of the Cloud Storage Bucket the packet is delivered to (if applicable).", + "type": "string" + }, "target": { "description": "Target type where the packet is delivered to.", "enum": [ @@ -1036,7 +1044,8 @@ "PRIVATE_NETWORK", "CLOUD_FUNCTION", "APP_ENGINE_VERSION", - "CLOUD_RUN_REVISION" + "CLOUD_RUN_REVISION", + "GOOGLE_MANAGED_SERVICE" ], "enumDescriptions": [ "Target not specified.", @@ -1046,14 +1055,15 @@ "Target is a Google Kubernetes Engine cluster master.", "Target is a Cloud SQL instance.", "Target is a published service that uses [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-services).", - "Target is all Google APIs that use [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).", + "Target is Google APIs that use [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).", "Target is a VPC-SC that uses [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).", "Target is a serverless network endpoint group.", "Target is a Cloud Storage bucket.", "Target is a private network. Used only for return traces.", "Target is a Cloud Function. Used only for return traces.", "Target is a App Engine service version. Used only for return traces.", - "Target is a Cloud Run revision. Used only for return traces." + "Target is a Cloud Run revision. Used only for return traces.", + "Target is a Google-managed service. Used only for return traces." ], "type": "string" } @@ -1128,7 +1138,8 @@ "DROPPED_INSIDE_PSC_SERVICE_PRODUCER", "LOAD_BALANCER_HAS_NO_PROXY_SUBNET", "CLOUD_NAT_NO_ADDRESSES", - "ROUTING_LOOP" + "ROUTING_LOOP", + "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE" ], "enumDescriptions": [ "Cause is unspecified.", @@ -1192,7 +1203,8 @@ "Packet was dropped inside Private Service Connect service producer.", "Packet sent to a load balancer, which requires a proxy-only subnet and the subnet is not found.", "Packet sent to Cloud Nat without active NAT IPs.", - "Packet is stuck in a routing loop." + "Packet is stuck in a routing loop.", + "Packet is dropped due to an unspecified reason inside a Google-managed service. Used only for return traces." ], "type": "string" }, @@ -1553,19 +1565,35 @@ "id": "ForwardingRuleInfo", "properties": { "displayName": { - "description": "Name of a Compute Engine forwarding rule.", + "description": "Name of the forwarding rule.", + "type": "string" + }, + "loadBalancerName": { + "description": "Name of the load balancer the forwarding rule belongs to. Empty for forwarding rules not related to load balancers (like PSC forwarding rules).", "type": "string" }, "matchedPortRange": { - "description": "Port range defined in the forwarding rule that matches the test.", + "description": "Port range defined in the forwarding rule that matches the packet.", "type": "string" }, "matchedProtocol": { - "description": "Protocol defined in the forwarding rule that matches the test.", + "description": "Protocol defined in the forwarding rule that matches the packet.", "type": "string" }, "networkUri": { - "description": "Network URI. Only valid for Internal Load Balancer.", + "description": "Network URI.", + "type": "string" + }, + "pscGoogleApiTarget": { + "description": "PSC Google API target this forwarding rule targets (if applicable).", + "type": "string" + }, + "pscServiceAttachmentUri": { + "description": "URI of the PSC service attachment this forwarding rule targets (if applicable).", + "type": "string" + }, + "region": { + "description": "Region of the forwarding rule. Set only for regional forwarding rules.", "type": "string" }, "target": { @@ -1573,7 +1601,7 @@ "type": "string" }, "uri": { - "description": "URI of a Compute Engine forwarding rule.", + "description": "URI of the forwarding rule.", "type": "string" }, "vip": { @@ -2487,6 +2515,17 @@ }, "type": "object" }, + "ServerlessNegInfo": { + "description": "For display only. Metadata associated with the serverless network endpoint group backend.", + "id": "ServerlessNegInfo", + "properties": { + "negUri": { + "description": "URI of the serverless network endpoint group.", + "type": "string" + } + }, + "type": "object" + }, "SetIamPolicyRequest": { "description": "Request message for `SetIamPolicy` method.", "id": "SetIamPolicyRequest", @@ -2627,6 +2666,10 @@ "$ref": "RouteInfo", "description": "Display information of a Compute Engine route." }, + "serverlessNeg": { + "$ref": "ServerlessNegInfo", + "description": "Display information of a Serverless network endpoint group backend. Used only for return traces." + }, "state": { "description": "Each step is in one of the pre-defined states.", "enum": [ @@ -2642,6 +2685,7 @@ "START_FROM_CLOUD_RUN_REVISION", "START_FROM_STORAGE_BUCKET", "START_FROM_PSC_PUBLISHED_SERVICE", + "START_FROM_SERVERLESS_NEG", "APPLY_INGRESS_FIREWALL_RULE", "APPLY_EGRESS_FIREWALL_RULE", "APPLY_ROUTE", @@ -2682,6 +2726,7 @@ false, false, false, + false, true, true, false, @@ -2708,6 +2753,7 @@ "Initial state: packet originating from a Cloud Run revision. A CloudRunRevisionInfo is populated with starting revision information.", "Initial state: packet originating from a Storage Bucket. Used only for return traces. The storage_bucket information is populated.", "Initial state: packet originating from a published service that uses Private Service Connect. Used only for return traces.", + "Initial state: packet originating from a serverless network endpoint group backend. Used only for return traces. The serverless_neg information is populated.", "Config checking state: verify ingress firewall rule.", "Config checking state: verify egress firewall rule.", "Config checking state: verify route.", diff --git a/networkmanagement/v1/networkmanagement-gen.go b/networkmanagement/v1/networkmanagement-gen.go index f7978143286..08057fdbd79 100644 --- a/networkmanagement/v1/networkmanagement-gen.go +++ b/networkmanagement/v1/networkmanagement-gen.go @@ -773,8 +773,14 @@ func (s *ConnectivityTest) MarshalJSON() ([]byte, error) { type DeliverInfo struct { // IpAddress: IP address of the target (if applicable). IpAddress string `json:"ipAddress,omitempty"` + // PscGoogleApiTarget: PSC Google API target the packet is delivered to (if + // applicable). + PscGoogleApiTarget string `json:"pscGoogleApiTarget,omitempty"` // ResourceUri: URI of the resource that the packet is delivered to. ResourceUri string `json:"resourceUri,omitempty"` + // StorageBucket: Name of the Cloud Storage Bucket the packet is delivered to + // (if applicable). + StorageBucket string `json:"storageBucket,omitempty"` // Target: Target type where the packet is delivered to. // // Possible values: @@ -788,7 +794,7 @@ type DeliverInfo struct { // Service // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect- // services). - // "PSC_GOOGLE_API" - Target is all Google APIs that use [Private Service + // "PSC_GOOGLE_API" - Target is Google APIs that use [Private Service // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect- // apis). // "PSC_VPC_SC" - Target is a VPC-SC that uses [Private Service @@ -804,6 +810,8 @@ type DeliverInfo struct { // for return traces. // "CLOUD_RUN_REVISION" - Target is a Cloud Run revision. Used only for // return traces. + // "GOOGLE_MANAGED_SERVICE" - Target is a Google-managed service. Used only + // for return traces. Target string `json:"target,omitempty"` // ForceSendFields is a list of field names (e.g. "IpAddress") to // unconditionally include in API requests. By default, fields with empty or @@ -983,6 +991,9 @@ type DropInfo struct { // "CLOUD_NAT_NO_ADDRESSES" - Packet sent to Cloud Nat without active NAT // IPs. // "ROUTING_LOOP" - Packet is stuck in a routing loop. + // "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE" - Packet is dropped due to an + // unspecified reason inside a Google-managed service. Used only for return + // traces. Cause string `json:"cause,omitempty"` // DestinationIp: Destination IP address of the dropped packet (if relevant). DestinationIp string `json:"destinationIp,omitempty"` @@ -1358,19 +1369,32 @@ func (s *ForwardInfo) MarshalJSON() ([]byte, error) { // ForwardingRuleInfo: For display only. Metadata associated with a Compute // Engine forwarding rule. type ForwardingRuleInfo struct { - // DisplayName: Name of a Compute Engine forwarding rule. + // DisplayName: Name of the forwarding rule. DisplayName string `json:"displayName,omitempty"` + // LoadBalancerName: Name of the load balancer the forwarding rule belongs to. + // Empty for forwarding rules not related to load balancers (like PSC + // forwarding rules). + LoadBalancerName string `json:"loadBalancerName,omitempty"` // MatchedPortRange: Port range defined in the forwarding rule that matches the - // test. + // packet. MatchedPortRange string `json:"matchedPortRange,omitempty"` // MatchedProtocol: Protocol defined in the forwarding rule that matches the - // test. + // packet. MatchedProtocol string `json:"matchedProtocol,omitempty"` - // NetworkUri: Network URI. Only valid for Internal Load Balancer. + // NetworkUri: Network URI. NetworkUri string `json:"networkUri,omitempty"` + // PscGoogleApiTarget: PSC Google API target this forwarding rule targets (if + // applicable). + PscGoogleApiTarget string `json:"pscGoogleApiTarget,omitempty"` + // PscServiceAttachmentUri: URI of the PSC service attachment this forwarding + // rule targets (if applicable). + PscServiceAttachmentUri string `json:"pscServiceAttachmentUri,omitempty"` + // Region: Region of the forwarding rule. Set only for regional forwarding + // rules. + Region string `json:"region,omitempty"` // Target: Target type of the forwarding rule. Target string `json:"target,omitempty"` - // Uri: URI of a Compute Engine forwarding rule. + // Uri: URI of the forwarding rule. Uri string `json:"uri,omitempty"` // Vip: VIP of the forwarding rule. Vip string `json:"vip,omitempty"` @@ -2363,6 +2387,29 @@ func (s *RouteInfo) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// ServerlessNegInfo: For display only. Metadata associated with the serverless +// network endpoint group backend. +type ServerlessNegInfo struct { + // NegUri: URI of the serverless network endpoint group. + NegUri string `json:"negUri,omitempty"` + // ForceSendFields is a list of field names (e.g. "NegUri") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "NegUri") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ServerlessNegInfo) MarshalJSON() ([]byte, error) { + type NoMethod ServerlessNegInfo + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // SetIamPolicyRequest: Request message for `SetIamPolicy` method. type SetIamPolicyRequest struct { // Policy: REQUIRED: The complete policy to be applied to the `resource`. The @@ -2482,6 +2529,9 @@ type Step struct { ProxyConnection *ProxyConnectionInfo `json:"proxyConnection,omitempty"` // Route: Display information of a Compute Engine route. Route *RouteInfo `json:"route,omitempty"` + // ServerlessNeg: Display information of a Serverless network endpoint group + // backend. Used only for return traces. + ServerlessNeg *ServerlessNegInfo `json:"serverlessNeg,omitempty"` // State: Each step is in one of the pre-defined states. // // Possible values: @@ -2518,6 +2568,9 @@ type Step struct { // "START_FROM_PSC_PUBLISHED_SERVICE" - Initial state: packet originating // from a published service that uses Private Service Connect. Used only for // return traces. + // "START_FROM_SERVERLESS_NEG" - Initial state: packet originating from a + // serverless network endpoint group backend. Used only for return traces. The + // serverless_neg information is populated. // "APPLY_INGRESS_FIREWALL_RULE" - Config checking state: verify ingress // firewall rule. // "APPLY_EGRESS_FIREWALL_RULE" - Config checking state: verify egress diff --git a/networkmanagement/v1beta1/networkmanagement-api.json b/networkmanagement/v1beta1/networkmanagement-api.json index a75a21b7c3a..8b60a461c33 100644 --- a/networkmanagement/v1beta1/networkmanagement-api.json +++ b/networkmanagement/v1beta1/networkmanagement-api.json @@ -591,7 +591,7 @@ } } }, - "revision": "20240501", + "revision": "20240515", "rootUrl": "https://networkmanagement.googleapis.com/", "schemas": { "AbortInfo": { @@ -1015,10 +1015,18 @@ "description": "IP address of the target (if applicable).", "type": "string" }, + "pscGoogleApiTarget": { + "description": "PSC Google API target the packet is delivered to (if applicable).", + "type": "string" + }, "resourceUri": { "description": "URI of the resource that the packet is delivered to.", "type": "string" }, + "storageBucket": { + "description": "Name of the Cloud Storage Bucket the packet is delivered to (if applicable).", + "type": "string" + }, "target": { "description": "Target type where the packet is delivered to.", "enum": [ @@ -1036,7 +1044,8 @@ "PRIVATE_NETWORK", "CLOUD_FUNCTION", "APP_ENGINE_VERSION", - "CLOUD_RUN_REVISION" + "CLOUD_RUN_REVISION", + "GOOGLE_MANAGED_SERVICE" ], "enumDescriptions": [ "Target not specified.", @@ -1046,14 +1055,15 @@ "Target is a Google Kubernetes Engine cluster master.", "Target is a Cloud SQL instance.", "Target is a published service that uses [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-services).", - "Target is all Google APIs that use [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).", + "Target is Google APIs that use [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).", "Target is a VPC-SC that uses [Private Service Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect-apis).", "Target is a serverless network endpoint group.", "Target is a Cloud Storage bucket.", "Target is a private network. Used only for return traces.", "Target is a Cloud Function. Used only for return traces.", "Target is a App Engine service version. Used only for return traces.", - "Target is a Cloud Run revision. Used only for return traces." + "Target is a Cloud Run revision. Used only for return traces.", + "Target is a Google-managed service. Used only for return traces." ], "type": "string" } @@ -1128,7 +1138,8 @@ "DROPPED_INSIDE_PSC_SERVICE_PRODUCER", "LOAD_BALANCER_HAS_NO_PROXY_SUBNET", "CLOUD_NAT_NO_ADDRESSES", - "ROUTING_LOOP" + "ROUTING_LOOP", + "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE" ], "enumDescriptions": [ "Cause is unspecified.", @@ -1192,7 +1203,8 @@ "Packet was dropped inside Private Service Connect service producer.", "Packet sent to a load balancer, which requires a proxy-only subnet and the subnet is not found.", "Packet sent to Cloud Nat without active NAT IPs.", - "Packet is stuck in a routing loop." + "Packet is stuck in a routing loop.", + "Packet is dropped due to an unspecified reason inside a Google-managed service. Used only for return traces." ], "type": "string" }, @@ -1553,19 +1565,35 @@ "id": "ForwardingRuleInfo", "properties": { "displayName": { - "description": "Name of a Compute Engine forwarding rule.", + "description": "Name of the forwarding rule.", + "type": "string" + }, + "loadBalancerName": { + "description": "Name of the load balancer the forwarding rule belongs to. Empty for forwarding rules not related to load balancers (like PSC forwarding rules).", "type": "string" }, "matchedPortRange": { - "description": "Port range defined in the forwarding rule that matches the test.", + "description": "Port range defined in the forwarding rule that matches the packet.", "type": "string" }, "matchedProtocol": { - "description": "Protocol defined in the forwarding rule that matches the test.", + "description": "Protocol defined in the forwarding rule that matches the packet.", "type": "string" }, "networkUri": { - "description": "Network URI. Only valid for Internal Load Balancer.", + "description": "Network URI.", + "type": "string" + }, + "pscGoogleApiTarget": { + "description": "PSC Google API target this forwarding rule targets (if applicable).", + "type": "string" + }, + "pscServiceAttachmentUri": { + "description": "URI of the PSC service attachment this forwarding rule targets (if applicable).", + "type": "string" + }, + "region": { + "description": "Region of the forwarding rule. Set only for regional forwarding rules.", "type": "string" }, "target": { @@ -1573,7 +1601,7 @@ "type": "string" }, "uri": { - "description": "URI of a Compute Engine forwarding rule.", + "description": "URI of the forwarding rule.", "type": "string" }, "vip": { @@ -2487,6 +2515,17 @@ }, "type": "object" }, + "ServerlessNegInfo": { + "description": "For display only. Metadata associated with the serverless network endpoint group backend.", + "id": "ServerlessNegInfo", + "properties": { + "negUri": { + "description": "URI of the serverless network endpoint group.", + "type": "string" + } + }, + "type": "object" + }, "SetIamPolicyRequest": { "description": "Request message for `SetIamPolicy` method.", "id": "SetIamPolicyRequest", @@ -2627,6 +2666,10 @@ "$ref": "RouteInfo", "description": "Display information of a Compute Engine route." }, + "serverlessNeg": { + "$ref": "ServerlessNegInfo", + "description": "Display information of a Serverless network endpoint group backend. Used only for return traces." + }, "state": { "description": "Each step is in one of the pre-defined states.", "enum": [ @@ -2642,6 +2685,7 @@ "START_FROM_CLOUD_RUN_REVISION", "START_FROM_STORAGE_BUCKET", "START_FROM_PSC_PUBLISHED_SERVICE", + "START_FROM_SERVERLESS_NEG", "APPLY_INGRESS_FIREWALL_RULE", "APPLY_EGRESS_FIREWALL_RULE", "APPLY_ROUTE", @@ -2682,6 +2726,7 @@ false, false, false, + false, true, true, false, @@ -2708,6 +2753,7 @@ "Initial state: packet originating from a Cloud Run revision. A CloudRunRevisionInfo is populated with starting revision information.", "Initial state: packet originating from a Storage Bucket. Used only for return traces. The storage_bucket information is populated.", "Initial state: packet originating from a published service that uses Private Service Connect. Used only for return traces.", + "Initial state: packet originating from a serverless network endpoint group backend. Used only for return traces. The serverless_neg information is populated.", "Config checking state: verify ingress firewall rule.", "Config checking state: verify egress firewall rule.", "Config checking state: verify route.", diff --git a/networkmanagement/v1beta1/networkmanagement-gen.go b/networkmanagement/v1beta1/networkmanagement-gen.go index acc55e0ae26..d6a7b4fae92 100644 --- a/networkmanagement/v1beta1/networkmanagement-gen.go +++ b/networkmanagement/v1beta1/networkmanagement-gen.go @@ -773,8 +773,14 @@ func (s *ConnectivityTest) MarshalJSON() ([]byte, error) { type DeliverInfo struct { // IpAddress: IP address of the target (if applicable). IpAddress string `json:"ipAddress,omitempty"` + // PscGoogleApiTarget: PSC Google API target the packet is delivered to (if + // applicable). + PscGoogleApiTarget string `json:"pscGoogleApiTarget,omitempty"` // ResourceUri: URI of the resource that the packet is delivered to. ResourceUri string `json:"resourceUri,omitempty"` + // StorageBucket: Name of the Cloud Storage Bucket the packet is delivered to + // (if applicable). + StorageBucket string `json:"storageBucket,omitempty"` // Target: Target type where the packet is delivered to. // // Possible values: @@ -788,7 +794,7 @@ type DeliverInfo struct { // Service // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect- // services). - // "PSC_GOOGLE_API" - Target is all Google APIs that use [Private Service + // "PSC_GOOGLE_API" - Target is Google APIs that use [Private Service // Connect](https://cloud.google.com/vpc/docs/configure-private-service-connect- // apis). // "PSC_VPC_SC" - Target is a VPC-SC that uses [Private Service @@ -804,6 +810,8 @@ type DeliverInfo struct { // for return traces. // "CLOUD_RUN_REVISION" - Target is a Cloud Run revision. Used only for // return traces. + // "GOOGLE_MANAGED_SERVICE" - Target is a Google-managed service. Used only + // for return traces. Target string `json:"target,omitempty"` // ForceSendFields is a list of field names (e.g. "IpAddress") to // unconditionally include in API requests. By default, fields with empty or @@ -983,6 +991,9 @@ type DropInfo struct { // "CLOUD_NAT_NO_ADDRESSES" - Packet sent to Cloud Nat without active NAT // IPs. // "ROUTING_LOOP" - Packet is stuck in a routing loop. + // "DROPPED_INSIDE_GOOGLE_MANAGED_SERVICE" - Packet is dropped due to an + // unspecified reason inside a Google-managed service. Used only for return + // traces. Cause string `json:"cause,omitempty"` // DestinationIp: Destination IP address of the dropped packet (if relevant). DestinationIp string `json:"destinationIp,omitempty"` @@ -1358,19 +1369,32 @@ func (s *ForwardInfo) MarshalJSON() ([]byte, error) { // ForwardingRuleInfo: For display only. Metadata associated with a Compute // Engine forwarding rule. type ForwardingRuleInfo struct { - // DisplayName: Name of a Compute Engine forwarding rule. + // DisplayName: Name of the forwarding rule. DisplayName string `json:"displayName,omitempty"` + // LoadBalancerName: Name of the load balancer the forwarding rule belongs to. + // Empty for forwarding rules not related to load balancers (like PSC + // forwarding rules). + LoadBalancerName string `json:"loadBalancerName,omitempty"` // MatchedPortRange: Port range defined in the forwarding rule that matches the - // test. + // packet. MatchedPortRange string `json:"matchedPortRange,omitempty"` // MatchedProtocol: Protocol defined in the forwarding rule that matches the - // test. + // packet. MatchedProtocol string `json:"matchedProtocol,omitempty"` - // NetworkUri: Network URI. Only valid for Internal Load Balancer. + // NetworkUri: Network URI. NetworkUri string `json:"networkUri,omitempty"` + // PscGoogleApiTarget: PSC Google API target this forwarding rule targets (if + // applicable). + PscGoogleApiTarget string `json:"pscGoogleApiTarget,omitempty"` + // PscServiceAttachmentUri: URI of the PSC service attachment this forwarding + // rule targets (if applicable). + PscServiceAttachmentUri string `json:"pscServiceAttachmentUri,omitempty"` + // Region: Region of the forwarding rule. Set only for regional forwarding + // rules. + Region string `json:"region,omitempty"` // Target: Target type of the forwarding rule. Target string `json:"target,omitempty"` - // Uri: URI of a Compute Engine forwarding rule. + // Uri: URI of the forwarding rule. Uri string `json:"uri,omitempty"` // Vip: VIP of the forwarding rule. Vip string `json:"vip,omitempty"` @@ -2363,6 +2387,29 @@ func (s *RouteInfo) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// ServerlessNegInfo: For display only. Metadata associated with the serverless +// network endpoint group backend. +type ServerlessNegInfo struct { + // NegUri: URI of the serverless network endpoint group. + NegUri string `json:"negUri,omitempty"` + // ForceSendFields is a list of field names (e.g. "NegUri") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "NegUri") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *ServerlessNegInfo) MarshalJSON() ([]byte, error) { + type NoMethod ServerlessNegInfo + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // SetIamPolicyRequest: Request message for `SetIamPolicy` method. type SetIamPolicyRequest struct { // Policy: REQUIRED: The complete policy to be applied to the `resource`. The @@ -2482,6 +2529,9 @@ type Step struct { ProxyConnection *ProxyConnectionInfo `json:"proxyConnection,omitempty"` // Route: Display information of a Compute Engine route. Route *RouteInfo `json:"route,omitempty"` + // ServerlessNeg: Display information of a Serverless network endpoint group + // backend. Used only for return traces. + ServerlessNeg *ServerlessNegInfo `json:"serverlessNeg,omitempty"` // State: Each step is in one of the pre-defined states. // // Possible values: @@ -2518,6 +2568,9 @@ type Step struct { // "START_FROM_PSC_PUBLISHED_SERVICE" - Initial state: packet originating // from a published service that uses Private Service Connect. Used only for // return traces. + // "START_FROM_SERVERLESS_NEG" - Initial state: packet originating from a + // serverless network endpoint group backend. Used only for return traces. The + // serverless_neg information is populated. // "APPLY_INGRESS_FIREWALL_RULE" - Config checking state: verify ingress // firewall rule. // "APPLY_EGRESS_FIREWALL_RULE" - Config checking state: verify egress diff --git a/networkservices/v1/networkservices-api.json b/networkservices/v1/networkservices-api.json index e6415211d93..5f99b9e26ee 100644 --- a/networkservices/v1/networkservices-api.json +++ b/networkservices/v1/networkservices-api.json @@ -2756,7 +2756,7 @@ } } }, - "revision": "20240506", + "revision": "20240515", "rootUrl": "https://networkservices.googleapis.com/", "schemas": { "AuditConfig": { @@ -3036,7 +3036,7 @@ "type": "string" }, "supportedEvents": { - "description": "Optional. A set of events during request or response processing for which this extension is called. This field is required for the `LbTrafficExtension` resource. It's not relevant for the `LbRouteExtension` resource.", + "description": "Optional. A set of events during request or response processing for which this extension is called. This field is required for the `LbTrafficExtension` resource. It must not be set for the `LbRouteExtension` resource.", "items": { "enum": [ "EVENT_TYPE_UNSPECIFIED", @@ -4108,6 +4108,14 @@ ], "type": "string" }, + "metadata": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. The metadata provided here will be included as part of the `metadata_context` (of type `google.protobuf.Struct`) in the `ProcessingRequest` message sent to the extension server. The metadata will be available under the namespace `com.google.lb_route_extension.`. The following variables are supported in the metadata Struct: `{forwarding_rule_id}` - substituted with the forwarding rule's fully qualified resource name.", + "type": "object" + }, "name": { "description": "Required. Identifier. Name of the `LbRouteExtension` resource in the following format: `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extension}`.", "type": "string" @@ -4170,6 +4178,14 @@ ], "type": "string" }, + "metadata": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. The metadata provided here will be included in the `ProcessingRequest.metadata_context.filter_metadata` map field. The metadata will be available under the key `com.google.lb_traffic_extension.`. The following variables are supported in the metadata: `{forwarding_rule_id}` - substituted with the forwarding rule's fully qualified resource name.", + "type": "object" + }, "name": { "description": "Required. Identifier. Name of the `LbTrafficExtension` resource in the following format: `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_extension}`.", "type": "string" diff --git a/networkservices/v1/networkservices-gen.go b/networkservices/v1/networkservices-gen.go index 2b719a947a5..2493b370ca6 100644 --- a/networkservices/v1/networkservices-gen.go +++ b/networkservices/v1/networkservices-gen.go @@ -836,7 +836,7 @@ type ExtensionChainExtension struct { Service string `json:"service,omitempty"` // SupportedEvents: Optional. A set of events during request or response // processing for which this extension is called. This field is required for - // the `LbTrafficExtension` resource. It's not relevant for the + // the `LbTrafficExtension` resource. It must not be set for the // `LbRouteExtension` resource. // // Possible values: @@ -2234,6 +2234,14 @@ type LbRouteExtension struct { // "EXTERNAL_MANAGED" - Signifies that this is used for External Managed // HTTP(S) Load Balancing. LoadBalancingScheme string `json:"loadBalancingScheme,omitempty"` + // Metadata: Optional. The metadata provided here will be included as part of + // the `metadata_context` (of type `google.protobuf.Struct`) in the + // `ProcessingRequest` message sent to the extension server. The metadata will + // be available under the namespace `com.google.lb_route_extension.`. The + // following variables are supported in the metadata Struct: + // `{forwarding_rule_id}` - substituted with the forwarding rule's fully + // qualified resource name. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` // Name: Required. Identifier. Name of the `LbRouteExtension` resource in the // following format: // `projects/{project}/locations/{location}/lbRouteExtensions/{lb_route_extensio @@ -2301,6 +2309,12 @@ type LbTrafficExtension struct { // "EXTERNAL_MANAGED" - Signifies that this is used for External Managed // HTTP(S) Load Balancing. LoadBalancingScheme string `json:"loadBalancingScheme,omitempty"` + // Metadata: Optional. The metadata provided here will be included in the + // `ProcessingRequest.metadata_context.filter_metadata` map field. The metadata + // will be available under the key `com.google.lb_traffic_extension.`. The + // following variables are supported in the metadata: `{forwarding_rule_id}` - + // substituted with the forwarding rule's fully qualified resource name. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` // Name: Required. Identifier. Name of the `LbTrafficExtension` resource in the // following format: // `projects/{project}/locations/{location}/lbTrafficExtensions/{lb_traffic_exte diff --git a/sqladmin/v1/sqladmin-api.json b/sqladmin/v1/sqladmin-api.json index 99e45f69a6e..b6f6fc5b802 100644 --- a/sqladmin/v1/sqladmin-api.json +++ b/sqladmin/v1/sqladmin-api.json @@ -2267,7 +2267,7 @@ } } }, - "revision": "20240507", + "revision": "20240521", "rootUrl": "https://sqladmin.googleapis.com/", "schemas": { "AclEntry": { @@ -2363,6 +2363,25 @@ }, "type": "object" }, + "AvailableDatabaseVersion": { + "description": "An available database version. It can be a major or a minor version.", + "id": "AvailableDatabaseVersion", + "properties": { + "displayName": { + "description": "The database version's display name.", + "type": "string" + }, + "majorVersion": { + "description": "The version's major version name.", + "type": "string" + }, + "name": { + "description": "The database version name. For MySQL 8.0, this string provides the database major and minor version.", + "type": "string" + } + }, + "type": "object" + }, "BackupConfiguration": { "description": "Database instance backup configuration.", "id": "BackupConfiguration", @@ -2696,7 +2715,7 @@ "type": "string" }, "preferredZone": { - "description": "Optional. (Point-in-time recovery for PostgreSQL only) Clone to an instance in the specified zone. If no zone is specified, clone to the same zone as the source instance.", + "description": "Optional. Copy clone and point-in-time recovery clone of an instance to the specified zone. If no zone is specified, clone to the same primary zone as the source instance. This field applies to all DB types.", "type": "string" } }, @@ -2747,6 +2766,7 @@ "POSTGRES_13", "POSTGRES_14", "POSTGRES_15", + "POSTGRES_16", "MYSQL_8_0", "MYSQL_8_0_18", "MYSQL_8_0_26", @@ -2765,6 +2785,7 @@ "MYSQL_8_0_39", "MYSQL_8_0_40", "MYSQL_8_4", + "MYSQL_8_4_0", "SQLSERVER_2019_STANDARD", "SQLSERVER_2019_ENTERPRISE", "SQLSERVER_2019_EXPRESS", @@ -2796,6 +2817,7 @@ false, false, false, + false, true, false, false, @@ -2816,6 +2838,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -2835,6 +2858,7 @@ "The database version is PostgreSQL 13.", "The database version is PostgreSQL 14.", "The database version is PostgreSQL 15.", + "The database version is PostgreSQL 16.", "The database version is MySQL 8.", "The database major version is MySQL 8.0 and the minor version is 18.", "The database major version is MySQL 8.0 and the minor version is 26.", @@ -2853,6 +2877,7 @@ "The database major version is MySQL 8.0 and the minor version is 39.", "The database major version is MySQL 8.0 and the minor version is 40.", "The database version is MySQL 8.4.", + "The database version is MySQL 8.4 and the patch version is 0.", "The database version is SQL Server 2019 Standard.", "The database version is SQL Server 2019 Enterprise.", "The database version is SQL Server 2019 Express.", @@ -3036,6 +3061,7 @@ "POSTGRES_13", "POSTGRES_14", "POSTGRES_15", + "POSTGRES_16", "MYSQL_8_0", "MYSQL_8_0_18", "MYSQL_8_0_26", @@ -3054,6 +3080,7 @@ "MYSQL_8_0_39", "MYSQL_8_0_40", "MYSQL_8_4", + "MYSQL_8_4_0", "SQLSERVER_2019_STANDARD", "SQLSERVER_2019_ENTERPRISE", "SQLSERVER_2019_EXPRESS", @@ -3085,6 +3112,7 @@ false, false, false, + false, true, false, false, @@ -3105,6 +3133,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -3124,6 +3153,7 @@ "The database version is PostgreSQL 13.", "The database version is PostgreSQL 14.", "The database version is PostgreSQL 15.", + "The database version is PostgreSQL 16.", "The database version is MySQL 8.", "The database major version is MySQL 8.0 and the minor version is 18.", "The database major version is MySQL 8.0 and the minor version is 26.", @@ -3142,6 +3172,7 @@ "The database major version is MySQL 8.0 and the minor version is 39.", "The database major version is MySQL 8.0 and the minor version is 40.", "The database version is MySQL 8.4.", + "The database version is MySQL 8.4 and the patch version is 0.", "The database version is SQL Server 2019 Standard.", "The database version is SQL Server 2019 Enterprise.", "The database version is SQL Server 2019 Express.", @@ -3384,6 +3415,14 @@ }, "type": "array" }, + "upgradableDatabaseVersions": { + "description": "Output only. All database versions that are available for upgrade.", + "items": { + "$ref": "AvailableDatabaseVersion" + }, + "readOnly": true, + "type": "array" + }, "writeEndpoint": { "description": "Output only. The dns name of the primary instance in a replication group.", "readOnly": true, @@ -3753,6 +3792,7 @@ "POSTGRES_13", "POSTGRES_14", "POSTGRES_15", + "POSTGRES_16", "MYSQL_8_0", "MYSQL_8_0_18", "MYSQL_8_0_26", @@ -3771,6 +3811,7 @@ "MYSQL_8_0_39", "MYSQL_8_0_40", "MYSQL_8_4", + "MYSQL_8_4_0", "SQLSERVER_2019_STANDARD", "SQLSERVER_2019_ENTERPRISE", "SQLSERVER_2019_EXPRESS", @@ -3802,6 +3843,7 @@ false, false, false, + false, true, false, false, @@ -3822,6 +3864,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -3841,6 +3884,7 @@ "The database version is PostgreSQL 13.", "The database version is PostgreSQL 14.", "The database version is PostgreSQL 15.", + "The database version is PostgreSQL 16.", "The database version is MySQL 8.", "The database major version is MySQL 8.0 and the minor version is 18.", "The database major version is MySQL 8.0 and the minor version is 26.", @@ -3859,6 +3903,7 @@ "The database major version is MySQL 8.0 and the minor version is 39.", "The database major version is MySQL 8.0 and the minor version is 40.", "The database version is MySQL 8.4.", + "The database version is MySQL 8.4 and the patch version is 0.", "The database version is SQL Server 2019 Standard.", "The database version is SQL Server 2019 Enterprise.", "The database version is SQL Server 2019 Express.", @@ -5213,7 +5258,7 @@ }, "advancedMachineFeatures": { "$ref": "AdvancedMachineFeatures", - "description": "Specifies advance machine configuration for the instance relevant only for SQL Server." + "description": "Specifies advanced machine configuration for the instances relevant only for SQL Server." }, "authorizedGaeApplications": { "deprecated": true, diff --git a/sqladmin/v1/sqladmin-gen.go b/sqladmin/v1/sqladmin-gen.go index 7a7df792cdc..483f284b3b8 100644 --- a/sqladmin/v1/sqladmin-gen.go +++ b/sqladmin/v1/sqladmin-gen.go @@ -414,6 +414,34 @@ func (s *ApiWarning) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// AvailableDatabaseVersion: An available database version. It can be a major +// or a minor version. +type AvailableDatabaseVersion struct { + // DisplayName: The database version's display name. + DisplayName string `json:"displayName,omitempty"` + // MajorVersion: The version's major version name. + MajorVersion string `json:"majorVersion,omitempty"` + // Name: The database version name. For MySQL 8.0, this string provides the + // database major and minor version. + Name string `json:"name,omitempty"` + // ForceSendFields is a list of field names (e.g. "DisplayName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DisplayName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *AvailableDatabaseVersion) MarshalJSON() ([]byte, error) { + type NoMethod AvailableDatabaseVersion + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // BackupConfiguration: Database instance backup configuration. type BackupConfiguration struct { // BackupRetentionSettings: Backup retention settings. @@ -739,9 +767,9 @@ type CloneContext struct { // PointInTime: Timestamp, if specified, identifies the time to which the // source instance is cloned. PointInTime string `json:"pointInTime,omitempty"` - // PreferredZone: Optional. (Point-in-time recovery for PostgreSQL only) Clone - // to an instance in the specified zone. If no zone is specified, clone to the - // same zone as the source instance. + // PreferredZone: Optional. Copy clone and point-in-time recovery clone of an + // instance to the specified zone. If no zone is specified, clone to the same + // primary zone as the source instance. This field applies to all DB types. PreferredZone string `json:"preferredZone,omitempty"` // ForceSendFields is a list of field names (e.g. "AllocatedIpRange") to // unconditionally include in API requests. By default, fields with empty or @@ -805,6 +833,7 @@ type ConnectSettings struct { // "POSTGRES_13" - The database version is PostgreSQL 13. // "POSTGRES_14" - The database version is PostgreSQL 14. // "POSTGRES_15" - The database version is PostgreSQL 15. + // "POSTGRES_16" - The database version is PostgreSQL 16. // "MYSQL_8_0" - The database version is MySQL 8. // "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor // version is 18. @@ -839,6 +868,8 @@ type ConnectSettings struct { // "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor // version is 40. // "MYSQL_8_4" - The database version is MySQL 8.4. + // "MYSQL_8_4_0" - The database version is MySQL 8.4 and the patch version is + // 0. // "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019 // Standard. // "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019 @@ -1041,6 +1072,7 @@ type DatabaseInstance struct { // "POSTGRES_13" - The database version is PostgreSQL 13. // "POSTGRES_14" - The database version is PostgreSQL 14. // "POSTGRES_15" - The database version is PostgreSQL 15. + // "POSTGRES_16" - The database version is PostgreSQL 16. // "MYSQL_8_0" - The database version is MySQL 8. // "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor // version is 18. @@ -1075,6 +1107,8 @@ type DatabaseInstance struct { // "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor // version is 40. // "MYSQL_8_4" - The database version is MySQL 8.4. + // "MYSQL_8_4_0" - The database version is MySQL 8.4 and the patch version is + // 0. // "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019 // Standard. // "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019 @@ -1225,6 +1259,9 @@ type DatabaseInstance struct { // "KMS_KEY_ISSUE" - The KMS key used by the instance is either revoked or // denied access to SuspensionReason []string `json:"suspensionReason,omitempty"` + // UpgradableDatabaseVersions: Output only. All database versions that are + // available for upgrade. + UpgradableDatabaseVersions []*AvailableDatabaseVersion `json:"upgradableDatabaseVersions,omitempty"` // WriteEndpoint: Output only. The dns name of the primary instance in a // replication group. WriteEndpoint string `json:"writeEndpoint,omitempty"` @@ -1777,6 +1814,7 @@ type Flag struct { // "POSTGRES_13" - The database version is PostgreSQL 13. // "POSTGRES_14" - The database version is PostgreSQL 14. // "POSTGRES_15" - The database version is PostgreSQL 15. + // "POSTGRES_16" - The database version is PostgreSQL 16. // "MYSQL_8_0" - The database version is MySQL 8. // "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor // version is 18. @@ -1811,6 +1849,8 @@ type Flag struct { // "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor // version is 40. // "MYSQL_8_4" - The database version is MySQL 8.4. + // "MYSQL_8_4_0" - The database version is MySQL 8.4 and the patch version is + // 0. // "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019 // Standard. // "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019 @@ -3454,8 +3494,8 @@ type Settings struct { // ActiveDirectoryConfig: Active Directory configuration, relevant only for // Cloud SQL for SQL Server. ActiveDirectoryConfig *SqlActiveDirectoryConfig `json:"activeDirectoryConfig,omitempty"` - // AdvancedMachineFeatures: Specifies advance machine configuration for the - // instance relevant only for SQL Server. + // AdvancedMachineFeatures: Specifies advanced machine configuration for the + // instances relevant only for SQL Server. AdvancedMachineFeatures *AdvancedMachineFeatures `json:"advancedMachineFeatures,omitempty"` // AuthorizedGaeApplications: The App Engine app IDs that can access this // instance. (Deprecated) Applied to First Generation instances only. diff --git a/sqladmin/v1beta4/sqladmin-api.json b/sqladmin/v1beta4/sqladmin-api.json index 24e082697e3..5f7e0cbb6ab 100644 --- a/sqladmin/v1beta4/sqladmin-api.json +++ b/sqladmin/v1beta4/sqladmin-api.json @@ -2267,7 +2267,7 @@ } } }, - "revision": "20240507", + "revision": "20240521", "rootUrl": "https://sqladmin.googleapis.com/", "schemas": { "AclEntry": { @@ -2363,6 +2363,25 @@ }, "type": "object" }, + "AvailableDatabaseVersion": { + "description": "An available database version. It can be a major or a minor version.", + "id": "AvailableDatabaseVersion", + "properties": { + "displayName": { + "description": "The database version's display name.", + "type": "string" + }, + "majorVersion": { + "description": "The version's major version name.", + "type": "string" + }, + "name": { + "description": "The database version name. For MySQL 8.0, this string provides the database major and minor version.", + "type": "string" + } + }, + "type": "object" + }, "BackupConfiguration": { "description": "Database instance backup configuration.", "id": "BackupConfiguration", @@ -2695,8 +2714,12 @@ "format": "google-datetime", "type": "string" }, + "preferredSecondaryZone": { + "description": "Optional. Copy clone and point-in-time recovery clone of a regional instance in the specified zones. If not specified, clone to the same secondary zone as the source instance. This value cannot be the same as the preferred_zone field.", + "type": "string" + }, "preferredZone": { - "description": "Optional. (Point-in-time recovery for PostgreSQL only) Clone to an instance in the specified zone. If no zone is specified, clone to the same zone as the source instance.", + "description": "Optional. Copy clone and point-in-time recovery clone of an instance to the specified zone. If no zone is specified, clone to the same primary zone as the source instance.", "type": "string" } }, @@ -2747,6 +2770,7 @@ "POSTGRES_13", "POSTGRES_14", "POSTGRES_15", + "POSTGRES_16", "MYSQL_8_0", "MYSQL_8_0_18", "MYSQL_8_0_26", @@ -2765,6 +2789,7 @@ "MYSQL_8_0_39", "MYSQL_8_0_40", "MYSQL_8_4", + "MYSQL_8_4_0", "SQLSERVER_2019_STANDARD", "SQLSERVER_2019_ENTERPRISE", "SQLSERVER_2019_EXPRESS", @@ -2796,6 +2821,7 @@ false, false, false, + false, true, false, false, @@ -2816,6 +2842,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -2835,6 +2862,7 @@ "The database version is PostgreSQL 13.", "The database version is PostgreSQL 14.", "The database version is PostgreSQL 15.", + "The database version is PostgreSQL 16.", "The database version is MySQL 8.", "The database major version is MySQL 8.0 and the minor version is 18.", "The database major version is MySQL 8.0 and the minor version is 26.", @@ -2853,6 +2881,7 @@ "The database major version is MySQL 8.0 and the minor version is 39.", "The database major version is MySQL 8.0 and the minor version is 40.", "The database version is MySQL 8.4.", + "The database version is MySQL 8.4 and the patch version is 0.", "The database version is SQL Server 2019 Standard.", "The database version is SQL Server 2019 Enterprise.", "The database version is SQL Server 2019 Express.", @@ -3036,6 +3065,7 @@ "POSTGRES_13", "POSTGRES_14", "POSTGRES_15", + "POSTGRES_16", "MYSQL_8_0", "MYSQL_8_0_18", "MYSQL_8_0_26", @@ -3054,6 +3084,7 @@ "MYSQL_8_0_39", "MYSQL_8_0_40", "MYSQL_8_4", + "MYSQL_8_4_0", "SQLSERVER_2019_STANDARD", "SQLSERVER_2019_ENTERPRISE", "SQLSERVER_2019_EXPRESS", @@ -3085,6 +3116,7 @@ false, false, false, + false, true, false, false, @@ -3105,6 +3137,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -3124,6 +3157,7 @@ "The database version is PostgreSQL 13.", "The database version is PostgreSQL 14.", "The database version is PostgreSQL 15.", + "The database version is PostgreSQL 16.", "The database version is MySQL 8.", "The database major version is MySQL 8.0 and the minor version is 18.", "The database major version is MySQL 8.0 and the minor version is 26.", @@ -3142,6 +3176,7 @@ "The database major version is MySQL 8.0 and the minor version is 39.", "The database major version is MySQL 8.0 and the minor version is 40.", "The database version is MySQL 8.4.", + "The database version is MySQL 8.4 and the patch version is 0.", "The database version is SQL Server 2019 Standard.", "The database version is SQL Server 2019 Enterprise.", "The database version is SQL Server 2019 Express.", @@ -3385,6 +3420,14 @@ }, "type": "array" }, + "upgradableDatabaseVersions": { + "description": "Output only. All database versions that are available for upgrade.", + "items": { + "$ref": "AvailableDatabaseVersion" + }, + "readOnly": true, + "type": "array" + }, "writeEndpoint": { "description": "Output only. The dns name of the primary instance in a replication group.", "readOnly": true, @@ -3754,6 +3797,7 @@ "POSTGRES_13", "POSTGRES_14", "POSTGRES_15", + "POSTGRES_16", "MYSQL_8_0", "MYSQL_8_0_18", "MYSQL_8_0_26", @@ -3772,6 +3816,7 @@ "MYSQL_8_0_39", "MYSQL_8_0_40", "MYSQL_8_4", + "MYSQL_8_4_0", "SQLSERVER_2019_STANDARD", "SQLSERVER_2019_ENTERPRISE", "SQLSERVER_2019_EXPRESS", @@ -3803,6 +3848,7 @@ false, false, false, + false, true, false, false, @@ -3823,6 +3869,7 @@ false, false, false, + false, false ], "enumDescriptions": [ @@ -3842,6 +3889,7 @@ "The database version is PostgreSQL 13.", "The database version is PostgreSQL 14.", "The database version is PostgreSQL 15.", + "The database version is PostgreSQL 16.", "The database version is MySQL 8.", "The database major version is MySQL 8.0 and the minor version is 18.", "The database major version is MySQL 8.0 and the minor version is 26.", @@ -3860,6 +3908,7 @@ "The database major version is MySQL 8.0 and the minor version is 39.", "The database major version is MySQL 8.0 and the minor version is 40.", "The database version is MySQL 8.4.", + "The database version is MySQL 8.4 and the patch version is 0.", "The database version is SQL Server 2019 Standard.", "The database version is SQL Server 2019 Enterprise.", "The database version is SQL Server 2019 Express.", @@ -5214,7 +5263,7 @@ }, "advancedMachineFeatures": { "$ref": "AdvancedMachineFeatures", - "description": "Specifies advance machine configuration for the instance relevant only for SQL Server." + "description": "Specifies advanced machine configuration for the instances relevant only for SQL Server." }, "authorizedGaeApplications": { "deprecated": true, diff --git a/sqladmin/v1beta4/sqladmin-gen.go b/sqladmin/v1beta4/sqladmin-gen.go index 1c9f4ce7802..f418ebba994 100644 --- a/sqladmin/v1beta4/sqladmin-gen.go +++ b/sqladmin/v1beta4/sqladmin-gen.go @@ -414,6 +414,34 @@ func (s *ApiWarning) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// AvailableDatabaseVersion: An available database version. It can be a major +// or a minor version. +type AvailableDatabaseVersion struct { + // DisplayName: The database version's display name. + DisplayName string `json:"displayName,omitempty"` + // MajorVersion: The version's major version name. + MajorVersion string `json:"majorVersion,omitempty"` + // Name: The database version name. For MySQL 8.0, this string provides the + // database major and minor version. + Name string `json:"name,omitempty"` + // ForceSendFields is a list of field names (e.g. "DisplayName") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "DisplayName") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *AvailableDatabaseVersion) MarshalJSON() ([]byte, error) { + type NoMethod AvailableDatabaseVersion + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // BackupConfiguration: Database instance backup configuration. type BackupConfiguration struct { // BackupRetentionSettings: Backup retention settings. @@ -738,9 +766,14 @@ type CloneContext struct { // PointInTime: Timestamp, if specified, identifies the time to which the // source instance is cloned. PointInTime string `json:"pointInTime,omitempty"` - // PreferredZone: Optional. (Point-in-time recovery for PostgreSQL only) Clone - // to an instance in the specified zone. If no zone is specified, clone to the - // same zone as the source instance. + // PreferredSecondaryZone: Optional. Copy clone and point-in-time recovery + // clone of a regional instance in the specified zones. If not specified, clone + // to the same secondary zone as the source instance. This value cannot be the + // same as the preferred_zone field. + PreferredSecondaryZone string `json:"preferredSecondaryZone,omitempty"` + // PreferredZone: Optional. Copy clone and point-in-time recovery clone of an + // instance to the specified zone. If no zone is specified, clone to the same + // primary zone as the source instance. PreferredZone string `json:"preferredZone,omitempty"` // ForceSendFields is a list of field names (e.g. "AllocatedIpRange") to // unconditionally include in API requests. By default, fields with empty or @@ -804,6 +837,7 @@ type ConnectSettings struct { // "POSTGRES_13" - The database version is PostgreSQL 13. // "POSTGRES_14" - The database version is PostgreSQL 14. // "POSTGRES_15" - The database version is PostgreSQL 15. + // "POSTGRES_16" - The database version is PostgreSQL 16. // "MYSQL_8_0" - The database version is MySQL 8. // "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor // version is 18. @@ -838,6 +872,8 @@ type ConnectSettings struct { // "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor // version is 40. // "MYSQL_8_4" - The database version is MySQL 8.4. + // "MYSQL_8_4_0" - The database version is MySQL 8.4 and the patch version is + // 0. // "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019 // Standard. // "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019 @@ -1040,6 +1076,7 @@ type DatabaseInstance struct { // "POSTGRES_13" - The database version is PostgreSQL 13. // "POSTGRES_14" - The database version is PostgreSQL 14. // "POSTGRES_15" - The database version is PostgreSQL 15. + // "POSTGRES_16" - The database version is PostgreSQL 16. // "MYSQL_8_0" - The database version is MySQL 8. // "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor // version is 18. @@ -1074,6 +1111,8 @@ type DatabaseInstance struct { // "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor // version is 40. // "MYSQL_8_4" - The database version is MySQL 8.4. + // "MYSQL_8_4_0" - The database version is MySQL 8.4 and the patch version is + // 0. // "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019 // Standard. // "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019 @@ -1226,6 +1265,9 @@ type DatabaseInstance struct { // "KMS_KEY_ISSUE" - The KMS key used by the instance is either revoked or // denied access to SuspensionReason []string `json:"suspensionReason,omitempty"` + // UpgradableDatabaseVersions: Output only. All database versions that are + // available for upgrade. + UpgradableDatabaseVersions []*AvailableDatabaseVersion `json:"upgradableDatabaseVersions,omitempty"` // WriteEndpoint: Output only. The dns name of the primary instance in a // replication group. WriteEndpoint string `json:"writeEndpoint,omitempty"` @@ -1778,6 +1820,7 @@ type Flag struct { // "POSTGRES_13" - The database version is PostgreSQL 13. // "POSTGRES_14" - The database version is PostgreSQL 14. // "POSTGRES_15" - The database version is PostgreSQL 15. + // "POSTGRES_16" - The database version is PostgreSQL 16. // "MYSQL_8_0" - The database version is MySQL 8. // "MYSQL_8_0_18" - The database major version is MySQL 8.0 and the minor // version is 18. @@ -1812,6 +1855,8 @@ type Flag struct { // "MYSQL_8_0_40" - The database major version is MySQL 8.0 and the minor // version is 40. // "MYSQL_8_4" - The database version is MySQL 8.4. + // "MYSQL_8_4_0" - The database version is MySQL 8.4 and the patch version is + // 0. // "SQLSERVER_2019_STANDARD" - The database version is SQL Server 2019 // Standard. // "SQLSERVER_2019_ENTERPRISE" - The database version is SQL Server 2019 @@ -3459,8 +3504,8 @@ type Settings struct { // ActiveDirectoryConfig: Active Directory configuration, relevant only for // Cloud SQL for SQL Server. ActiveDirectoryConfig *SqlActiveDirectoryConfig `json:"activeDirectoryConfig,omitempty"` - // AdvancedMachineFeatures: Specifies advance machine configuration for the - // instance relevant only for SQL Server. + // AdvancedMachineFeatures: Specifies advanced machine configuration for the + // instances relevant only for SQL Server. AdvancedMachineFeatures *AdvancedMachineFeatures `json:"advancedMachineFeatures,omitempty"` // AuthorizedGaeApplications: The App Engine app IDs that can access this // instance. (Deprecated) Applied to First Generation instances only. diff --git a/vmmigration/v1alpha1/vmmigration-api.json b/vmmigration/v1alpha1/vmmigration-api.json index 1d253f990ed..b140c9181b8 100644 --- a/vmmigration/v1alpha1/vmmigration-api.json +++ b/vmmigration/v1alpha1/vmmigration-api.json @@ -2220,7 +2220,7 @@ } } }, - "revision": "20240509", + "revision": "20240516", "rootUrl": "https://vmmigration.googleapis.com/", "schemas": { "AccessKeyCredentials": { @@ -5461,7 +5461,7 @@ "A Standard disk type.", "An alternative to SSD persistent disks that balance performance and cost.", "SSD hard disk type.", - "Hyperdusk balanced disk type." + "Hyperdisk balanced disk type." ], "type": "string" }, diff --git a/vmmigration/v1alpha1/vmmigration-gen.go b/vmmigration/v1alpha1/vmmigration-gen.go index 07f9b8403e4..604369f5893 100644 --- a/vmmigration/v1alpha1/vmmigration-gen.go +++ b/vmmigration/v1alpha1/vmmigration-gen.go @@ -3431,7 +3431,7 @@ type TargetVMDetails struct { // "BALANCED" - An alternative to SSD persistent disks that balance // performance and cost. // "SSD" - SSD hard disk type. - // "HYPERDISK_BALANCED" - Hyperdusk balanced disk type. + // "HYPERDISK_BALANCED" - Hyperdisk balanced disk type. DiskType string `json:"diskType,omitempty"` // ExternalIp: The external IP to define in the VM. ExternalIp string `json:"externalIp,omitempty"`